My aim is to fit functions to covariance matrices. Furthermore I would like to have these functions positive definite.

For example the figure below shows a fitted covariance matrix modeled using a Gaussian function centered at point [4,4] with a given SD. This is excellent because this matrix is positive definite, thus I can factor it with Cholesky decomposition for finding the best fit to the observed data (not shown).

I also have observations which exhibits circular similarity. Below is an example of observed 8x8 covariance matrix. Here the circularity of similarity between the 8 different dataset can be appreciated by high covariance along the off-diagonals, as well as high covariance between first vs. 8th datasets (right upper corner).

Covariance showing circular similarity

My question is what function can I use to model this kind of similarity structure, which also ensures positive definiteness?

  • 1
    $\begingroup$ It would be nice for you to describe and explain your pictures of matrices. In what way the 1st is "centered" and the 2nd is "circular" statistically? $\endgroup$
    – ttnphns
    Jul 17, 2015 at 21:36
  • 1
    $\begingroup$ For insight, note that a perfectly "circular symmetric" matrix will be a circulant. Since it is symmetric, it will have real eigenvalues, but the need for them to be nonnegative imposes definite (relatively simple) restrictions on the matrix entries. I suspect this might be where you're trying to go, but it's not clear what you mean by using a "function" to "model this kind of similarity structure." Could you elaborate on what you mean by that? $\endgroup$
    – whuber
    Jul 17, 2015 at 21:40
  • $\begingroup$ @bonobo How about $\sum_{k=-\infty}^{\infty} \exp(\frac{-(i-j - k*N)^2}{2\sigma^2})$? For practical reasons only $k\in\{-1,0,1\}$ should suffice. $\endgroup$ Jul 17, 2015 at 21:58
  • $\begingroup$ The first matrix was generated using a simple Gaussian function fixed at point [4 4] (where the peak of Gaussian is located) and an arbitrary sigma (same for x and y dimensions). The covariance matrices of some data I am working currently looks exactly like this, therefore I would like to model these data with Gaussians and figure out different parameters that best describe them. The positive definiteness is broken with very tiny deviations from these restrictions you mention, so I guess that is the reason why some of the modeled covariance matrices fail in the Cholesky decomposition. $\endgroup$
    – bonobo
    Jul 17, 2015 at 22:01
  • 2
    $\begingroup$ I can confirm that the problem was due to numerical precision. Many matrices that seems to fulfill positive definiteness restrictions still result in very small negative eigenvalues, which breaks the Cholesky decomposition. One needs to zero these beforehand. $\endgroup$
    – bonobo
    Jul 17, 2015 at 22:44


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.