---
title: Brownian Distance Covariance
url: https://www.emergentmind.com/topics/brownian-distance-covariance
type: topic
---

# Brownian Distance Covariance

Brownian distance covariance (BdCov, also called distance covariance or dCov) is a dependence measure for random vectors that generalizes classical covariance to quantify all types of dependence, including nonlinear and nonmonotone associations. Introduced by Székely and Rizzo, BdCov is defined via characteristic functions with a special weighting derived from Brownian motion, and is zero if and only if the random variables are independent. Its construction, based on pairwise Euclidean distances, is fundamentally nonparametric and applies to multivariate data of arbitrary dimension, with rigorous statistical properties and numerous extensions to metric, Hilbert, and functional spaces [1010.0297], [1010.0844], [1106.5758].

## 1. Formal Definition and Equivalent Forms

Let $X \in \mathbb{R}^p$, $Y \in \mathbb{R}^q$ be random vectors with joint characteristic function $\phi_{X,Y}(t, s) = E[e^{i (t^T X + s^T Y)}]$ and marginals $\phi_X(t) = E[e^{i t^T X}]$, $\phi_Y(s) = E[e^{i s^T Y}]$. The squared population Brownian distance covariance is [1010.0297], [2204.04567]:
\[
V^2(X, Y) = \frac{1}{c_p c_q} \int_{\mathbb{R}^p} \int_{\mathbb{R}^q} 
\frac{|\phi_{X,Y}(t, s) - \phi_X(t)\phi_Y(s)|^2}{|t|^{1+p} |s|^{1+q}} dt ds,
\]
where $c_d = \pi^{(1+d)/2} / \Gamma((1+d)/2)$. This construction reduces to the normed $L^2$-distance between the joint and product characteristic functions, weighted by a kernel corresponding to Brownian motion increments.

