# Matérn covariance function

In statistics, the Matérn covariance (named after the Swedish forestry statistician Bertil Matérn[1]) is a covariance function used in spatial statistics, geostatistics, machine learning, image analysis, and other applications of multivariate statistical analysis on metric spaces. It is commonly used to define the statistical covariance between measurements made at two points that are d units distant from each other. Since the covariance only depends on distances between points, it is stationary. If the distance is Euclidean distance, the Matérn covariance is also isotropic.

## DefinitionEdit

The Matérn covariance between two points separated by d distance units is given by [2]

${\displaystyle C_{\nu }(d)=\sigma ^{2}{\frac {2^{1-\nu }}{\Gamma (\nu )}}{\Bigg (}{\sqrt {2\nu }}{\frac {d}{\rho }}{\Bigg )}^{\nu }K_{\nu }{\Bigg (}{\sqrt {2\nu }}{\frac {d}{\rho }}{\Bigg )}}$ ,

where ${\displaystyle \Gamma }$  is the gamma function, ${\displaystyle K_{\nu }}$  is the modified Bessel function of the second kind, and ρ and ν are non-negative parameters of the covariance.

A Gaussian process with Matérn covariance has sample paths that are ${\displaystyle \lceil \nu \rceil }$  -1 times differentiable.[3]

## Simplification for specific values of νEdit

### Simplification for ν half integerEdit

When ${\displaystyle \nu =p+1/2,\ p\in \mathbb {N} ^{+}}$  , the Matérn covariance can be written as a product of an exponential and a polynomial of order ${\displaystyle p}$ :[4]

${\displaystyle C_{p+1/2}(d)=\sigma ^{2}\exp \left(-{\frac {{\sqrt {2\nu }}d}{\rho }}\right){\frac {\Gamma (p+1)}{\Gamma (2p+1)}}\sum _{i=0}^{p}{\frac {(p+i)!}{i!(p-i)!}}\left({\frac {{\sqrt {8\nu }}d}{\rho }}\right)^{p-i},}$

which gives:

• for ${\displaystyle \nu =1/2\ (p=0)}$ : ${\displaystyle C_{1/2}(d)=\sigma ^{2}\exp \left(-{\frac {d}{\rho }}\right)}$ ,
• for ${\displaystyle \nu =3/2\ (p=1)}$ : ${\displaystyle C_{3/2}(d)=\sigma ^{2}\left(1+{\frac {{\sqrt {3}}d}{\rho }}\right)\exp \left(-{\frac {{\sqrt {3}}d}{\rho }}\right)}$ ,
• for ${\displaystyle \nu =5/2\ (p=2)}$ : ${\displaystyle C_{5/2}(d)=\sigma ^{2}\left(1+{\frac {{\sqrt {5}}d}{\rho }}+{\frac {5d^{2}}{3\rho ^{2}}}\right)\exp \left(-{\frac {{\sqrt {5}}d}{\rho }}\right)}$ .

### The Gaussian case in the limit of infinite νEdit

As ${\displaystyle \nu \rightarrow \infty }$ , the Matérn covariance converges to the squared exponential covariance function

${\displaystyle \lim _{\nu \rightarrow \infty }C_{\nu }(d)=\sigma ^{2}\exp \left(-{\frac {d^{2}}{2\rho ^{2}}}\right)}$ .

## Taylor series at zero and spectral momentsEdit

The behavior for ${\displaystyle d\rightarrow 0}$  can be obtained by the following Taylor series:

${\displaystyle C_{\nu }(d)=\sigma ^{2}\left(1+{\frac {\nu }{2(1-\nu )}}\left({\frac {d}{\rho }}\right)^{2}+{\frac {\nu ^{2}}{8(2-3\nu +\nu ^{2})}}\left({\frac {d}{\rho }}\right)^{4}+{\mathcal {O}}\left(d^{5}\right)\right).}$

When defined, the following spectral moments can be derived from the Taylor series:

• ${\displaystyle \lambda _{0}=C_{\nu }(0)=\sigma ^{2}}$ ,
• ${\displaystyle \lambda _{2}=-\left.{\frac {\partial ^{2}C_{\nu }(d)}{\partial d^{2}}}\right|_{d=0}={\frac {\sigma ^{2}\nu }{\rho ^{2}(\nu -1)}}}$ .