MPC Pendulum Swing-Up (MPPI)
This interactive simulator explores MPC Pendulum Swing-Up (MPPI) in Engineering. Sampling-based Model Predictive Control: K candidate torque rollouts over horizon H, MPPI cost-weighted update, bounded torque |u|≤u_max — swing up an inverted pendulum live and watch the planner replan. Use the controls to change the scenario; watch the visualization and any graphs or readouts to connect the model with lectures, labs, and homework.
Who it's for: For learners comfortable with heavier math or second-level detail. Typical context: Engineering.
Key terms
- mpc
- pendulum
- swing
- mppi
- mpc pendulum
- engineering
How it works
**Sampling-based Model Predictive Control (MPPI)** drives a damped pendulum from hanging (θ = 0) to the upright fixed point (θ = π) under a **bounded torque** |u| ≤ u_max. Every Δt the controller samples **K** candidate torque sequences over a horizon **H**, simulates each forward with RK4, and re-fits the mean by an exponentially weighted average of the costs (MPPI update with temperature **λ**). The first action is applied; the plan is shifted and warm-started for the next step. Try the **Swing-up** preset where u_max < m·g·L: the controller has to *pump* energy by swinging back and forth before catching the inverted equilibrium. Purple lines are the K candidate rollouts; green is the best one.
Key equations
More from Engineering
Other simulators in this category — or see all 23.
A* / Dijkstra Pathfinding (Grid)
Interactive 40×28 grid pathfinder: A* (f=g+h), Dijkstra, or greedy best-first; Manhattan / octile / Euclidean heuristics, 4- vs 8-connectivity, paint walls + weighted cells, watch open / closed sets expand.
3-Link 3D Arm Inverse Kinematics (CCD)
Continuation of two-link-arm-ik into 3D: 3 revolute joints (yaw + 2 pitches) solved with constrained Cyclic Coordinate Descent. Drag target in 3D or follow a helix / lemniscate / figure-8 trajectory.
Bicycle Model & Stanley Controller
Kinematic bicycle (rear-axle): δ = θ_e + atan2(k_e·e, v) Stanley path-following law. Pick oval, race-track, lemniscate, sine-road or S-curve and tune k_e, v, L; live cross-track e(t) and steering δ(t).
Stress–Strain & Hooke’s Law
Qualitative σ–ε curve: elastic Hooke region, yield, strain hardening, necking, and fracture. Drag strain and tune E, σ_y, σ_u.
Quadcopter 2D (Pitch)
Side view: two rotors, PD on thrust split vs pitch — whiteboard quad slice.
Watt Governor (schematic)
Flyballs and sleeve vs RPM; steam throttle gap — speed feedback cartoon.