Find all functions $f(x)$ such that $f\left(x^2+f(y)\right)$=$y+(f(x))^2$ Let $\mathbb R$ denote the set of all real numbers. Find all function $f: R\to \ R$ such that   $$f\left(x^2+f(y)\right)=y+(f(x))^2$$   It is the problem. I tried to it by putting many at the place of $x$ and $y$ but I can't proceed. Please somebody help me. 

Observe


*

*$f(x^2+f(0)) = [f(x)]^2$

*$f(f(x)) = x+[f(0)]^2$.


Plugging $0$ into expression 1 yields
\begin{align}
f_2(0):=f(f(0)) = [f(0)]^2
\end{align}
and plugging $f(0)$ into expression 1 yields
\begin{align}
f(f(0)^2+f(0)) =[f_2(0)]^2 = [f(0)]^4. 
\end{align}
Moreover, by expression 2, we have
\begin{align}
f(f(0)^2+f(0))= f([f(0)]^2)=f(f_2(0)) = f_3(0).
\end{align}
Hence we have
\begin{align}
f_3(0) = [f(0)]^4.
\end{align}
Next, using both 1 and 2, we have
\begin{align}
f(f(x^2+f(0)))=x^2+f(0)+[f(0)]^2. \ \ (\ast)
\end{align}
Plugging $0$ into $(\ast)$ yields
\begin{align}
f_3(0) = f(0)+[f(0)]^2.
\end{align}
Combining everything yields
\begin{align}
[f(0)]^4= f_3(0) = f(0)+[f(0)]^2 \ \ \Rightarrow \ \ f(0)[f(0)^3-f(0)-1] =0.
\end{align}
Solving for $f(0)$ yields that either $f(0) = 0$ or $f(0)$ is a root of the polynomial $p(x) = x^3-x-1$, which only has one real root.
Moreover, observe
\begin{align}
f_4(0) = [f(0)]^4
\end{align}
and
\begin{align}
f_4(0) = f(f(f_2(0))) = f_2(0) + [f(0)]^2 = 2[f(0)]^2
\end{align}
which means
\begin{align}
[f(0)]^4-2[f(0)]^2 = 0.
\end{align}
Thus, $f(0)$ is also a root of $x^4-2x^2 = x^2(x^2-2)$. 
In conclusion, $f(0)$ has to be $0$. Thus, $f(f(x)) = x$ and $f(x^2) = [f(x)]^2$. 
