28 June 2009

The Special Theory of Relativity by David Bohm

I just finished reading The Special Theory of Relativity by David Bohm, based on Bohm's undergraduate lectures at Birkbeck College. Bohm approaches relativity in a somewhat unusual way: he focuses on exposing the implicit assumptions that underlie our common-sense notions of spacetime; it is these assumptions that make relativity seem paradoxical for many people. For that reason I consider it worth reading, even if you've studied relativity before. In addition to the material on relativity itself, Bohm also has some insightful comments about the nature of scientific inquiry as well as about the development of human perception and how we acquire our common-sense notions of spacetime.

Some take-home points:

  • Lorentz and proponents of the ether theory actually had predicted many of the well-known relativistic effects (e.g. length contraction and time dilation for moving objects). One of Einstein's major contributions was to focus solely on relationships between objects, which are in principle observable, rather than on substances like the ether, which are not.
  • Relativity of simultaneity (i.e. the fact that observers can disagree on whether events occur at the same time or not) is very counterintuitive and can be thought of as the source of a lot of the apparent paradoxes in relativity. For example, when you measure the length of an object you record where its ends are at the same time, but the notion of "at the same time" is relative. Length contraction occurs because different observers disagree on what it is that should be measured.
  • It is kind of cute to characterize relativity as saying that "everything is relative" but it is really the things that the theory says are not relative that are of interest (e.g. the speed of light, the spacetime interval, and proper time and mass). It is through invariants that we can understand the aspects of a situation that are really fundamental to it and separate them from those that are contingent, or relative to our viewpoint. The idea is like being able to perceive that a table is circular even if it appears to look like ellipses of various shapes and sizes as we walk around the room. Bohm argues that the same process of inferring invariants is at the heart of both scientific inquiry and human perception.

Star Trek

I watched Star Trek a few weeks ago, and I loved it. It is probably the best movie I have seen this year.

The film is witty and full of wondrousness. The casting is brilliant. And it's both a nice coming-of-age story as well as a chronicle of a remarkable friendship. I'm not sure what more I can say.

20 June 2009

Gödel, Escher, Bach

I just finished Douglas Hofstadter's Gödel, Escher, Bach: An Eternal Golden Braid. It is quite entertaining, no small feat for a book that revolves around Gödel's incompleteness theorems. Highly recommended, if you can tolerate a little bit of math and a lot of punning (Hofstadter is incredibly witty).

In GEB, Hofstadter builds up the argument that minds and machines are fundamentally the same, in the sense that both can be represented by mechanical/mathematical rules. In particular, he shows that a sufficiently complex formal system gains the ability to reason and make statements about itself.

On the way, Hofstadter takes a tour through music, art, logic, neurology, computer science, genetics, Zen... you name it. The scope of this book is astounding.

I think the most intriguing theme is the idea of taking a step back and making generalizations (or induction, if you like) about a system. This property is at the core of what we would call intelligence and is commonly believed to be one of the things that separates us from most animals (and from computers). Hofstadter relates an anecdote about the Sphex wasp to argue that animals are just hard-wired to handle a finite repertoire. But it is kind of chilling when you realize that the same is likely true of humans— the only thing that is different is the size of our repertoire:

[The Sphex wasp] has no ability to notice when the same thing occurs over and over and over again in its system, for to notice such a thing would be to jump out of the system, even if only ever so slightly. It simply does not notice the sameness of the repetitions. [...] Are there highly repetitious situations which occur in our lives time and time again, and which we handle in the identical stupid way each time, because we don't have enough of an overview to perceive their sameness?

Hofstadter concludes the book with some speculation about how the mind might be "implemented" in hardware, i.e. neurons (for example, how high-level pattern recognition happens, and how features in the mind might be represented in hardware) and how we might begin to understand the physical basis for high-level features of the mind (intentions, emotions, etc.). You might find this part interesting even if you skimmed over (or wanted to skim over) the more mathematical content of the book. GEB was written 30 years ago but much of it is still relevant— little of Hofstadter's speculation about neurology has been resolved since.

19 June 2009

Slumdog Millionaire; Terminator; Up

