Trace - Maple Help

# Online Help

###### All Products    Maple    MapleSim

Student[LinearAlgebra]

 Trace
 compute the trace of a square Matrix

 Calling Sequence Trace(A)

Parameters

 A - square Matrix

Description

 • The Trace(A) command computes the sum of the diagonal elements of Matrix A.

Examples

 > $\mathrm{with}\left(\mathrm{Student}\left[\mathrm{LinearAlgebra}\right]\right):$
 > $A≔⟨⟨a,b,c⟩|⟨d,e,f⟩|⟨g,h,i⟩⟩$
 ${A}{≔}\left[\begin{array}{ccc}{a}& {d}& {g}\\ {b}& {e}& {h}\\ {c}& {f}& {i}\end{array}\right]$ (1)
 > $\mathrm{Trace}\left(A\right)$
 ${a}{+}{e}{+}{i}$ (2)

 See Also