Newton's Cradle

previous next


Simulation of Newton's Cradle, a device consisting of several steel balls suspended from a cage. Uses the 2D Rigid Body Physics Engine.

Each ball acts like an individual pendulum. At rest all the balls are touching. The surprising thing is that when you lift one of the end balls and let it hit the resting balls, only the ball at the other end moves, and the initial ball stops at rest.

Click near an object to exert a rubber band force with your mouse. Click reset to set the balls at rest. Try changing gravity, elasticity (bounciness), and damping (friction).

Experiments to try:

There are "joints" attaching each pendulum to the background, two joints for each connection: one vertical, one horizontal. Each pendulum is a single rigid body, as opposed to being made of a flexible rope and steel ball in the real world toy.

The method of collision handling for this simulation is important. For the balls to be in resting contact with each other, only the "simultaneous" or "hybrid" methods of collision handling work correctly.

Also available: source code, documentation and how to customize.

previous next Valid HTML 4.01