Find all functions such that $f(x^2+y^2f(x))=xf(y)^2-f(x)^2$

contest-mathfunctional-equations

I am dealing with the test of the OBM (Brasilian Math Olympiad), University level, 2016, phase 2.

I hope someone can help me to discuss this test. Thanks for any help.

The question 2 says:

Find all functions $f:\mathbb{R}\rightarrow \mathbb{R}$ such that

$f(x^2+y^2f(x))=xf(y)^2-f(x)^2$

for all $x,y\in\mathbb{R}$.

My attempt:

Note that $f(0)\in\{0,-1\}$. In fact, by taking $x=y=0$, we have $f(0)=-f(0)^2$.

Case 1 $f(0)=0$

By taking $y=0$, we have

$f(x^2)=-f(x)^2\forall x\in\mathbb{R}$

Particularly, $f(1)=-f(1)^2$, so $f(1)\in\{0,-1\}$.

(a) f(1)=0

By taking $x=1$, we have $f(1)=f(y)^2\forall y\in\mathbb{R}$.

So, $f\equiv 0$. Is trivial that it respects the statement.

(b) f(1)=-1

By taking $x=1$, we have $f(1-y^2)=f(y)^2-1=-f(y^2)-1\forall y\in\mathbb{R}$. So, to $t\leq 0$, we have $f(1-x)=-f(x)-1$.

By taking $y=1$, we have $f(x^2+f(x))=x-f(x)^2=x+f(x^2) \forall x\in\mathbb{R}$.

I could not finish this subcase

Case 2 $f(0)=-1$

By taking $x=0$,

$f(-y^2)=-1\forall y\in\mathbb{R}$

So, $f(t)=-1\forall t\leq0$.

By taking $y=0$,

$f(x^2)=-x-f(x)^2 \forall x\in\mathbb{R}$

So, $f(t)=-\sqrt{t}-1\forall t\geq0$.

But this function does not is correct. For instance, to $x=y=1$, $f(x^2+y^2f(x))=f(1+1(-2))=f(-1)=-1$, but $xf(y)^2-f(x)^2=1(-2)^2-(-2)=6\not=-1$.

Best Answer

My solution builds on Patrick Stevens's answer. For now on, I'm considering the case where $f$ isn't zero everywhere, and I'll prove that $f(x)=-x$ everywhere.

We already have $f(x+1)=f(x)-1$ for $x\ge 0$. But this is true for all $x$, here's why. Let $t \ge 0$ and set $x=1$ and $y=\sqrt{t}$ in the original identity, using $f(x^2)=-f(x)^2$. We get $f(1-t)=-1-f(t)$. Substitute $t=1-s$ to get $f(s)=-1-f(1-s)$ for $s \le 1$. Therefore, $f(x)+f(1-x)=-1$ for all $x$. Using sign-reversal and induction, we find $$ f(x+n)=f(x)-n $$ for all real $x$ and integer $n$.

Let $n$ be an integer and $t \ge 0$ be a real. Set $x=-n$ and $y=\sqrt{t}$ to get $f(n^2 + t f(n))=f(n^2) - n f(t)$, which leads to $f(-tn)-n^2=-n^2 - n f(t)$, then $f(n t) = n f(t)$. Using sign-reversal, this is also true when $t$ is negative, so (replacing $t$ with $x$) $$ f(n x) = n f(x) $$ for all real $x$ and integer $n$.

Replace $x$ with $x/n$ to find $ f(x/n) = n f(x/n)/n = f(nx/n)/n = f(x)/n $. Let $a$ be an integer and $b$ be a positive integer. Then $f((a/b)x) = f(a(x/b)) = a f(x/b) = a f(x) / b = (a/b)f(x)$ and $f(x + a/b) = f((bx + a)/b) = f(bx + a)/b = (f(bx) - a)/b = f(bx)/b - a/b = f(x) - a/b$. So $$\begin{align} f(x+q) &= f(x)-q \\ f(qx) &= q f(x) \end{align}$$ for all real $x$ and rational $q$.

$f(q)=-q$ for all rational $q$. Now let's show that it's true for irrational values.

We already know that $f$ if negative over positive values, and vice versa. Let $x$ be any irrational number, and let $q < x$ be some rational number. Then $f(x-q)=f(x)+q$. Since $x-q$ is positive, $f(x-q)$ is negative, and so $f(x)<-q$. We can choose $q$ to be as close as we want, so $f(x) \le -x$. Doing the same from the other side shows $f(x) \ge -x$.