From kwgoodwin Wed Dec 18 01:02:20 1991
Received: by icaen.uiowa.edu ( 5.52 (84)/1.1) id AA13745
	on Wed, 18 Dec 91 01:02:16 CST.
From: Kirk W Goodwin <kwgoodwin@icaen.uiowa.edu>
To: clif@idui1.csrv.uidaho.edu, kwgoodwin
Path: icaen.uiowa.edu!kwgoodwin
Date: 18 Dec 91 06:22:36 GMT
Message-Id: <kwgoodwin.693037356@icaen.uiowa.edu>
Newsgroups: sci.misc
Subject: Re: How to calculate pi to nth place
References: <1991Dec17.231322.5550@groucho>
Status: R

clif@idui1.csrv.uidaho.edu (Clif White) writes:

>I was talking with a High School Physics teacher and we were wondering
>how does one calculate the pi from scratch.

>What iteration does the Cray supercomputer use to run out pi to some 
>outrageous decimal place?

>Any help would be greatly appreciated.  We plan on springing this some 
>unsuspecting high school students as a math challenge problem.

>Clifton White
>User Services
>University of Idaho

I'm taking this from my high school Calc book, "Elements of Calculus and Analyticaly Geomoetry" by Thomas and Finney.
 
Computation of pi

Archimedes (287-212 BC) gave the approximation
 
		3 1/7 > pi > 3 10/71

in the  third centruy B.C. A French mathematician, Vieta (1540-1603), gave the
formula
 
	2
      ____   = sqrt(1/2) * sqrt (1/2+1/2*sqrt(1/2)) * ... ect.
       pi

which Turnball (Wold of Matematics, Vol. 1,p. 121) calls "the first actual 
formula for the time-honored number pi"  Others include
 
	pi				1
      _____  = ___________________________________________________,
        4        			   1^2
                  1    +     _____________________________________
						3^2
			2   +  ___________________________________ 
						   5^2
			    2    + _______________________________
							7^2
				2  +  ____________________________
						
					2 + 		...	

which is credited to Lord Broucnket, an Irish peer;

	pi	2 X 4 X 4 X 6 X 6 X 8 X ...
      ____  = ___________________________
        4       3 X 3 X 5 X 5 X 7 X 7 X ...

discovered by the English mathEmatician Wallis; and
 
        pi     	    1    1    1      
      ____  =  1 - __ + __ - __ + ...
        4           3    5    7 
known as Leibniz's formula
	All of these formulas involve limits and must derived [they go on and
derive Veita's formula...  if you really want this feel free to email me and
I'll get it to you...]

Leibiniz's formula is the most often used for pi calculations...

							    x^(2n+2) 
since tan^(-1) x = x - x^3/3 + x^5/5 - x^7/7 + ... + (-1)^n _________ + R
							      2n + 1 
where 

		R = is the error

or simply stated
						(-1)^n x^(2n + 1)
	tan^(-1) x =  Summation (n=0,infinity) __________________
						     2n + 1

Let a = tan^(-1) 1/2 and b = tan ^(-1) 1/3,

Now, since

		     tan a  + tan b               pi
	tan (a+b) = _________________	= 1 = tan __
		     1-(tan a)(tan b)	           4

Therefore,

	pi/4 = a + b = tan^(-1) 1/2 + tan ^(-1) 1/3

in 1961 it was calculated from

	pi = 48 invtan 1/18 + 32 invtan 1/57 - 20 invtan 1/239
and
	pi = 24 invtan 1/18 +  8 invtan 1/57 +  4 invtan 1/239.

Eugene Salamin devloped this:

      
         a(o) = 1                     b(o) = 1/sqr(2)
  
              ( a(n) + b(n) )                    
    a(n+1) =  _______________          b(n+1) = sqr( a(n) * b(n) )
                     2
 
  
                                   4 * a(n) * b(n)
            c(n) = _________________________________________________
                              n     
                      1 - SUMMATION  ( 2^(j+1) (a(j)^2 +b(j)^2) )
                             j=1
   
  
  
 Where c(n) converges to pi
           E. Salamin "Computation of pi using arithmetic-geometric means" 
              _Mathematics of Computation_, 30, July 1976, pp. 565-570.
  
Additional readings include  Chapter 12 of David A Smith's _Interface: Calculus
and the Computer_, Houghton Mifflin Co., Boston MA, 1976.

Hope this helps



	pi/4 = a + b = tan

