Post Reply 
Riemann's Zeta Function - another approach (RPL)
07-30-2017, 10:18 PM (This post was last modified: 07-30-2017 10:42 PM by Dieter.)
Post: #67
RE: Riemann's Zeta Function - another approach (RPL)
(07-30-2017 04:17 PM)Gerson W. Barbosa Wrote:  
(07-30-2017 07:57 AM)Dieter Wrote:  BTW, I see your program has a RCL 00 in line 24. For x≤2 the ZETA routine leaves x in R00, but for x>2 R00 finally holds –x. Have you considered this?

Yes, that's what ABS in line 19 is for.

I see, but the HP-41 version has is another RCL 00 without an ABS in line 24. ;-)

(07-30-2017 04:17 PM)Gerson W. Barbosa Wrote:  That's a good suggestion, but we'd need x! (or Gamma) to be that accurate too. Is there a math module with x! or Gamma?

I do not know of an (official HP)-ROM with a full-precision 10-digit Mcode-Gamma-implementation.

(07-30-2017 04:17 PM)Gerson W. Barbosa Wrote:  A few guard digits (perhaps just a couple of them) combined with built-in Gamma might give perfect 10-digit results most always, even when using 10-digits constants, which is quite impressive.

To assess the final accuracy it might be helpful to know the error of the two polynomial approxmations for x between 0 and 2. If evaluated with sufficient precision and using the coefficients given in the HP-41 program (note that c0 effectively has 12 digits since 0,57 is added later) the one for 0≤x<1 has a largest error of ~3,5 units in the 12th significant digit, while for 1<x≤2 it's less than 0,7 units.

(07-30-2017 04:17 PM)Gerson W. Barbosa Wrote:  On Free42:

I tried Free42 BCD where Gamma seems to be good for 30+ digits. So the results should only be limited by the approximation error. However, for x>2 the number of terms (cf. line 38 ff. in the 42s Zeta program) of course has to be adjusted in a higher precision environment. ;-) This should improve the results for x>2 resp. x<–1.

Dieter
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Riemann's Zeta Function - another approach (RPL) - Dieter - 07-30-2017 10:18 PM



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