Two of my favorite numbers are pi:

and the golden ratio:

They’re related:

Greg Egan and I came up with this formula last weekend. It’s probably not new, and it certainly wouldn’t surprise experts, but it’s still fun coming up with a formula like this. Let me explain how we did it.

History has a fractal texture. It’s not exactly *self-similar*, but the closer you look at any incident, the more fine-grained detail you see. The simplified stories we learn about the history of math and physics in school are like blurry pictures of the Mandelbrot set. You can see the overall shape, but the really exciting stuff is hidden.

François Viète is a French mathematician who doesn’t show up in those simplified stories. He studied law at Poitiers, graduating in 1559. He began his career as an attorney at a quite high level, with cases involving the widow of King Francis I of France and also Mary, Queen of Scots. But his true interest was always mathematics. A friend said he could think about a single question for up to three days, his elbow on the desk, feeding himself without changing position.

Nonetheless, he was highly successful in law. By 1590 he was working for King Henry IV. The king admired his mathematical talents, and Viète soon confirmed his worth by cracking a Spanish cipher, thus allowing the French to read all the Spanish communications they were able to obtain.

In 1591, François Viète came out with an important book, introducing what is called the new algebra: a symbolic method for dealing with polynomial equations. This deserves to be much better known; it was very familiar to Descartes and others, and it was an important precursor to our modern notation and methods. For example, he emphasized care with the use of variables, and advocated denoting known quantities by consonants and unknown quantities by vowels. (Later people switched to using letters near the beginning of the alphabet for known quantities and letters near the end like for unknowns.)

In 1593 he came out with another book, *Variorum De Rebus Mathematicis Responsorum, Liber VIII*. Among other things, it includes a formula for pi. In modernized notation, it looks like this:

This is remarkable! First of all, it looks cool. Second, it’s the earliest known example of an infinite product in mathematics. Third, it’s the earliest known formula for the exact value of pi. In fact, it seems to be the earliest formula representing a number as the result of an infinite process rather than of a finite calculation! So, Viète’s formula has been called the beginning of analysis. In his article “The life of pi”, Jonathan Borwein went even further and called Viète’s formula “the dawn of modern mathematics”.

How did Viète come up with his formula? I haven’t read his book, but the idea seems fairly clear. The area of the unit circle is pi. So, you can approximate pi better and better by computing the area of a square inscribed in this circle, and then an octagon, and then a 16-gon, and so on:

If you compute these areas in a clever way, you get this series of numbers:

and so on, where is the area of a regular *n*-gon inscribed in the unit circle. So, it was only a small step for Viète (though an infinite leap for mankind) to conclude that

or, if square roots in a denominator make you uncomfortable:

The basic idea here would not have surprised Archimedes, who rigorously proved that

by approximating the circumference of a circle using a regular 96-gon. Since , you can draw a regular 96-gon with ruler and compass by taking an equilateral triangle and bisecting its edges to get a hexagon, bisecting the edges of that to get a 12-gon, and so on up to 96. In a more modern way of thinking, you can figure out everything you need to know by starting with the angle and using half-angle formulas 4 times to work out the sine or cosine of . And indeed, before Viète came along, Ludolph van Ceulen had computed pi to 35 digits using a regular polygon with sides! So Viète’s daring new idea was to give an *exact* formula for pi that involved an *infinite* process.

Now let’s see in detail how Viète’s formula works. Since there’s no need to start with a square, we might as well start with a regular *n*-gon inscribed in the circle and repeatedly bisect its sides, getting better and better approximations to pi. If we start with a pentagon, we’ll get a formula for pi that involves the golden ratio!

We have

so we can also compute pi by starting with a regular *n*-gon and repeatedly doubling the number of vertices:

The key trick is to write as a ‘telescoping product’:

Thus, taking the limit as we get

where we start with the area of the *n*-gon and keep ‘correcting’ it to get the area of the *2n*-gon, the *4n*-gon, the *8n*-gon and so on.

There’s a simple formula for the area of a regular *n*-gon inscribed in a circle. You can chop it into right triangles, each of which has base and height , and thus area :

Thus,

This lets us understand how the area changes when we double the number of vertices:

