Tutorials on simulation.
Start with one falling point mass. Finish by tracing an articulated, contact-rich robot through the complete native timestep. Every chapter pairs physical intuition with tested NumPy code, LavenderSim experiments, and the actual engine implementation.
Three implementations may appear in one lesson.
Knowing which system an equation describes is part of understanding simulation.
| Label | Meaning |
|---|---|
| Reference lab | A small NumPy implementation designed to make an algorithm readable. |
| LavenderSim | Behavior verified against the current Python API and compact C++ engine. |
| MuJoCo comparison | A conceptual comparison grounded in MuJoCo's official computation documentation—not a compatibility claim. |
| Future feature | Instrumentation or an algorithm proposed by the curriculum but not yet part of the engine. |
Reference shelves.
Recover a definition, locate an equation, trace current engine code, or continue into primary sources.
Foundations
Turn continuous equations into stable, inspectable state updates.
Articulated systems
Move from isolated bodies to robot coordinates and recursive dynamics.
Generalized coordinates
Degrees of freedom, kinematic trees, forward kinematics, and singularities.
Lagrangian mechanics
Energy, generalized forces, mass matrices, and gravity terms—selectively.
Rigid-body algorithms
Readable RNEA, CRBA, and ABA implementations for a planar chain.
Interaction
Understand the geometry and numerical constraints behind joints and contact.
Constraints
Jacobians, multipliers, stabilization, projection, joints, and limits.
Collision detection
Broad phase, AABBs, support mappings, GJK, EPA, and manifolds.
Contact mechanics
Non-penetration, impulses, restitution, compliance, and caching.
Friction
Coulomb limits, sticking, sliding, cones, rolling, and torsional resistance.
Constraint solvers
Direct solves, PGS, sequential impulses, warm starts, and residuals.
The whole engine
Put control, collision, solving, integration, sensing, and RL into one timestep.
Read less. Predict, run, and explain more.
Write down what should happen
Direction, scale, conserved quantity, and likely failure mode are more useful than a vague guess.
Change one thing
Keep the scene and initial state fixed while sweeping timestep, stiffness, friction, or solver iterations.
Use the telemetry
A plot should support a causal explanation, not merely show that two curves differ.