I have the following formula to implement $$\Sigma_{ij} = \rho_{ij}\sigma_i\sigma_j$$ where no implicit summation is implied. I have both the $\sigma$ vector and the $\rho$ matrix and I want to calculate the $\Sigma$ matrix.
To be pedantic what i need is a way to find the elements of the matrix $\Sigma$ such that, take for example the element $(1,2)$, this is given by the normal multiplication $$\Sigma_{12} = \rho_{12}\sigma_1\sigma_2$$
Specifically the vector is a $1\times 10$ vector and the matrix is $10\times 10$. At the end I want another $10\times10$ matrix defined as before.
How can I do this?
matrix KroneckerProduct[vector, vector]
orvector matrix.DiagonalMatrix[SparseArray[vector]]
. $\endgroup$KroneckerProduct[vector, vector]
is a $10 \times 10$ matrix. $\endgroup$Flatten
:matrix KroneckerProduct[Flatten[vector], Flatten[vector]]
. $\endgroup$