Skip to content

Geometric Contact Flows: Contactomorphisms for Dynamics and Control

Conference: ICML2025
arXiv: 2506.17868
Code: Project Page
Area: Robotics/Contact Dynamics
Keywords: Contact Geometry, Contact Hamiltonian, Diffeomorphisms, Dynamical Systems Learning, Uncertainty Quantification, Riemannian Geodesics, Robotic Interaction Control

TL;DR

Proposes Geometric Contact Flows (GCF), which leverage Riemannian and contact geometry as inductive biases. Using contactomorphisms, GCF maps latent contact Hamiltonian dynamics with desired properties (such as stability and energy conservation) to the target dynamics, while utilizing ensemble uncertainty to drive geodesics for robust generalization and obstacle avoidance.

Background & Motivation

Modeling complex dynamical systems involving force exchange and dissipation is a core challenge in fields such as robotics and fluid mechanics. Pure black-box methods (e.g., MLPs) cannot encode physical relationships between variables, failing to extrapolate in data-sparse regions and lacking physical interpretability.

Limitations of prior physical prior methods:

  • Symplectic Methods (e.g., HNN): Limited to conservative systems; unable to model friction and energy exchange.
  • Extended Symplectic Methods (e.g., DHNN): Treat damping as external perturbations, which destroys the symplectic structure and fails to guarantee property preservation through geometric structure preservation.
  • Diffeomorphism Methods (e.g., EF, NCDS): Limited to first-order systems; unable to model complex behaviors like self-intersecting trajectories and physical interactions.

Core Motivation: Contact geometry naturally extends symplectic manifolds by adding only one physically meaningful variable, \(s\) (the Lagrangian action), thereby offering a unified description of energy dissipation and generation in non-conservative systems.

Method

Overall Architecture

