Proof: Expected value of the trace of a matrix
Index:
The Book of Statistical Proofs ▷
General Theorems ▷
Probability theory ▷
Expected value ▷
Expectation of a trace
Metadata: ID: P298 | shortcut: mean-tr | author: JoramSoch | date: 2021-12-07, 09:03.
Theorem: Let $A$ be an $n \times n$ random matrix. Then, the expectation of the trace of $A$ is equal to the trace of the expectation of $A$:
\[\label{eq:mean-tr} \mathrm{E}\left[ \mathrm{tr}(A) \right] = \mathrm{tr}\left( \mathrm{E}[A] \right) \; .\]Proof: The trace of an $n \times n$ matrix $A$ is defined as:
\[\label{eq:tr} \mathrm{tr}(A) = \sum_{i=1}^{n} a_{ii} \; .\]Using this definition of the trace, the linearity of the expected value and the expected value of a random matrix, we have:
\[\label{eq:mean-tr-qed} \begin{split} \mathrm{E}\left[ \mathrm{tr}(A) \right] &= \mathrm{E}\left[ \sum_{i=1}^{n} a_{ii} \right] \\ &= \sum_{i=1}^{n} \mathrm{E}\left[ a_{ii} \right] \\ &= \mathrm{tr}\left( \left[ \begin{matrix} \mathrm{E}[a_{11}] & \ldots & \mathrm{E}[a_{1n}] \\ \vdots & \ddots & \vdots \\ \mathrm{E}[a_{n1}] & \ldots & \mathrm{E}[a_{nn}] \end{matrix} \right] \right) \\ &= \mathrm{tr}\left( \mathrm{E}[A] \right) \; . \end{split}\]∎
Sources: - drerD (2018): "'Trace trick' for expectations of quadratic forms"; in: StackExchange Mathematics, retrieved on 2021-12-07; URL: https://math.stackexchange.com/a/3004034/480910.
Metadata: ID: P298 | shortcut: mean-tr | author: JoramSoch | date: 2021-12-07, 09:03.