r/programming • u/ttsiodras • Dec 23 '12
Simulating a solar system with Python
http://users.softlab.ntua.gr/~ttsiod/gravityRK4.html
244
Upvotes
r/programming • u/ttsiodras • Dec 23 '12
View all comments
Show parent comment
19
u/jminuse Dec 23 '12
Runge-Kutta is not symplectic: it is very accurate in position, but it does not conserve energy over long time periods. It's still better than Euler, but the correct approach would be some form of Verlet integration.