Monday, 4 March 2013

A slice of π


March 14th is denoted π day. Why? Because our American brethren write the date with the month first, producing a date of 3/14, which are the first three digits in the decimal expansion of π.

To celebrate this most holy of mathematical days the Continuing Education Department of the University of Oxford are hosting π day, which is going to be presented by none other than Professor Marcus du Sautoy. And what's more you can join in the discussion.


The project is an ambitious attempt to simultaneously run an online lecture (in which you can take part) as well as stream the presentation live on YouTube. Not only will you get a nice lecture on the properties and history of π, but you'll also get a chance to be part in a huge experiment estimating π.

Using computers can calculate π to any accuracy we would like. But because π is irrational it never repeats. The goal of the experiment is to see how well we can estimate π through physical experimentation. After all, that is how it was first found; as the constant ratio of diameter to circumference of all circles.

Left: initial set up. Right: The rain drops and calculation for π.
Many potential methods of approximating π are possible, many of which are described here. However, I thought I'd suggest one more for all of you stuck here in rainy ol' England.
  1. Draw a large square, the larger the better.
  2. Connect two of the corners by a circular arc.
  3. Wait for the rain. A drizzle is better than a down pour.
  4. As best you can, mark the point where each drop hits the paper.
  5. Catch a cold from being out in the rain. Step 5 is optional.
Call the length of the square's side L. The area of the square is then L2 and the area of the quarter circle is πL2/4. The probability of being inside the circle (having hit the square) is then,
Area of circle/Area of square=π/4.
This can also be estimated through the rain drop data as,
Number of raindrops in the circle/Total number of rain drops inside the square.
Equating these two we find that: four times the above fraction (gained from the data) is an estimate of π.

Good luck with your estimations and I look forward to seeing the results.


Monday, 18 February 2013

Finding the impossible

Over the past few weeks we have been looking into stable and unstable objects. Our aim is to try and find a shape that is a natural weeble. Specifically, we want a solid shape that has constant density throughout (i.e. it is made of only one material) and this shape must have only one stable equilibrium point and one unstable equilibrium point.
Figure 1. Gábor Domokos and Péter Várkonyi.
Finding this shape has not been an easy task and became an obsession for a couple of mathematicians: Gábor Domokos and Péter Várkonyi, from the Budapest University of Technology and Economics. Early this year I was very fortunate to meet Gábor and learn, firsthand, the lengths that he went to, to prove the existence of such a shape.

Figure 2. Pebble beach on Rhodes.
Gábor worked on this problem for a long time, making headway to a final goal, but a proof of existence or non-existence eluded him. Thus, he did what any good scientist would do; he did an experiment. Whilst on holiday in Rhodes he collected 2000 pebbles from a beach and, along with his wife, set about catergorising the pebbles by their number of stable and unstable equilibria. Although he found many interesting shapes (and attracted the attention of a couple of police officer as he was returning the pebbles to the beach) he did not find the one he was looking for.

Figure 3. Part of Gábor's stone collection, ordered according to (number of stable equilibria, number of unstable equilibria).
During their work they found many clues pointing to the properties that the object must have (if it existed). For example, they discovered that such an object could neither be too flat object, nor too thin. If it was two flat, like a piece of paper, then it would be would have two stable equilibria, one on each of the flat sides. Similarly, a thin object, like a baguette, will generally have two unstable equilibrium points at the tips. This suggested that if the object existed and was perfectly smooth then it would have to be very close to a sphere.

Using this information they started modifying the sphere and, finally, they did it. They found a three-dimensional object that had exactly one stable equilibrium point and one unstable equilibrium point. In other words they had theoretically shown that it was possible to create a weeble using only one material (you did not need to weigh the end). However, because they wanted a smooth solution their initial shape was incredibly close to the sphere. This meant that although they had proven the principle it would not be physically possible to make such a shape as the error tolerance in the construction was so low.

