- Thread starter Patrick Yan
- Start date

\( \begin{bmatrix} \mathbf{1} && \mathbf{X}_1 && \cdots && \mathbf{X}_{p-1} \end{bmatrix} \begin{bmatrix} 1 \\ 0 \\ \vdots \\ 0 \end{bmatrix} = \mathbf{1} \)

In short, we have the relationship \( X\mathbf{e}_1 = \mathbf{1} \) and a direct substitution in the definition of hat matrix can yield the desired result.