Find the maximum value of
\[\frac{x + 2y + 3}{\sqrt{x^2 + y^2 + 1}}\]over all real numbers $x$ and $y.$
In fact, if I let $\vec{u} = (x, y, 1)$ and $\vec{v} = (1, 2, 3)$, then I can write the fraction as \[\frac{\vec{u} \cdot \vec{v}}{|\vec{u}|},\] where $|\vec{u}|$ is the magnitude of $\vec{u}$. Now, by the Cauchy-Schwarz inequality, I know that \[|\vec{u} \cdot \vec{v}| \leq |\vec{u}| |\vec{v}|,\] which implies that \[\frac{\vec{u} \cdot \vec{v}}{|\vec{u}|} \leq |\vec{v}|.\] This means that the fraction is always less than or equal to the magnitude of $\vec{v}$, which is \[|\vec{v}| = \sqrt{1^2 + 2^2 + 3^2} = \sqrt{14}.\] 