Building on this, they decided to relax their desire of smoothness and so the shape could have corners. This allowed them much more freedom and eventually they produced a shape that was visually very different from the sphere (see Figure 4), but still maintained the property of having only one stable and one unstable point.

Figure 4. The computed solution on the left and a fabricated version on the right.
Due to the mathematics showing that the smooth object should be close to a sphere the shape was called a gömböc (pronounced gumbuts), which is a diminutive of the word gömb ("sphere" in Hungarian).
Below is footage, taken by Alain Goriely, of a gömböc that Gábor brought to Oxford.


The final post on this subject will be in two weeks and we will take a look at one of the most amazing natural uses of the gömböc.
________________________________________________________________
________________________________________

Gábor Domokos and Péter Várkonyi pictures: http://www.gomboc-shop.com
Gömböc pictures courtesy of Gábor Domokos.

Monday, 4 February 2013

The egg of Columbus

Figure 1. An egg standing to attention.
Last time I demonstrated that if a weeble of uniform density existed, then it could not be effectively 2D. This then led to considerations of the stability of 3D shapes in order to try and find the elusive shape with exactly one stable equilibrium point and one unstable equilibrium point. Since we can construct shapes with lots of stable points what we would really like to do is find a find of reducing this number. However, today, we take a sleight detour and consider the opposite problem of making an unstable point stable!

We start with a challenge (supposedly) set by Christopher Columbus. Whilst dining one night, a nobleman approached him and suggested that finding the Americas was not that impressive because anyone sailing out that way could not have missed them. In reply Columbus challenged the nobleman to take a normal egg and place it so it stood upright. Now, there are many ways of doing this, but most use some other piece of apparatus (such as alternating current), but Columbus used only the egg.

When the nobleman gave up Columbus simply took the egg and tapped it gently breaking the top of the shell, making it flatter. The moral of the story is normally anyone can solve a problem once they have seen a solution. However, for us, the story shows how to make unstable points stable.
Figure 2. Stabilising the unstable. By flattening the top the egg becomes stable upside down.
What is more amazing is that you can actually rigorously construct a mathematical algorithm that does exactly this flattening operation. Thus, if a uniform density weeble does exist then following this algorithm will allow us to construct a solid with any number of stable equilbria.

In two weeks we return to the trail of finding this illusive shape.

________________________________________________________________
________________________________________

Monday, 21 January 2013

Lazy eggs

Figure 1. Lazy eggs don't stand up.
Last week I introduced the idea of stable and unstable equilibrium points using weebles as an example. As I mentioned, they work because their bottom is much heavier than the rest of the toy. However, suppose now that the weeble is constructed from a completely uniform material. Thus, the bottom would only be heavier if it had a larger volume of substance was put there. Would the weeble still work? This is the question we will be starting to look at this week.

It may surprise you but the simple answer is actually in your fridge! An uncooked egg’s density is pretty constant throughout its shape. There are small differences between the shell, albumen and yolk but they are unimportant and it is obvious to see that eggs don’t stand to attention [1]. The eggs actually have an infinite number of equilibrium points because they can be rolled over to any point on their side and they won’t move.

So a uniform egg shape won’t stand up, but will any shape? Mathematically, what we are looking for is a shape that has exactly one stable equilibrium point and one unstable equilibrium point.

Before we consider the 3D case, let us remove a dimension and consider flat 2D shapes. For two-dimensional convex shapes it can be proven that:

all planar, convex, homogenous shapes have at least 2 stable and 2 unstable equilibria.

A sketch of the proof can be found below. Hence, we know that if a weeble of uniform density exists then it cannot be effectively two-dimensional. What we can observe is that the 2D oval has two stable equilibria and for any number greater or equal to three the regular polygon with “n” sides will have “n” stable equilibria.


But what about three dimensions? Sadly, things are not so simple. However, when logical proofs are not forthcoming mathematicians are just as open to experimentation as any other scientist.

