A trace is the scalar associated to an n×nn\times n matrix A=(aij)A=(a_{ij}) over a field F\mathbb{F} defined by

tr⁡(A)=∑i=1naii.\operatorname{tr}(A)=\sum_{i=1}^n a_{ii}.

For a T:V→VT:V\to V on a finite-dimensional , the trace tr⁡(T)\operatorname{tr}(T) is defined as tr⁡(A)\operatorname{tr}(A) for any matrix AA representing TT in a basis; this is independent of the basis.

Remarks

Trace is often paired with the in matrix identities and appears in coefficients of the . When the characteristic polynomial splits, the trace equals the sum of the counted with algebraic multiplicity.

Examples
  • If AA is diagonal with diagonal entries d1,…,dnd_1,\dots,d_n, then tr⁡(A)=d1+⋯+dn\operatorname{tr}(A)=d_1+\cdots+d_n.
  • The identity matrix InI_n satisfies tr⁡(In)=n⋅1F\operatorname{tr}(I_n)=n\cdot 1_{\mathbb F}.
  • Any nilpotent matrix (some power equals 00) has trace 00.