Items tagged with functions

Feed

I'm back from presenting work in the "23rd Conference on Applications of Computer Algebra -2017" . It was a very interesting event. This fifth presentation, about "The Appell doubly hypergeometric functions", describes a very recent project I've been working at Maple, i.e. the very first complete computational implementation of the Appell doubly hypergeometric functions. This work appeared in Maple 2017. These functions have a tremendous potential in that, at the same time, they have a myriad of properties, and include as particular cases most of the existing mathematical language, and so they have obvious applications in integration, differential equations, and applied mathematics all around. I think these will be the functions of this XXI century, analogously to what happened with hypergeometric functions in the previous century.

At the end, there is a link to the presentation worksheet, with which one could open the sections and reproduce the presentation examples.
 

The four double-hypergeometric Appell functions,

a complete implementation in a computer algebra system

 

Edgardo S. Cheb-Terrab

Physics, Differential Equations and Mathematical Functions, Maplesoft

 

Abstract:
The four multi-parameter Appell functions, AppellF1 , AppellF2 , AppellF3  and AppellF4  are doubly hypergeometric functions that include as particular cases the 2F1 hypergeometric  and some cases of the MeijerG  function, and with them most of the known functions of mathematical physics. Appell functions have been popping up with increasing frequency in applications in quantum mechanics, molecular physics, and general relativity. In this talk, a full implementation of these functions in the Maple computer algebra system, including, for the first time, their numerical evaluation over the whole complex plane, is presented, with details about the symbolic and numerical strategies used.

Appell Functions (symbolic)

 

 

The main references:

• 

P. Appel, J.Kamke de Feriet, "Fonctions hypergeometriques et Hyperspheriques", 1926

• 

H. Srivastava, P.W. Karlsson, "Multiple Gaussian Hypergeometric Series", 1985

• 

24 papers in the literature, ranging from 1882 to 2015

 

Definition and Symmetries

   

Polynomial and Singular Cases

   

Single Power Series with Hypergeometric Coefficients

   

Analytic Extension from the Appell Series to the Appell Functions

   

Euler-Type and Contiguity Identities

   

Appell Differential Equations

   

Putting all together

   

Problem: some formulas in the literature are wrong or miss the conditions indicating when are they valid (exchange with the Mathematics director of the DLMF - NIST)

   

Appell Functions (numeric)

 

 

Goals

 

• 

Compute these Appell functions over the whole complex plane

• 

Considering that this is a research problem, implement different methods and flexible optional arguments to allow for:

a) comparison between methods (both performance and correctness),

b) investigation of a single method in different circumstances.

• 

Develop a computational structure that can be reused with other special functions (abstract code and provide the main options), and that could also be translated to C (so: only one numerical implementation, not 100 special function numerical implementations)

Limitation: the Maple original evalf command does not accept optional arguments

 

The cost of numerically evaluating an Appell function

 

• 

If it is a special hypergeometric case, then between 1 to 2 hypergeometric functions

• 

Next simplest case (series/recurrence below) 3 to 4 hypergeometric functions plus adding somewhat large formulas that involve only arithmetic operations up to 20,000 times (frequently less than 100 times)

• 

Next simplest case: the formulas themselves are power series with hypergeometric function coefficients; these cases frequently converge rapidly but may involve the numerical evaluation of up to hundreds of hypergeometric functions to get the value of a single Appell function.

 

Strategy for the numerical evaluation of Appell functions (or other functions ...)

 

 

The numerical evaluation flows orderly according to:

1) check whether it is a singular case

2) check whether it is a special value

3) compute the value using a series derived from a recurrence related to the underlying ODE

4) perform an sum using an infinite sum formula, checking for convergence

5) perform the numerical integration of the ODE underlying the given Appell function

6) perform a sequence of concatenated Taylor series expansions

Examples

   

Series/recurrence

   

Numerical integration of an underlying differential equation (ODEs and dsolve/numeric)

   

Concatenated Taylor series expansions covering the whole complex plane

   

