Wednesday, April 8, 2009

Pi by fractions

The circumference of a circle divided by its diameter is always the same number, no matter the size of the circle. This number is called π (pi) and has the value 3.1415926535...

π is an irrational number, which means that it cannot be expressed as a simple fraction such as 1/5 or 3/4. However, you can get pretty close.

A fraction that is often used is 22/7. This is not all that good:

22/7 = 3.14285714...
π = 3.14159265...

Although within 0.04% of the correct answer, 22/7 is only correct to 2 decimal places. We can do better than this.

355/113 is correct to 6 decimal places. It's within 0.000009% of π.

355/113 = 3.1415929203...
π = 3.1415926535...

355/113 is such a good approximation to π, that there is not a more accurate fraction until 52163 / 16604, and that is only marginally closer to π, still only correct to 6 decimal places.

52163/16604 = 3.1415923874...
355/113 = 3.1415929203...
π = 3.1415926535...

To be accurate to 7 decimal places we need to go as far as 86953 / 27678

86953/27678 = 3.1415926006...
52163/16604 = 3.1415923874...
355/113 = 3.1415929203...
π = 3.1415926535...

The importance of 355/113 has been recognized, giving it the name Milü.

2 comments:

  1. There's an easy way to remember 355/113:

    Write down each number twice: 1 1 3 3 5 5
    That's 1,3,5, of course.
    split the sequence in the middle:
    113 355

    ReplyDelete
  2. If you have Matlab, you can see how absurdly accurate 355/113 is:

    format long;
    bestapproxerror = .2;
    tic
    a=[];
    for i=1:100000
    for j=1:round(i/3)
    if(abs((i/j)-pi)<bestapproxerror)
    bestapproxerror = abs((i/j)-pi);
    a(size(a,1)+1,:) = [i j bestapproxerror toc]
    tic
    end
    end
    end

    plot(a(:,1),a(:,3))

    ReplyDelete