This is nice and simple, but we really need a recursive formula for this quantity. Let’s define

Why the factor of 2? It simplifies our calculations slightly. We can express in terms of using the half-angle formula for the cosine:

Now we’re ready for some fun! We have

so using our recursive formula , which holds for any , we get

I think this deserves to be called the **generalized Viète formula**. And indeed, if we start with a square, we get

and

giving Viète’s formula:

as desired!

But what if we start with a pentagon? For this it helps to remember a beautiful but slightly obscure trig fact:

and a slightly less beautiful one:

It’s easy to prove these, and I’ll show you how later. For now, note that they imply

and

Thus, the formula

gives us

or, cleaning it up a bit, the formula we want:

Voilà!

There’s a lot more to say, but let me just explain the slightly obscure trigonometry facts we needed. To derive these, I find it nice to remember that a regular pentagon, and the pentagram inside it, contain lots of similar triangles:

Using the fact that all these triangles are similar, it’s easy to show that for any one, the ratio of the long side to the short side is to 1, since

Another important fact is that the pentagram trisects the interior angle of the regular pentagon, breaking the interior angle of into 3 angles of :

Again this is easy and fun to show.

Combining these facts, we can prove that

and

To prove the first equation, chop one of those golden triangles into two right triangles and do things you learned in high school. To prove the second, do the same things to one of the short squat isosceles triangles:

Starting from these equations and using , we can show

and, just for completeness (we don’t need it here):

These require some mildly annoying calculations, where it helps to use the identity

Okay, that’s all for now! But if you want more fun, try a couple of puzzles:

**Puzzle 1.** We’ve gotten formulas for pi starting from a square or a regular pentagon. What formula do you get starting from an equilateral triangle?

**Puzzle 2.** Using the generalized Viète formula, prove Euler’s formula

Conversely, use Euler’s formula to prove the generalized Viète formula.

So, one might say that the real point of Viète’s formula, and its generalized version, is not any special property of pi, but Euler’s formula.

[…] Two of my favorite numbers are pi: and the golden ratio: They’re related: $latex pi =… – Read full story at Hacker News […]

Congratulations!, Very interesting presentation of ideas, these is one of most favourites too, other is Sequence Limits of Euler and Fibonacci Numbers and the golden section in nature, art, geometry, architecture, music and even for calculating pi!

Cool !

was sometimes called “Ludolph’s number” for a while.

The Golden Ratio is often used as the numerical value for the aspect ratio (Y Axis Height/ X Axis length) when graphing functions. Doesn’t work for the cycloid and it’s variants. The aspect ratio for the cycloid, a ‘wheel function’ must be set to Y = 1 / X = pi. Failing to do so locates the inflection point of Roberval’s ‘companion curve to the cycloid’ away from the center of the bounding rectangle.

that first in puzzle 2 is bothering me; it has zeros that the other side doesn’t.

I’m pretty sure that first in puzzle 2 is a typo, and not actually part of Euler’s formula.

Thanks for catching that mistake! Fixed.

Mar Kac’s book “Statistical Independence in Probability, Analysis and Number Theory” starts out with Viete’s formula (essentially puzzle 2) and then uses Rademacher functions to ultimately derive the central limit theorem. It is a ripping read. Kac is also famous for his “Can you hearth shape of a drum paper?” (Answer is “no”)

¿Vòila? Voilà !

I

knewsomething looked funny about that. I’ll fix it. Thanks!voilò? voilà!

Wow, amazing! This time it’s

reallyfixed.In my defense, to write “Voilà” here I actually type “Voilà”, and that makes it a bit easier to screw up.

Curiously, there is another infinite product formula for that is also attributed to Euler:

and setting in this one leads to the Wallis formula for that JB discussed here:

Yes, this other infinite product formula

is more famous: the young Euler used it to show

thus meeting Bernoulli’s challenge to the world to sum this series:

• John Baez, The Riemann zeta function, 21 December 2003.

Euler simply

guessedthis product formula by creating an ‘infinite polynomial’ with zeros at the same places as (though I imagine he checked his guess in various ways). Later Weierstrass came up with a nice general theory of such product expansions:• Wikipedia, Weierstrass factorization theorem.

