R: Compute multiplication efficiently
If I have a matrix A (5000-by-6000), which means it has n rows and m columns, it a_ij
is an element. I would like to calculate sum (k=1..m, l=1..m) (a[i,l]*a[j,k])
(ie this formula ) that is 5000 by 5000. What is the efficient way to calculate such a formula?
Thanks in advance.
+3
source to share