Basic Mathematics

by Charles Miller on September 14, 2003

Yesterday, I spent most of the day with Alan and David hacking on a Robocode-style game in Python. It was a good excuse to get my hands dirty with the language, and get some idea of what it's like to code in it.

(I am completely un-apologetically a Ruby hacker, which means that every time I try to write a Python app, I end up writing it in Ruby instead because that's what I'm more familiar with, and I can't really see any particular advantage in switching.)

Anyway, as part of the game, there are some pretty simple mathematics that need to be handled: coordinate geometry for the map, and predicting the movements of ships based on their thrust and speed of rotation and acceleration.

I sat staring at the screen for a very long time. It seems that ten years after leaving school (and five since I last studied mathematics in any meaningful way) my mathematical skills have atrophied to the point where I'd forgotten how the hell sine and cosine really worked.

Needless to say, this annoys me. I'll probably go out and buy one of those Physics for Games Developers books next week and re-learn a bunch of this stuff, but the very concept that my mathematics knowledge has atrophied back to grade 8 level just really, really shits me.

Previously: How toLowerCase and isLowerCase Interact: Not a Bug.

Next: Verisign: the Ultimate in Typo-Squatting