Differentiable Physics Simulations with Contacts: Do They Have Correct Gradients w.r.t. Position, Velocity and Control?
Not on the map. Why?
Abstract (arXiv)
In recent years, an increasing amount of work has focused on differentiable physics simulation and has produced a set of open source projects such as Tiny Differentiable Simulator, Nimble Physics, diffTaichi, Brax, Warp, Dojo and DiffCoSim. By making physics simulations end-to-end differentiable, we can perform gradient-based optimization and learning tasks. A majority of differentiable simulators consider collisions and contacts between objects, but they use different contact models for differentiability. In this paper, we overview four kinds of differentiable contact formulations - linear complementarity problems (LCP), convex optimization models, compliant models and position-based dynamics (PBD). We analyze and compare the gradients calculated by these models and show that the gradients are not always correct. We also demonstrate their ability to learn an optimal control strategy by comparing the learned strategies with the optimal strategy in an analytical form. The codebase to reproduce the experiment results is available at https://github.com/DesmondZhong/diff_sim_grads.
Key facts. Cited by 7 papers in the map (data through 14 Oct 2026). Builds on 27 of its 52 references that are in the map. First posted on arXiv 8 Jul 2022.
Builds on
27 of 52 references.
References · 27
- 2017Proximal Policy Optimization Algorithmscited by 15,215
- 2017OptNet: Differentiable Optimization as a Layer in Neural Networkscited by 599
- 2019Differentiable Convex Optimization Layerscited by 465
- 2021Brax -- A Differentiable Physics Engine for Large Scale Rigid Body Simulationcited by 407
- 2019DiffTaichi: Differentiable Programming for Physical Simulationcited by 258
- 2016A Differentiable Physics Engine for Deep Learning in Roboticscited by 108
- 2022Accelerated Policy Learning with Parallel Differentiable Simulationcited by 104
- 2022Do Differentiable Simulators Give Better Policy Gradients?cited by 89
- 2020NeuralSim: Augmenting Differentiable Simulators with Neural Networkscited by 82
- 2020Scalable Differentiable Physics for Learning and Controlcited by 73
- 2021DiffCloth: Differentiable Cloth Simulation with Dry Frictional Contactcited by 65
- 2021DiSECt: A Differentiable Simulation Engine for Autonomous Robotic Cuttingcited by 64
15 more
- 2021DiffPD: Differentiable Projective Dynamicscited by 62
- 2021An End-to-End Differentiable Framework for Contact-Aware Robot Designcited by 54
- 2021Fast and Feature-Complete Differentiable Physics for Articulated Rigid Bodies with Contactcited by 52
- 2021Efficient Differentiable Simulation of Articulated Bodiescited by 39
- 2022Differentiable Simulation of Soft Multi-body Systemscited by 39
- 2021Extending Lagrangian and Hamiltonian Neural Networks with Differentiable Contact Modelscited by 34
- 2020Encoding Physical Constraints in Differentiable Newton-Euler Algorithmcited by 23
- 2020Learning Physical Constraints with Neural Projectionscited by 19
- 2020ADD: Analytically Differentiable Dynamics for Multi-Body Systems with Frictional Contactcited by 17
- 2021DiffSDFSim: Differentiable Rigid-Body Dynamics With Implicit Shapescited by 14
- 2020Learning to Slide Unknown Objects with Differentiable Physics Simulationscited by 12
- 2017Automatic Differentiation of Rigid Body Dynamics for Optimal Control and Estimationcited by 11
- 2020Augmenting Differentiable Simulators with Neural Networks to Close the Sim2Real Gapcited by 9
- 2021Differentiable Implicit Soft-Body Physicscited by 9
- 2022Solving Optimal Control Problems of Rigid-Body Dynamics with Collisions Using the Hybrid Minimum Principlecited by 3
Built on by
Citing papers per year: 2023: 3; 2024: 0; 2025: 0; 2026: 4.
7 papers.
- 2023DiffMimic: Efficient Motion Mimicking with Differentiable Physicscited by 19
- 2023Improving Gradient Computation for Differentiable Physics Simulation with Contactscited by 5
- 2023STAMP: Differentiable Task and Motion Planning via Stein Variational Gradient Descentcited by 4
- 2026VisualPatchWorld: Code World Models as Latent Structured Representations for Planningcited by 2
- 2026Dimensional Peeking for Low-Variance Gradients in Zeroth-Order Discrete Optimization via Simulationcited by 0
- 2026Where-to-Learn: Analytical Policy Gradient Directed Exploration for On-Policy Robotic Reinforcement Learningcited by 0
- 2026Amortising Trajectory Optimisation for Residual MPC via Implicit Contact Differentiationcited by 0
- 2026VisualPatchWorld: Code World Models as Latent Structured Representations for Planning28 Jul 2026
- 2026Amortising Trajectory Optimisation for Residual MPC via Implicit Contact Differentiation27 Jul 2026
- 2026Where-to-Learn: Analytical Policy Gradient Directed Exploration for On-Policy Robotic Reinforcement Learning28 Mar 2026
- 2026Dimensional Peeking for Low-Variance Gradients in Zeroth-Order Discrete Optimization via Simulation21 Jan 2026
- 2023STAMP: Differentiable Task and Motion Planning via Stein Variational Gradient Descent3 Oct 2023
- 2023Improving Gradient Computation for Differentiable Physics Simulation with Contacts28 Apr 2023
- 2023DiffMimic: Efficient Motion Mimicking with Differentiable Physics6 Apr 2023