Calculus/Leibniz' formula for pi
In mathematics, the Leibniz formula for π, named after 17th century mathematician Gottfried Wilhelm Leibniz, states that
an alternating series. While the series is easy to write and calculate, it is a very inefficient method for calculating , so it is seldom used in modern calculations of .
By the alternating series test, this series converges. It satisfies both of the test's criteria:
- I) The terms decrease monotonically in absolute value.
- II) The terms tend to 0 as the index tends to infinity.
Leibniz' formula for is a special case of the Gregory's series for the arctangent,
discovered by mathematician James Gregory in 1668.
Since , and thus, , the formula is derived, and proved, by plugging into Gregory's series.
It is worth noting that lies on the boundary of the circle of convergence for Gregory's series. For , the alternating series fails both criteria: for , the terms increase in absolute value, and the terms tend to infinity, the opposite of what needs to be true for an alternating series to converge. Even a value of very close to 1, but still greater than it, such as , still lies outside the series' radius of convergence.
The following is a table of the first 10 partial sums and a selected list of other notable partial sums. This series converges to which to 16 significant figures, is 0.7853981633974483. The approximations for itself, found by multiplying the partial sums by four, are also shown. To 16 significant figures, .
Note: The second and third partial sums are exactly and , respectively. Both decimals feature a repeating "6"; for these entries, only the first three sixes are shown, followed by three dots to show that the sixes repeat endlessly. For all later terms, the sums are rounded to 9 digits after the decimal point, or the nearest billionth.
|n||Partial Sum||Approximation for pi|
An interesting curiosityEdit
You may have noticed that the later partial sums chosen at "round" numbers like 100 or 5000, look very similar to the limiting sums. For example, the partial sum of 3.131592903 at 100 terms, even after disagreeing with "3.14159265..." with a "3" instead of a "4" on the second digit, agrees for the next four digits, sharing the "1592" part. And the partial sum of 3.140592654 at 1000 terms differs on the third digit, but then goes on to agree with pi on the "59265" part. Similar behavior can also be seen in the second column of partial sums, such as the 250th term, which disagrees on the third digit but agrees from the fourth digit to the eighth digit (0.78439816 instead of 0.78539816). This pattern is very consistent throughout the remaining partial sums in the table. This is not an accident. This can be predicted using the Euler numbers. For any positive integer , one can get a very close approximation of the th approximation for with the following formula:
- If is odd, the th approximation for is approximately , and the th partial sum is approximately .
- If is even, the th approximation for is approximately , and the th partial sum is approximately .
The error of this approximation is on the order of so this approximation is remarkably accurate even for relatively small values of . Even after only four terms, the approximation of 0.722898163 predicted by the formula differs from the true partial sum of 0.723809524 by only about , which is less than 10−3. The error is less than 10−6 for all and less than 10−10 for all .