Subproducts

 

Improvements in the numerical evaluation of hypergeometric functions

   

Evalf: an organized structure to implement the numerical evaluation of special functions in general

   

To be done

   


 

Download Appell_Functions.mw   
Download Appell_Functions.pdf

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

I'm back from presenting work in the "23rd Conference on Applications of Computer Algebra -2017" . It was a very interesting event. This fourth presentation, about "The FunctionAdvisor: extending information on mathematical functions with computer algebra algorithms", describes the FunctionAdvisor project at Maple, a project I started working during 1998, where the key idea I am trying to explore is that we do not need to collect a gazillion of formulas but just core blocks of mathematical information surrounded by clouds of algorithms able to derive extended information from them. In this sense this is also unique piece of software: it can derive properties for rather general algebraic expressions, not just well known tabulated functions. The examples illustrate the idea.

At the end, there is a link to the presentation worksheet, with which one could open the sections and reproduce the presentation examples.
 

The FunctionAdvisor: extending information on mathematical functions

with computer algebra algorithms

 

Edgardo S. Cheb-Terrab

Physics, Differential Equations and Mathematical Functions, Maplesoft

 

Abstract:

A shift in paradigm is happening, from: encoding information into a database, to: encoding essential blocks of information together with algorithms within a computer algebra system. Then, the information is not only searchable but can also be recreated in many different ways and actually used to compute. This talk focuses on this shift in paradigm over a real case example: the digitizing of information regarding mathematical functions as the FunctionAdvisor project of the Maple computer algebra system.

The FunctionAdvisor (basic)

   

Beyond the concept of a database

 
  

" Mathematical functions, are defined by algebraic expressions. So consider algebraic expressions in general ..."

Formal power series for algebraic expressions

   

Differential polynomial forms for algebraic expressions

   

Branch cuts for algebraic expressions

   

The nth derivative problem for algebraic expressions

   

Conversion network for mathematical and algebraic expressions

   

References

   


 

Download FunctionAdvisor.mw

Download FunctionAdvisor.pdf

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

Hello

Can Maple compute the weak derivative of piecewise function like

f:=x->piecewise(0<x and x<0.5,x,0.5<x and x<1,1-x,  elsewhere 0);

Many thanks

 

how to convert a^2*b+c to func2(func1(func1(abc[1],abc[1]),abc[2]),abc[3])

when i use custom function func2 to represent plus, func1 to represent multiply

input 3 parameters,

one is a^2*b + c one is [func1, func2] and second is [abc[1],abc[2],abc[3]] corresponding to a, b, c
a^2*b + c = func2(func1(func1(abc[1],abc[1]),abc[2]),abc[3]);

The material below was presented in the "Semantic Representation of Mathematical Knowledge Workshop", February 3-5, 2016 at the Fields Institute, University of Toronto. It shows the approach I used for “digitizing mathematical knowledge" regarding Differential Equations, Special Functions and Solutions to Einstein's equations. While for these areas using databases of information helps (for example textbooks frequently contain these sort of databases), these are areas that, at the same time, are very suitable for using algorithmic mathematical approaches, that result in much richer mathematics than what can be hard-coded into a database. The material also focuses on an interesting cherry-picked collection of Maple functionality, that I think is beautiful, not well know, and seldom focused inter-related as here.

 

 

Digitizing of special functions,

differential equations,

and solutions to Einstein’s equations

within a computer algebra system

 

Edgardo S. Cheb-Terrab

Physics, Differential Equations and Mathematical Functions, Maplesoft

Editor, Computer Physics Communications

 

 

Digitizing (old paradigm)

 

• 

Big amounts of knowledge available to everybody in local machines or through the internet

• 

Take advantage of basic computer functionality, like searching and editing

 

 

Digitizing (new paradigm)

• 

By digitizing mathematical knowledge inside appropriate computational contexts that understand about the topics, one can use the digitized knowledge to automatically generate more and higher level knowledge

 

 

Challenges


