Lecture 2: Fréchet Means — Existence and Uniqueness

Generalizing the mean to metric spaces

1 Learning Goals

By the end of this lecture, learners should be able to:

  • Define the population and sample Fréchet functions and Fréchet mean sets.
  • Explain why the Fréchet mean generalizes the ordinary Euclidean mean.
  • Construct a counterexample where a Fréchet mean fails to exist.
  • State and prove the existence theorem for Fréchet means in Heine–Borel metric spaces.
  • Define geodesics, geodesic spaces, and uniquely geodesic spaces.
  • Explain Alexandrov curvature bounds and the definition of CAT(\(\kappa\)) spaces.
  • State the definition of a Hadamard space and give examples.
  • Prove that the Fréchet mean is unique in Hadamard spaces using convexity arguments.

2 From Euclidean Mean to Fréchet Mean

The arithmetic mean is arguably the single most important summary statistic in data analysis. It serves as the canonical measure of central tendency, the foundation of linear regression, and the building block of nearly every classical statistical method. Its centrality is no accident: the mean is the unique point that minimizes the sum of squared Euclidean distances to the data — a property that links geometry, optimization, and probability in one simple formula. This variational characterization is the key that unlocks a vast generalization beyond Euclidean space.

Let \(X = (X_1, \ldots, X_p) \in \mathbb{R}^p\) be a random vector. In classical statistics, the mean vector \(\mathbb{E}X\) is defined componentwise:

\[ \mathbb{E}X = (\mathbb{E}X_1, \ldots, \mathbb{E}X_p). \]

This definition relies on the vector space structure of \(\mathbb{R}^p\). When \(X\) is a random element in a space \(\mathcal{M}\) without a vector space structure, the usual definition of \(\mathbb{E}X\) no longer applies.

However, there is an alternative characterization: the mean \(\mathbb{E}X\) minimizes the function

\[ F(x) = \mathbb{E}\|X - x\|_2^2 \]

over \(x \in \mathbb{R}^p\), provided \(\mathbb{E}\|X\|_2^2 < \infty\). This definition only involves the Euclidean distance \(\|\cdot\|_2\) and is readily extended to any metric space.

Definition 1 Let \((\mathcal{M}, d)\) be a metric space and let \(X\) be a random element taking values in \(\mathcal{M}\) such that \(\mathbb{E}\{d^2(X, x_0)\} < \infty\) for some \(x_0 \in \mathcal{M}\). The population Fréchet function is

\[ F(x) = \mathbb{E}\{d^2(X, x)\}, \qquad x \in \mathcal{M}, \]

and for observations \(X_1, \ldots, X_n\) the sample Fréchet function is

\[ F_n(x) = \frac{1}{n}\sum_{i=1}^n d^2(X_i, x). \]

NoteFiniteness Check

Prove that \(\mathbb{E}\{d^2(X, x_0)\} < \infty\) for some \(x_0 \in \mathcal{M}\) implies that \(\mathbb{E}\{d^2(X, x)\} < \infty\) for all \(x \in \mathcal{M}\). (Hint: use the triangle inequality and the fact that \((a+b)^2 \le 2a^2 + 2b^2\).)

Definition 2 The population Fréchet mean set is

\[ \mathscr{E}_X = \left\{x \in \mathcal{M} : F(x) = \inf_{y \in \mathcal{M}} F(y)\right\}, \]

and the sample Fréchet mean set is

\[ \mathscr{E}_n = \left\{x \in \mathcal{M} : F_n(x) = \inf_{y \in \mathcal{M}} F_n(y)\right\}. \]

If either set is a singleton, we identify it with its unique element and call it the Fréchet mean or sample Fréchet mean.

When \(\mathcal{M} = \mathbb{R}^p\) with the Euclidean distance, the unique Fréchet mean is the ordinary mean \(\mathbb{E}(X)\). The Fréchet mean thus extends the concept of a probability mass center to general metric spaces.

TipExercise: Verify That the Fréchet Mean Generalizes the Usual Mean

Show that when \(\mathcal{M} = \mathbb{R}^p\) with the Euclidean distance \(d(x, y) = \|x - y\|_2\), the Fréchet mean of a random vector \(X\) with \(\mathbb{E}\|X\|^2 < \infty\) is exactly the usual mean \(\mathbb{E}X\). That is, prove that \(\mathbb{E}X\) is the unique minimizer of the Fréchet function \(F(x) = \mathbb{E}\|X - x\|_2^2\). 📝 Show Solution

NoteHistorical and Terminological Notes

The formulation goes back to Fréchet (1948). On a Riemannian manifold equipped with its geodesic distance, a Fréchet mean is also called an intrinsic mean (Bhattacharya and Patrangenaru 2003), a Riemannian center of mass (Grove and Karcher 1973; Karcher 1977), a Karcher mean, or a barycenter. A historical note regarding the Karcher mean is provided by Karcher (2014).

3 Existence and Uniqueness

The usual mean is unique if exists. However, existence and uniqueness of the Fréchet mean are now geometric rather than purely probabilistic issues. In an arbitrary metric space a Fréchet mean may fail to exist, and even when it exists it need not be unique.

Example 1 Let \(\mathcal{M} = \mathbb{R} \setminus \{0\}\) with the usual distance \(d(x, y) = |x - y|\), and let \(X\) take the values \(-1\) and \(1\) with probability \(1/2\) each. Then for any \(x \in \mathcal{M}\),

\[ F(x) = \mathbb{E}\,d^2(X, x) = \frac{1}{2}(x+1)^2 + \frac{1}{2}(x-1)^2 = x^2 + 1. \]

This function has infimum \(1\), attained only at \(x = 0\). Since \(0 \notin \mathcal{M}\), the infimum is not attained on \(\mathcal{M}\), so the population Fréchet mean set is empty.

