Five Steps Through a Two-Unit Layer

Matrix DecompositionsMedium+20 XP+20

Five Steps Through a Two-Unit Layer

A miniature recurrent layer holds a two-number state ht\mathbf{h}_tht​ and updates it by the same matrix at every step:

ht+1=A ht,A=[5−23−2]\mathbf{h}_{t+1} = A\,\mathbf{h}_t, \qquad A = \begin{bmatrix} 5 & -2 \\ 3 & -2 \end{bmatrix}ht+1​=Aht​,A=[53​−2−2​]

SymbolMeaning
ht[1]\mathbf{h}_t[1]ht​[1]activation of unit 1 after ttt steps
ht[2]\mathbf{h}_t[2]ht​[2]activation of unit 2 after ttt steps

After five steps the state is h5=A5h0\mathbf{h}_5 = A^5\mathbf{h}_0h5​=A5h0​, so the whole five-step behaviour is packed into the single matrix A5A^5A5. You want the cross term: the entry in row 1, column 2 of A5A^5A5, which says how strongly unit 2's starting activation feeds into unit 1 five steps later.

AAA is diagonalizable and both of its eigenvalues are integers, so A=PDP−1A = PDP^{-1}A=PDP−1 for some invertible PPP and diagonal DDD.

What is the entry of A5A^5A5 in row 1, column 2? Your answer is an exact integer.

Hints

Solve it to unlock the solution

Once you get it right, the reasoning behind the answer shows up here.