Recipe
Compute a matrix power A^k
Use when: you have a square matrix A and a positive integer k, and need the matrix A^k
Goal: the matrix A^k, found by whichever method is actually fastest for A's shape and k's size
Taught in Powers of a matrix
Quick recipe
-
1
Only a square matrix can multiply itself — check that its row count equals its column count before doing anything else.
Example
A=\begin{pmatrix}0&1\\-1&0\end{pmatrix} is 2\times2, so A^2, A^3,\dots are all defined.
- A is square — continue to Step 2.
- A is not square — A^k for k\geq2 doesn't exist; stop here.
Why: AA requires A's column count to match A's row count, the same inner-dimension rule any matrix product requires — a genuine power only exists when those two counts happen to be equal.
-
2
A diagonal matrix's powers come from raising each diagonal entry to the k-th power directly; a triangular matrix (upper or lower) is guaranteed to stay triangular of the same kind at every power, though its entries still take real multiplication to find.
Example
A=\begin{pmatrix}0&1\\-1&0\end{pmatrix} is neither diagonal nor triangular — both off-diagonal entries are nonzero and the diagonal itself is 0 — so no shortcut skips the arithmetic here; Steps 3–4 have to do the actual multiplying.
⚡ Shortcut
If A actually is diagonal, skip Steps 3–4 entirely. For D=\begin{pmatrix}2&0&0\\0&-3&0\\0&0&5\end{pmatrix}, D^4=\begin{pmatrix}2^4&0&0\\0&(-3)^4&0\\0&0&5^4\end{pmatrix}=\begin{pmatrix}16&0&0\\0&81&0\\0&0&625\end{pmatrix} — no matrix multiplication at all, just three scalar exponents.
Why: these shapes aren't special-cased by accident — every off-diagonal entry of a diagonal matrix's product is a sum of terms that each include at least one zero factor, so it vanishes automatically, and the same zero pattern that makes a matrix triangular reproduces itself under multiplication.
-
3
Compute A^2=AA first, then A^3=A^2A, and so on, reusing each previous power rather than starting over from scratch.
Example
A^2=\begin{pmatrix}0&1\\-1&0\end{pmatrix}\begin{pmatrix}0&1\\-1&0\end{pmatrix}=\begin{pmatrix}-1&0\\0&-1\end{pmatrix}=-IA^3=A^2A=(-I)A=-A=\begin{pmatrix}0&-1\\1&0\end{pmatrix}Why: associativity guarantees A^jA^k=A^{j+k} no matter how the factors are grouped, so building up gradually from the last power computed always lands on the correct next one.
-
4
If an early power comes back to I, to -I, or to A itself, every later power is forced to cycle through the same short list, and a large k can be reached by repeated squaring (A^2, A^4, A^8, \dots) instead of one multiplication at a time.
Example
Since A^2=-I, squaring again gives A^4=(A^2)^2=(-I)^2=I. Then A^5=A^4A=IA=A — the original matrix, with no further multiplication needed once the -I,I pattern is spotted: \boxed{A^5=\begin{pmatrix}0&1\\-1&0\end{pmatrix}}
Why: once a power repeats an earlier one, every later power is forced to repeat too, by the same associativity that makes A^jA^k=A^{j+k} well-defined regardless of how the factors are grouped.
Common mistakes
- Squaring each entry individually (A^{\circ2}) instead of multiplying A by itself — the entrywise square is a different, far less useful operation.
- Trying to compute A^k for a matrix that isn't square.
- Recomputing A^3 as three fresh multiplications from scratch instead of reusing the already-computed A^2.
- Forgetting that A^0=I, not the zero matrix.
- Assuming a triangular matrix's powers can be read off entry by entry the way a diagonal matrix's can — triangular only guarantees the zero pattern survives, not that the surviving entries come for free.