Example 2 Let \(X\) be uniformly distributed on the sphere \(\mathbb{S}^p\) for \(p \ge 1\). Show that any point \(x \in \mathbb{S}^p\) is a Fréchet mean of \(X\). (Hint: by symmetry, \(F(x)\) is constant on \(\mathbb{S}^p\).)

For certain spaces, such as Heine–Borel spaces, we can guarantee that the Fréchet mean set is nonempty.

Theorem 1 Suppose \(X\) is a random element on a metric space \((\mathcal{M}, d)\) where every closed bounded subset is compact. If \(F(x) < \infty\) for some \(x \in \mathcal{M}\), then the Fréchet mean set \(\mathscr{E}_X\) is nonempty and compact.

Proof. Let \(x_0 \in \mathcal{M}\) be such that \(F(x_0) = c < \infty\).

First, \(F(x) < \infty\) for all \(x \in \mathcal{M}\) (by the exercise above) and \(F\) is continuous. Also, the set \(S_c := \{x \in \mathcal{M} : F(x) \le c\}\) is bounded (exercise) and nonempty. Continuity of \(F\) implies that \(S_c\) is closed. The Heine–Borel property of \(\mathcal{M}\) then implies that the closed bounded \(S_c\) is compact. By continuity, \(F\) attains its minimum on \(S_c\), which is also the global minimum since \(F(x) > c\) for any \(x \notin S_c\). Therefore, the Fréchet mean set is nonempty.

The existence result Theorem 1 relies on three topological concepts that appear throughout these lectures:

Closed set. A subset \(C \subseteq \mathcal{M}\) of a metric space is closed if it contains all its limit points — equivalently, if whenever a sequence \((x_n) \subset C\) converges to some \(x \in \mathcal{M}\), then \(x \in C\). The complement of a closed set is open. The entire space \(\mathcal{M}\) and the empty set \(\varnothing\) are both closed and open.

Bounded set. A subset \(B \subseteq \mathcal{M}\) is bounded if its diameter is finite: \[ \operatorname{diam}(B) := \sup_{x, y \in B} d(x, y) \;<\; \infty. \] Equivalently, \(B\) is contained in some open ball \(B_r(p) = \{x \in \mathcal{M} : d(x, p) < r\}\) of finite radius. Boundedness depends on the metric, not on the topology alone.

Compactness. A subset \(K \subseteq \mathcal{M}\) is compact if every open cover of \(K\) admits a finite subcover. For metric spaces, this is equivalent to sequential compactness: every sequence in \(K\) has a subsequence that converges to a point in \(K\). Compact sets are always closed and bounded; the converse is false in general but holds in \(\mathbb{R}^n\) (the classical Heine–Borel theorem).

Heine–Borel property. A metric space \((\mathcal{M}, d)\) has the Heine–Borel property (or is a Heine–Borel space) if every closed and bounded subset of \(\mathcal{M}\) is compact. Euclidean space \(\mathbb{R}^n\) is the canonical example; in contrast, infinite-dimensional Hilbert spaces with the norm topology do not have this property. The property is crucial for guaranteeing that continuous functions attain their minima on closed bounded sets — exactly the argument used in the proof above.

4 Geometric Preliminaries

To discuss uniqueness, we need additional geometric concepts: geodesics and curvature bounds.

4.1 Geodesics and Geodesic Spaces

In Euclidean statistics, straight lines connect data points and provide canonical interpolations. In a general metric space, this role is played by geodesics.

Definition 3 A curve \(\gamma : [0,1] \to \mathcal{M}\) is a constant-speed geodesic from \(x\) to \(y\) if \(\gamma(0) = x\), \(\gamma(1) = y\), and

\[ d\bigl(\gamma(s), \gamma(t)\bigr) = |s - t|\,d(x, y), \qquad s, t \in [0,1]. \]

NoteIllustration: geodesic on a hemisphere

The half-sphere (hemisphere) \(\mathbb{S}^2_+ = \{(x,y,z) : x^2 + y^2 + z^2 = 1,\; z \ge 0\}\) is a geodesic space. A geodesic between two points is the shorter great-circle arc connecting them, which always lies on the hemisphere surface.

Drag the slider to move the red dot along γ(t) from A to B. Drag the view to orbit, scroll to zoom.

The metric space \((\mathcal{M}, d)\) is a geodesic space if every pair \(x, y \in \mathcal{M}\) can be joined by at least one geodesic. It is uniquely geodesic if that geodesic is unique for every pair of points.

A subset \(C \subset \mathcal{M}\) of a geodesic space is called geodesically convex if every geodesic joining two points of \(C\) lies entirely inside \(C\). In non-Euclidean statistics, geodesic convexity replaces ordinary convexity.

Examples:

  • Euclidean spaces are uniquely geodesic, with geodesics given by affine segments \(t \mapsto (1-t)x + ty\).
  • On the sphere, geodesics are great-circle arcs, and they fail to be unique at antipodal points.
  • SPD space with the affine-invariant distance is uniquely geodesic.
  • In Wasserstein space, geodesics are displacement interpolations induced by optimal transport.

4.2 Alexandrov Curvature and Hadamard Spaces

Curvature can be formulated in purely metric terms by comparing triangles with those in constant-curvature model spaces. For \(\kappa \in \mathbb{R}\), let \(\mathbb{M}_\kappa^2\) denote the complete simply connected two-dimensional space form of constant curvature \(\kappa\): the Euclidean plane when \(\kappa = 0\), the sphere of radius \(1/\sqrt{\kappa}\) when \(\kappa > 0\), and the hyperbolic plane when \(\kappa < 0\).

Consider a geodesic triangle \(\triangle(x, y, z)\) in \(\mathcal{M}\). A comparison triangle in \(\mathbb{M}_\kappa^2\) is a triangle \(\overline{\triangle}(\bar{x}, \bar{y}, \bar{z})\) having the same side lengths,

