Analogous Oscillations of a Pendulum and Liquid in a U-Tube
The simple harmonic motion for a liquid in a U-tube and a simple pendulum as proposed by Newton in his Principia Mathematica is animated in this Demonstration, with similar design and constraints (no friction) as in Newton's original work. All units are imperial. The energy level plot on the left is the water's energy; however, the timing is also for the pendulum. The clock starts with motion already in progress at the displacement position for maximum kinetic energy for both the water and the pendulum. The assumed initial condition would be pressure on side of the tube, causing displacement from equilibrium of and to a variable distance at and ; then the pressure is released to allow the water to move.
The snapshots show PE maximum, PE equal to KE, and KE maximum.
The "Period (sec)" display is for both the pendulum and the water. The quantity is half the length of the water column and the full length of the pendulum support line. The displacement of the water above or below equilibrium ( and ) is represented by . Constants used: , water density , and radius of water column .
Generally, it's best to fix the length and displacement and then animate the time. To animate or , make their animation rates much slower than the clock .
 I. Newton, Philosophiæ Naturalis Principia Mathematica, 3rd ed., Book II, Sec. VIII: Proposition XLIV, Theorem XXXV, 1726.
 MIT Deptartment of Physics, Physics 8.01, "Worked Example W13D1-1: U-Tube Oscillations Solution." (Can be found here.)