Commit 3b30bab
committed
refactor: upgrade N-body simulation with Leapfrog integrator and energy monitoring
- Replaced Euler method with Leapfrog (Symplectic) integration for better stability
- Added total_energy() method for quantitative physical verification
- Refactored components using Vector2D abstraction for semantic clarity
- Verified >700x improvement in energy conservation compared to naive Euler1 parent ca5b8c1 commit 3b30bab
1 file changed
+204
-347
lines changed
0 commit comments