\[ d(x, y) = d_\kappa(\bar{x}, \bar{y}), \quad d(y, z) = d_\kappa(\bar{y}, \bar{z}), \quad d(z, x) = d_\kappa(\bar{z}, \bar{x}), \]

where \(d_\kappa\) denotes the distance in \(\mathbb{M}_\kappa^2\). When \(\kappa > 0\), one restricts to sufficiently small triangles.

Comparison triangle: for a geodesic triangle \(\triangle(x,y,z)\) in \(\mathcal{M}\) (left) and its comparison triangle \(\overline{\triangle}(\bar{x},\bar{y},\bar{z})\) in the model space \(\mathbb{M}_\kappa^2\) (right). The comparison point \(\bar{p}\) on the side from \(\bar{y}\) to \(\bar{z}\) satisfies \(d(\bar{y}, \bar{p}) = d_\kappa(y, p)\).

Definition 4 Let

\[ D_\kappa = \begin{cases} \pi / \sqrt{\kappa}, & \kappa > 0, \\ \infty, & \kappa \le 0. \end{cases} \]

A geodesic metric space \((\mathcal{M}, d)\) is called a \(\mathrm{CAT}(\kappa)\) space if for every geodesic triangle \(\triangle(x, y, z)\) with perimeter

\[ d(x, y) + d(y, z) + d(z, x) < 2D_\kappa, \]

and for every comparison triangle \(\overline{\triangle}(\bar{x}, \bar{y}, \bar{z})\) in \(\mathbb{M}_\kappa^2\), the following holds: if \(p\) lies on the side from \(y\) to \(z\) and \(\bar{p}\) is its comparison point, then

\[ d(x, p) \le d_\kappa(\bar{x}, \bar{p}). \]

A metric space \(\mathcal{M}\) is said to be a space with curvature \(\le \kappa\), or locally \(\mathrm{CAT}(\kappa)\), if every point of \(\mathcal{M}\) has a geodesically convex \(\mathrm{CAT}(\kappa)\) neighbourhood. A locally \(\mathrm{CAT}(0)\) space may be said to have non-positive curvature; such spaces are also called NPC spaces.

If the inequality is reversed — \(d(x, p) \ge d_\kappa(\bar{x}, \bar{p})\) — then we say \(\mathcal{M}\) has curvature bounded from below, or curvature \(\ge \kappa\).

Definition 5 A Hadamard space is a complete geodesic \(\mathrm{CAT}(0)\) space.

NoteExercise

Show that a Hadamard space is uniquely geodesic. (Hint: use the \(\mathrm{CAT}(0)\) inequality.) 📝 Show Solution

Hadamard spaces behave in many respects like Hilbert spaces: geodesics are unique, geodesically convex sets admit unique metric projections, and squared distance functions are convex along geodesics. These properties make statistical analysis on data from Hadamard spaces much more tractable.

4.3 Examples of Curvature Behavior

Space Curvature Notes
Sphere \(\mathbb{S}^p\) \(\mathrm{CAT}(1)\) (positive) Not Hadamard; antipodal points have many geodesics
SPD matrices (affine-invariant / log-Euclidean / log-Cholesky) \(\mathrm{CAT}(0)\) Unbounded Hadamard space
BHV tree space \(\mathrm{CAT}(0)\) Unbounded Hadamard space (Billera et al. 2001)
\((\mathcal{P}_2(\mathbb{R}), W_2)\) \(\mathrm{CAT}(0)\) Flat: isometric to convex subset of \(L^2(0,1)\) (Panaretos and Zemel 2020; Kloeckner 2010)
\((\mathcal{P}_2(\mathbb{R}^p), W_2)\) for \(p > 1\) Curvature \(\ge 0\) Genuinely curved, nonnegative Alexandrov curvature (Otto 2001; Lott 2008)

5 Uniqueness in Hadamard Spaces

The Fréchet mean in Hadamard spaces, if it exists, is unique, due to Proposition 4.3 of Sturm (2003).

Proposition 1 Let \((\mathcal{M}, d)\) be a Hadamard space and \(X\) a random element on \(\mathcal{M}\) such that \(\mathbb{E}\,d(X, x) < \infty\) for some \(x \in \mathcal{M}\). Fix \(y \in \mathcal{M}\). Then there exists a unique point \(\mu \in \mathcal{M}\) minimizing the uniformly convex continuous function

\[ G(z) = \mathbb{E}[d^2(X, z) - d^2(X, y)], \]

and this minimizer is independent of \(y\). If further \(\mathbb{E}\,d^2(X, x) < \infty\) for some \(x \in \mathcal{M}\), then

\[ \mu = \arg\min_{z \in \mathcal{M}} \mathbb{E}\,d^2(X, z), \]

that is, \(\mu\) is the Fréchet mean of \(X\).

Corollary 1 The sample Fréchet mean exists and is unique in Hadamard spaces.

To present the proof, we need notions of convexity on geodesic metric spaces.

Definition 6 Let \((\mathcal{M}, d)\) be a geodesic metric space and let \(f : \mathcal{M} \to \mathbb{R}\).

  • \(f\) is convex if for every geodesic \(\gamma : [0,1] \to \mathcal{M}\),

\[ f\bigl(\gamma(t)\bigr) \le (1-t)f\bigl(\gamma(0)\bigr) + t f\bigl(\gamma(1)\bigr), \qquad t \in [0,1]. \]

  • Given \(\lambda > 0\), \(f\) is \(\lambda\)-strongly convex if for every geodesic \(\gamma : [0,1] \to \mathcal{M}\),

\[ f\bigl(\gamma(t)\bigr) \le (1-t)f\bigl(\gamma(0)\bigr) + t f\bigl(\gamma(1)\bigr) - \frac{\lambda}{2}t(1-t)d^2\bigl(\gamma(0), \gamma(1)\bigr), \qquad t \in [0,1]. \]

  • \(f\) is uniformly convex if there exists a strictly increasing function \(\eta : [0,\infty) \to [0,\infty)\) with \(\eta(0) = 0\) such that for every geodesic \(\gamma : [0,1] \to \mathcal{M}\),

