← All projectsGitHub
Digital twins & sim-to-real

How wrong is a simulator's pendulum period at its default timestep?

research/free-integperiod

How wrong is a simulator's pendulum period at its default timestep? Exact elliptic-integral period against Euler, semi-implicit Euler, Verlet and RK4: Euler fails (14% period error at 2 ms), the symplectic pair is 0.75 ppm, and releasing from rest hides the symplectic error.

6 tests

What it found

Exact large-angle period (complete elliptic integral, 2.367842 s at 90°) against explicit Euler, semi-implicit Euler, velocity Verlet and RK4 at 0.5 to 16 ms. Explicit Euler is unusable (energy +81% and period +14% after 60 s at 2 ms). Semi-implicit Euler and Verlet keep energy error under 0.3% and have period error 0.75 ppm at 2 ms, falling 4× per halving; RK4 reaches 1.8×10−6 ppm. Started on the same orbit the two second-order methods have identical period error, but releasing from rest makes semi-implicit Euler look 4th order (≤10−4 ppm), an initial-condition artefact. Textbook integrators on an undamped pendulum, not the MuJoCo or PyBullet code. Every input is sourced or swept; nothing is assumed.

A figure from its own output

Figure produced by research/free-integperiod: period_error
free-integperiod/experiments/period_error.svg, written by the project's own experiment code.

Paper, code and results

More in Digital twins & sim-to-real

All 164 Digital twins & sim-to-real projects →

Other research topics

Proper scoring & elicitation28Effort & peer prediction9Verification games & slashing19Detection & tolerances14Markets as routers13Prediction-market design9Paying contributors8Decentralised training systems23Digital twins & sim-to-real164LLM chip design loops40Robot manufacturing loops53Ambient AI assistant46Self-replicating manufacturing34Simulation-first design64Engineered clothing45Task-specific AI accelerators40Algorithmic chip-design loops42Open-source purpose-built robots44The software-engineering loop43Adversarial human imitation41Open-source residential construction41Autonomous multi-angle capture34Sensing, imaging and 3D31Energy supply and dense energy storage39Robot societies among people31Agentic co-design of low-cost robots27Laundry-hanging robots25Machine learning on qualitative data23Robots on the building site27Civilizations & group psychology1History & human sciences1

Produced with AI assistance (Claude). Results are from the code in this repository and are simulated or stylised unless the abstract says otherwise; nothing here implies affiliation with or endorsement by any lab, researcher or company cited. MIT licensed.