1) how to identify, test and organize the key blocks of information,

 

2) how to access it: the interface,

 

3) how to mathematically process it to automatically obtain more information on demand

 

 

 

 

                                           Three examples


Mathematical Functions

 

"Mathematical functions, are defined by algebraic expressions. So consider algebraic expressions in general ..."

The FunctionAdvisor (basic)

 

"Supporting information on definitions, identities, possible simplifications, integral forms, different types of series expansions, and mathematical properties in general"

Examples

   

General description

   

References

   

 

Differential equation representation for generic nonlinear algebraic expressions - their use

 

"Compute differential polynomial forms for arbitrary systems of non-polynomial equations ..."

The Differential Equations representing arbitrary algebraic expresssions

   

Deriving knowledge: ODE solving methods

   

Extending the mathematical language to include the inverse functions

   

Solving non-polynomial algebraic equations by solving polynomial differential equations

   

References

   

 

Branch Cuts of algebraic expressions

 

"Algebraically compute, and visualize, the branch cuts of arbitrary mathematical expressions"

Examples

   

References

   

 

Algebraic expresssions in terms of specified functions

 

"A conversion network for arbitrary mathematical expressions, to rewrite them in terms of different functions in flexible ways"

Examples

   

General description

   

References

   

 

Symbolic differentiation of algebraic expressions

 

"Perform symbolic differentiation by combining different algebraic techniques, including functions of symbolic sequences and Faà di Bruno's formula"

Examples

   

References

   

 

Ordinary Differential Equations

 

"Beyond the concept of a database, classify an arbitrary ODE and suggest solution methods for it"

General description

   

Examples

   

References

   

 

Exact Solutions to Einstein's equations

 

 

Lambda*g[mu, nu]+G[mu, nu] = 8*Pi*T[mu, nu]

 

"The authors of "Exact solutions toEinstein's equations" reviewed more than 4,000 papers containing solutions to Einstein’s equations in the general relativity literature, organized the whole material into chapters according to the physical properties of these solutions. These solutions are key in the area of general relativity, are now all digitized and become alive in a worksheet"


The ability to search the database according to the physical properties of the solutions, their classification, or just by parts of keywords (old paradigm) changes the game.

More important, within a computer algebra system this knowledge becomes alive (new paradigm).

• 

The solutions are turned active by a simple call to one commend, called the g_  spacetime metric.

• 

Everything else gets automatically derived and set on the fly ( Christoffel symbols  , Ricci  and Riemann  tensors orthonormal and null tetrads , etc.)

• 

Almost all of the mathematical operations one can perform on these solutions are implemented as commands in the Physics  and DifferentialGeometry  packages.

• 

All the mathematics within the Maple library are instantly ready to work with these solutions and derived mathematical objects.

 

Finally, in the Maple PDEtools package , we have all the mathematical tools to tackle the equivalence problem around these solutions.

Examples

   

References

   

 

Download:  Digitizing_Mathematical_Information.mw,    Digitizing_Mathematical_Information.pdf

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

This may be a silly question, but does there exist some simple way of (Taylor) expanding an expression of 'small' functions in terms of these functions.

A simple example: Assume that diff(f(x),x) and g(x) are two functions both with range, say, in [-a,+a], where a << 1, and consider the following expression:

sqrt(1 + diff(f(x),x)) * (2 + g(x));

Its expansion to first order in terms of diff(f(x),x) and g(x) should be 2 + diff(f(x),x) + g(x). My problem is that mtaylor does not accept functions as variables to expand on, and I would prefer not to have to substitute back and forth with some 'placeholders'.

Hi! I'm trying to find the way to plot the solution with series representation. I need some help to find the easiest way.

Note: I realized some typing errors, which do not change the question a lot ,and I corrected them.

plot.mw

Typically sets are created like:

A:={a,b,c};

B:={c,q,w,e};

and then you can carryout A union B or B\A

 

what if  you wanted to create the set as

A:={values in some three dimensional space};

