A proper proof would require an induction-like argument, but we will argue more informally.
The nonzero generating vector \(\uvec{w}\) is linearly independent all by itself. On the other hand, the collection
\begin{equation*}
\uvec{w}, A \uvec{w}, A^2 \uvec{w} , \dotsc, A^n \uvec{w}
\end{equation*}
must be linearly dependent because it is a collection of
\(n+1\) vectors in a
\(n\)-dimensional space (
Lemma 18.5.7). So there must be a “transition” exponent
\(k \le n\) where
\begin{equation*}
\uvec{w}, A \uvec{w}, A^2 \uvec{w}, \dotsc, A^{k-1} \uvec{w}
\end{equation*}
is independent but
\begin{equation*}
\uvec{w}, A \uvec{w}, A^2 \uvec{w}, \dotsc, A^k \uvec{w}
\end{equation*}
is dependent (where we take \(A^0 \uvec{w}\) to mean \(\uvec{w}\) even if \(A\) is not invertible). We claim that this transition value \(k\) is the one required by the statement of the lemma.
Since we already have independence, to verify this claim we only need to demonstrate that
\begin{equation*}
W' = \Span \{ \uvec{w}, A \uvec{w}, A^2 \uvec{w}, \dotsc, A^{k-1} \uvec{w} \}
\end{equation*}
is the same space as the full cyclic subspace
\begin{equation*}
W = \Span \{ \uvec{w}, A \uvec{w}, A^2 \uvec{w}, \dotsc \} \text{.}
\end{equation*}
And to do that, it is enough to verify that each of
\begin{equation*}
A^k \uvec{w}, A^{k+1} \uvec{w}, A^{k+2} \uvec{w}, \dotsc
\end{equation*}
Now, we already know that \(A^k \uvec{w}\) must be in \(W'\) by its dependence with the finite spanning set for \(W'\text{.}\) If we write
\begin{equation*}
A^k \uvec{w} = a_0 \uvec{w} + a_1 A \uvec{w} + a_2 A^2 \uvec{w} + \dotsb + a_{k-1} A^{k-1} \uvec{w} \text{,}
\end{equation*}
then multiplying through by \(A\) gives
\begin{equation*}
A^{k+1} \uvec{w} = a_0 A \uvec{w} + a_1 A^2 \uvec{w} + a_2 A^3 \uvec{w} + \dotsb + a_{k-1} A^k \uvec{w} \text{.}
\end{equation*}
This expression for
\(A^{k+1} \uvec{w}\) is a linear combination of vectors in
\(W'\text{,}\) and so must be in
\(W'\) as well (
Proposition 17.5.2). Similarly, we can multiply that expression for
\(A^{k+1} \uvec{w}\) through by
\(A\) to get an expression for
\(A^{k+2} \uvec{w}\) as a linear combination of vectors in
\(W'\text{.}\) And similarly for
\(A^{k+3} \uvec{w}\text{,}\) and so on.