# Interleaving distance

In topological data analysis, the interleaving distance is a measure of similarity between persistence modules, a common object of study in topological data analysis and persistent homology. The interleaving distance was first introduced by Frédéric Chazal et al. in 2009. since then, it and its generalizations have been a central consideration in the study of applied algebraic topology and topological data analysis.

## Definition

A persistence module $\mathbb {V}$ is a collection $(V_{t}\mid t\in \mathbb {R} )$ of vector spaces indexed over the real line, along with a collection $(v_{t}^{s}:V_{s}\to V_{t}\mid s\leq t)$ of linear maps such that $v_{t}^{t}$ is always an isomorphism, and the relation $v_{t}^{s}\circ v_{s}^{r}=v_{t}^{r}$ is satisfied for every $r\leq s\leq t$. The case of $\mathbb {R}$ indexing is presented here for simplicity, though the interleaving distance can be readily adapted to more general settings, including multi-dimensional persistence modules.
Let $\mathbb {U}$ and $\mathbb {V}$ be persistence modules. Then for any $\delta \in \mathbb {R}$, a $\delta$-shift is a collection $(\phi _{t}:U_{t}\to V_{t+\delta }\mid t\in \mathbb {R} )$ of linear maps between the persistence modules that commute with the internal maps of $\mathbb {U}$ and $\mathbb {V}$.
The persistence modules $\mathbb {U}$ and $\mathbb {V}$ are said to be $\delta$-interleaved if there are $\delta$-shifts $\phi _{t}:U_{t}\to V_{t+\delta }$ and $\psi _{t}:V_{t}\to U_{t+\delta }$ such that the following diagrams commute for all $s\leq t$.
It follows from the definition that if $\mathbb {U}$ and $\mathbb {V}$ are $\delta$-interleaved for some $\delta$, then they are also $(\delta +\varepsilon )$-interleaved for any positive $\varepsilon$. Therefore, in order to find the closest interleaving between the two modules, we must take the infimum across all possible interleavings.
The interleaving distance between two persistence modules $\mathbb {U}$ and $\mathbb {V}$ is defined as $d_{I}(\mathbb {U} ,\mathbb {V} )=\inf\{\delta \mid \mathbb {U} {\text{ and }}\mathbb {V} {\text{ are }}\delta {\text{-interleaved}}\}$.

## Properties
### Metric properties

It can be shown that the interleaving distance satisfies the triangle inequality. Namely, given three persistence modules $\mathbb {U}$, $\mathbb {V}$, and $\mathbb {W}$, the inequality $d_{I}(\mathbb {U} ,\mathbb {W} )\leq d_{I}(\mathbb {U} ,\mathbb {V} )+d_{I}(\mathbb {V} ,\mathbb {W} )$ is satisfied.
On the other hand, there are examples of persistence modules that are not isomorphic but that have interleaving distance zero. Furthermore, if no suitable $\delta$ exists then two persistence modules are said to have infinite interleaving distance. These two properties make the interleaving distance an extended pseudometric, which means non-identical objects are allowed to have distance zero, and objects are allowed to have infinite distance, but the other properties of a proper metric are satisfied.
Further metric properties of the interleaving distance and its variants were investigated by Luis Scoccola in 2020.

### Computational complexity

Computing the interleaving distance between two single-parameter persistence modules can be accomplished in polynomial time. On the other hand, it was shown in 2018 that computing the interleaving distance between two multi-dimensional persistence modules is NP-hard.