\[ f\bigl(\gamma(1/2)\bigr) \le \frac{1}{2}f\bigl(\gamma(0)\bigr) + \frac{1}{2}f\bigl(\gamma(1)\bigr) - \eta\bigl(d(\gamma(0), \gamma(1))\bigr). \]

Clearly, a strongly convex function is also uniformly convex.

Proposition 2 Let \((\mathcal{M}, d)\) be a complete geodesic space, and let \(f : \mathcal{M} \to \mathbb{R}\) be uniformly convex and lower semicontinuous. Then there exists a unique point \(\mu \in \mathcal{M}\) such that

\[ f(\mu) = \inf_{z \in \mathcal{M}} f(z). \]

Equivalently, \(\mu = \arg\min_{z \in \mathcal{M}} f(z)\).

A function \(f : \mathcal{M} \to \mathbb{R}\) on a metric space \((\mathcal{M}, d)\) is lower semicontinuous (l.s.c.) at a point \(x \in \mathcal{M}\) if

\[ f(x) \le \liminf_{n \to \infty} f(x_n) \]

for every sequence \((x_n)\) converging to \(x\). Equivalently, for every \(\varepsilon > 0\) there exists \(\delta > 0\) such that \(f(y) > f(x) - \varepsilon\) whenever \(d(x, y) < \delta\). The function \(f\) is lower semicontinuous on \(\mathcal{M}\) if it is l.s.c. at every point.

Intuition. While a continuous function cannot jump in either direction, a lower semicontinuous function may only jump downwards, never upwards. Equivalently, its sublevel sets \(\{x : f(x) \le c\}\) are closed for every \(c \in \mathbb{R}\).

Why it matters here. Lower semicontinuity is the minimal regularity condition needed for an optimization problem to attain its minimum on a compact set — a continuous function is automatically l.s.c., but l.s.c. is enough.

Proposition 3 If \((\mathcal{M}, d)\) is a Hadamard space, then for each pair of points \(x_0, x_1 \in \mathcal{M}\) there exists a unique geodesic \(t \mapsto x_t\) on \([0,1]\) joining them. For each fixed \(t \in [0,1]\), the point \(x_t\) depends continuously on the endpoints \(x_0, x_1\). Moreover, for every \(z \in \mathcal{M}\) and every \(t \in [0,1]\),

\[ d^2(z, x_t) \le (1-t)d^2(z, x_0) + t d^2(z, x_1) - t(1-t)d^2(x_0, x_1). \]

Therefore, for any fixed \(z\), the squared distance function \(f(x) = d^2(z, x)\) is strongly convex in a Hadamard space.

Proof of Proposition 2.1. Let \(q\) denote the law of \(X\), and for fixed \(y \in \mathcal{M}\) define

\[ F_y(z) = \int_{\mathcal{M}} \bigl[d^2(z, u) - d^2(y, u)\bigr]\,q(du) = \mathbb{E}\bigl[d^2(X, z) - d^2(X, y)\bigr]. \]

Then \(F_y = G\). If \(y_0 \in \mathcal{M}\) is another base point, then

\[ F_y(z) - F_{y_0}(z) = \int_{\mathcal{M}} \bigl[d^2(y_0, u) - d^2(y, u)\bigr]\,q(du), \]

which is independent of \(z\). Hence any minimizer is independent of the choice of \(y\).

Now let \(z_0, z_1 \in \mathcal{M}\) and let \(z_t\) be the geodesic joining them. By the squared-distance convexity proposition, for every \(u \in \mathcal{M}\),

\[ d^2(z_t, u) \le (1-t)d^2(z_0, u) + t d^2(z_1, u) - t(1-t)d^2(z_0, z_1), \]

or equivalently,

\[ d^2(z_t, u) - d^2(y, u) \le (1-t)[d^2(z_0, u) - d^2(y, u)] + t[d^2(z_1, u) - d^2(y, u)] - t(1-t)d^2(z_0, z_1). \]

Integrating with respect to \(q\) yields

\[ F_y(z_t) \le (1-t)F_y(z_0) + t F_y(z_1) - t(1-t)d^2(z_0, z_1), \]

so \(F_y\) is strongly convex and thus uniformly convex. Moreover,

\[ |F_y(z) - F_y(z_0)| \le d(z, z_0)\int_{\mathcal{M}} \bigl(d(z, u) + d(z_0, u)\bigr)\,q(du), \]

so \(F_y\) is continuous. Therefore \(F_y\) has a unique minimizer on the Hadamard space \(\mathcal{M}\).

If in addition \(\mathbb{E}\,d^2(X, x) < \infty\), then

\[ F_y(z) = \mathbb{E}\,d^2(X, z) - \mathbb{E}\,d^2(X, y) \]

differs from \(z \mapsto \mathbb{E}\,d^2(X, z)\) only by an additive constant. Thus they have the same unique minimizer — the Fréchet mean of \(X\). □

6 Application: Fréchet Mean of Covariance Matrices for Portfolio Risk

Covariance matrices are central to portfolio theory and risk management. The variance of a portfolio with weight vector \(w \in \mathbb{R}^p\) is

\[ \operatorname{Var}(w^\top R) = w^\top \Sigma w, \]

where \(\Sigma \in \mathcal{S}_{++}^{p}\) is the covariance matrix of asset returns. Covariance matrices live not in \(\mathbb{R}^{p \times p}\) but in the cone of symmetric positive definite (SPD) matrices — a non-Euclidean space with its own curved geometry (Bhattacharya and Patrangenaru 2003; Pennec et al. 2006).

A natural question arises: if we observe covariance matrices \(\Sigma_1, \Sigma_2, \ldots, \Sigma_n\) estimated from rolling time windows, what is the “average market risk structure”? The ordinary Euclidean average

