Problem 282
Medium Remainders and Fourier Series

Using arctan x=sum from n=0 to infinity

Using $\arctan x=\sum_{n=0}^{\infty}\dfrac{(-1)^nx^{2n+1}}{2n+1}$, calculate $\pi$ with five correct decimal places.

Explanation of Method

Plugging $x=1$ directly gives the Leibniz series, but it converges far too slowly to be practical. Machin's formula rewrites $\pi/4$ as a combination of arctangents of small arguments $1/5$ and $1/239$, so the same series converges dramatically faster.

  1. Note the impracticality of the direct $\arctan 1$ series.
  2. Verify Machin's identity $\pi/4=4\arctan\frac15-\arctan\frac1{239}$ using the tangent addition formula.
  3. Compute both arctangents via the series and combine.

Step 1 · Why not use $x=1$ directly?

$\dfrac\pi4=1-\dfrac13+\dfrac15-\cdots$ converges so slowly that reaching 5 correct decimals would require on the order of $10^5$ terms — impractical by hand.

Step 2 · Verify Machin's formula

Let $\alpha=\arctan\frac15$. Using the double-angle tangent formula twice: $$ \tan2\alpha=\frac{2/5}{1-1/25}=\frac5{12}, \qquad \tan4\alpha=\frac{2\cdot5/12}{1-25/144}=\frac{120}{119}. $$ With $\beta=\arctan\frac1{239}$: $$ \tan(4\alpha-\beta)=\frac{\frac{120}{119}-\frac1{239}}{1+\frac{120}{119\cdot239}}=\frac{120\cdot239-119}{119\cdot239+120}=\frac{28561}{28561}=1, $$ so $4\alpha-\beta=\arctan1=\frac\pi4$.

Step 3 · Compute both series and combine

$$ \arctan\frac15 = \frac15-\frac1{3\cdot5^3}+\frac1{5\cdot5^5}-\frac1{7\cdot5^7}+\cdots \approx 0.197395560, $$ $$ \arctan\frac1{239} = \frac1{239}-\frac1{3\cdot239^3}+\cdots \approx 0.004184076. $$ (Only 5–6 terms of the first series and 2 terms of the second are needed for this precision.) Then: $$ \frac\pi4 = 4(0.197395560)-0.004184076 = 0.785398164, \qquad \pi \approx 3.14159266. $$


Summary Table

PropertyValue
Machin's formula$\pi/4=4\arctan\frac15-\arctan\frac1{239}$
Result$\pi\approx3.14159$
Terms needed$\sim8$ total (vs.\ $\sim10^5$ direct)

Additional Notes

Result

$$ \pi = 16\arctan\frac15 - 4\arctan\frac1{239} \approx 3.14159 \ \text{(5 correct decimal places)}. $$