Is there a map that maps the mean vector and the variance matrix of a multivariate lognormal to its location vector and diffusion matrix?

39 Views Asked by At

Suppose ${\xi} \sim logNormal_d ({\mu},{\Sigma})$, where $\mu$ is a d-dimensional vector (called location vector) and $\Sigma$ is a $d \times d$ symmetric positive definite matrix (called diffusion matrix). Then $$m=E(\xi)=e^{\mu + \frac{1}{2} diag(\Sigma)}$$ where $diag(\Sigma) = [\sigma_{1,1},\sigma_{2,2},\ldots,\sigma_{d,d}]'$ and $Var(\xi) = V$ with elements $$v_{i,j} = e^{\mu_1 + \mu_2 +\frac{\sigma_{i,i}+\sigma{j,j}}{2}}\left(e^{\sigma_{i,j}}-1\right).$$

The transformation $(m,V)\mapsto(\mu,\Sigma)$ is defined by the equations: $$\begin{aligned} \mu= & \log \left( m\oslash\sqrt{1+diag(V)\oslash(m\odot m})\right) \\ \Sigma = & \log \left(1+V\oslash\left( m\cdot m'\right) \right), \end{aligned} $$ where $\odot$ is the element-by-element product and $\oslash$ is the element-by-element division.

I am quite sure of the correctness of this transformation but the simple Matlab code I wrote to implement it, when using a general SPD matrix V as input, returns a $\Sigma$ matrix that is symmetric but not not PD. Is this due to some "computational" error (e.g. rounding or something like that)? Or simply the transformation I found does not guarantee positive-definitness of the $\Sigma$ matrix?

Does anybody know something about a transormation $(m,V)\mapsto(\mu,\Sigma)$ (and maybe a matlab code to implement it...) that guarantees the positive definitness of the matrix $\Sigma$?

Thanks,

Nicola