\[ \bar{\Sigma}_{\text{Euclid}} = \frac{1}{n}\sum_{i=1}^n \Sigma_i \]

is a valid SPD matrix (the SPD cone is convex in the Euclidean sense), but it ignores the intrinsic geometry of \(\mathcal{S}_{++}^{p}\). Two geometrically motivated alternatives are:

  1. Log-Euclidean Fréchet mean (Arsigny et al. 2006): map each \(\Sigma_i\) to the tangent space at the identity via the matrix logarithm, average in that flat space, and map back:

    \[ \hat{\Sigma}_{\mathrm{LE}} = \exp\!\left(\frac{1}{n}\sum_{i=1}^n \log(\Sigma_i)\right). \]

    This is the unique Fréchet mean under the log-Euclidean metric \(d_{\mathrm{LE}}(\Sigma_1, \Sigma_2) = \|\log(\Sigma_1) - \log(\Sigma_2)\|_F\).

  2. Affine-invariant Riemannian Fréchet mean (Pennec et al. 2006; Moakher 2005): the intrinsic mean under the affine-invariant metric \(d_{\mathrm{AI}}(\Sigma_1, \Sigma_2) = \|\log(\Sigma_1^{-1/2}\Sigma_2\Sigma_1^{-1/2})\|_F\). This metric is invariant under congruence transformations \(\Sigma \mapsto A\Sigma A^\top\), making it particularly natural for covariance matrices. Its Fréchet mean has no closed form and requires iterative computation.

The log-Euclidean and affine-invariant means both respect the SPD cone geometry, unlike the Euclidean mean which can produce “swelling” artifacts (inflated determinants) and does not preserve the natural Riemannian structure.

The demo below generates synthetic monthly covariance matrices for three assets (modeled on AAPL, MSFT, and JPM). Each matrix corresponds to a different market regime (turbulent, calm, tech-rally, etc.). Adjust the seed to explore different realizations, then compare the Euclidean and log-Euclidean Fréchet means.

Observations

  • The Euclidean mean of SPD matrices can inflate variances and correlations — the SPD cone geometry is not flat.
  • The log-Euclidean Fréchet mean respects the multiplicative structure: variances and covariances are averaged geometrically via the matrix logarithm.
  • In practice, the choice of metric for averaging covariance matrices affects portfolio risk estimates, diversification measures, and regulatory capital calculations.
  • The affine-invariant Fréchet mean goes further by ensuring invariance under changes of basis (e.g., currency conversions or factor rotations), but at the cost of requiring iterative computation (Pennec et al. 2006).

7 Key Takeaways

  • The Fréchet mean generalizes the Euclidean mean by minimizing expected squared distance.
  • In arbitrary metric spaces, Fréchet means may fail to exist or may not be unique.
  • The Heine–Borel property (closed bounded sets are compact) guarantees existence.
  • Hadamard spaces — complete geodesic \(\mathrm{CAT}(0)\) spaces — guarantee uniqueness.
  • The squared distance function in a Hadamard space is strongly convex along geodesics, which is the key geometric fact behind uniqueness.
  • Key examples of Hadamard spaces: SPD matrices (under intrinsic metrics), BHV tree space, and the 1D Wasserstein space.

8 Exercises

  1. Finiteness of the Fréchet function: Prove that if \(\mathbb{E}\{d^2(X, x_0)\} < \infty\) for some \(x_0 \in \mathcal{M}\), then \(\mathbb{E}\{d^2(X, x)\} < \infty\) for all \(x \in \mathcal{M}\). 📝 Show Solution

  2. Non-uniqueness on the sphere: Let \(X\) be uniformly distributed on \(\mathbb{S}^p\). Show that \(F(x)\) is constant on \(\mathbb{S}^p\), so every point is a Fréchet mean. (Hint: use rotational symmetry.) 📝 Show Solution

  3. Boundedness of \(S_c\): In the proof of Theorem 2.1, show that the set \(S_c = \{x \in \mathcal{M} : F(x) \le c\}\) is bounded. 📝 Show Solution

  4. Hadamard spaces are uniquely geodesic: Prove that a Hadamard space is uniquely geodesic. (Hint: use the \(\mathrm{CAT}(0)\) inequality.) 📝 Show Solution

  5. Strong convexity of squared distance: Verify that in \(\mathbb{R}^p\) with the Euclidean metric, the squared-distance convexity inequality holds with equality (in fact, it’s the parallelogram law in disguise). 📝 Show Solution

  6. Comparison triangle construction: For three points in \(\mathbb{R}^2\) with the Euclidean metric, construct their comparison triangle. Show that \(d(x, p) = d_0(\bar{x}, \bar{p})\) — there is no distortion. 📝 Show Solution

Exercise 1: Finiteness of the Fréchet Function

Exercise: Prove that if \(\mathbb{E}\{d^2(X, x_0)\} < \infty\) for some \(x_0 \in \mathcal{M}\), then \(\mathbb{E}\{d^2(X, x)\} < \infty\) for all \(x \in \mathcal{M}\).

Solution:

By the triangle inequality, for any \(x, x_0 \in \mathcal{M}\),

\[d(X, x) \le d(X, x_0) + d(x_0, x).\]

Squaring both sides and using the inequality \((a+b)^2 \le 2a^2 + 2b^2\) (which follows from \((a-b)^2 \ge 0\)),

\[d^2(X, x) \le \bigl(d(X, x_0) + d(x_0, x)\bigr)^2 \le 2\,d^2(X, x_0) + 2\,d^2(x_0, x).\]

Taking expectations,

\[\mathbb{E}\,d^2(X, x) \le 2\,\mathbb{E}\,d^2(X, x_0) + 2\,d^2(x_0, x).\]

Since \(\mathbb{E}\,d^2(X, x_0) < \infty\) by assumption and \(d(x_0, x)\) is a finite constant (not random), the right-hand side is finite. Therefore \(\mathbb{E}\,d^2(X, x) < \infty\) for all \(x \in \mathcal{M}\).

