# The functional equation $f(x) + f\bigl(x+f(y)\bigr) = y + f\Bigl(f(x) + f\bigl(f(y)\bigr)\Bigr)$

I'm having trouble with this functional equation:

Find all functions $$f:\mathbb R \to \mathbb R$$ for which the following is valid for all $$x,y\in \mathbb R$$: $$f(x) + f\bigl(x+f(y)\bigr) = y + f\Bigl(f(x) + f\bigl(f(y)\bigr)\Bigr)$$

I haven't been able to pinpoint any solution, nor to prove surjectivity or injectivity, So no progress. I tried $$x=y=0$$, $$x=0$$, $$y=0$$, $$x=-f(y)$$, $$y=f(x)$$, and even with some assumptions on bijectivity, but nothing helped.

I don't know the source, but it seems like a pretty difficult problem, maybe even impossible to solve.

I arrive at a proof that no such funtion exist (assuming the statement is correct).

Replace $$x$$ with $$f(x)$$ in the original equation: $$f(f(x)) - y = f(f(f(x)) + f(f(y))) - f(f(x) + f(y)).\tag{1}$$

The right hand side is symmetric in $$x$$ and $$y$$, so we get $$f(f(x)) - y = f(f(y)) - x,$$ or $$f(f(x)) + x$$ is constant for all $$x$$. Write $$c$$ for this constant. Thus $$f(f(x)) = c - x.\tag{2}$$

(In particular, this shows that $$f$$ is both injective and surjective.)

It follows that $$f(c - x) = f(f(f(x))) = c - f(x),\tag{3}$$ which gives $$f(\frac c 2) = \frac c 2$$.

Using (2), the equation (1) becomes $$x + y + f(2c - x - y) = c + f(f(x) + f(y)).\tag{4}$$

Put $$x = \frac c 2$$ and $$y = c$$: $$c = f(\frac c 2 + f(c)).$$

Applying $$f$$ again and using (2), we get $$f(c) = \frac c 4$$, and then $$f(0) = \frac {3c}4$$ by (3).

In (4), replace $$x$$ with $$0$$ and $$y$$ with $$x + y$$: $$x + y + f(2c - x - y) = c + f(\frac {3c}4 + f(x + y)).$$

We compare this with (4). From injectivity of $$f$$, we get

$$f(x + y) + \frac {3c} 4 = f(x) + f(y).\tag{5}$$

If we define $$g(x) = f(x) - \frac{3c} 4$$, then we have $$g(x + y) = g(x) + g(y)$$. This implies that $$g(rc) = rg(c) = -\frac{rc}2$$ for any rational number $$r$$.

Therefore $$f(rc) = (\frac 3 4 - \frac r 2)c$$ for any rational number $$r$$.

Applying $$f$$ again gives $$f(f(rc)) = (\frac 3 8 + \frac r 4) c$$. Together with (2), we conclude that $$c = 0$$.

Thus (5) becomes $$f(x + y) = f(x) + f(y)$$ and (2) becomes $$f(f(x)) = -x$$.

The original equation can then be rewritten as: $$f(x) + f(x) + f(f(y)) = y + f(f(x)) + f(f(f(y))),$$ or: $$2f(x) + f(y) = 2y - x.\tag{6}$$

Apply $$f$$ again: $$-2x - y = 2f(y) - f(x).\tag{7}$$

We take a linear combination of (6) and (7) and get: $$5f(x) = 5y.$$

This obviously cannot hold for all $$x, y \in \Bbb R$$.

• I don't see why the right hand side should be symmetric in your first equation. In the first term, we apply f three times to one but only two times to the other...? Commented Nov 26, 2020 at 23:34
• @MushuNrek Please look more carefully. One $f$ is on the outer most. It's $f[f(f(x)) + f(f(y))]$. Commented Nov 26, 2020 at 23:35
• That is a very nice proof you came up with! Commented Nov 26, 2020 at 23:47
• I'm not sure you can replace x with f(x). x is from R, and f(x) is from the image of f. Commented Nov 27, 2020 at 1:15
• No, your understanding is wrong. The original formula is true for all $x \in \Bbb R$, and for every $t \in \Bbb R$, we have $f(t)\in \Bbb R$, thus replacing $x$ with $f(t)$ gives us a formula that is true for all $t\in \Bbb R$. Now rename the variable $t$ back to $x$. Commented Nov 27, 2020 at 1:22

I do not have a solution, but I want to share with you my ideas so far. To make things every to read, we write $$f^k$$ for $$f\circ \dots\circ f$$ $$k$$-times.

Applying $$f$$ to the left hand side, we obtain the expression $$f\big{(} \underbrace{f(x)}_{=:x'} + f(\underbrace{x + f(y)}_{=:y'})\big{)} = f(x' + f(y')) = y' + f\left(f(x') + f^2(y')\right) - f(x'),$$ i.e. $$f(f(x) + f(x+f(y))) = x + f(y) + f(f^2(x) + f^2(x+f(y))) - f^2(x).$$ But we can also write $$f\big{(} f(\underbrace{x}_{=:y'}) + \underbrace{f(x + f(y))}_{=:y'}\big{)} = x + f(f^2(x + f(y)) + f^2(x)) - f^2(x+f(y)).$$ Comparing the two quantities gives $$f(y) = f^2(x) - f^2(x+f(y)).$$ For $$y = f(x)$$, this implies $$f^2(x + f^2(x)) = 0$$ for all $$x\in\Bbb R$$. Also, if $$f$$ was surjective, we could find $$y$$ such that $$f(y) = -x$$ giving $$f^2(x) = f^2(0) - x.$$ Combining this with the previous yields $$f^4(0) = 0.$$

(Edit: more precisely, we get $$f^4(x) = f^2(0)- f^2(x) = x.$$ In particular, subjectivity implies bijectivity and gives the inverse function explicitly.)

Naturally, the last bit completely relies on surjectivity which might not be given.

That are my thoughts so far.

• I believe to have shown that $f(0)\neq 0$ so $f$ cannot be surjective if my proof is correct. Commented Nov 26, 2020 at 23:27
• How have I shown that? Could you be more precise? Commented Nov 26, 2020 at 23:32