[guided]The reachable subspace is the part of the state space that can be affected by the input through repeated interaction with the drift matrix $A$. We define it explicitly by
\begin{align*}
\mathcal R := \operatorname{span}_{\mathbb R}\{A^j Bv : 0 \le j \le n-1,\ v \in \mathbb R^m\}.
\end{align*}
This is a real linear subspace of $\mathbb R^n$. It contains $\operatorname{Range}B$ because the term $j=0$ gives $Bv$.
We next verify that $\mathcal R$ is invariant under $A$. If $0 \le j \le n-2$, then
\begin{align*}
A(A^jBv)=A^{j+1}Bv \in \mathcal R.
\end{align*}
For the remaining power, the [Cayley-Hamilton Theorem](/theorems/865) applied to $A$ expresses $A^n$ as a real linear combination of $I_n,A,\dots,A^{n-1}$. Hence $A^nBv$ is a real linear combination of $Bv,ABv,\dots,A^{n-1}Bv$, so it also belongs to $\mathcal R$. Therefore $A\mathcal R \subset \mathcal R$.
Let $r:=\dim_{\mathbb R}\mathcal R$. Choose a basis $e_1,\dots,e_r$ of $\mathcal R$ and extend it to a basis $e_1,\dots,e_n$ of $\mathbb R^n$. Let $T \in \mathbb R^{n \times n}$ be the change-of-basis matrix with these columns. In this basis, the first $r$ coordinates describe $\mathcal R$. Since $A\mathcal R \subset \mathcal R$, the lower-left block of $T^{-1}AT$ is zero. Since $\operatorname{Range}B \subset \mathcal R$, the lower block of $T^{-1}B$ is zero. Thus there are real matrices $A_{11} \in \mathbb R^{r \times r}$, $A_{12} \in \mathbb R^{r \times (n-r)}$, $A_{22} \in \mathbb R^{(n-r) \times (n-r)}$, and $B_1 \in \mathbb R^{r \times m}$ with the following block description relative to $\mathbb R^n = \mathbb R^r \oplus \mathbb R^{n-r}$: the upper-left, upper-right, lower-left, and lower-right blocks of $T^{-1}AT$ are respectively $A_{11}$, $A_{12}$, $0$, and $A_{22}$, while the upper and lower blocks of $T^{-1}B$ are respectively $B_1$ and $0$.
The point of this decomposition is that the lower block is not directly actuated. The upper block is precisely the reachable part: for each $0 \le j \le n-1$ and $v \in \mathbb R^m$, the vector $A^jBv$ has reduced coordinates $(A_{11}^jB_1v,0)$. Because $e_1,\dots,e_r$ form a basis of $\mathcal R$, the span of the vectors $A_{11}^jB_1v$ with $0 \le j \le n-1$ is all of $\mathbb R^r$. To match the usual controllability criterion for the $r$-dimensional pair, we reduce the powers. Applying the [Cayley-Hamilton Theorem](/theorems/865) to $A_{11}$ expresses every $A_{11}^j$ with $j \ge r$ as a real linear combination of $I_r,A_{11},\dots,A_{11}^{r-1}$. Therefore the vectors $A_{11}^jB_1v$ with $0 \le j \le r-1$ and $v \in \mathbb R^m$ still span $\mathbb R^r$. Hence the reachable subspace of $(A_{11},B_1)$ is $\mathbb R^r$, so $(A_{11},B_1)$ is controllable on $\mathbb R^r$.[/guided]