Convex Optimization · Problem 2.36

Convex functions — Boyd & Vandenberghe

Mathematics — Optimization · euclidean-distance-matrices

Problem

Euclidean distance matrices. Let x1,…,xn∈Rkx_1, \ldots, x_n \in \mathbf{R}^k. The matrix D∈SnD \in \mathbf{S}^n defined by Dij=∥xi−xj∥22D_{ij} = \|x_i - x_j\|_2^2 is called a Euclidean distance matrix. It satisfies some obvious properties such as Dij=DjiD_{ij} = D_{ji}, Dii=0D_{ii} = 0, Dij≥0D_{ij} \geq 0, and (from the triangle inequality) Dik1/2≤Dij1/2+Djk1/2D_{ik}^{1/2} \leq D_{ij}^{1/2} + D_{jk}^{1/2}. We now pose the question: When is a matrix D∈SnD \in \mathbf{S}^n a Euclidean distance matrix (for some points in Rk\mathbf{R}^k, for some kk)? A famous result answers this question: D∈SnD \in \mathbf{S}^n is a Euclidean distance matrix if and only if Dii=0D_{ii} = 0 and xTDx≤0x^T D x \leq 0 for all xx with 1Tx=0\mathbf{1}^T x = 0. (See §8.3.3.) Show that the set of Euclidean distance matrices is a convex cone.
Intuitive explanation

A Euclidean distance matrix is defined by a simple algebraic constraint: Dii=0D_{ii} = 0 and xTDx≤0x^T D x \leq 0 for all centered vectors xx. To show this set forms a convex cone, you need to verify two closure properties: that non-negative scalar multiples of any EDM stay in the set, and that sums of any two EDMs remain EDMs. Both properties follow directly from the linearity of the constraints—scaling and adding preserve the zero diagonal and the inequality condition for all centered vectors.

Intuitive explanation

A Euclidean distance matrix is defined by a simple algebraic constraint: Dii=0D_{ii} = 0 and xTDx≤0x^T D x \leq 0 for all centered vectors xx. To show this set forms a convex cone, you need to verify two closure properties: that non-negative scalar multiples of any EDM stay in the set, and that sums of any two EDMs remain EDMs. Both properties follow directly from the linearity of the constraints—scaling and adding preserve the zero diagonal and the inequality condition for all centered vectors.

Related theory

Browse the problem library