Search for a tool
Trace of a Matrix

Tool to compute the trace of a matrix. The trace of a square matrix M is the sum of its main diagonal denoted Tr(M).

Results

Trace of a Matrix -

Tag(s) : Mathematics, Algebra, Symbolic Computation

dCode and you

dCode is free and its tools are a valuable help in games, puzzles and problems to solve every day!
You have a problem, an idea for a project, a specific need and dCode can not (yet) help you? You need custom development? Contact-me!


Team dCode read all messages and answer them if you leave an email (not published). It is thanks to you that dCode has the best Trace of a Matrix tool. Thank you.

This page is using the new English version of dCode, please make comments !

Trace of a Matrix

Sponsored ads

Square Matrix Trace Calculator NxN

Rectangular Matrix Trace Calculator NxM

Tool to compute the trace of a matrix. The trace of a square matrix M is the sum of its main diagonal denoted Tr(M).

Answers to Questions

How to calculate a matrix trace?

To calculate the trace of a square matrix \( M \) of size \( n \), you make the sum of diagonal values:

$$ \mathrm{Tr}(M) = \sum_{i=1}^{n} a_{i \, i} $$

For a 2x2 matrix : $$ M = \begin{bmatrix} a & b \\ c & d \end{bmatrix} \\ \mathrm{Tr}(M) = a+d $$

$$ M = \begin{bmatrix} 1 & 2 \\ 3 & 4 \end{bmatrix} \\ \mathrm{Tr}(M) = 1+4 = 5 $$

For a 3x3 matrix : $$ M = \begin{bmatrix} a & b & c \\d & e & f \\ g & h & i \end{bmatrix} \\ \mathrm{Tr}(M) = a+e+i $$

For rectangular matrix, the diagonal used is the one of the included square matrix (from top left corner).

$$ M = \begin{bmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{bmatrix} \Rightarrow \mathrm{Tr}(M) = \mathrm{Tr} \begin{bmatrix} 1 & 2 \\ 4 & 5 \end{bmatrix} $$

What are trace mathematical properties?

Trace follows the following properties:

The trace of an identity matrix \( I_n \) of size \( n \) equals \( n \).

$$ \mathrm{Tr}(I_n) = n $$

For A and B of the same order (that can be added):

$$ \mathrm{Tr}(A + B) = \mathrm{Tr}(A) + \mathrm{Tr}(B) $$

For a given scalar c:

$$ \mathrm{Tr}(c A) = c \mathrm{Tr}(A) $$

For \( A^T \) the transposed matrixhref of A:

$$ \mathrm{Tr}(A^T) = \mathrm{Tr}(A) $$

Ask a new question

Source code

dCode retains ownership of the source code of the script Trace of a Matrix. Except explicit open source licence (indicated Creative Commons / free), any algorithm, applet, snippet, software (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, translator), or any function (convert, solve, decrypt, encrypt, decipher, cipher, decode, code, translate) written in any informatic langauge (PHP, Java, C#, Python, Javascript, etc.) which dCode owns rights can be transferred after sales quote. So if you need to download the Trace of a Matrix script for offline use, for you, your company or association, see you on contact page !

Questions / Comments


Team dCode read all messages and answer them if you leave an email (not published). It is thanks to you that dCode has the best Trace of a Matrix tool. Thank you.


Source : http://www.dcode.fr/matrix-trace
© 2017 dCode — The ultimate 'toolkit' to solve every games / riddles / geocaches. dCode