Below are a number 3D shapes, have a go at counting the number of stable equilibria they have. The answers can be found if you scroll down past the theorem proof.
Figure 2. A cube, a square based pyramid and a cylinder with edges sliced at an angle.
Now that you have got a feel for finding stable equilibria, have a think about what kind of shape would have one stable equilibrium point and one unstable only. Are you sure it even exists? Before we answer this question we take a detour next week and show how we can make our eggs not so lazy!

________________________________________________________________
________________________________________

[1] It is possible to get your eggs to stand up right if you hard boil them and give them a spin. http://charlottemasonway.blogspot.co.uk/2012/09/weekly-wrap-up-week-4.html


________________________________________________________________
________________________________________

Proof of theorem 1

Consider a 2D convex object that has only one stable and one unstable equilibrium point. Define a function, R(ɵ), that is the distance of the perimeter away from the centre of gravity as shown in the figure on the left. The function depends on the angle ɵ (measured in radians) around the centre of gravity and so as ɵ increases from 0 to 2π the function, R, will do one revolution of the shape.

Now consider the graph of R. By assumption there are only two equilibria, one stable and one unstable, thus, the corresponding graph has just one maximum and one minimum, as shown in the figure on the right. This is how the equilibria where defined last week.

Suppose we now drop a horizontal line across the graph. In particular let the points at which the horizontal line touches the graph be separated by an angular distance of π radians. This will correspond to a straight cut through the shape. Call this corresponding value R0.

By definition everything above this horizontal would be the part of the shape that is further than R0 away from the centre of gravity and everything below would the part of the shape closer than R0 to the centre of gravity. This means that one half of the shape would be bigger than the other half, and, thus, heavier. But by definition the cut goes through the centre of gravity and so each side weighs the same. As we come to a contradiction, our original hypothesis (that such a shape exists) must be wrong.
________________________________________________________________
________________________________________

Answers

The cube has 6 stable equilibria; one on each of the flat faces, as shown.
The cube has 5 stable equilibria; one on each of the flat faces, as shown.
The sliced cylinder only has 1 stable equilibrium. However, it is not a shape that satisfies our need because it has 3 unstable equilibria; one on the top of the cylinder and one at each of the tips.

Monday, 7 January 2013

Sense and instability

Figure 1. A worried little weeble.
Did you ever have set of weebles? I did. They were wonderful little toys that lived up to their advertising slogan of “weebles wobble, but they don’t fall down”. The whole premise was that you got a set of several small plastic egg shaped characters (as seen in Figure 1) that would always wobble back to an upright position, no matter what position you started them from. As you can imagine hours of fun could be had with these little things.

The toy's mechanism is very simple. The bottom of the weeble is much heavier than the rest of the body, this means its centre of gravity is very low. Due its egg shaped body the weeble will always wobble such that its centre of gravity is at its lowest point. The applet below shows how this idea works [1]. On the left shape click on the red star which is the centre of mass and move it around the shape. The effect can be seen in the shape on the right. The shape on the right can then be grabbed and started from different initial points. However, it will always evolve to a stable point.


Why am I talking about weebles? Well, they are a really nice way of demonstrating how mathematicians understand equilibrium points, stability and instability. Although theoretically if a body was placed at its equilibrium points nothing further would occur, we know that physically we cannot be that accurate. Thus, equilibrium points can then be separated (generally) into stable and unstable points [2]. Thankfully, the mathematical notion of stability accords with our everyday use of the word. A body is stable if given a small push (or perturbation) it returns back to its previous position.
Figure 2. A wobbling weeble.
For a concrete example of this consider Figure 3, which is a schematic diagram of a curved bowl containing some balls. A is a stable equilibrium point; if the ball is given a small push it will return back to A. If the ball is given a big enough push it can roll right over the dividing line into the C position and this is also a stable equilibrium point. Now consider placing a ball at B. Since the bowl is completely flat there B is also an equilibrium point. However, it is an unstable equilibrium point. This is because no matter how small a push the ball is given it will never head back to B, but rather roll to one of A or C. Importantly, stability is only defined at points A, B and C because these are the only equilibrium points.

