In linear algebra, the trace of a square matrix A, denoted tr(A), is defined as a sum of the elements on its main diagonal, a 11 + a 22 + ⋯ + a n n {\displaystyle a_{11}+a_{22}+\dots +a_{nn}} . It is only defined for a square matrix (n × n). It can be shown that the trace of a matrix is equal to the sum of its eigenvalues (counted with algebraic multiplicities), see below. Also, tr(AB) = tr(BA) for any matrices A and B of the same size. Thus, similar matrices have the same trace. As a consequence, one can define the trace of a linear operator mapping a finite-dimensional vector space into itself, since all matrices describing such an operator with respect to a basis are similar. The trace is related to the derivative of the determinant (see Jacobi's formula).
Definition The trace of an n × n square matrix A is defined as
tr ( A ) = ∑ i = 1 n a i i = a 11 + a 22 + ⋯ + a n n {\displaystyle \operatorname {tr} (\mathbf {A} )=\sum _{i=1}^{n}a_{ii}=a_{11}+a_{22}+\dots +a_{nn}}
where aii denotes the entry on the i th row and i th column of A. The entries of A can be real numbers, complex numbers, or more generally elements of a field F. The trace is not defined for non-square matrices.
Example Let A be a matrix, with
A = ( a 11 a 12 a 13 a 21 a 22 a 23 a 31 a 32 a 33 ) = ( 1 0 3 11 5 2 6 12 − 5 ) {\displaystyle \mathbf {A} ={\begin{pmatrix}a_{11}&a_{12}&a_{13}\\a_{21}&a_{22}&a_{23}\\a_{31}&a_{32}&a_{33}\end{pmatrix}}={\begin{pmatrix}1&0&3\\11&5&2\\6&12&-5\end{pmatrix}}}
Then
tr ( A ) = ∑ i = 1 3 a i i = a 11 + a 22 + a 33 = 1 + 5 + ( − 5 ) = 1. {\displaystyle \operatorname {tr} (\mathbf {A} )=\sum _{i=1}^{3}a_{ii}=a_{11}+a_{22}+a_{33}=1+5+(-5)=1.}
Properties
Basic properties The trace is a linear mapping. That is,
… excerpt ends here. Continue reading the full article.
