Sunday 13 May 2012

Metrics

Hi. I wanted to avoid making this blog become little more than the diary of an ever-repeating cycle: I got behind schedule; I had a TMA due in and stayed up all night to finish; I got the results back. That certainly seems to be the way it's been going recently, so I have decided this time, to talk about some of the actual maths we've been up to lately, namely 'metrics'.

Why metrics you may ask if you're familiar with them. What are metrics you may ask if you're not. Good questions. The easy answer to the first is that I quite enjoyed them. The easy answer to the second is below. (It should probably be noted here, that I don't have the books with me, so I'm likely to make some mistakes...)

Metrics are a generalisation of the concept of distance between two points, that satisfy three axioms:
(M1) d(a, b) ≥ 0 with equality if and only if a = b.
(M2) d(ab) = d(b, a)
(M3) d(ac) ≤ d(a, b) + d(b, c)
So basically, and also quite obviously, the distance between two points a and b is always non-negative, and is 0 only if the points are in the same place. The distance from a and b is the same as from b to a. And yes, (M3) is our old friend the Triangle Inequality. The direct distance between two points a and c, is not more than it would be via a third point b.

Metrics have been my favourite part of the topology course thus far. To begin with, even within the highly abstract realm of topology, metrics have a very easy to grasp real-world basis, since after all, we talk in terms of distance all the time (as it goes, the basic distance we use is the 'Euclidian metric'). One of the first different ones presented in the text is the 'taxicab metric' (e1(a,b) = |b1 – a1| + |b2 – a2|, the sum of the horizontal and vertical distances between a and b), which gives us the distance a taxi would travel to get from a to b in a city based on a block design, where roads only run in two perpendicular directions. Indeed, without knowing, we all use such an alternate measure of distance (albeit one that's a bit harder to define than the taxicab metric) which is the distance between two places via the roads. So the concept of different definitions of distance is really not all that alien.

With a particular metric, one can define an open ball Bd(a, r), which is the set of all points with distance less than r (the radius) from point a, a sphere Sd(a, r), which is the set of points with distance r from point a, and a closed ball Bd[a, r], which is the set of points with distance less than or equal to r from point a. Or, simply the union of the open ball and sphere. In two and three dimensions, things are pretty intuitive; in the plane, these are a disc, circle, and disc with boundary respectively, which fits nicely with our idea of balls and spheres as being round; in 3D, it can be pictured as something like the air inside a (round) balloon, the rubber of the balloon as the sphere, and then both together as the closed ball. Take it down to one dimension, on the real line, and things are not so round. The sphere is just two points, a –  r and a + r, but it makes sense considering the definition, because they're the only points with distance exactly r from point a. Well that was all with the Euclidian metric. But what about other metrics? Well, the definitions work just as well when we have another type of distance, another metric. With the taxicab metric, for example, balls and spheres end up as squares rotated by pi over 4. Squares balanced on a corner. And on it goes, getting less and less ball-like as we take less familiar metrics.

Which is the charming thing about metrics, the weirdness of abstraction: take for example, distances between infinite sequences of 1s and 0s, or distances between functions! Not something the average human considers on a daily basis, true, but defined appropriately, they can be shown to satisfy (M1) to (M3) and therefore qualify as metrics. If memory serves, the distance between infinite sequences of 1s and 0s was something like: given two such sequences a and b, then d(a, b) = 2-n, where n is the number of the position where they first differ. So if = 1,1,1,0,1,0,0,0..... and = 1,1,1,1,1,0,0,0....., then they first differ at the 4th place, so their distance apart is 2-4 = 0.0625. (Is that right? I can't remember, but it's something along those lines anyway).

I'm starting to drone on a bit, but I wanted at least, to mention the thing that first made me ponder writing about metrics, and that was the interesting one we encountered recently, namely the 'vine-picker's metric', which was in our recent TMA. I figure it was long enough ago that it's not a problem to discuss it, and anyway, I'm not going to go any further into the question than the info on the assignment booklet. A week or so after the TMA was done, I cleaned some space on my blackboard and had a little play with the vine-picker's metric. It is defined as:
d(x, y) = |x1 – y1| if x2 = y2, or |x1| + |x2 – y2| + |y1| if x2  ≠  y2.
Below is a photo of my blackboard. On the left is the rule and graph, and on the right is some vine-picker distances worked out for points on the graph.


So, we end up with a situation that's as if there is something stopping you from moving in the up-down direction, unless you are above the origin, like there are impenetrable grape vines blocking your way, and the only gap between them runs vertically through the origin (for the record, my diagram simplifies it somewhat; in this case the points have integer coordinates, so the vines could be drawn in).  To travel from one point to another in vine-picker metric terms, you therefore have two cases: if the points are at the same "height", (x2 = y2), you just go directly horizontal, but if they're not at the same "height" (x2  ≠  y2), then you must walk horizontally to the axis, then up (or down) to the appropriate height, and then back out to the second point. The example on the blackboard demonstrates d((2, 3), (8, 3)) = 6 and d((5, 1), (3, 5)) = 12.

Of course, the vine-picker's metric satisfies (M1) to (M3). We had to prove some stuff about it in the TMA.

Anyway, that's metrics. Very cool indeed. It's only Unit A2 of Topology, so there's clearly plenty more fun where that came from. For what it's worth, it was the surfaces and shapes side of topology that I was really looking forward to (surely that was the case for most of us?). However, since I've been going back through (or indeed simply "through" in certain cases) and more carefully learning block A, I'm beginning to really enjoy the point-set variety.

Thursday 10 May 2012

In Our Time

I've been listening to Radio 4 for more than 5 years now, and (despite loving I'm Sorry I Haven't a A Clue, Laura Solon's Talking and Not Talking and various other 6.30-slot comedies) my favourite program remains In Our Time with Melvyn Bragg. Little can make you feel as sophisticated and intelligent as listening to Baron Bragg and his distinguished academic guests discussing the fall of Carthage, the Observatory at Jaipur, Schopenhauer, or some other deep topic.

Anyway, every now and then, we get treated to a maths topic for 45 minutes, usually involving Ian Stewart and Marcus Du Sautoy. I've heard discussions on Godel, infinity, the Calculus, the Poincare Conjecture, pi and many more subjects In My Time :)

After what seems to have been forever (though I could easily have missed some without noticing), it was a mathsy topic again this morning, namely Game Theory. I'm not overly interested in Game Theory myself, but it was entertaining enough, and gave me something to listen to while doing the washing up and tidying the kitchen. Ian Stewart was there as anticipated, and was as brilliant as ever. I'm quite an Ian Stewart fan for what it's worth. I made the (blindingly obvious) prediction to Kim, that John Nash would get a mention, and lo, at 18 past 9, he did. Other stars included von Neumann, and a tramp.

If anyone's interested, a cut-down-to-thirty-minutes version is usually repeated at 9.30pm tonight. It's also available on the Radio 4 website, as are all the episodes of In Our Time since 1998. Actually, I got rather good at Minesweeper a few years ago when I played it to keep myself visually stimulated (I tend to drop off eventually if the only thing I am doing is listening to something) while going through all the science and maths ones that caught my eye... and there were quite a few. I'm not very cultured, so I didn't bother with the art, philosophy, religion, &c, but I do listen to them if they're "live."

More maths please Melvyn!