[Beowulf] Re: Pi calculator
Peter Pacheco
peter at cs.usfca.edu
Tue Mar 1 12:19:41 EST 2005
On Mon, Feb 28, 2005 at 07:58:49AM -0500, Joe Landman wrote:
>
> >>2. Does anybody know of a program that will calculate pi, one digit at a
> >>time, infinitely that will run in parallel?
> >
> >
> >I don't know about one that will compute an infinite number of digits in
> >PI, but the computation of PI via the arctan series is trivially
> >partitionable in a variety of ways. You'll spend more time working to
> >sum and align the digits you get (as they obviously will have to be
> >obtained and manipulated piecewise as strings) than you will doing the
> >computation per se. It actually sounds like a decent exercise, as the
> >carry from small digits may have to propagate iteratively back to larger
> >ones as you extend the computation farther and farther.
> >
>
>
> http://mathworld.wolfram.com/PiDigits.html
> http://mathworld.wolfram.com/PiFormulas.html
> http://www.andrews.edu/~calkins/physics/Miracle.pdf
>
> and others.
>
> It is possible to calculate the digits individually using the Bailey et
> al algorithm.
>
> Joe
I wrote a short MPI program last summer that uses
the Bailey-Borwein-Plouffe algorithm and the GMP library
(http://www.swox.com/gmp/) to compute arbitrarily many digits of pi.
Jake, send me email (peter at cs.usfca.edu) if you want a copy.
Best wishes,
Peter Pacheco
Department of Computer Science
University of San Francisco
San Francisco, CA 94117
(415) 422-6630
peter at cs.usfca.edu
_______________________________________________
Beowulf mailing list, Beowulf at beowulf.org
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/listinfo/beowulf
More information about the Beowulf
mailing list