N-link compound pendulum simulation
For our Mechanical Dynamics final project, a friend and I decided to generalize the equations for compound pendulums to write a simulation program that could generate animations for n-link compound pendulums with user specified lengths, masses, angular displacement and velocities. We originally wanted to write a full blown physics engine, but quickly realized that two weeks was not enough time to do something of that scale, haha.
First things first, a demonstration! The following is an simulation of a 5 link compound pendulum:
Read our final report for a more formal/comprehensive explanation of the process!
Download the code!