1969 Lunar Lander

Conclusion

Quoting Jim, I’d like to close the post by contributing something from this fun exercise.

In July 2023 S. Vakulenko found, with the aid of a C++ program search, this near perfect game on the simulator that lands at only 0.17 mph with 588 pounds of fuel remaining, and then in August 2023 M. Martin also with the the aid of a C++ program search found a game that lands at a faster 1.0 mph but with more fuel remaining (658 pounds). The two make it seem easy in hindsight, but before looking at them, try it yourself without a computer program to help

https://www.cs.brandeis.edu/~storer/LunarLander/LunarLander.html

My simple 0 hidden neurons AI managed a suicide burn landing at 0.06MPH with 636LB fuel! It’s the picture on the first page, not that you probably noticed!

0, 0, 0, 0, 0, 0, 0, 197.40637124602983, 196.28365446184193, 194.67804007921129, 192.38972973637863, 189.14857833210445, 184.60533421949435, 178.3418927913643, 169.92352249205936, 159.02005902338976

The formula for that is:

_fuelRateLBsPerSec = 
   200*(Math.Tanh((0.41610000375658274*AltitudeInMiles/150)+
                  (0.5881000086665154*DownwardSpeedInMilesPerSecond)+
                  (1.0708499982574722*FuelRemainingLBs/WeightOfFullTankOfFuelLBs)+
                  (0.791800007224083*ElapsedTimeInSeconds/200)
   +0.406799990683794));

It may have faired better than “0.17” because it uses the corrected calculations proposed by Martin (mentioned at the start). If the C++ app had used the correct mathematics, it might have matched or beaten mine.

I am not claiming AI is more efficient for a search. I tried for fun, nothing more, or less.

In terms of “M Martin” mentioned (is that Martin C Martin?), I refer the reader to the comment earlier, I easily achieved 0.2 mph from a suicide burn(!), with 653.81 lbs of fuel left. It doesn’t even clarify whether “M Martin” used a suicide burn or not.

Mine lands with 4 lb less fuel remaining. I would rather forego it and hit the moon at 0.2 mph than 1 mph but Apollo had aluminium honeycomb shock absorbers.

According to ChatGPT:

  • Impacting the moon at 1 mph would result in a deceleration of about 0.456 times the acceleration due to gravity on Earth (0.456g). This would feel like a strong jolt but not necessarily dangerous if the lander and occupants are properly secured.
  • Impacting at 0.2 mph would result in a much milder deceleration of about 0.091g, which would feel like a gentle bump and be more comfortable for the occupants.

My accompanying source code is on GitHub here.

If you didn’t read Martin’s post, and you got this far, please take a look, you won’t be disappointed.

Given no one has called out the minimum amount of fuel you require to return to the command module, at least in the scoring. It is possible to achieve a 0.03mph landing even with a suicide burn, at the expense of burning more fuel. I am probably inviting people to prove they can beat it… I suspect it’s possible to reach 0 mph via iteration or search.

If you liked this post, or want to point out something I’ve gone wrong, please post a comment!

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *