If we consider a linear model $\mathbf{y}=\beta_0\mathbf{1}+\beta_1\mathbf{a_1}+\beta_0\mathbf{a_2}+\varepsilon$ with $a_1,a_2$ column vectors with $n$ entries and $\beta_1\neq\beta_2\neq 0$.
Then, what would be the conditions on $a_1$ and $a_2$ for $\beta_0=\bar{y}$?
I've re writen the linear formula as $\mathbf{y}=\mathbf{X}\mathbf{\beta}+\mathbf{\varepsilon}$,
which gives $\mathbf{\beta}=(\mathbf{X}^T\mathbf{X})^{-1}\mathbf{X}^T\mathbf{y},\quad$ with $\beta=\begin{pmatrix} \beta_0 \\ \beta_1 \\ \beta_2 \end{pmatrix}\quad$ and $\quad\mathbf{X}=\begin{pmatrix} 1 & a_1 & a_2\end{pmatrix}$.
However I don't know how to go from there, when I try to compute $(\mathbf{X}^T\mathbf{X})^{-1}$ it gives me an non inversible matrix.
Any help would be appreciated, thanks!