Power of matrix using diagonalization First one
$$\begin{pmatrix}
2& 3\\5
& 1
\end{pmatrix}^{20}$$
Second one
$$A=\begin{pmatrix}
4&0& 0\\0
& 3&0\\2 &0&2
\end{pmatrix}^{20}$$
$$P=\begin{pmatrix}
1&0& 0\\0
& 1&0\\1 &0&1
\end{pmatrix}$$
$$P^{-1}=\begin{pmatrix}
1&0& 0\\0
& 1&0\\-1 &0&1
\end{pmatrix}$$
I have some difficult to solve this problem.
For the first one, the characteristic equation is $(\lambda-1)(\lambda-2)-15=\lambda^2-3\lambda-13=0$ that $\lambda$ is $\frac{3\pm\sqrt{61}}2$ is it right?
For the second one, I find $P$ and $P^{-1}$, but multiplication of $P^{-1}AP$ is not diagonal.
Is there any case that $A$ cannot be represented as a diagonal but power of $A$ can be calculated?

$A$ has distinct eigenvalues, it must be diagonalizable.
\begin{align}\begin{bmatrix}1 & 0 & 0 \\ 0 & 1 & 0 \\ -1 & 0 & 1 \end{bmatrix}\begin{bmatrix}4 & 0 & 0 \\ 0 & 3 & 0 \\ 2 & 0 & 2 \end{bmatrix} \begin{bmatrix}1 & 0 & 0 \\ 0 & 1 & 0 \\ 1 & 0 & 1 \end{bmatrix} &= \begin{bmatrix}1 & 0 & 0 \\ 0 & 1 & 0 \\ -1 & 0 & 1 \end{bmatrix}\begin{bmatrix}4 & 0 & 0 \\ 0 & 3 & 0 \\ 4 & 0 & 2 \end{bmatrix}  \\
&=\begin{bmatrix}4 & 0 & 0 \\ 0 & 3 & 0 \\ 0 & 0 & 2 \end{bmatrix} \end{align}