This simple observation ensures that the Fréchet function \(F(x) = \mathbb{E}\,d^2(X, x)\) is well-defined on the whole space whenever it is finite at a single point.

Exercise 2: Non-Uniqueness on the Sphere

Exercise: Let \(X\) be uniformly distributed on \(\mathbb{S}^p\). Show that \(F(x)\) is constant on \(\mathbb{S}^p\), so every point is a Fréchet mean.

Solution:

Let \(X \sim \operatorname{Uniform}(\mathbb{S}^p)\). The distribution of \(X\) is invariant under the action of the orthogonal group \(O(p+1)\): for any \(R \in O(p+1)\), the random variable \(R X\) has the same distribution as \(X\), because the uniform measure on the sphere is the unique rotationally-invariant probability measure.

Now fix any two points \(x, y \in \mathbb{S}^p\). Since \(O(p+1)\) acts transitively on the sphere, there exists a rotation \(R \in O(p+1)\) such that \(y = R x\). Then

\[\begin{align*} F(y) = F(R x) &= \mathbb{E}\bigl[d^2(X, R x)\bigr] \\ &= \mathbb{E}\bigl[d^2(R^{-1} X, x)\bigr] \quad \text{(since } R \text{ is an isometry)} \\ &= \mathbb{E}\bigl[d^2(X, x)\bigr] \quad \text{(since } R^{-1}X \stackrel{d}{=} X \text{ by rotational invariance)} \\ &= F(x). \end{align*}\]

Thus \(F(x) = F(y)\) for all \(x, y \in \mathbb{S}^p\) — the Fréchet function is constant. Since every point attains the same value, every point is a minimizer, and hence every point on the sphere is a Fréchet mean.

Exercise 3: Boundedness of \(S_c\)

Exercise: In the proof of Theorem 2.1, show that the set \(S_c = \{x \in \mathcal{M} : F(x) \le c\}\) is bounded.

Solution:

Let \(x_0 \in \mathcal{M}\) be any fixed point. For any \(x \in S_c\), we bound \(d(x_0, x)\) as follows.

First, by the triangle inequality, \(d(x_0, x) \le d(x_0, X) + d(X, x)\). Squaring and using \((a+b)^2 \le 2a^2 + 2b^2\):

\[d^2(x_0, x) \le 2\,d^2(X, x_0) + 2\,d^2(X, x).\]

Now take expectations:

\[\begin{align*} d^2(x_0, x) &= \mathbb{E}\,d^2(x_0, x) \quad \text{(left side is deterministic)} \\ &\le 2\,\mathbb{E}\,d^2(X, x_0) + 2\,\mathbb{E}\,d^2(X, x) \\ &= 2F(x_0) + 2F(x). \end{align*}\]

Since \(x \in S_c\), we have \(F(x) \le c\). Therefore

\[d^2(x_0, x) \le 2F(x_0) + 2c.\]

Taking square roots,

\[d(x_0, x) \le \sqrt{2F(x_0) + 2c}.\]

This uniform bound holds for every \(x \in S_c\). Hence \(S_c\) is contained in the closed ball of radius \(R = \sqrt{2F(x_0) + 2c}\) centered at \(x_0\), and is therefore bounded.

Exercise 4: Hadamard Spaces Are Uniquely Geodesic

Exercise: Prove that a Hadamard space is uniquely geodesic. (Hint: use the \(\mathrm{CAT}(0)\) inequality.)

Solution:

Let \((\mathcal{M}, d)\) be a Hadamard space (a complete geodesic \(\mathrm{CAT}(0)\) space). Because it is geodesic, at least one geodesic joins every pair of points. It remains to prove uniqueness.

Suppose that two geodesics \(\gamma_1, \gamma_2 : [0,1] \to \mathcal{M}\) have the same endpoints:

\[\gamma_1(0) = \gamma_2(0) = x, \qquad \gamma_1(1) = \gamma_2(1) = y.\]

Fix any \(t_0 \in (0,1)\) and set

\[m_1 = \gamma_1(t_0), \qquad m_2 = \gamma_2(t_0), \qquad L=d(x,y).\]

The picture shows the only apparent way the two geodesics could differ, and why the \(\mathrm{CAT}(0)\) comparison rules it out.

Two candidate geodesics from \(x\) to \(y\) give points \(m_1=\gamma_1(t_0)\) and \(m_2=\gamma_2(t_0)\). Their Euclidean comparison triangle is degenerate, so the comparison points coincide and the \(\mathrm{CAT}(0)\) inequality forces \(m_1=m_2\).

Now consider the geodesic triangle \(\triangle(x, y, m_2)\) whose side from \(x\) to \(y\) is \(\gamma_1\), while its other two sides are the corresponding subsegments of \(\gamma_2\). Construct its comparison triangle \(\overline{\triangle}(\bar{x}, \bar{y}, \bar{m}_2)\) in the Euclidean plane \(\mathbb{R}^2\) (the model space \(\mathbb{M}_0^2\)). The comparison triangle has side lengths:

\[d_0(\bar{x}, \bar{y}) = L, \quad d_0(\bar{x}, \bar{m}_2) = t_0L, \quad d_0(\bar{m}_2, \bar{y}) = (1-t_0)L.\]

These lengths add with equality: \(t_0L+(1-t_0)L=L\). Consequently the comparison triangle is degenerate, with \(\bar{m}_2\) at parameter \(t_0\) on the segment from \(\bar{x}\) to \(\bar{y}\).

The point \(m_1\) lies at the same parameter \(t_0\) on the other side from \(x\) to \(y\). Its comparison point \(\bar{m}_1\) therefore also lies at parameter \(t_0\) on \(\bar{x}\bar{y}\). Hence \(\bar{m}_1=\bar{m}_2\).

By the \(\mathrm{CAT}(0)\) inequality applied to the triangle \(\triangle(x, y, m_2)\) with the point \(m_1\) on the side \(xy\),

