5 ms·
When I looked into making a solar system simulation awhile back, I actually found it shocking how much goes into monitoring and ensuring conservation of energy/
by nonbel 10y ago
When I looked into making a solar system simulation awhile back, I actually found it shocking how much goes into monitoring and ensuring conservation of energy/momentum in these models.
Once I was aware of this issue though, even more shocking to me was that many papers on climate models I came across do not even mention they monitored adherence to conservation laws. There is a disconnect there, I would think this adherence either is a big deal (as would be suggested by the practice in astronomy) or not (as would be suggested by climate research), not that it would change by subfield.
- DamonHD 10y agoIt would surely depended on how numerically (un)stable the calculations were. Some of the stuff we did in fixed income derivatives was rock solid robust, and some would go off the rails at the slightest provocation, so I don't think that your thesis is valid as it stands.
- nonbel 10y agoI'm not sure I follow. Both responses to my post seem suggest that "following conservation laws is not an important issue for climate models". Ok, I am open to that but I don't really follow the argument that the stability of the simulation can be used to tell us that violation of conservation laws will not lead to inaccurate results.
- strainer 10y agoWhen just doing point gravity dynamics (no friction, collision etc) energy and momentum take care of themselves as long as the math is clean. I say this confidently because I made a solar system simulation[1] with no attention to conservation of energy at all. In practice Star systems also shed large amounts of angular momentum through solar wind[2], but I expect this is often not modelled. Climate models are an entirely different matter and with respect, there is a disconnect with your scepticism of them for this matter. [1] https://strainer.github.io/fancy#00 https://strainer.github.io/fancy#00 [2] http://farside.ph.utexas.edu/teaching/plasma/Plasmahtml/node69.html http://farside.ph.utexas.edu/teaching/plasma/Plasmahtml/node...
- nonbel 10y agoIt says in your readme[1] though that your solar system simulation simulation is off by 70k km (regarding Earth orbit) after only 1 year relative to the JPL ephemerides, for "unknown reasons". I don't see how you can use that to justify not checking for conservation of momentum/energy. I also do not understand your final sentence. [1] https://github.com/strainer/fancy https://github.com/strainer/fancy
- strainer 10y agoCome on it doesnt say "unknown reasons" it says the "It is possible the discrepancy is due to the limitation of javascripts 64bit FP numbers rather than subtle algorithmic or physics error" 70k km / a year (on a billion km long orbit) was a lot closer than I had hoped for, considering its a 64 bit newtonian model. But this is beside the fact that having worked on the project a fair bit, I understand that any model adjustments to conserve energy or momentum are non-physical 'fudges' to correct deficiencies of the model. There are no laws of physics dedicated to adjusting energy, momentum, information in order to conserve them. They are conserved by a mathematical correctness of every physical law - a proper account of that eludes me, but it is certainly explained somewhere.
- nonbel 10y agoRight, you don't know how much error the floating point error accounts for. You also brought up loss of angular momentum to solar wind, etc. These are all just speculations. That may be fine for the purposes of your simulation, but not for predicting if asteroids will impact the earth or the influence of human activity on Earth's climate. Also, I know you are supposed to use a symplectic integrator to ensure conservation of energy when doing these simulations, so it is not somehow hardcoded into the laws, eg: https://en.wikipedia.org/wiki/Leapfrog_integration https://en.wikipedia.org/wiki/Leapfrog_integration
- strainer 10y agoWe could certainly calculate how much error was introduced by rounding, if we had the time and inclination. It is useful to understand that about numerical modelling, it should not be necessary to accept any indeterminable discrepancies. Conservation of energy, momentum, information is hardcoded into all known laws of Physics. It is our integration algorithms which do not all ensure conservation of information - but that is carefully achievable with basic first order schemes, such as Verlet and leapfrog integration.
- mikeash 10y agoI suspect the fact that the Earth itself is an effectively infinite sink of momentum, and space is an infinite sink of energy, has something to do with why conservation laws aren't as much of a thing for climate models.
- Animats 10y agoI did that in Falling Bodies, my 1990s ragdoll simulator. At the end of each step, the system energy was computed, and if it had changed, the timestep was reduced. Most simulators don't do that. Older, bad approaches could inject energy, which is why some games would suddenly have things fly apart. Newer approaches err in the direction of losing energy, which doesn't look so bad.
- antognini 10y agoHanno Rein, one of the experts in the field, just published a new algorithm which is exactly time-reversible for floating point numbers. Figure 1 of the paper is pretty incredible: https://arxiv.org/abs/1704.07715 https://arxiv.org/abs/1704.07715