You probably think you are sitting in Euclidean space right now. But how can you be certain of this? Isn't it possible that you are living in a geometry that looks exactly like Euclidean space inside a sphere centred on the earth with some enormous radius (let's say a few light years) but outside that region is different? How could you tell? In fact there are non-Euclidean geometries that locally look like Euclidean space but globally are not Euclidean space. I would love to know how Euclid would react to this suggestion.

But now the story is getting out of order. It all starts with Euclidean geometry. Euclid proposed various axioms or postulates in his Elements and starting from those deduced the familiar theorems of Euclidean geometry. One of those axioms, the parallel postulate, seemed less basic than the others and many people tried (unsucessfully) to show that it could be deduced from the others. Fast forward two thousand years and Gauss solved the problem. He showed that there was a very interesting geometry, called hyperbolic geometry or Lobachevski geometry, which satisfies all of Euclid's axioms except the parallel postulate which he replaced by a variant. The reason Lobachevski gets a mention here (and also János Bolyai) is that Gauss didn't publish his results. Lobachevski published in 1826 and Bolyai in 1829, ten years or so after Gauss' discoveries.

To go further than this we need to make a precise mathematical definition of what a geometry is and we need to see some examples to convince us that the notion is worth pusuing. Let's just say for now that a geometry is a set equipped with a distance function that has to satisfy certain natural properties. From this point of view Euclidean space with the usual Pythagorean distance is just an example of a geometry. This is a modern way to think about geometry, where we have properly divorced mathematics from the real world. That doesn't mean that we must stop using our intuition to guess what might be true, but we always remember that mathematics is what follows from the axioms of set theory, not something that we measure or observe. Of course this point of view doesn't stop mathematics from being useful for modelling the real world! Actually, it's worth pointing out that there are some problems with Euclid's axioms and his logic. Despite this the Elements is an incredible achievement and we shouldn't be too harsh. Euclid was a man of his time.

Let's consider spherical geometry. First of all we have the natural distance function on the sphere, the distance between two points is the shortest distance travelled by walking from one point to the other along the sphere surface. This is not some abstract nonsense, this is how we measure distance on the earth! Also, note that this is not the same thing as the Euclidean distance between these points (travelling along a straight line burrowing through the earth is not very congenial just to get from A to B). For example, if the sphere has diameter d then the distnace between the two poles in spherical geometry is d.pi/2 whereas the Euclidean distance is d.

Once you have a distance function that satisfies certain natural properties you are ready to do some geometry. What is the correct notion of line for this geometry? It turns out that great circles of the sphere are the analogues of lines. Think about it. This is a big difference from the usual Euclidean geometry. Suddenly lines have finite length! If you take two distinct points on the sphere that are not antipodal then there is a unique great circle passing through the points (just like Euclidean geometry). But if they are antipodal then there are infinitely many great circles through the two points! So this is quite different from Euclidean geometry where two distinct points determine a unique straight line. Another interesting difference is that sum of the angles in a triangle. turns out to be greater than pi. Enough non-Euclidean weirdness, it's time for the definition now.

Definition A geometry is a set X together with a function d:XxX-->R that satisfies the following axioms for all a,b,c in X.

  1. d(a,b)>=0 and d(a,b)=0 iff a=b.
  2. d(a,b)=d(b,a).
  3. d(a,c)<=d(a,b)+d(b,c).
  4. Given any two points a,b in X and any two positive real numbers d,e there exist points p1,...,pn such that p1=a and pn=b,
    for 1<=i<=n-1, we have d(pi,pi+1)<d
    and
    0<= d(p1,p2)+...+ d(pn-1,pn) - d(a,b) < e.
The first three axioms are fairly natural for a notion of distance, so let's just discuss the last one. Intuitively you should think of this as saying there is a curve in our geometry joining a and b (approximated by line segments pi to pi+1 of the definition) so that the distance along the curve is the distance between a and b.

Here's another example a geometry on the torus. This is a nice one. We start with a square strip

  --------------
 |   B          |
 |              |
 |A           A'|
 |              |
 |              |
 |              |
 |   B'         |
  --------------    
and we imagine that the points on opposite edges are identified. So, for example, we think of the edge points B and B' as being equal and likewise A and A' are equal. Topologically what we get from this identification is a torus. Think about physically glueing the edge with point A on it to the edge with point A' on it, to make a cylinder. Then stretch and bend this cylinder around to glue its two ends together. Now we want to think about distance. This is defined as follows, for two points a,b on the strip the distance between them is just the usual Euclidean distance except that if we get a shorter distance by using the edge identification to zip from one edge to another then we will always take that.
  --------------
 |              |
 |              |
 |    a  b      |
 |              |
 |              |
 | a'        b' |
 |              |
  --------------    
For example the distance from a to b for this geometry is the same as the usual Euclidean distance but the distance between a' and b' would be the sum of the Euclidean distances of a' to the left-most edge and b' to the right-most edge.

It is tempting to think that this example is quite similar to spherical geometry, we just replaced a sphere by a torus, but this is wrong. When we made the identifications to create the torus, the bending and stretching we did distorted distance, so the distance between two points on the torus for this geometry is not just the distance we get by walking along the surface of the torus.

One of the important ideas to grasp here is that we are thinking about geometry from the perspective of an inhabitant of the geometry. We are not thinking about our set as sitting inside some Euclidean space. What we are doing here is intrinsic. This thinking, which is the modern viewpoint, goes back to Gauss.