<s>[INST] Exponentiation of a symmetric $2 \times 2$ matrix Why does the following hold?
$$\left[\begin{matrix}a & b\\b & a\end{matrix}\right]^k=\frac{1}{2}\left[\begin{matrix}\left(a - b\right)^{k} + \left(a + b\right)^{k} & - \left(a - b\right)^{k} + \left(a + b\right)^{k}\\- \left(a - b\right)^{k} + \left(a + b\right)^{k} & \left(a - b\right)^{k} + \left(a + b\right)^{k}\end{matrix}\right]$$
 [/INST] Note that 
$$
\pmatrix{a&b\\b&a} = \frac 12 \pmatrix{1&1\\1&-1}\pmatrix{a+b&0\\0&a-b} \pmatrix{1 & 1\\1&-1}
$$
where we observe that 
$$
\pmatrix{1 & 1\\1&-1}^2 = 2I
$$
With that, we compute
$$
\begin{align*}
\pmatrix{a&b\\b&a}^k &= \left[\frac 12 \pmatrix{1&1\\1&-1}\pmatrix{a+b&0\\0&a-b} \pmatrix{1 & 1\\1&-1}\right]^k\\
&= 
\frac 12 \pmatrix{1&1\\1&-1}\left[\pmatrix{a+b&0\\0&a-b}  \underbrace{\left(\frac 12 \pmatrix{1 & 1\\1&-1}\pmatrix{1&1\\1&-1}\right)}_I\right]^{k-1}
\\ & \qquad \cdot \pmatrix{a+b&0\\0&a-b} \pmatrix{1&1\\1&-1} 
\\ & = \frac 12 \pmatrix{1&1\\1&-1}\pmatrix{a+b&0\\0&a-b}^{k}\pmatrix{1&1\\1&-1}
\end{align*}
$$
I'll let you figure out the rest.
</s>