I recently wrote a small number-crunching program that basically loops over an N-dimensional grid and performs some calculation at each point.
for (int i1 =
If you ever do it in .NET, use the Parallel Extensions.