Post Reply 
integral competition HP50g vs. DM42
04-04-2024, 10:53 PM
Post: #30
RE: integral competition HP50g vs. DM42
(04-04-2024 08:35 PM)John Keith Wrote:  How do you get an accurate erfc(z) from 1-erf(z)? erf(3.9) = 0.999999965208,
and that number subtracted from 1 is 0.000000034792 which has only 5 significant digits.

For big z, it is the other way around, erf(z) = 1 - erfc(z)
We need only few sig. digits of erfc(z) to get accurate erf(z)

Quote:erf x = (2x/Pi^(1/2)) * exp(-x*x) * 1F1( 1 , 3/2 , x^2 )

For CiS(3.9), erf argument is complex, A&S eqn 7.1.6 may not help with accuracy.

p2> k = 2/sqrt(pi)
p2> erf = lambda x: k*x * exp(-x*x) * hyp1f1(1, 3/2, x*x)
p2> CiS = lambda x, erf=erf: (1+1j)/2 * erf((1-1j)/k * x)
p2> CiS(3.9)
(0.42233255931844371+0.47520226114155328j)
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: integral competition HP50g vs. DM42 - Albert Chan - 04-04-2024 10:53 PM



User(s) browsing this thread: 4 Guest(s)