TL;DR
Modern neural networks are great at predicting where a vehicle will go next on average, but their predicted paths often violate basic physics—like cars sliding sideways or turning sharper than their wheels allow. The Markovian Dynamics Enforcer (MaDE) is a plug-and-play, post-hoc "physics filter" that snaps impossible trajectory predictions back onto a realistic physical manifold, without needing ground-truth steering or pedal data to learn how the system moves.
What Problem Does This Paper Address?
When predicting trajectories—say, forecasting where cars in an intersection will be in three seconds—neural models optimize for statistical accuracy (like minimizing Euclidean distance to ground truth). However, low average error doesn't guarantee physical admissibility. A predicted trajectory might jitter, teleport slightly, or demand impossible accelerations, breaking downstream planning and safety modules that assume real-world physics.
Existing fixes usually embed physics directly into the predictor, which requires retraining the whole network, coupling it to a specific architecture, or assuming we know the exact analytical equations of motion. In the messy real world, two things are usually true: our physics equations are incomplete (e.g., a simple kinematic model misses tire slip and inertia), and we only observe states (positions, velocities) from external sensors, never the controls (steering torque, pedal pressure) the driver actually applied. How do you enforce physical laws post-hoc on any predictor when the laws are only partially known and controls are invisible?
Methods
MaDE is a stateless, one-step correction operator that sits downstream of any frozen trajectory predictor. Given an anchor state ($x_{t-1}$) and a raw, potentially unphysical next-state proposal ($\tilde{x}_t$), MaDE cleans up the transition in three steps:
- Inverse Dynamics: Infers the unobserved physical control ($\hat{u}_{t-1}$, like acceleration and steering angle) that explains the jump from $x_{t-1}$ to $\tilde{x}_t$. It combines a known kinematic formula with a small learned neural residual.
- Dynamics Completion: Instead of trusting $\tilde{x}_t$, MaDE throws it away and integrates forward from $x_{t-1}$ using $\hat{u}_{t-1}$ through a hybrid physics model (known differential equations + a minimum-norm learned residual, inspired by APHYNITY). By construction, the resulting state $\hat{x}_t$ now lives on the learned dynamics manifold.
- Control-Space Corrector: What if $\hat{x}_t$ or $\hat{u}_{t-1}$ violates hard limits (like speed limits or max steering angles)? Instead of crudely clipping the state—which would break dynamical consistency—MaDE runs projected gradient descent in control space to minimize constraint violations, re-running the completion model at every step so the trajectory never leaves the physics manifold.
Because ground-truth controls don't exist in the dataset, MaDE trains via self-supervised cycle consistency on state transitions alone, penalizing the learned residuals so they only capture physics the analytical prior misses.
Datasets
- Simulated Four-System Ladder: Synthetic 32-step trajectories across four systems: Double Integrator (DI), Kinematic Unicycle (UNI), Kinematic Bicycle (KB), and Dynamic Bicycle (DB). In the first three, MaDE's known physics match the true simulator. In DB, the simulator includes tire forces and slip while MaDE only gets a basic kinematic bicycle prior, testing underspecified physics.
- inD Dataset: Real-world drone recordings of naturalistic traffic at German intersections (sampled at 5 Hz), filtered for moving vehicles. MaDE is tested downstream of three physics-unaware predictors: an LSTM, a Mamba/S6 state-space model, and a Transformer.
Key Insights and Ideas
- Never edit states directly; optimize controls: Simple state-clamping satisfies state bounds at the cost of massive implied control violations and broken physics. By pushing gradient updates through inferred controls and re-integrating, every output state remains strictly consistent with the learned dynamics.
- Completion alone isn't enough: Running just the inverse-and-completion steps without the gradient corrector actually increases inequality violations on real data (jumping from 5.0% in raw forecasts to 11.8%). The active control-space corrector is essential, dropping violations below 1.0%.
- The Consistency–Accuracy Trade-off: Enforcing one-step Markovian physics recursively over a horizon causes slight errors to compound. On real data, MaDE makes trajectories dramatically smoother and more kinematically plausible—even cleaner than noisy sensor recordings—at the cost of drifting further from the recorded ground-truth positions.
Key Results
- Simulations: On fully specified systems (DI, UNI, KB), MaDE drives physics residuals to essentially zero ($< 0.0004$). On the underspecified Dynamic Bicycle (DB), MaDE cuts true-dynamics residuals to 0.3736 (vs. 1.4897–2.3552 for MLP, clamping, and autoencoder baselines) and more than halves trajectory fidelity error (5.20 vs. 12.51 for the strongest baseline).
- Real Vehicle Trajectories (inD): Attached to frozen LSTM, State-Space, and Transformer predictors, MaDE slashes one-step kinematic residuals from ~0.171 down to ~0.0071, and drops total inequality violation rates from 3.6%–5.8% down to 0.65%–1.14% (outperforming classical EKF/RTS smoothers).
- Accuracy Cost & Speed: That physical realism raises Average Displacement Error (ADE) over a 3-second horizon by a factor of 1.57x to 1.83x. Inference is fast: ~2.51 ms per trajectory (batch size 16), with 95% of steps needing at most 1 corrector iteration.
Limitations and Future Work
- Local vs. Sequence-Level Corrections: Because MaDE operates strictly step-by-step without seeing predictor history or future horizons, recursive application trades multi-step positional accuracy (ADE/FDE) for local dynamical admissibility.
- Model-Relative & Best-Effort Guarantees: MaDE guarantees consistency relative to its learned model, not true reality (hence it is not a deployment safety certificate). Furthermore, inequality satisfaction is limited by a fixed 50-iteration budget—hitting the cap with unresolved violations on ~0.96% of calls.
- Requires a Physics Prior: MaDE relies on having a useful baseline physical model; systems with zero known physics are outside its intended scope. Future directions are not explicitly discussed in the main text.
Summary updated