Programming, mathematics and 1984

I’ve been spending quite a lot of time in the last few days coding some web applications in the programming language PHP. While writing libraries of reusable code, I realised that some of the design issues have interesting parallels both to the expression of mathematics, and the linguistic aspects of Orwell’s classic novel 1984.

First, for newcomers, some software engineering jargon: classes are collections of code and associated data that are written to behave as coherent objects, which are then”plugged in” to other parts of programs, or indeed each other, to create entire programs. For example, a simple text entry box is an object, that stores whatever is typed in it, along with code to describe how to handle keyboard activity within the box, how to draw the box on the screen, and so on.
Continue reading “Programming, mathematics and 1984”

Supercomputing in your living room

Just read an article in the Economist, confirmed by many other sites, like say Eurogamer.net. It’s about the new processor released by Sony, IBM and Toshiba, called the Cell. It’s got a central processor that sends “packets” of code and data to each of the eight actual processing centres on the chip, or to nearby other Cells if multiple chips are included in the setup.

All this means it’s not aimed (at this stage) at PC’s, as it will only run code that has been split into this “packets”. So supercomputers with customised code are an obvious application.

But the other application is the Playstation 3. It looks like there may be 4 Cells per Playstation. Here’s the punchline: if it were released today, that would put each individual Playstation 3 in the top 500 supercomputers in the world.

Ah yes, remember the days when the rumours required (insert “Axis of Evil” country of choice) to have hundreds of Playstation 2’s to have a supercomputer…

Knots and different dimensions

It seems that most of the time these days, I being asked to think about things in a different number of spacial dimensions than 3 (up-down, left-right, forwards-backwards). Now, some properties follow through to additional dimensions quite easily, but I was thinking recently about one that doesn’t: knots — it’s a great example of the tricks that dimensions can play on one.

What’s a knot? Take a piece of string (an object extended in one dimension). Form a loop and feed it through the loop. The knot so formed cannot, by continuous deformation of the string, be “undone” without moving an end of the string back through the loop.

But knots only exist in three spacial dimensions.
Continue reading “Knots and different dimensions”