import sympy as spp = sp.symbols('p')I_p = sp.Identity(p)C = sp.BlockMatrix([[I_p, I_p], [I_p, -I_p]])Sigma_1 = sp.MatrixSymbol('Sigma_1', p, p)Sigma_2 = sp.MatrixSymbol('Sigma_2', p, p)Sigma = sp.BlockMatrix([[Sigma_1, Sigma_2], [Sigma_2, Sigma_1]])C_Sigma_C_transpose = C * Sigma * C.Tprint(C_Sigma_C_transpose)## Matrix([## [I, I],## [I, -I]])*Matrix([## [Sigma_1, Sigma_2],## [Sigma_2, Sigma_1]])*Matrix([## [I, I],## [I, -I]])
The result does not match the expected output. How can we correct it?