B:={volume, based on values taken from A};

Can these relationships be set up in Maple? If so, how? If there are commands that specifically handle these types of sets, what does maple call them?  I've seen the term 'set function' but what might Maple call them?

Note: I am not even sure i 'tagged' this correctly because it I am not sure the proper terms for these functions/sets.

Thanks in advance for any help.

I am working in Document mode, 2D input.  I have doing some complex number evalutions

Lets say I have a complex number Z= 2+3i

when I ask maple for the "abs(Z)" I get the display of "abs(2+3i)" rather than the numberic answer. This occurs with all the complex operation arg, abs, polar conversion, 

polar(abs(2+3*i), argument(2+3*i))   this is from Maple. 

How do I display the numeric value for these functions in my document

 

Thanks Bill

I have entered three functions into Maple and I would like to create a set of all possible two-function and three-function compositions involving the three functions. For instance, for my three functions f(x), g(x) and h(x), the set would contain f(g(x)), g(f(x)), f(g(h(x))), f(f(f(x))), etc. 

I'm also looking for a method that will be generalisable to larger numbers of initial functions than just three.

i'm using maple in a research but i want to add a recursive function h_m(t) in 2 case : if m is integer positive and not, 
la formule est donnée comme suit :  if (mod(m,1) = 0  and m>0) then  h:=proc(m,t)  local  t ;  h[0,t]:=t ;   for  i from -4 to  m  by  2 do  h [m,t]:= h[0, t]-(GAMMA(i/(2)))/(2*GAMMA((i+1)/(2)))*cos(Pi*t)*sin(Pi*t)  od:  fi:  end; 
  if (mod(m,1) = 0  and m>0) then  h:=proc(m,t)  local  t ;  h[0,t]:=t ;   for  i from -4 to  m  by  2 do  h [m,t]:= h[0, t]-(GAMMA(i/(2)))/(2*GAMMA((i+1)/(2)))*cos(Pi*t)*sin(Pi*t)  od:  fi:  end;
and i wanna to know how to programmate a Gaus Hypegeometric function. Thank You

 

I am fairly new to Maple and cannot figure this out.

I'm having some trouble in computing formally the derivatives of
some composite functions

h:= x -> f(g(x)),

imposing conditions on the unknown functions f and g.

For example, I cannot find a way to impose g'(0)=0,
such that the computation of

h'(0)

simply gives 0.

 

Thank you in advance!

This is a stripped down example of something I've been doing. Basically I'm building matrices which I then, using unapply, convert into functions of some variables of t.
.... but found that simplify seems to often not work as i'd wish.
 

restart:
mm:=Matrix([[cos(sqrt(g__1^2)*t), (-I*g__1*sin(sqrt(g__1^2)*t))*(1/sqrt(g__1^2))], [(-I*g__1*sin(sqrt(g__1^2)*t))*(1/sqrt(g__1^2)) ,cos(sqrt(g__1^2)*t)]]);

#great - simplifies as i'd expect:
simplify(mm) assuming g__1::positive;

Do the same thing but when matrix is a function of t
mmFun:=unapply(mm, t);

#the function works - gives what i'd expect
mmFun(3); mmFun(t);

#but now the simplification does not work - why the g__1 in the argument of cos does not get properly simplified?
simplify(mmFun(t)) assuming g__1::positive;

Any ideas if this is a bug? I'm using maple 2015.2 on linux 64-bit.

here is the worksheet: simplify_issue.mw

thanks

EDIT:

as a side note once can sometimes overcome this with mapping simplify  as in :

map(simplify, resultMatrix ) assuming g__1::positive;

but this is not optimal, and sometimes does not work when i first multiply the matrix by say a vector.

 

 

 

Hello,

I would like to create a function from an equation.
I have define 4 functions u[1](t), ..., u[4](t).
From these 4 functions, I would like to define 4 equations. I would like to obtain this result:
Equ[1]:=u[1](t)=L/2*cos(w*t+phi[1])
Equ[2]:=u[2](t)=L/2*cos(w*t+phi[2])
Equ[3]:=u[3](t)=L/2*cos(w*t+phi[3])
Equ[4]:=u[4](t)=L/2*cos(w*t+phi[4])

