I found the explanation for how to use the formula here. Though example is for ^. 2
http://en.wikipedia.org/wiki/Spigot_algorithm ln 2 has a simpler formula than pi (one term instead of 4) but essentially the same process. ----- Original Message ----- From: Skip Cave <[email protected]> To: "[email protected]" <[email protected]> Cc: Sent: Tuesday, January 6, 2015 4:20 PM Subject: Re: [Jprogramming] nth digit of pi f=: 3 : '10|<.@o. 10x^y' f 0 3 f 1 1 f 2 4 f 10 5 f 100 9 f 1000 9 f 10000 ...... still waiting.... Skip Cave Cave Consulting LLC On Tue, Jan 6, 2015 at 3:04 PM, 'Pascal Jasmin' via Programming < [email protected]> wrote: > to be more specific, a function that gets the 10000th digit of pi? > > > ----- Original Message ----- > From: Roger Hui <[email protected]> > To: Programming forum <[email protected]> > Cc: > Sent: Tuesday, January 6, 2015 3:58 PM > Subject: Re: [Jprogramming] nth digit of pi > > Answering the letter if not the spirit of your question: > > f=: 3 : '10|<.@o. 10x^y' > f"0 i.5 20 > 3 1 4 1 5 9 2 6 5 3 5 8 9 7 9 3 2 3 8 4 > 6 2 6 4 3 3 8 3 2 7 9 5 0 2 8 8 4 1 9 7 > 1 6 9 3 9 9 3 7 5 1 0 5 8 2 0 9 7 4 9 4 > 4 5 9 2 3 0 7 8 1 6 4 0 6 2 8 6 2 0 8 9 > 9 8 6 2 8 0 3 4 8 2 5 3 4 2 1 1 7 0 6 7 > > > > On Tue, Jan 6, 2015 at 12:50 PM, 'Pascal Jasmin' via Programming < > [email protected]> wrote: > > > I don't really understand this well: > > > > > > > http://en.wikipedia.org/wiki/Approximations_of_%CF%80#Digit_extraction_methods > > > > is there a J program for finding the y th digit of pi (any base is ok) > > ---------------------------------------------------------------------- > > For information about J forums see http://www.jsoftware.com/forums.htm > > > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
