Skip to content
Robotics.world

Research

Differentiable Contact Dynamics for Legged Locomotion: Policy Learning and Contact-Implicit Trajectory Optimization

When a robot's foot touches the ground, a differentiable simulator gives you a gradient — but the standard "exact" gradient only describes what happens if the foot stays in its current contact state…

The paper’s first page · arXiv:2610.35852
arXiv
2610.35852 · Preprint · not peer-reviewed
Published
2026-10-26
Authors
Gijeong Kim, Seungbin Oh, Dongyun Kang, Hae-Won Park

In plain words

When a robot's foot touches the ground, a differentiable simulator gives you a gradient — but the standard "exact" gradient only describes what happens if the foot stays in its current contact state (stuck, sliding, or airborne). It provides no first-order direction that would let an optimizer change that state, which is exactly what legged locomotion requires.

AI summary

Overview

Research area: Differentiable physics simulation and contact-rich optimal control for legged robots, spanning first-order policy learning (backpropagation through time) and shooting-based contact-implicit trajectory optimization (DDP/iLQR).

Technical level: Advanced. The paper assumes familiarity with complementarity formulations of Coulomb friction, second-order cone programming, Jordan algebra, the Delassus matrix, and Riccati-sweep trajectory optimization.

Scope (one sentence): The paper derives a backward-pass-only relaxation of the full de Saxcé-corrected frictional contact law and demonstrates, on a quadruped, that this contact gradient improves both BPTT policy learning and contact-implicit trajectory optimization relative to the exact and Signorini-relaxed alternatives.

What This Paper Is About

When a robot's foot touches the ground, a differentiable simulator gives you a gradient — but the standard "exact" gradient only describes what happens if the foot stays in its current contact state (stuck, sliding, or airborne). It provides no first-order direction that would let an optimizer change that state, which is exactly what legged locomotion requires. The authors propose a gradient that is relaxed smoothly enough to point toward neighboring contact modes, yet is used only in the backward pass so the simulated motion itself remains hard-contact and physically feasible.

Key Contributions

  1. An analytic backward contact sensitivity that relaxes the complete de Saxcé-corrected frictional contact law along its central path, while leaving the hard-contact forward solve untouched. The relaxation is applied to the full friction cone (not just the normal/Signorini direction), so it couples normal and tangential information and offers first-order directions toward separation, clamping, and sliding in every contact mode. It recovers the exact sensitivity as the relaxation vanishes.

  2. A separate evaluation point for the relaxed sensitivity. Rather than differentiating an intermediate iterate produced by the forward solver, the relaxed sensitivity is evaluated at a point on the central path obtained by a Newton iteration initialized from the hard-contact solution — so the relaxation level is a free parameter chosen for the backward pass alone.

  3. Demonstration in two optimal-control settings with a quadruped robot. Both policy learning (BPTT through a closed-loop rollout) and contact-implicit trajectory optimization are run with the forward model, objective, and initialization held fixed, isolating the effect of the gradient alone; exact and Signorini-relaxed gradients serve as baselines.

  4. Hardware validation without fine-tuning. Trotting policies obtained from 100,000 samples and less than 2 minutes of training on a desktop PC transfer directly to hardware, where the robot withstands pushes and traverses debris and slippery ground; pacing and gait-free locomotion are also demonstrated.

Main Findings

  • The exact gradient is mode-locked, and this is a real failure mode. In the planar point-mass benchmarks (mass 1 kg, 0.05 s time step, horizon H = 30, friction coefficient μ = 1), the exact gradient did not reach the target in any of the three tasks. At a clamped contact the mode constraint gives zero contact-velocity variation, so the loss derivative transmitted through contact-point motion vanishes even when motion would help.

  • Normal-only (Signorini) relaxation is not enough. The Signorini-relaxed gradient succeeded in the lift-off task (a) but failed in the traverse task (b) and the friction-braking task (c). In (b), reaching the lateral target requires tangential contact-velocity variation, which a normal-only relaxation does not provide; the proposed full-cone gradient instead lifts off, travels laterally in the separating mode to avoid frictional resistance, then slides and reclamps at the target.

  • The proposed gradient succeeds on all three point-mass tasks, and in task (c) it produces a trajectory that descends, brakes through sliding friction, and returns to the target, whereas the exact and Signorini-relaxed optimizations saturated the force input without returning. Costs in these comparisons are normalized by a mixed-integer quadratic program (MIQP) solved to zero optimality gap over the contact-mode sequence.

  • Single-rollout BPTT is sufficient. With the proposed gradient, one rollout per update suffices to learn locomotion policies that transfer directly to hardware — in contrast to comparable prior locomotion work that relied on 128 or 64 parallel simulation environments.

  • Sample and compute efficiency. Policy learning used 100,000 samples and less than 2 minutes of training on a desktop PC, with no fine-tuning on the physical robot.

  • Hardware robustness. The resulting trotting policy withstands pushes and traverses debris and slippery ground on the physical quadruped.

  • CITO reaches contact-rich solutions the baselines miss. In trajectory optimization, the proposed gradient reaches contact-rich solutions that the exact and Signorini-relaxed gradients do not, including recovery from unmodeled external pulls through contact-mode changes and foot repositioning. (Quantitative cost values from the quadruped CITO experiments are not available in the provided excerpt.)

  • Theoretical property. The relaxed sensitivity remains continuous through contact-mode transitions and converges to the exact sensitivity as the relaxation parameter vanishes.

