Ask Your Question

How can one use maxima kummer confluent functions in sage

asked 2012-02-21 05:20:27 +0100 gravatar image

updated 2012-02-21 09:10:33 +0100

kcrisman gravatar image

Hi, here is my piece of code

assume(m, 'integer')
y = function('y', x)
desolve(diff(y,x,2) + 2*x*diff(y,x) - 4*m*y, y,contrib_ode=true,ivar=x)

which yields

[y(x) == k1*kummer_m(-m, 1/2, -x^2) + k2*kummer_u(-m, 1/2, -x^2)]

Internet(Wikipedia) sais that the solutions to this differential equation are the Kummer functions or Confluent_hypergeometric_functions. I now want to know how I can use these functions in sage since they must be defined in maxima.

Thanks in advance

edit retag flag offensive close merge delete


@kcrisman Can you tell me what you did change in my question? gravatar ( 2012-02-22 01:28:34 +0100 )edit

I'm not even sure! You can click "edit" to see the previous versions, but it doesn't give you a thing that shows what has *changed*.

kcrisman gravatar imagekcrisman ( 2012-02-22 12:48:53 +0100 )edit
kcrisman gravatar imagekcrisman ( 2012-02-22 12:50:37 +0100 )edit

Okay, they followed up. If you click on the hyperlink where it says "updated Feb 21", you can see that I added "kummer confluent " to the title of the post. Very hard to find...

kcrisman gravatar imagekcrisman ( 2012-02-27 13:25:28 +0100 )edit

Good, very good indeed. Thanks for the info and the effort. gravatar ( 2012-02-28 03:59:17 +0100 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2012-02-21 09:09:48 +0100

kcrisman gravatar image

The short answer is "we don't have this yet".

The long answer is that we have the kummer_u function implemented (search for hypergeometric_U), but not the kummer_m function in question, and the former only as a numerical function.

You can always access Maxima stuff in a roundabout way, though I couldn't do more than

sage: maxima_calculus('load(contrib_ode)')
sage: maxima_calculus('kummer_m(-1,1/2,-1)')

Note that

The only use of this function is in solutions of ODEs returned by odelin and contrib_ode. The definition and use of this function may change in future releases of Maxima.

and I couldn't get it to evaluate numerically, though maybe it does.

Also, mpmath has both solutions so we could easily implement this symbolically in Sage. I've updated the Trac wiki about this, though my guess is that we will focus first on getting some of the more well-known special functions more fully supported in Sage. You can get the numerics now by doing

sage: mpmath.hyp1f1(2,-1/3,3.25)

Finally, if you want to make your own symbolic function now for this, you can follow some of the examples like our new beta function, which has positive review, and it would be possible to just add your own custom code for this by cutting and pasting.

edit flag offensive delete link more


Thank you for the fast answer. gravatar ( 2012-02-22 01:26:47 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2012-02-21 05:20:27 +0100

Seen: 1,848 times

Last updated: Feb 21 '12