Solution by MellowMelon.
We claim the only solutions are f(x)≡x, f(x)≡−x and f(x)≡0, which obviously work. We now show they are the only solutions. Let P(x,y) denote the assertion that f(x+f(x)f(y))=f(x)+xf(y).
P(−1,−1) gives f(−1+f(−1)2)=0 so there exists t such that f(t)=0.
P(t,y) implies f(t)=tf(y), so unless f is identically 0 (which is a solution), f(0)=0 and f is injective at 0.
Hence, f(−1)2=1.
From P(1,−1), f(1+f(−1)f(1))=f(1)+f(−1).
Now P(−1,1+f(−1)f(1)) gives f(−1+f(−1)f(−1)+f(−1)f(1))=f(−1)−(f(1)+f(−1)), simplify to get
f(f(−1)f(1))=−f(1) (*).
Now P(1,f(−1)f(1)) gives f(1−f(1)f(1))=0, so f(1)2=1. This means that f(1)=±f(−1).
Note that if f(−1)=f(1), then f(f(−1)f(1))=−f(1) implies that f(1)=−f(1), contradicting f(1)2=1. So f(1)=−f(−1).
Let us suppose that we have a such that f(a)=af(−1). From P(−1,a),
f(−1+f(−1)f(−1)a)=f(−1)−f(−1)a, or
f(a−1)=f(1)(a−1).
Now from P(1,a−1), we get
f(1+f(1)f(1)(a−1))=f(1)+f(1)(a−1), or
f(1+a−1)=f(1)+f(1)a−f(1), or
f(a)=af(1).
But f(a)=af(−1), so af(−1)=af(1) and a=0 (**).
From P(x,−1), f(x+f(−1)f(x))=f(x)+xf(−1). Observe that if a=x+f(−1)f(x), this is of the form f(a)=af(−1). Therefore by (**) a=0, so x+f(−1)f(x)=0. But then x=−f(−1)f(x), or x=f(1)f(x).
Since f(1) is its own reciprocal, f(x)=xf(1). Since f(1)=1 or −1, f(x)=x or f(x)=−x. We also have the solution f(x)=0 that we assumed away earlier. These are the three answers, and we are done.