The model integrates the nonlinear pendulum equation with a fixed time step:
θ̈ + γθ̇ + (g/L) sin θ = 0
Here θ is angular displacement, γ is the damping rate, g is gravitational acceleration and L is string length. The bob mass affects energy, but cancels from this ideal angular equation.
E = ½mL²ω² + mgL(1 − cos θ)
dE/dt = −mL²γω²
The exact undamped period uses the complete elliptic integral K. The familiar textbook shortcut is T ≈ 2π√(L/g), which is accurate only for small angles.
T₀ = 2π√(L/g)
Texact = 4√(L/g) K(sin(θ₀/2))
Simplifications: a point-like bob, a massless inextensible string, planar motion, constant gravity and linear viscous damping. The numerical reference uses a much smaller RK4 step than the live model.
Independent educational model; not affiliated with any museum, school or scientific institution. All parameter settings are illustrative; the diagram is visually scaled.