Skip to content

ICFP 12 (2009)

The 12th ICFP Programming Contest was about controlling a satellite (“Hohmann Transfer”); you would specify how fast you would like to accelerate in a direction, and could read some sensor to know where you (and other objects) are.

The first part of the contest required writing a “virtual machine”; then you need to figure out what the optimal accelerations are.

“Virtual Machine”

I decided to just convert the “binaries” into C; with one special feature:

The selection of the scenario is not done via the special port; I just used a simple parameter to the function, so the “in”-array is small.

Physics

I only added some code to calculate the current velocity and acceleration from two consecutive positions.

Source code

https://git.stbuehler.de/icfp/icfp12