TITLE: real values of $x$ in $\sqrt{5-x} = 5-x^2$.
QUESTION [7 upvotes]: Calculate the real solutions $x\in\mathbb{R}$ to
$$
\sqrt{5-x} = 5-x^2
$$

My Attempt:
We know that $5-x\geq 0$ and thus $x\leq 5$ and
$$
\begin{align}
5-x^2&\geq 0\\
x^2-\left(\sqrt{5}\right)^2&\leq 0
\end{align}
$$
which implies that $-\sqrt{5}\leq x \leq \sqrt{5}$. Now let $y=\sqrt{5-x}$. Then
$$
\tag1 y^2=5-x
$$
and the equation converts into
$$
\begin{align}
y &= 5-x^2\\
x^2 &= 5-y\\
y^2-x^2 &= 5-x-(5-y)\\
y^2-x^2 &= y-x\\
(y-x)(y+x)-(y-x) &= 0\\
(y-x)(y+x-1) &= 0
\end{align}
$$
So either $y=x$ or $x+y=1$.
Case 1 ($y=x$):
We can plug this into $(1)$ to get
$$
\begin{align}
y^2 &= 5-x\\
x^2 &= 5-x\\
x^2+x-5 &= 0\\
x &= \frac{-1\pm \sqrt{1+20}}{2}
\end{align}
$$
Since $-\sqrt{5}\leq x\leq \sqrt{5}$, the only solution is
$$
x = \frac{-1+\sqrt{21}}{2}
$$
Case 2 ($y=1-x$):
We can plug this into $(1)$ to get
$$
\begin{align}
y^2 &= 5-x\\
(1-x)^2 &= 5-x\\
1+x^2-2x &= 5-x\\
x^2-x-4 &= 0\\
x &= \frac{1\pm\sqrt{17}}{2}
\end{align}
$$
Since $-\sqrt{5}\leq x\leq \sqrt{5}$, the only solution is
$$
x = \frac{1-\sqrt{17}}{2}
$$
So final solution is
$$
x \in \left\{\displaystyle  \frac{1-\sqrt{17}}{2}, \frac{-1+\sqrt{21}}{2} \right\}
$$
Is it possible to solve this problem using geometry? For example, could we use the properties of a half-circle and a parabola?

REPLY [3 votes]: You can see the solutions as the abscissa of the intersection points of the two curves $y=5-x^2$ (a parabola) and $y=\sqrt{5-x}$ (upper half of a parabola). These twoo parabolas intersect at 4 points, but only two of them lie in the $y>0$ half-plane.