An Infinite Series for Calculating Pi Discovered by Ramanujan

There are other calculations for Pi which work in a similar manner. A more complex series was devised by the Indian mathematician Ramanujan which calculates Pi very accurately but which needs knowledge of some more functions in Excel. This series is implemented more as a mechanical exercise in Excel rather than as a lesson in understanding Ramanujan's mathematics! The Ramanujan series uses factorials which are calculated in Excel using the FACT() function. FACT(4) returns 24, that is 4 x 3 x 2 x 1. The mathematical notation for factorial is '!'.)

The Ramanujan series is as follows:

  <

This looks forbidding but if we break it down carefully in a spreadsheet we can show how it works. We proceed as follows: 

  1. Find the square root of 8 in cell B2 and then divide it by 9801 in cell B3.

  2. Create a sequence 0..6 in the A column

  3. Calculate 4n! in B6

  4. Calculate n!^4 in C6

  5. Calculate (4n!) / (n!^4) in D6

  6. Calculate 26390 x 26390n in E6

  7. Calculate 396 ^ 4n in F6

  8. Calculate (26390 x 26390n) / (396 ^ 4n) in G6

  9. Multiply the terms in D6 and G6 in H6

  10. Select cells B6 to H6 and use the copy marker to apply the formulae to rows underneath

  11. Put the sum of the values in the H column in E2

  12. In G2 multiply the total in E2 by the value in B3 (SQRT(8)/9801)

  13. In E3 find 1/G2 which provides the estimation of Pi

  14. For comparison copy the value of Pi from Excel's function PI() into G3

  (This first sheet was created by selecting Tools/Options/View and checking the Formulae box - this displays formulae instead of contents.) The second sheet shows the numbers these formulae produce.

Use the Back Button to Return to the previous page