Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Awesome stuff! A few months back I found a double pendulum simulation in less than 100 lines of JavaScript. It was a ton of fun to play around with the code.

Code and explanation: http://www.physicsandbox.com/projects/double-pendulum.html

Demo: http://www.physicsandbox.com/projects/double-pendulum-sim.ht...



For an accurate double pendulum you almost certainly need a symplectic integrator---not just Euler's method---or risk numerical instabilities that come from nonconservation of energy.


An integrator that is symplectic or conserves energy isn't necessarily accurate, especially if the dynamical system is chaotic. Can you recommend particular algorithm that is accurate for pendulum or double pendulum?


Here is a n-pendulum, solved both iteratively (one constraint at a time) and simultaneously (all the chain at once)

http://htmlpreview.github.io/?https://github.com/aguaviva/Ph...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: