What's the formula used for kummerU?
6 views (last 30 days)
Show older comments
Hi! Thanks for reading!
I need to write a kummer U function for myself.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1357178/image.png)
But it's only for Re(a)>0 and Re(z)>0, while I want the formula for a<0. So I try to read its source code:
function y = kummerU(a,b,x)
%KUMMERU Kummer's confluent hypergeometric U function.
% U = kummerU(a,b,x) computes the value of Kummer's U function
% U = 1/gamma(a) * int(exp(-x*t)*t^(a-1)*(1+t)^(b-a-1),t,0,inf).
%
% Reference:
% [1] Abramowitz, Milton; Stegun, Irene A., eds., "Chapter 13",
% Handbook of Mathematical Functions with Formulas, Graphs, and
% Mathematical Tables, New York: Dover, pp. 504, 1965.
% Copyright 2014 The MathWorks, Inc.
y = sym.useSymForNumeric(@kummerU, a, b, x);
end
There is nothing for me. So does the function
sym.useSymForNumeric(@kummerU, a, b, x)
There is no str "kummerU" inside it.
So how can I find out how matlab realize kummerU with negative a?
Or it would be better if you know the formula for negative a.
Any suggestion is appreciated!
2 Comments
Walter Roberson
on 15 Apr 2023
However there are special cases for negative integer a, in which case the formula becomes a polynomial
Accepted Answer
Walter Roberson
on 15 Apr 2023
Execute
regexprep(char(evalin(symengine, 'expose(kummerU)')) , '\\n', '\n')
to be shown the formula used.
2 Comments
More Answers (0)
See Also
Categories
Find more on Transforms in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!