Archive for March, 2011

I’ve seen some really bad methods for drawing confidence ellipsoids recently, they all seem to make it really complicated and confusing (and specific). So I thought I would show how to calculate points on an ellipse corresponding to a covariance matrix – this method works for any number of dimensions without any need to change it.

For all those that don’t care why, the method to generate the points of an ellipsoid is as follows:

1) make a unit n-sphere (which for 2D is a circle with radius 1), call these points X:

If it is an elipse you want, make a matrix with columns of and for some incrementing values between and (=开)

2) apply the following linear transformation to get the points of your ellipsoid (Y):

where M is the vector of the means (center of the ellipsoid) and is the covariance matrix. C represents the Cholesky Decomposition, sort of a matrix square root. k is the number of standard deviations at which one wishes to draw the ellipse

The Cholesky decomposition can be accessed as, “numpy.linalg.cholesky” in Python, “Cholesky” in R (matrix package), “chol” in MATLAB and “spotrf” (amongst others, I think) in LAPACK

Here are some well-established things that are being done wrong and should be changed.

1.

Pi, that most fundamental of mathematical constants. Except that pretty much whenever you see it in an equation it’s always got a 2 along with it. This is because pi is defined as the ratio of a circle’s circumference to its diameter when it really should have been defined in relation to the radius instead. That’s why there’s radians in a circle instead of , which would make more sense.

I was cheered to discover recently that there are others who share this opinion. The link is to the “Tau Manifesto”. They make a good argument that one should define a new circle constant represented by the Greek letter (tau), such that . I agree with their argument, but still sort-of prefer my own idea, which was to replace by a new character which looks like one stacked on top of another, like this:

开

This character would be called “cake”, so the above equation would be read “cake equals 2 pie”. Which is true.

Let me prefix this by saying that the early universe was a very boring place. There was a lot of energy, (at one point too much to even allow the formation of matter) and everything was very ordered with no interesting features. The proof of this comes from the recently measured cosmic microwave background radiation which found that at the point it was created (about 370 000 years after the big bang). The differences in temperature between any points in the universe were around one part in 100 000 (i.e. if it was 100 000K then the max temperature difference would be 1K). A rough idea of the second law of thermodynamics would also make this clear that it is required – if everything gets less ordered with time (entropy increases) then the start of the universe must have been a very well ordered place.

I have decided that the subject of my posts will not be about a particular subject and will not have any prolonged subject matter as I find it very difficult. They will however contain things I found interesting about science and the general world. The starting point of these rambles will be nothing.

This is kind of a follow-up to Lucas’ previous post on the communication of science. In that post, Lucas argued that part of the problem in communicating science to non-scientists comes from a failure to teach philosophy. I completely agree with this.

One of the most useful parts of philosophy, from an educational point of view, is logic. I mean the really basic, “if Socrates is a man, and all men are mortal, then Socrates is mortal” stuff. Learning this is an important part of learning to assess arguments, and thus learning to think for ones self.

Yesterday, I went to a science communication conference thing at the University of Brighton. Here is what I learned…

So the first thing to say is that it was quite comforting to hear the science editor for The Observer saying that the medias reporting on genetic modification and the measles, mumps and rubella (MMR) vaccine were real failures of science reporting. He even described the reporting on MMR as “a deep burning shame”. Less favorable was the media representatives description of their roles. Both of them said that their job was not to educate, but rather to either entertain or to “hold our masters to account”. Education, if it occurs, is a side effect. I find this slightly worrying – but less so than other people I have talked to. I will not dwell as I have a different point to make.

We all know that those emails offering you a PhD for no work aren’t offering real PhDs, and if you go round making a big deal of it people will most likely take the piss. However there is one way to get a degree from a reputable institution without doing any work, and that is to get a Master’s from Oxford or Cambridge.

A quick update to my previous post about visualising the distribution of wealth: someone called Mark Olmsted has found another, really quite ingenious way to display the data (for the US rather than the UK), over at Huffington Post.

I’m not an expert on menstruation. I’ve never done it, or had any reason to take a significant interest in it. But I had heard that women living together often “synchronise”, i.e. start to have their periods at the same time. Synchronisation is something that interests me, so I decided to look it up.