I would like the number $a$ to be taken out:

$Assumptions = (a) \[Element] Complexes && (X) \[Element] 
    Matrices[{n, n}];

(a X).(a IdentityMatrix[n]) // FullSimplify 

Is there a way to make this product to yield $a^2 X$ instead of (X a).(a IdentityMatrix[n])? And to simplify the IdentityMatrix[n] as well?

P.S. Mathematica 10.


1 Answer 1


Use TensorExpand[] instead:

Assuming[a ∈ Complexes && X ∈ Matrices[{n, n}], 
         TensorExpand[(a X).(a IdentityMatrix[n])]]
   a^2 X

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.