Methodology in Plain English

The starting point is that rigid frictional contact has three possible states per foot: separated (no force), clamped/sticking, or sliding. The classical way to write all three is a complementarity condition, and the de Saxcé correction folds the friction cone and the maximum-dissipation principle into a single second-order cone complementarity problem.

Differentiating that condition while holding the contact state fixed gives the "exact" sensitivity — correct, but blind to the possibility of switching states. The authors' alternative is to soften the condition slightly, the way interior-point methods do, by pushing the solution a small distance inside the cone along a "central path." At any point on that path, all three states have well-defined derivatives that blend into one another, so the gradient always contains a direction toward the neighboring states. As the softening goes to zero, the softened solution converges back to the true hard-contact one.

The key engineering choice is where to evaluate the softened derivative. Interior-point approaches naturally differentiate whatever iterate the solver happened to visit, which couples the relaxation level to the forward solve. Here the forward solve stays fully hard, and a short Newton iteration started from that hard solution walks a controlled distance onto the central path purely to provide a differentiation point. The rollout the optimizer reasons about is therefore always physically feasible, while the search directions it receives come from a smoothed landscape.

The authors validate the idea in a deliberately small setting first — a planar point mass with horizontal and vertical thrusters — so that successes and failures can be attributed to the gradient alone, using an MIQP over contact-mode sequences as ground truth. They then scale to a quadruped, using iLQR/DDP for trajectory optimization and BPTT for policy learning, comparing exact, Signorini-relaxed, and proposed gradients with everything else fixed. The policy-learning forward rollouts use RaiSim for speed at fine time steps; the CITO forward model keeps the three rigid-contact principles and solves sliding subproblems by bisection with the de Saxcé correction.

Why This Matters

Impact on research. The paper isolates a specific, widely felt pathology — first-order gradients through contact that cannot propose a mode change — and offers a fix that touches only the backward pass. Because the forward simulation is unchanged, the idea is compatible with existing hard-contact simulators and with shooting-based optimal control, rather than requiring a new smoothed dynamics model or a reduced-order surrogate. The point-mass ablation also explains why normal-only relaxation is insufficient, which sharpens the design target for future differentiable-contact work.

Real-world applications (illustrative):

  • Quadruped delivery or inspection robots that must keep walking after being kicked, or cross gravel, mud, and wet flooring.
  • Search-and-rescue robots operating on debris where footing is unpredictable and slipping is routine.
  • Warehouse and logistics fleets running on polished concrete, where low-friction surfaces are the dominant failure mode.
  • Contact-rich manipulation and legged manipulators, where the same mode-transition problem appears at hand–object contacts.

Industry relevance. Training that finishes in under 2 minutes on a desktop PC from 100,000 samples, with a single rollout per update and no fine-tuning before deployment, is a materially lower compute barrier than the thousands-of-parallel-environments paradigm typical of large-scale RL. That changes the economics of iterating on a gait or a robot design, and it makes sim-to-real policy training feasible without a GPU cluster.

Future Directions

These are open questions raised by the work rather than a stated future-work list, which is not reported in the provided excerpt:

  • Choosing the relaxation level systematically. The relaxation parameter is deliberately decoupled from the forward solve, but the paper does not (in the available content) specify a general rule for setting it; a principled or adaptive schedule would make the method easier to transfer to new tasks.
  • Scaling beyond the demonstrated settings. The controlled study uses a planar point mass and the hardware study a quadruped; extending the analysis to high-DOF multi-contact systems, humanoids, or legged manipulators would test whether the central-path sensitivity stays informative as contact count grows.
  • Combining with complementary techniques. Layering the backward-only relaxation on top of shortened differentiation horizons, actor–critic bootstrapping, or parallel environments is an obvious composition that the paper does not evaluate.
  • Quantifying robustness more rigorously. The hardware results are qualitative (pushes, debris, slippery ground); standardized disturbance tests and repeated trials would let the gradient's benefit be compared against other contact-gradient methods on equal footing.

Target Audience

Robotics researchers and graduate students working on differentiable simulation, contact-implicit trajectory optimization, or legged locomotion; practitioners building sim-to-real pipelines who have hit the "the gradient doesn't know the foot can lift" wall; and numerically minded readers interested in complementarity formulations of frictional contact. Readers without background in cone complementarity or DDP will find the point-mass section accessible but the derivation sections demanding.

Authors’ abstract

This paper proposes a smooth analytic gradient for frictional contact and applies it to policy learning and contact-implicit trajectory optimization for legged locomotion. The exact contact sensitivity is available in closed form but describes changes within the current contact mode, providing no first-order information toward neighboring contact modes. The proposed gradient replaces this sensitivity only in the backward pass, leaving the hard-contact forward solve unchanged…

The full abstract on arXiv
Read the original paper

Related papers