Figure 3. Illustrating stable and unstable equilibrium points.
A similar idea is applicable to the states of the weeble. When the weeble is upright it is equivalent to the ball being at A or C; the weeble is at a stable equilibrium point. Now suppose you could balance the weeble perfectly on its head, such that the centre of gravity, G, is directly above the flat point of its head, as in Figure 4. This is equivalent to the point B in Figure 2. It is an equilibrium point and, so, theoretically, if placed there, with no perturbation, then the weeble would stay there forever. However, any perturbation, no matter how small, will cause it to flip over and turn the right way up.
Figure 4. Stable and unstable weebles.
In two weeks time I will continue this topic and see what happens when we remove the possibility of weighting the bottom and only depend on the geometry of the object.
________________________________________________________________
________________________________________

[1] All credit of the applet goes to this website: http://l.d.v.dujardin.pagesperso-orange.fr/ct/cusp.html

[2] Note that there are also saddle points and centres but we’re not going to talk about them as they’re special cases that few people care about. Also, the stable and unstable points could each be further split up into oscillatory and non-oscillatory points but again we’re going to ignore this complexity.


Monday, 24 December 2012

Santa’s job is harder than you think!

Who wouldn’t want to be Santa? You work one day a year, people give you mince pies and you spend the rest of your time deciding who’s naughty and who’s nice. However, Santa’s job is more difficult than you might think and he is certainly a mathematical genius who could win $1,000,000!

Efficient packing is an Elf's forte.
Let’s focus on just two of his important tasks. Firstly, he has to pack his sleigh full of toys. Annoyingly, toys are not all the same shape so how does he efficiently pack his sleigh? Either he is excellent at Tetris, or he has managed to solve an extremely difficult maths problem known as “bin packing”. The problem is, simply stated, ‘given a fixed amount of space and packages of different sizes, is there a complete list of instructions that will allow you to make the most of the space?’


Santa's problems are bigger than his belly.
The second problem he faces is finding the quickest route around Earth that visits every house. This is known as the “travelling salesperson problem”. Is it possible to find a recipe that will always give you the fastest route?

In both cases no one knows the answer. What is worse is that we don’t even know if there is an answer! Mathematicians describe these problems as “NP” (Not Polynomial). This means that the difficulty of finding the best solution increases dramatically whenever you add another package or house.

Although these problems may be placed in fantasy, real life logistic companies face these obstacles every day and solving them would save a fortune. In fact, the solutions are so important that the Clay Mathematics Institute offers one million dollars to anyone who can either produce a method that works flawlessly, or show that one doesn’t exist.

So until Santa decides to retire and give up his secrets, that million is waiting for the right mind. Who knows? It could even be yours.

Merry Christmas from the Laughing Mathematician and see in 2013 for a new set of posts on the gömböc.
A very seasonal Turing pattern.

Addendum
Although we may not able to solve the problem yet we can still take a peak at Santa's solution. The United States and Canada aerospace defence organisation, known as NORAD, take it upon themselves to track Santa every year as he travels around the globe. You can follow Santa's journey through their website, http://www.noradsanta.org/.
A previous NORAD tracked route of Santa's.
________________________________________________________________
________________________________________

An abridged version of the above post first appeared in the Oxford Mail 20/10/12.

Wednesday, 19 September 2012

Everything is Mathematical

The set of Everything is Mathematical books.
I've recently been involved with a new mathematical project called Everything is Mathematical. A group of Spanish Mathematicians have written a comprehensive set of popular maths books, which have proved so successful that they're being translated into other languages, including English. The team behind the series have joined up with The Times newspaper and Marcus du Sautoy to present the series to the British audience.

But where do I fit it? Well, to generate some interest in the series they're producing a number of maths challenges that can be found on their website (mine is below).
 
Some of the challenges are fairly standard and well known, however, there are a couple of gems in there that I had never seen before! Keep a look out on the website for the weekly challenges. If you do solve one of the problems there is a competition you can enter. The winners receive a free subscription to the entire set of books.