\[d(m_2,m_1)\le d_0(\bar{m}_2,\bar{m}_1)=0.\]

Thus \(\gamma_1(t_0)=\gamma_2(t_0)\). Since \(t_0\) was arbitrary (and the endpoints already agree), \(\gamma_1(t)=\gamma_2(t)\) for every \(t\in[0,1]\).

Thus geodesics in a Hadamard space are unique.

Exercise 5: Strong Convexity of Squared Distance in \(\mathbb{R}^p\)

Exercise: Verify that in \(\mathbb{R}^p\) with the Euclidean metric, the squared-distance convexity inequality holds with equality (in fact, it’s the parallelogram law in disguise).

Solution:

In \(\mathbb{R}^p\), the geodesic from \(x_0\) to \(x_1\) is \(\gamma(t) = x_t = (1-t)x_0 + t x_1\). For any \(z \in \mathbb{R}^p\), we compute:

\[\begin{align*} d^2(z, x_t) &= \|z - x_t\|^2 = \|z - (1-t)x_0 - t x_1\|^2 \\ &= \|(1-t)(z - x_0) + t(z - x_1)\|^2 \\ &= (1-t)^2\|z - x_0\|^2 + t^2\|z - x_1\|^2 + 2t(1-t)\langle z - x_0, z - x_1 \rangle. \end{align*}\]

On the other hand,

\[\begin{align*} &(1-t)d^2(z, x_0) + t d^2(z, x_1) - t(1-t)d^2(x_0, x_1) \\ &= (1-t)\|z-x_0\|^2 + t\|z-x_1\|^2 - t(1-t)\|x_0 - x_1\|^2. \end{align*}\]

The difference is:

\[\begin{align*} &\bigl[(1-t) - (1-t)^2\bigr]\|z-x_0\|^2 + \bigl[t - t^2\bigr]\|z-x_1\|^2 \\ &\qquad - 2t(1-t)\langle z-x_0, z-x_1 \rangle - t(1-t)\|x_0-x_1\|^2 \\ &= t(1-t)\Bigl[\|z-x_0\|^2 + \|z-x_1\|^2 - 2\langle z-x_0, z-x_1 \rangle - \|x_0-x_1\|^2\Bigr]. \end{align*}\]

Now observe:

\[\begin{align*} \|z-x_0\|^2 + \|z-x_1\|^2 - 2\langle z-x_0, z-x_1 \rangle &= \|(z-x_0) - (z-x_1)\|^2 \\ &= \|x_1 - x_0\|^2 = \|x_0 - x_1\|^2. \end{align*}\]

Therefore the difference is \(t(1-t)[\|x_0-x_1\|^2 - \|x_0-x_1\|^2] = 0\), and we have:

\[d^2(z, x_t) = (1-t)d^2(z, x_0) + t d^2(z, x_1) - t(1-t)d^2(x_0, x_1).\]

The convexity inequality holds with equality in Euclidean space. This is indeed a disguised form of the parallelogram law: the “gap” \(t(1-t)d^2(x_0, x_1)\) exactly accounts for the curvature of the squared-distance function along the geodesic. In positively curved spaces, the gap is smaller; in negatively curved (Hadamard) spaces, the gap is larger, which is what drives the strong convexity used in the uniqueness proof.

Exercise 6: Comparison Triangle in Euclidean Space

Exercise: For three points in \(\mathbb{R}^2\) with the Euclidean metric, construct their comparison triangle. Show that \(d(x, p) = d_0(\bar{x}, \bar{p})\) — there is no distortion.

Solution:

Let \(x, y, z \in \mathbb{R}^2\) be three points forming a geodesic triangle \(\triangle(x, y, z)\). The comparison triangle \(\overline{\triangle}(\bar{x}, \bar{y}, \bar{z})\) in the model space \(\mathbb{M}_0^2 = \mathbb{R}^2\) is any triangle with the same side lengths:

\[d(\bar{x}, \bar{y}) = d(x, y), \quad d(\bar{y}, \bar{z}) = d(y, z), \quad d(\bar{z}, \bar{x}) = d(z, x).\]

Since both the original triangle and the comparison triangle lie in \(\mathbb{R}^2\) and have identical side lengths, they are congruent — there exists a rigid motion (translation + rotation + possibly reflection) mapping one to the other. Without loss of generality, we may take \(\bar{x} = x\), \(\bar{y} = y\), \(\bar{z} = z\).

Now let \(p\) be a point on the geodesic from \(y\) to \(z\), say \(p = (1-s)y + s z\) for some \(s \in [0,1]\). Its comparison point \(\bar{p}\) on the side \(\bar{y}\bar{z}\) is \(\bar{p} = (1-s)\bar{y} + s\bar{z} = (1-s)y + s z = p\).

Therefore \(d(x, p) = \|\bar{x} - \bar{p}\| = d_0(\bar{x}, \bar{p})\), and the \(\mathrm{CAT}(0)\) inequality

\[d(x, p) \le d_0(\bar{x}, \bar{p})\]

holds with equality. There is no distortion because Euclidean space is itself the model space for \(\kappa = 0\).

This is the defining property of \(\mathrm{CAT}(0)\) spaces: triangles are “at least as thin” as their Euclidean comparison triangles. Euclidean space itself saturates this bound exactly, while negatively curved spaces have strictly thinner triangles (\(d(x, p) < d_0(\bar{x}, \bar{p})\)), and positively curved spaces violate the inequality.

Exercise: Frechet Mean = Usual Mean in \(\mathbb{R}^p\)

Exercise: Show that when \(\mathcal{M} = \mathbb{R}^p\) with the Euclidean distance, the Frechet mean of a random vector \(X\) is exactly the usual mean \(\mathbb{E}X\).

Solution:

Let \(X\) be a random vector in \(\mathbb{R}^p\) with \(\mathbb{E}\|X\|^2 < \infty\), and let \(\mu = \mathbb{E}X\) denote the usual mean. The Frechet function is

