smmills / Phodymm

Photodynamics Code v1
2 stars 2 forks source link

Measure of energy conservation #32

Open sealauren opened 5 years ago

sealauren commented 5 years ago

Is there a way to test how well Phodymm is conserving energy?

smmills commented 5 years ago

There is not a flag or switch to do this. You would have to have the code print out the positions and velocities of the planets at different times and then compute the Energy directly (you know all the masses). If you just want to test that you're not losing too much E or L, the simplest way would be to have tepoch at some point early in your time interval and set printepoch to a time near the end, and then just compare the energy from these two points.