But I’ve never seen anything written about

except in the Wikipedia article on Vieète’s formula, so I’m a bit curious about its history.

Friedmann and Hagen have got Wallis formula for pi from a variational computation of the spectrum of the hydrogen atom. Check out the proof here:

http://dx.doi.org/10.1063/1.4930800

I will need to go through that sometime. People keep telling me about it, but I haven’t checked out the calculation! By doing a calculation in a sufficiently complicated way you can relate it to almost anything, so the question is how elegantly they make the connection.

Th only step I couldn’t immediately replicate was the expectation of the Hamiltonian and I have never got back to it – the rest is correct. I must do it but it is 40 years since I did that stuff.

I believe it should read

because .

You’re right, I got them switched. Earlier, when I actually

usedthem, I had ’em right.Fixed.

I am thinking that it would be possible to write a pi calculus with a volume of a sphere, but the problem is with the polyhedrons that must be ever increasingly smaller (it is impossible to have more of five regular polyhedra, so that a generalization of Viete in three dimension is not possible).

I tried to generate a general irregular polyhedra using a Bravais lattice on the sphere (for increase the faces of the polyhedron reducing the primitive vectors), with the discrete translations replaced with the versors for the rotation along the edge of the spherical triangles, and I have used the Rodrigues rotation formula to obtain the points on the sphere (with a little program), so that there are an infinite number of tessellation using an arbitrary initial spherical triangle (that generate the primitive vectors of Bravais lattice) with a vertex in the zenit, an edge along a meridian, and the other edge with an arbitrary lengths and directions (to complete the scalene triangle): the edges of the triangles have different lengths in the primitive vectors, but have the same rotations in the primitive vectors; the volumes of the polyhedron are too complex to evaluate, but it seem that it is possible to obtain the tetrahedron, the octahedron and the cube using the Bravais lattice (so that could be possible for all the regular polyhedra).

That generalized formula is so good. Puzzle-1 is simple enough but but nevertheless an excuse to write my first comment here in this blog;

I think there is a typo in the paragraph about the area of the regular n-gon, although it is correctly stated after the pentagon depiction. It should read n.sin()… instead of 2.sin()…

Hi, Akira. Thanks! I haven’t actually worked out the answer to Puzzle 1, but I’ll check your answer and see if it’s right. It’s certainly pretty.

Also thanks for catching that typo. I fixed it.

By the way, you used double dollar signs in your LaTeX; those don’t work here, alas. You can use \displaystyle{ } to make the text in an equation taller, and

around the equation to center it. With those tricks your equation becomes

or, even more gloriously:

gives

But these extra tricks are not very important!

John I read many of your Maths/physics papers and always take time for Azimuth in/email. I sent you a series of polyhedrons, one I described as a tesseract or hypercube, a 3D icosahedral/cuboid construct yielding eight tetrahedrons.

My working background is in building science, I’m a serious amateur mathematician with an emphasis on greenhouse and climate impacts, and number theory. its sometimes a bit awkward to explain but bricks, curvature and modularities are my areas of focused interest.

The PI : PHI golden section relationship in 3D solids is an example I find fascinating, and the maths reasoning is why I follow Azimuth to connect the environment with pure maths and physics.

A relationship between Phi and Pi; phi brick in ball, the brick in a sphere shows a simple relationship between Pi and Phi, using the values for the diagonal D that we have just found and the surface area S.

If we imagine the brick tightly packed into a sphere, the centre of the sphere will be half way along diagonal D.

So the radius of the sphere will be 1 and its surface area will be 4 Pi.

http://www.maths.surrey.ac.uk/hosted-sites/R.Knott/Fibonacci/propsOfPhi.html#phiBrick

[…] in order to learn something new about π, go read this lovely post by John […]

The general formula IS lovely. I particularly like that you get the same result whether you start with an equilateral triangle (Puzzle 1) or a regular hexagon! (The triangle case just has one extra factor get cancelled out.)

I should try to figure out whether the formula for n always agrees with the formula for kn (which it should), and why the algebra works out; it seems like it must be a beautiful pattern.

I don’t think the formula for n will agree with that for kn unless k is a power of 2.