The matrix trace of an square matrix
over a commutative ring
is defined to be
|
(1)
|
i.e., the sum of the diagonal elements. The matrix trace is implemented in the Wolfram Language as Tr[list].
For square matrices and
of the same size and a scalar
in the coefficient ring, it is
true that
|
(2)
| |||
|
(3)
| |||
|
(4)
|
(Lang 1987, p. 40), where denotes the transpose. The
trace is also invariant under a similarity
transformation
|
(5)
|
(Lang 1987, p. 64), where is an invertible matrix.
Since
|
(6)
|
(where Einstein summation is used here to sum over repeated indices), it follows that
|
(7)
| |||
|
(8)
| |||
|
(9)
| |||
|
(10)
| |||
|
(11)
|
where
is the Kronecker delta.
The trace of a product of two square matrices of the same size is independent of the order of multiplication since
|
(12)
| |||
|
(13)
| |||
|
(14)
| |||
|
(15)
| |||
|
(16)
|
(again using Einstein summation). Therefore, the trace of the commutator of and
is given by
|
(17)
|
For three or more square matrices of the same size, a similar argument gives invariance under cyclic permutations of the factors. Arbitrary permutations need not preserve the trace.
Over
or
, the product of a symmetric
matrix
and an antisymmetric matrix
of the same size has zero trace,
|
(18)
|
The trace of a rotation matrix representing a rotation through angle
can be found by choosing a coordinate
system in which the z-axis lies along the axis
of rotation. In this coordinate system, the matrix is
|
(19)
|
so the trace is
|
(20)
|
where
is interpreted as Einstein summation notation.
In group theory, the group character of a finite-dimensional group representation is the function that assigns to each group element the trace of its matrix under the representation.