My code is the following:

for i to 4
do
u[i]:=unapply(L/2*cos(w*t+phi[i]),t);
Equ[i]:='u[i](t)'=u[i](t);
end do;

These lines are not working because the left member is not incremented (u[i](t) stays at each iteration u[i](t))

Generally, how can I transform a function to an equation ?
And, in this specific case, how can I obtain the four equations mentioned above ?

Thanks a lot for your help.

 


The year 2015 has been one with interesting and relevant developments in the MathematicalFunctions  and FunctionAdvisor projects.

• 

Gaps were filled regarding mathematical formulas, with more identities for all of BesselI, BesselK, BesselY, ChebyshevT, ChebyshevU, Chi, Ci, FresnelC, FresnelS, GAMMA(z), HankelH1, HankelH2, InverseJacobiAM, the twelve InverseJacobiPQ for P, Q in [C,D,N,S], KelvinBei, KelvinBer, KelvinKei, KelvinKer, LerchPhi, arcsin, arcsinh, arctan, ln;

• 

Developments happened in the Mathematical function package, to both compute with symbolic sequences and symbolic nth order derivatives of algebraic expressions and functions;

• 

The input FunctionAdvisor(differentiate_rule, mathematical_function) now returns both the first derivative (old behavior) and the nth symbolic derivative (new behavior) of a mathematical function;

• 

A new topic, plot, used as FunctionAdvisor(plot, mathematical_function), now returns 2D and 3D plots for each mathematical function, following the NIST Digital Library of Mathematical Functions;

• 

The previously existing FunctionAdvisor(display, mathematical_function) got redesigned, so that it now displays more information about any mathematical function, and organized into a Section with subsections for each of the different topics, making it simpler to find the information one needs without getting distracted by a myriad of formulas that are not related to what one is looking for.

More mathematics

 

More mathematical knowledge is in place, more identities, differentiation rules of special functions with respect to their parameters, differentiation of functions whose arguments involve symbolic sequences with an indeterminate number of operands, and sum representations for special functions under different conditions on the functions' parameters.

Examples

   

More powerful symbolic differentiation (nth order derivative)

 

Significative developments happened in the computation of the nth order derivative of mathematical functions and algebraic expressions involving them.

Examples

   

Mathematical handling of symbolic sequences

 

Symbolic sequences enter various formulations in mathematics. Their computerized mathematical handling, however, was never implemented - only a representation for them existed in the Maple system. In connection with this, a new subpackage, Sequences , within the MathematicalFunctions package, has been developed.

Examples

   

Visualization of mathematical functions

 

When working with mathematical functions, it is frequently desired to have a rapid glimpse of the shape of the function for some sampled values of their parameters. Following the NIST Digital Library of Mathematical Functions, a new option, plot, has now been implemented.

Examples

   

Section and subsections displaying properties of mathematical functions

 

Until recently, the display of a whole set of mathematical information regarding a function was somehow cumbersome, appearing all together on the screen. That display was and is still available via entering, for instance for the sin function, FunctionAdvisor(sin) . That returns a table of information that can be used programmatically.

With time however, the FunctionAdvisor evolved into a consultation tool, where a better organization of the information being displayed is required, making it simpler to find the information we need without being distracted by a screen full of complicated formulas.

To address this requirement, the FunctionAdvisor now returns the information organized into a Section with subsections, built using the DocumentTools package. This enhances the presentation significantly.

Examples

   

These developments can be installed in Maple 2015 as usual, by downloading the updates (bundled with the Physics and Differential Equations updates) from the Maplesoft R&D webpage for Mathematical Functions and Differential Equations


Download MathematicalFunctionsAndFunctionAdvisor.mw

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

1 2 3 4 5 6 7 Last Page 1 of 40