Watched a few movies recently.

  • Slumdog Millionaire was pretty good (provided you think of it as a modern fairy tale, kind of). It paints quite a stark picture of poverty and class divisions in modern India. The ending doesn't totally hang together but the Bollywood dance number before the credits more than makes up for that.
  • The Terminator. As it turns out I watched Terminators 1-3 in reverse order, concluding with The Terminator most recently. It was kind of interesting watching the plots get better and the special effects get worse. (It looks like The Terminator was done in stop-motion. That sounds about right for 1984.) The movie was quite enjoyable. Perhaps it just seemed better because, having seen Terminators 2 and 3 already, the original now seemed more pregnant with meaning.
  • Up. Beautiful concept, top notch visuals. The beginning was poignant and fantastic, but by the middle it had kind of degenerated into "archetypal summer cartoon action movie". Not bad, although it was no WALL-E. But 98% on RT? There must have been something in the water at the screenings.

13 June 2009

Why does the same side of the Moon always face the Earth?

I've long suspected that it was no coincidence that the Moon always keeps the same face towards the Earth, but I never actually knew why until yesterday.

Short answer

There is indeed a negative feedback loop that tends to synchronize the Moon's rotation with its orbit. This phenomenon is called tidal locking.

Longer answer

The Earth exerts a tidal force on the Moon, elongating it in the direction of the Earth-Moon axis (and compressing it in the perpendicular directions). However, since the Moon resists being deformed to some degree (don't we all?), if it rotates faster or slower than its orbital angular velocity, the axis of elongation can run ahead of, or behind, the Earth-Moon axis. In either of these cases, the Earth's gravity provides torque on the moon to slow down or speed up its rotation, respectively. Thus the Moon tends to keep the same face towards the Earth.

The things you learn every day!

10 June 2009

UN launches tuition-free online university

This is cool:

As part of this year's focus on education, the UN Global Alliance for Information and Communication Technology and Development (GAID) presented the newly formed University of the People, a non-profit institution offering higher education to the masses.


For hundreds of millions of people around the world higher education is no more than a dream, Shai Reshef, the founder of the University of the People, told reporters. [...] Mr. Reshef said that this University opened the gate to these people to continue their studies from home and at minimal cost by using open-source technology, open course materials, e-learning methods and peer-to-peer teaching.

Press release: http://www.un.org/apps/news/story.asp?NewsID=30848

07 June 2009

Predictably Irrational, the abridged version

I previously raved about Dan Ariely's Predictably Irrational. So I also eagerly watched the two TED talks he has given, which cover a lot of the same ideas presented in his book, but with a couple of novel anecdotes. They are kind of like the Readers Digest version of Predictably Irrational, and I recommend them if you can spare 35 minutes:

Now, in any introductory psychology or economics class you learn a lot about cognitive failings, or apparent deviations from rationality. I think that what makes Dan Ariely's books and talks so valuable is that in addition to pointing out our flaws, he gives advice on how we can work around them in order to make life better for people. I think the conclusions from these two TED talks are, in particular, quite important:

  • We can create more effective institutions if we design them so that they take into account our cognitive limitations, rather than designing them under the assumption that we (the users) are beings of perfect rationality.
  • We could find many better ways of doing things if only we were willing to test our intuitions with experiments.

01 June 2009

Effective Java

I just finished re-reading Effective Java by Joshua Bloch.

Most of the problems described in the book do not have super subtle roots. When you read about each issue it is easy to understand in retrospect the source of the problem and how to avoid it. Yet, and this is really sobering, even the designers of the Java libraries made many of the mistakes described (the book has lots of Java war stories). And they are still paying for some of them so that they can maintain API compatibility. This book represents a lot of collective experience that Java programmers have acquired over the years. So it's really valuable to have all these tips in one place. In addition, Bloch's writing is fantastically lucid, one of the best among all technical books I've read.

I had read Effective Java before but now that I'm actually working on some big Java projects (for work, not hobby) I think I had a much higher absorption rate than before.

I had the first edition of Effective Java on hand, which was written for Java 1.3. The second edition was published in 2008 and includes new chapters about, among other things, generics, which were introduced in Java 1.5. Conveniently enough, the book's website has the chapter on generics as a free download. Since generics can be sort of tricky to get right I recommend reading that chapter (did I mention it's free?).

As a bonus, I now know what the heck these declarations

static <T extends Comparable<? super T>> void sort(List<T> list)
static <T> T max(Collection<? extends T> coll, Comparator<? super T> comp)

(from Collections in the Java API) actually mean, and why they are the way they are. (See items 27 and 28 in the chapter on generics.)