Solution by jasperE3.
f(f(x)+f(y))=f(x)+f(y).
Let ∅=S⊆R be closed under addition, then all functions f are characterized as:
f(x)={xg(x)if x∈S+Sif x∈/S+S
where S+S={s1+s2∣s1,s2∈S} and g:R∖(S+S)→S is any function.
Easy to verify that these functions work, and to show that all functions with f(f(x)+f(y))=f(x)+f(y) are of this form we choose S=f(R).
For instance, with S=[1,∞) and g(x)=x2+1 we get f(x)={xx2+1if x≥2if x<2.