<s>[INST] Solve the equation: $x=\sqrt{a-\sqrt{a+x}},(a\geq 1)$ 
Solve the equation: $x=\sqrt{a-\sqrt{a+x}},(a\geq 1)$ 

We have: $x^2=a-\sqrt{a+x}$ , if we take both sides to the power of 2 we will get a 4th order equation which I don't know of!
Please help.
 [/INST] Note that $0 \le x\le a(a-1)$,
\begin{align*}
  x &= \sqrt{a-\sqrt{a+x}} \\
  x^2 &= a-\sqrt{a+x} \\
  a+x &= (a-x^2)^2 \\
  a+x &= a^2-2ax^2+x^4 \\
  x^4-2ax^2-x+a^2-a &= 0 \\
  (x^2-x-a)(x^2+x-a+1) &= 0 \\
\end{align*}
$$x=\frac{1 \pm \sqrt{4a+1}}{2} \quad \text{or} \quad \frac{-1 \pm \sqrt{4a-3}}{2}$$

For $a\ge 1$,
$$x=\frac{-1+\sqrt{4a-3}}{2}$$

Alternative solution from problem $168$ in The USSR Olympiad Problem Book
Let $y=\sqrt{a+x}$, then $x=\sqrt{a-y}$
\begin{align*}
  a+x &= y^2 \\
  a-y &= x^2 \\
  x+y &= y^2-x^2 \\
  x^2-y^2+x+y &= 0 \\
  (x+y)(x-y+1) &= 0 \\
  (x+\sqrt{a+x})(x-\sqrt{a+x}+1) &= 0
\end{align*}
Rejecting $x+\sqrt{a+x}=0$,
$$x^2+x-a+1=0$$
$$x=\frac{-1+\sqrt{4a-3}}{2}$$
</s>