erfi(z)= -i erf(iz)
Does anyone of a ready implementation in Matlab? My arguments to erfi are
always real, which I *think* means the result of erfi will be real as well.
(Indeed, I suspect that for this class of arguments, erfi could be rewritten
as some combination of other erf functions, but I've spent a long time
combing my math reference books and trying to work it out myself, but my math
skills are just not up to it.)
--
Mike Hucka hu...@umich.edu <URL: http://ai.eecs.umich.edu/people/hucka>
PhD to be, computational models of human visual processing (AI Lab) University
UNIX systems administrator & programmer/analyst (EECS DCO) of Michigan
I checked my copy of Abramowitz and Stegun, HANDBOOK OF
MATHEMATICAL FUNCTIONS WITH FORMLAS, GRAPHS, AND
MATHEMATICAL TABLES--one of the most remarkable math
references ever. (My 10th printing copy says "For sale by
the Superintendent of Documents, U.S. Gov. Printing Office,
Wa, DC 20402, $11.35 postpaid." I bought mine at the
Stanford bookstore in 1981 for $12.65)
Page 325 has tables of the error function for complex
arguments. The function is:
w(z)= exp(-(z^2))*erfc(-j*z), z= x + j*y, j= sqrt(-1)
Further, w(x)= exp(-(x^2)) + (2*j/sqrt(pi))*F(x)
F(x) is Dawson's integral
F(x)= exp(-(x^2))*[integral of exp(t^2)*dt, from 0 to x]
And at last
w(j*y)= exp(y^2)*erfc(y)
I hope that helps.
Perry Stout
pws...@pacbell.net
-------------------==== Posted via Deja News ====-----------------------
http://www.dejanews.com/ Search, Read, Post to Usenet
hucka> Matlab offers erf, erfc, erfcx, and an erfinv. As luck would have
hucka> it, I have some calculations involving expressions with the
hucka> imaginary erf function
(Answering my own posting!) Sometime after posting the message above, I was
searching the MathWorks' "Solution search engine" on their web site, and
found note #3131 which discusses the erf function in Matlab. It happened to
mention the use of the erf implementation in the Maple kernel, and the fact
that this version of erf accepts complex number arguments. So I've been able
to implement a version of erfi using
function y = erfi(z)
y = -i .* mfun('erf', i .* z);