Accurate Normal Distribution for the HP67/97
|
12-16-2018, 11:08 PM
(This post was last modified: 12-19-2018 01:27 AM by Albert Chan.)
Post: #45
|
|||
|
|||
RE: Accurate Normal Distribution for the HP67/97
Hi, John Keith
Regarding how to split z for 1 Exp Method Revision 1, note the reason for the split: Z(z) = Z(x + h) = Z(x) exp(-x h - h²/2) = Z(x) exp(y) The split have to ensure *BOTH* good Z(x) and exp(y). If |z| is limited to below √2000 ~ 44.7, FIX-4 work well. Above this z range, x = -5 RND of z, (to evaluate Z(x) correctly). |y| is now too big, exp(y) need more terms to get "good enough". Instead of updating revision 1 with above, I choose an easier way. 1 Exp Method Revision 2 only need a linear correction, and work for even bigger |z| Example: Z(99.1234567), assuming calculator can handle bigger exponent B = z²/2 = 4912.72 983408 D = exp(-B) / √(2 Pi) = 1.07016 820397 e-2134 x = z to 5 digits = 99.123 h = z - x = 0.0004567 y = B - x²/2 - x h - h²/2 = 161.2555 e-11 Z(z) = D + y D = D + 173 ULP = 1.07016 820570 e-2134, error = +1 ULP |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)