GCF consists of three key components:

  1. Latent Contact Hamiltonian Dynamics: Designing dynamics with desired properties in the latent space \((\mathcal{N}, \eta')\).
  2. Ensemble of Contactomorphisms: \(N\) contactomorphisms map the latent space to the ambient space while preserving the contact structure.
  3. Uncertainty-Aware Geodesics: Utilizing the ensemble variance to modify the Riemannian metric, guiding trajectories away from data-sparse regions.

Latent Dynamics Design

On a \((2d+1)\)-dimensional contact manifold, the contact Hamiltonian function \(H_g(\mathbf{z})\) generates the dynamical flow \(\mathbf{z}(t) = \varphi_g(t)(\mathbf{z}(0))\). The energy evolution is controlled by the damping coefficient:

\[H(t) = H(0) \, e^{\int_0^t \partial H / \partial s \, d\tau}\]

The paper designs three types of latent Hamiltonians to cover different scenarios:

Hamiltonian Form Application Scenario
\(H_{g^A}\) \(\frac{1}{2}\mathbf{p}^\top\mathbf{p} + \frac{1}{2}\mathbf{q}^\top\mathbf{q}\) Periodic Orbits
\(H_{g^B}\) \(\frac{1}{2}\mathbf{p}^\top\mathbf{p} + \frac{1}{2}\mathbf{q}^\top\mathbf{q} + s\) Convergence to Attractor
\(H_{g^C}\) \((\frac{1}{2}\mathbf{p}^\top\mathbf{p} + \frac{1}{2}\mathbf{q}^\top\mathbf{q} + s)s^2\) Safe Stop

Contactomorphism

Transforms the latent space coordinates \(\mathbf{z}\) to ambient space coordinates \(\mathbf{x}\) while preserving the contact form \(\eta\) (up to a conformal factor). The mapping is implemented as a composition of \(K\) parameterized networks:

\[\varphi_r(T) = \varphi_{r_{\theta_K}}(\tau) \circ \cdots \circ \varphi_{r_{\theta_1}}(\tau)\]

Each sub-transformation is generated by the flow of a contact Hamiltonian vector field:

\[H_{r_{\theta_k}} = \frac{1}{2}\mathbf{p}^\top M_{\theta_k}(\mathbf{p})\mathbf{p} + V_{\theta_k}(\mathbf{q}) + F_{\theta_k}(\mathbf{q})s\]

Where \(M_{\theta_k}, V_{\theta_k}, F_{\theta_k}\) are parameterized by Random Fourier Feature networks. The architecture is analytically invertible, meaning forward and inverse transformations have comparable computational costs.

Prediction Process

Given an initial point \(\mathbf{x}_0\), predicting the trajectory requires only one forward and one inverse mapping:

\[\mathbf{x}(t) = \varphi_r^{-1}(T) \circ \varphi_g(t) \circ \varphi_r(T)(\mathbf{x}_0)\]

No repeated calls to the contactomorphism are needed during the integration of latent dynamics, ensuring highly efficient long-horizon prediction.

Uncertainty-Aware Generalization

An ensemble of \(N\) contactomorphisms is constructed, which predicts consistently in data-rich areas and diverges in data-sparse regions. By modifying the Riemannian metric \(\hat{g}\) to incorporate the uncertainty \(\sigma_{\mathbf{z}}\) into geodesic calculation, this is formulated as an optimal control problem:

\[\min_{\mathbf{u}} \int_{t_0}^{t_1} \big(\sigma_{\mathbf{z}}^2(\mathbf{z}(t)) + \|\mathbf{u}(t)\|^2\big) dt, \quad \text{s.t.} \quad \dot{\mathbf{z}}(t) = Z_{H_g}(\mathbf{z}(t)) + \mathbf{u}(t)\]

Furthermore, an obstacle energy term \(E_\Upsilon\) can be incorporated to achieve safe obstacle avoidance.

Key Experimental Results

Spring Mesh Dynamics Reconstruction (60-dimensional)

Method GCF DHNN HNN EF NCDS MLP
DTWD↓ 0.50±0.19 1.24±0.62 1.49±0.74 30.9±3.3 24.9±2.6 1.71±0.56

GCF reduces the error by 57% compared to the second-best method, DHNN.

Quantum System Dynamics Reconstruction

Method GCF EF NCDS MLP
DTWD↓ 0.29±0.04 0.72±0.12 0.70±0.11 0.41±0.06

HNN/DHNN are not applicable due to their restriction to even-dimensional phase spaces. GCF reduces the error by 60%.

Robotic Wrap-and-Pull Task

Method EF NCDS DHNN GCF Safe GCF Stable
DTWD↓ 1.79±0.04 3.37±0.12 4.25±0.68 0.62±0.22 0.61±0.25

In the real robotic interaction task, GCF reduces reconstruction error by approximately 66% compared to EF. Once loaded, the Safe variant can automatically stop when energy is depleted, providing safety guarantees.

Handwriting Dataset Generalization (Convergence Rate)

Dataset EF NCDS DHNN GCF
LASA Leaf_2 0.49±0.37 0.94±0.19 0.18±0.13 0.69±0.19
DigiLeTs Elle 0.61±0.30 0.54±0.35 0.17±0.15 0.66±0.12

GCF significantly outperforms all first-order methods in the second-order dynamics scenario (DigiLeTs), while exhibiting the smallest variance.

Highlights & Insights

  1. Contact Geometry as an Inductive Bias: Naturally unifies conservative and non-conservative system modeling by introducing only one extra physical variable, \(s\) (the Lagrangian action). This is far superior to doubling the dimensions of symplectic manifolds or adding external perturbations.
  2. Dual Geometric Perspective: Interpreting contact flows as Riemannian geodesics allows both guaranteeing physical properties via the contact structure and achieving generalization control through metric modification.
  3. Ensemble + Geodesic Generalization Mechanism: Rather than using simple ensemble averaging, it utilizes uncertainty to modify the geometric metric, guiding trajectories directly on the geometric level.
  4. Safe Stopping of the Safe Variant: \(H_{g^C}\) enables the system to stop automatically before energy is thoroughly depleted, removing the need for auxiliary safety constraints.
  5. Analytically Invertible Architecture: Since contactomorphisms are analytically invertible, long-range prediction requires only a single forward and inverse mapping.

Limitations & Future Work

  1. Coordinate Transformation Overhead: Consists of transforming observational data \(\{q, \dot{q}\}\) into canonical coordinates \(\{q, p, s\}\). Since the Lagrangian action \(s\) is not directly observable, it must be estimated by comparing the Maupertuis principle with the Noether theorem.
  2. Ensemble Training Cost: Jointly training \(N\) contactomorphisms results in \(N\) times the computational cost of a single model.
  3. Underperformance on the Handwriting Dataset LASA vs EF: In simple first-order scenarios, GCF shows no prominent advantage over EF (0.44 vs 0.43).
  4. Obstacle Avoidance Dependency on Obstacle Priors: Obstacles must be explicitly represented as point sets in the state space, limiting adaptability to complex environments.
  5. High-Dimensional Scalability: Although some dimension expansion experiments are provided in the appendix, the performance on ultra-high-dimensional systems still requires more validation.
  • Euclideanizing Flows (EF): A pioneer in diffeomorphism learning, but limited to first-order systems.
  • Neural Contractive DS (NCDS): Guarantees strong contraction but is likewise limited to first-order systems.
  • Contact Hamiltonian (Zadra 2023): Directly parameterizes the contact Hamiltonian function, which can be unstable outside the training data.
  • Maupertuis Principle: Acts as a bridge between contact flows and Riemannian geodesics, providing a theoretical foundation for geometric generalization.
  • Insight: The concept of incorporating uncertainty into the geometric structure (instead of applying it as a post-processing step) can be generalized to other physical prior models.

Rating

  • Novelty: ⭐⭐⭐⭐⭐ — Elegantly introduces a complete contact geometry framework to dynamical systems learning for the first time.
  • Experimental Thoroughness: ⭐⭐⭐⭐ — Comprehensive coverage across physical systems, handwriting, and real robots, though with limited advantage on LASA.
  • Writing Quality: ⭐⭐⭐⭐ — Mathematically rigorous and clearly illustrated, but with high mathematical density.
  • Value: ⭐⭐⭐⭐⭐ — Establishes a new paradigm for learning non-conservative dynamical systems; offers broad development prospects in robotic interaction control.