Post Reply 
Can you calculate Pi using a Solver?
12-09-2019, 06:38 PM (This post was last modified: 12-09-2019 06:51 PM by jthole.)
Post: #7
RE: Can you calculate Pi using a Solver?
(12-09-2019 03:35 PM)Valentin Albillo Wrote:  If your Solver has Square Root and Factorial, this one from Ramanujan converges very fast and it's quite simple, few bytes to program it and only a few terms to add up for full precision...

[Image: 0993bfb34b91c895c4a55899e71b875dc8d4dd3b]

... and no trigs used, as requested, just basic arithmetic. Once you get 1/Pi just invert it with 1/x

Regards.
V.

Very nice! Here is the equation for the 17Bii:

1 ÷ PIVAL = ( ( 2 x SQRT( 2 ) ) ÷ 9801 ) x sigma ( I : 0 : N : 1 : ( FACT( 4 x I ) x ( 1103 + 26390 x I ) ÷ ( ( FACT( I ) ^ 4 ) x ( 396 ^ ( 4 x I ) ) ) )

I only tested it on the iPhone emulator, but it goes to full precision very quickly (N=2) indeed.

11C, 12C, 17Bii, DM42
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Can you calculate Pi using a Solver? - jthole - 12-09-2019 06:38 PM



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