Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Storing more decimal places in a variable

by sleepingsquirrel (Chaplain)
on Dec 16, 2004 at 00:32 UTC ( [id://415241]=note: print w/replies, xml ) Need Help??


in reply to Storing more decimal places in a variable

You could also think of using a different algorithm, one which doesn't depend on perl's floating point numbers. Here I'm thinking of something like the Unbounded Spigot Algorithms for the Digits of π...
Rabinowitz and Wagon call their algorithm a spigot algorithm, because it yields digits incrementally, and does not use digits after they have been computed. The digits drip out one by one, as if from a leaky tap. In contrast, most algorithms for computing the digits of π deliver no output until the whole computation is completed.
Update: fixed broken link.


-- All code is 100% tested and functional unless otherwise noted.
  • Comment on Re: Storing more decimal places in a variable

Replies are listed 'Best First'.
Re^2: Storing more decimal places in a variable
by penguin_asylum (Sexton) on Dec 16, 2004 at 00:48 UTC
    That link appears to be broken... but thanks for the info anyway :P

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://415241]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (7)
As of 2024-04-23 11:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found