prepare_cov#

anri.fwd.prepare_cov(cov)[source]#

Get inverse covariance matrix and normalisation constant for sample_intensities().

Parameters:

cov (Array) – [3,3] or [3,4] output covariance matrix from anri.fwd.propagate_cov_box() or anri.fwd.propagate_cov_scan()

Returns:

Notes

From Wikipedia [1]:

For a \(N\)-dimensional normal distribution, the probability density of an observation \(\vec{x}\) can be determined:

\[\Pr[{\vec{x}}]\,d{\vec{x}} = \frac{1}{\sqrt{\det{2\pi\matr{\Sigma}}}}\exp{\left(-\frac{d_{M}\left(\vec{x},\vec{y},Q\right)^2}{2}\right)}\]

References