\[ F(x) = \mathbb{E}\|X - x\|_2^2. \]

We expand the squared norm by adding and subtracting \(\mu\):

\[\begin{align*} F(x) &= \mathbb{E}\|(X - \mu) + (\mu - x)\|_2^2 \\ &= \mathbb{E}\Bigl[\|X - \mu\|_2^2 + 2\langle X - \mu,\, \mu - x \rangle + \|\mu - x\|_2^2\Bigr] \\ &= \mathbb{E}\|X - \mu\|_2^2 + 2\langle \mathbb{E}[X - \mu],\, \mu - x \rangle + \|\mu - x\|_2^2 \\ &= \mathbb{E}\|X - \mu\|_2^2 + 2\langle 0,\, \mu - x \rangle + \|\mu - x\|_2^2 \\ &= \mathbb{E}\|X - \mu\|_2^2 + \|\mu - x\|_2^2. \end{align*}\]

The first term \(\mathbb{E}\|X - \mu\|_2^2\) is constant (it does not depend on \(x\)). The second term \(\|\mu - x\|_2^2\) is nonnegative and equals zero if and only if \(x = \mu\). Therefore,

\[ F(x) \ge F(\mu) \quad \text{for all } x \in \mathbb{R}^p, \]

with equality only at \(x = \mu\). Hence \(\mu = \mathbb{E}X\) is the unique global minimizer of \(F(x)\), i.e., the unique Frechet mean.

This calculation confirms that the Frechet mean on \(\mathbb{R}^p\) with the Euclidean metric recovers the ordinary expectation. The proof also reveals why the squared Euclidean distance is essential: it makes the cross term vanish exactly when \(\mathbb{E}[X - \mu] = 0\), which is the defining property of the mean.

9 Further Reading

  • Fréchet (1948) — The original paper introducing the Fréchet mean.
  • Sturm (2003) — A foundational treatment of probability measures on \(\mathrm{CAT}(0)\) spaces, including the uniqueness result.
  • Bhattacharya and Patrangenaru (2003) — First systematic study of intrinsic means on Riemannian manifolds.
  • Grove and Karcher (1973); Karcher (1977) — Classical work on the Riemannian center of mass.
  • Billera et al. (2001) — The original BHV tree space construction (a key Hadamard space example).
  • Pennec et al. (2006) — Riemannian geometry for SPD matrices with medical imaging applications.

10 Self-Assessment Quiz

Test your understanding of this lecture with the interactive MCQ quiz:

👉 Lecture 2 Quiz — 10 Multiple-Choice Questions

References

Arsigny, V., P. Fillard, X. Pennec, and N. Ayache. 2006. “Log-Euclidean Metrics for Fast and Simple Calculus on Diffusion Tensors.” Magnetic Resonance in Medicine 56 (2): 411–21.
Bhattacharya, Rabi, and Vic Patrangenaru. 2003. “Large Sample Theory of Intrinsic and Extrinsic Sample Means on Manifolds. I.” The Annals of Statistics 31 (1): 1–29. https://doi.org/10.1214/aos/1046294456.
Billera, Louis J., Susan P. Holmes, and Karen Vogtmann. 2001. “Geometry of the Space of Phylogenetic Trees.” Advances in Applied Mathematics 27 (4): 733–67.
Fréchet, Maurice. 1948. “Les éléments Aléatoires de Nature Quelconque Dans Un Espace Distancié.” Annales de l’Institut Henri Poincaré 10 (4): 215–310.
Grove, Karsten, and Hermann Karcher. 1973. “How to Conjugate \(C^1\)-Close Group Actions.” Mathematische Zeitschrift 132 (1): 11–20. https://doi.org/10.1007/BF01214029.
Karcher, Hermann. 1977. “Riemannian Center of Mass and Mollifier Smoothing.” Communications on Pure and Applied Mathematics 30 (5): 509–41. https://doi.org/10.1002/cpa.3160300502.
Karcher, Hermann. 2014. Riemannian Center of Mass and so-Called Karcher Mean. https://arxiv.org/abs/1407.2087.
Kloeckner, Benoît R. 2010. “A Geometric Study of Wasserstein Spaces: Euclidean Spaces.” Annali Della Scuola Normale Superiore Di Pisa. Classe Di Scienze 9 (2): 297–323. https://doi.org/10.2422/2036-2145.2010.2.03.
Lott, John. 2008. “Some Geometric Calculations on Wasserstein Space.” Communications in Mathematical Physics 277 (2): 423–37. https://doi.org/10.1007/s00220-007-0367-3.
Moakher, M. 2005. “A Differential Geometric Approach to the Geometric Mean of Symmetric Positive-Definite Matrices.” SIAM Journal on Matrix Analysis and Applications 26 (3): 735–47. https://doi.org/10.1137/S0895479803436937.
Otto, Felix. 2001. “The Geometry of Dissipative Evolution Equations: The Porous Medium Equation.” Communications in Partial Differential Equations 26 (1–2): 101–74. https://doi.org/10.1081/PDE-100002243.
Panaretos, Victor M., and Yoav Zemel. 2020. An Invitation to Statistics in Wasserstein Space. SpringerBriefs in Probability and Mathematical Statistics. Springer. https://doi.org/10.1007/978-3-030-38438-8.
Pennec, X., P. Fillard, and N. Ayache. 2006. “A Riemannian Framework for Tensor Computing.” International Journal of Computer Vision 66 (1): 41–66. https://doi.org/10.1007/s11263-005-3222-z.
Sturm, Karl-Theodor. 2003. “Probability Measures on Metric Spaces of Nonpositive Curvature.” In Heat Kernels and Analysis on Manifolds, Graphs, and Metric Spaces, vol. 338. Contemporary Mathematics. American Mathematical Society. https://doi.org/10.1090/conm/338/06080.