# How to find the correct value of pi? [duplicate]

Pi is defined as the ratio of $\frac{c}{r}$. Many ancient scintist try to find the value of pi. Some of the values are $\frac{22}{7}$(good hold upto 10 decimal point), $\frac{355}{113}$ (good hold upto 63 Decimal point). modern computer determine upto million decimal point.

my qustion is that how ( algorithm or formula ) modern computer find the value of pi ?

• 113/355?-I think you typed something wrong – Ahmed S. Attaalla Apr 22 '16 at 4:36
• One simple yet not very accurate way is to use probability. – Colescu Apr 22 '16 at 4:38
• Nop, i dont't want any guss. I need exect way of algo. That modern computer follow to find exect value of pi. – Prashant Apr 22 '16 at 4:40
• Also, $\pi$ is not "defined as the ratio $\frac{c}{r}$." It is $\frac{c}{d}$. – Joel Reyes Noche Apr 22 '16 at 4:51
• Why do you say $22/7$ is a "good hold upto 10 decimal point"? $\pi=3.141592...$ and $22/7=3.142857...$ and they differ at the third decimal place. – Joel Reyes Noche Apr 22 '16 at 4:57

There are many formulas after the development of calculus, mostly in the form of infinite series. For a simple example, it is a fact that $$\pi=4\left(1-\frac{1}{3}+\frac{1}{5}-\frac{1}{7}+\cdots\right).$$ (This can be seen through the Taylor series of arctan x). This is a simple example, but it converges really slowly; you need about 100 terms to get the 3.14 value. There are more sophisticated formulas, but I hope this gave you the idea.