# Create correlated random variables from uncorrelated variables [duplicate]

Say there are $$n$$ mean-zero random normal variables $$\varepsilon_i,...,\varepsilon_n$$ with a $$n \times n$$ covariance matrix $$\Sigma$$.

I have $$n$$ mean-zero random normal variables $$u_i, ...,u_n$$ which are independent from one-another but may have different variances $$\sigma_i^2$$ (i.e. the covariance matrix $$\Sigma_u$$ is diagonal).

Is it possible to write every $$\varepsilon_i$$ as a sum of the variables $$u_1,...,u_n$$ in such a way that the covariance matrix is $$\Sigma$$?

(Another way of phrasing the question is: can I construct a set of $$n$$ arbitrarily correlated random normal variables by summing $$n$$ independent random normal variables?)

• Yes. Good search terms include "QR" and "Cholesky." One definition of the multivariate Normal distribution is that it arises as an affine transformation of independent standard Normal variables. This site search for "create correlated normal" turns up many solutions.
– whuber
Mar 4, 2022 at 16:02