An equivalent form in terms of Euclidean distances is [1010.0297], [1106.5758]:
\[
V^2(X, Y) = E[|X-X'|\,|Y-Y'|] + E|X-X'|\,E|Y-Y'| - 2 E[|X-X'|]\,E[|Y-Y''|],
\]
where $(X', Y')$ and $(X'', Y'')$ are independent copies.

Sample (empirical) Brownian distance covariance for i.i.d. pairs $\{(X_i, Y_i)\}_{i=1}^n$ is computed by forming $n\times n$ distance matrices:
\[
a_{ij} = |X_i - X_j|, \quad b_{ij} = |Y_i - Y_j|,
\]
double-centering each:
\[
A_{ij} = a_{ij} - \bar{a}_{i\cdot} - \bar{a}_{\cdot j} + \bar{a}_{\cdot \cdot},
\]
and analogously for $B_{ij}$. The empirical squared distance covariance is then
\[
V_n^2(X, Y) = \frac{1}{n^2} \sum_{i,j=1}^n A_{ij}B_{ij}.
\]

The corresponding sample distance correlation is defined as
\[
R_n(X, Y) = \frac{V_n(X, Y)}{\sqrt{V_n(X, X)\,V_n(Y, Y)}},
\]
with $R_n = 0$ whenever the denominator vanishes [1010.0297].

## 2. Theoretical Properties

**Characterization of independence:** $V^2(X, Y) = 0$ if and only if $X$ and $Y$ are independent, under mild moment conditions (finite first moments) [1010.0297], [1106.5758]. This property holds in general metric spaces of strong negative type.

**Scale and orthogonal invariance:** $V^2(a_1 + b_1 C_1 X,\, a_2 + b_2 C_2 Y) = |b_1 b_2| V^2(X, Y)$ for scalars $b_1, b_2 \neq 0$ and orthonormal matrices $C_1$, $C_2$; $R_n$ is fully invariant under these transformations [1010.0297], [1010.0844].

**Non-negativity:** $V^2(X,Y) \ge 0$, equality holds if and only if independence.

**Asymptotics:** Under independence, $n V_n^2(X,Y)$ converges in distribution to a non-degenerate quadratic form $\sum \lambda_k Z_k^2$, with weights $\{\lambda_k\}$ depending on the underlying distributions [1010.0297], [1106.5758]. Under alternatives, $V_n^2 \xrightarrow{a.s.} V^2 > 0$ with $O_P(n^{-1/2})$ convergence rates.

**Bias and Unbiased Estimation:** The standard $V_n^2$ estimator is biased upward in small samples. Székely and Rizzo provided an unbiased estimator [1010.0844]:
\[
U_n(X, Y) = \frac{n^2}{(n-1)(n-2)} \left[V_n^2(X, Y) - \frac{T_2}{n-1}\right],
\]
where $T_2$ estimates the product of marginal distance means. The bias-corrected correlation $C_n$ uses $U_n$ in the same ratio as $R_n$.

## 3. Relation to Brownian Motion

The “Brownian” in Brownian distance covariance refers to a stochastic-process interpretation: $V^2(X, Y)$ can be viewed as the squared covariance between $W(X)$ and $W'(Y)$, where $W$ and $W'$ are independent Brownian motions with covariance kernels $E[W(t)W(s)] = |t| + |s| - |t-s|$ [1010.0297]. This viewpoint establishes that BdCov “sees” all deviations from independence, including nonmonotone nonlinearities, since Brownian motion has a full-rank expansion in function space [1010.0297].

## 4. Extensions Beyond Euclidean Data

Brownian distance covariance generalizes to any pair of metric spaces of strong negative type, such as separable Hilbert spaces, allowing its application to high-dimensional, functional, and even non-Euclidean data [1106.5758], [1010.0297]. For functional data, the method applies to projections or truncated expansions, and with categorical variables, the distance matrices become indicator matrices on the simplex, reducing the method to analogues of squared-deviation statistics for contingency tables.

The BdCov machinery extends naturally to weighting schemes and other norms ($A$,$B$) in the distance calculations, allowing emphasis on “signal” directions or downweighting noise, and leads to unbiasedness and consistency even in non-standard spaces [1010.0297].

## 5. Computational Aspects and Practical Considerations

Computation of the empirical statistic is $O(n^2(p+q))$ due to the pairwise distances, which can be limiting for large $n$. For univariate data, algorithms of $O(n \log n)$ exist, and for high-dimensional settings, dimensionality reduction (e.g., via PCA or random projections) is recommended [1206.6361]. The bias in finite $n$ especially affects small-sample, high-dimensional applications such as genomics and motivates use of the unbiased estimator [1010.0844], [1010.0825].

Permutation tests are recommended for independence hypotheses, leveraging the exchangeability of labels under the null. Principal components or clustering using the $p \times p$ distance correlation matrix may exhibit artifacts from small-sample bias; application of regularization or thresholding is advised [1010.0825].

## 6. Connections with Kernel, Energy, and Other Independence Measures

BdCov is closely related to energy distances and kernel-based dependence statistics. Its weighting kernel is related via Bochner’s theorem to reproducing kernel Hilbert space (RKHS) embeddings, and the Hilbert–Schmidt independence criterion (HSIC) is a special case with suitable kernel choice [1010.0836]. The form of BdCov enables extension to arbitrary domains (strings, graphs, groups) where a metric is available.

HSIC has some computational and power advantages, particularly at small sample sizes with well-chosen characteristic kernels. Both measures are consistent against all alternatives and have V-statistic-type estimators [1010.0836].

## 7. Applications and Recent Developments

Brownian distance covariance has been used in testing independence, model diagnostics, structure learning in Markov networks, and as a pooling layer in deep neural networks for few-shot classification [2204.04567], [1206.6361]. For instance, DeepBDC constructs a layer implementing the empirical BdCov matrix in high-dimensional embedding spaces, enabling plug-and-play nonparametric dependency measures in deep models [2204.04567].

Applied examples include detection of nonmonotone and nonlinear associations in genomics, ecological, and socio-economic data, with empirical demonstrations showing sensitivity to dependencies missed by linear correlation [1010.0297], [1010.0297].

Extensions under active research include adaptations to mutual independence among more than two variables, high-dimensional consistency, fast approximations, and relaxation of metric and moment conditions [1106.5758], [1010.0297].

---

**References:**  
- [1010.0297] G. J. Székely and M. L. Rizzo, "Brownian distance covariance," Ann. Appl. Statist. 3(4), 1236–1265 (2009).  
- [1010.0844] G. J. Székely and M. L. Rizzo, "Rejoinder: Brownian distance covariance."  
- [1010.0836] Gretton et al., "Discussion of: Brownian distance covariance."  
- [1010.0825] Leslie Cope, "Discussion of: Brownian distance covariance."  
- [1106.5758] R. Lyons, "Distance covariance in metric spaces."  
- [1206.6361] Y. Luo, "Learning Markov Network Structure using Brownian Distance Covariance."  
- [2204.04567] P. Hu et al., "Joint Distribution Matters: Deep Brownian Distance Covariance for Few-Shot Classification."

Source: https://www.emergentmind.com/topics/brownian-distance-covariance