# How to write function series in Mathematica?

How do I write the function given below as a mathematical function:

$$\Sigma^{8}_{i=1}\Sigma^{8}_{j=1}c_{ij}\lambda_i \otimes\lambda_j$$

I have the values of $$\lambda_i$$ and $$\lambda_j$$.They are 3x3 matrices.

• why are you using cross product between two matrices? Commented Nov 4, 2023 at 11:33

I am assuming $$\otimes$$ means normal matrix multiplication. In that case

n=8;
mat=Table[ResourceFunction["RandomMatrix"][Integer,{0,10},{3,3}],{n}];
sum=Sum[Sum[c[i,j]* (mat[[i]].mat[[j]]),{j,1,n}],{i,1,n}];


If normal matrix product is not what you meant, then try instead tensor product

Sum[Sum[c[i, j]*KroneckerProduct[mat[[i]], mat[[j]]], {j, 1, n}],{i, 1, 8}];


Or may be you meant

Sum[Sum[c[i,j]* TensorProduct[mat[[i]],mat[[j]]],{j,1,n}],{i,1,8}];


You can try them and see which one is what you had in mind.

You really should make it clear what $$\otimes$$ means here.

• $\otimes$ means tensor product between matrices Commented Nov 6, 2023 at 6:14