Now since there are 40 in the set and each one is £10, you may need come convincing before you part with your cash. To get you interested I thought I would review one of the books. Of course since I'm working with these guys you'll have to weight my review with the fact that I'm biased :) (although I'll try to remain neutral).

Who are they for?
Based on what I've read I think these books are more suitable for an older audience. It could certainly appeal to those who were educated in numerical subjects and then left due to career decisions, but never lost their interest, as well as those who never really got on with mathematics but realise its importance. Having said that I could also also see parents buying a set to enhance their children's education as school as well as benefit their own interests.

Appearance
The first thing I noticed about the series is the sheer comprehensiveness of the books. To be honest, I'd be hard pressed to even name 40 different mathematical fields! The books cover all the standard aspects such as geometry, symmetry, probability, etc. but then goes further with books on the mathematics of our senses and perception, artificial intelligence and, of course (my favourite) mathematical biology.

You may think (as I did) that, by spanning so many subjects, each one would be a pamphlet in size. Here, again, I am pleased to say I was surprised. Each book I've seen is a really nice hard back spanning over 100 pages in length. They contain: nice clear diagrams; formulas; anecdotes about the history; fact boxes and even problems to challenge you.

Book number 1.
What about the content? 
Well here is my first admission: I haven't actually read the first book. The first one is all about the golden ratio and its geometry and to be honest, I've never been a fan of the golden ratio because even though it has some extremely nice mathematical properties I find that discussions quickly descend into numerology [Rant 1]. So, instead of starting with The Golden Ratio, I jumped straight in with "When Straight Lines Meet" a book all about non-Euclidean geometry.

Now I would've expected the book to have started with easy stuff, y'know setting up the cartesian coordinates and linear geometry leading on to hyperbolic and elliptic geometry later. How wrong could I have been? The first chapter drops you straight in by explaining the taxi cab metric, using the city of el Ensanche as an illustration.

el Ensanche's very regular city set up.
This is certainly one of the strengths of the books. They use of definite, tangible examples allowing them to discuss complex ideas and very quickly outstrip even my knowledge! For example I had never heard of Girolamo Saccheri's contribution to non-Euclidean geometry.

Each chapter is completely different and could potentially be read independently. For getting a deep overview about a specific aspect (history of geometry, curved space in relativity, uses in computing, etc.) then this format is very appealing. However, it lacks an overarching sense of story that will keep you reading all the way through like the best popular science books can.

What is good to see is they're not afraid of displaying mathematical functions and formulas and then challenging you to calculations that actually mean something, e.g. why calculate the length of a line of a sphere when you can calculate the distance between New York and Sydney on the Earth?
Summary
£400 is a steep price for a comprehensive set of popular maths books, although calling them "popular" perhaps does not do them credit. Think of them more as a set of encyclopaedias of the mathematical world, but with each chapter being eminently more readable than a fact driven summary of events.

There is no better set that will give you the range and depth of subjects available. Due to their diverse nature you will discover topics that interest, entertain and even surprise you. Thus, if you have want to see what mathematics can really do outside of the classroom then these books are you.
________________________________________________________________
________________________________________

[Rant 1] Of course you're going to find things in the golden ratio if you look for it. Any ratio can be found in nature if you look hard enough. I freely admit that in certain cases you can attribute inspiration to the golden ratio, e.g. Le Corbusier's architecture or Dali's and Da Vinci's paintings. However, these are explicit uses. Stating that certain natural phenomena occur in the golden ratio is much dodgier.

To really believe that the ratio is there I would want to understand WHY it is there. This is the essence of mathematical biology. Biologists observe phenomena, mathematicians try to understand its cause. For instance, there are reasons why the golden ratio/ Fibonacci's sequence should appear in sunflower seed packing as it is the optimal packing ratio. Compare this to the claim that your fingers are in the golden ratio and the suggestion that beautiful people are more in the golden ratio than not. Not only are you left asking why but you're suggesting that people who don't fit your rigid proportions are ugly!

The golden ratio supposedly appearing in the human body.