SPD(N) with the Bures-Wasserstein Metric
A second Riemannian structure on the symmetric positive definite cone, distinct from the affine-invariant metric at /manifolds/spd. The Bures-Wasserstein metric is the quotient geometry of by the right action and coincides with the -Wasserstein metric restricted to centred Gaussian measures .
When to reach for it
Pick affine-invariant SPD when you want invariance under covariance re-parameterisation (log-Euclidean-adjacent, Fisher-Rao-compatible). Pick Bures-Wasserstein when you want distance between Gaussian measures in the sense of optimal transport — the natural choice for vol-surface interpolation, McCann-Brenier covariance transport, or Wasserstein barycentres.
Metric
where solves the Lyapunov equation
Numerically, is computed once per inner-product evaluation via symmetric eigendecomposition of : diagonalise , then .
Geodesics
The geodesic from with initial velocity is
Exponential and logarithm
is the McCann-Brenier optimal-transport map from to , represented as a symmetric matrix. The logarithm is well-defined globally: Bures-Wasserstein SPD is geodesically complete with no cut locus.
Distance
The closed-form 2-Wasserstein distance between centred Gaussians:
Exposed as a standalone helper bw_distance_sq() for speed — the default Manifold::dist routes through log + norm, which requires two eigendecompositions and a Lyapunov solve.
Curvature
Bures-Wasserstein SPD has non-negative sectional curvature bounded above by a dimensional constant (Takatsu, 2011). Contrast with affine-invariant SPD, which has non-positive curvature everywhere.
| Geometry | Sectional | Cut locus |
|---|---|---|
| Affine-invariant | (Cartan-Hadamard) | empty |
| Bures-Wasserstein | empty |
Parallel transport
Parallel transport does not admit a clean closed form for general . cartan-stochastic exposes the weaker VectorTransport trait implemented via the Fréchet derivative of the retraction:
This is sufficient for the Stratonovich development integrator (which re-orthonormalises the frame each step) but not for algorithms that require isometric transport. Exact parallel transport is a pending upstream work item tied to an elworthy/bismut consumer.
API
use cartan_core::{Manifold, Retraction};
use cartan_manifolds::SpdBuresWasserstein;
use nalgebra::SMatrix;
let m: SpdBuresWasserstein<3> = SpdBuresWasserstein;
let p = SMatrix::<f64, 3, 3>::identity();
let v = /* symmetric tangent */;
let q = m.exp(&p, &v);
let v_recovered = m.log(&p, &q)?;Integration with L1
BW-SPD plugs directly into cartan-stochastic::stochastic_development:
let frame = random_frame_at(&m, &p, &mut rng)?;
let result = stochastic_development(&m, &p, frame, n_steps, dt, &mut rng, 1e-8)?;
// Every point in result.path is a valid SPD matrix.References
- Bhatia, R., Jain, T., Lim, Y. On the Bures-Wasserstein distance between positive definite matrices. Expositiones Mathematicae 37(2), 2019.
- Malagò, L., Montrucchio, L., Pistone, G. Wasserstein Riemannian geometry of Gaussian densities. Information Geometry 1, 2018.
- Takatsu, A. Wasserstein geometry of Gaussian measures. Osaka J. Math. 48(4), 2011.