An excerpt from my Physics Notes. The topic is solving for angular momentum in rigid bodies.
$$\vec{r} \times (\vec{\omega}\times \vec{r})=(\vec{r} \cdot \vec{r})\vec{\omega}-(\vec{r} \cdot \vec{\omega})\vec{r}$$ $$\vec{\omega}=(\omega_x,\omega_y,\omega_z)=\begin{bmatrix} \omega_x\\\omega_y\\ \omega_z\end{bmatrix}$$ $$(\vec{r} \cdot \vec{r})\vec{\omega}-(\vec{r} \cdot \vec{\omega})\bf{\vec{r}}=\begin{bmatrix} (x^2+y^2+z^2)\omega_x\\(x^2+y^2+z^2)\omega_y\\(x^2+y^2+z^2)\omega_z\end{bmatrix}-\begin{bmatrix}(x\omega_x+y\omega_y+z\omega_z) \bf{x}\\(x\omega_x+y\omega_y+z\omega_z)\bf{y}\\(x\omega_x+y\omega_y+z\omega_z)\bf{z} \end{bmatrix}$$
My question is concerning the very last $\bf{\vec{r}}$ (bolded in the work above). When it's turned into a matrix, why is it treated as$\begin{bmatrix} x\\y\\ z\end{bmatrix}$ instead of $\begin{bmatrix} (x+y+z)\\(x+y+z)\\(x+y+z)\end{bmatrix}$ like the $\vec{r}$ just before it, that was dotted with $\vec{\omega}$?
Any insight is appreciated.