# 2019 IMO Problems/Problem 1

Problem:

Let $\mathbb{Z}$ be the set of integers. Determine all functions $f : \mathbb{Z} \to \mathbb{Z}$ such that, for all integers $a$ and $b$, $$f(2a) + 2f(b) = f(f(a + b)).$$

Solution 1:

Let us substitute $0$ in for $a$ to get $$f(0) + 2f(b) = f(f(b)).$$

Now, since the domain and range of $f$ are the same, we can let $x = f(b)$ and $f(0)$ equal some constant $c$ to get $$c + 2x = f(x).$$ Therefore, we have found that all solutions must be of the form $f(x) = 2x + c.$

Plugging back into the original equation, we have: $4a + c + 4b + 2c = 4a + 4b + 2c + c$ which is true. Therefore, we know that $f(x) = 2x + c$ satisfies the above for any integral constant c, and that this family of equations is unique.

Solution 2: We plug in $a=-b=x$ and $a=-b=x+k$ to get $$f(2x)+2f(-x)=f(f(0)),$$ $$f(2(x+k))+2f(-(x+k))=f(f(0)),$$ respectively.

Setting them equal to each other, we have the equation $$f(2x)+2f(-x)=f(2(x+k))+2f(-(x+k)),$$ and moving "like terms" to one side of the equation yields $$f(2(x+k))-f(2x)=2f(-x)-2f(-(x+k)).$$ Seeing that this is a difference of outputs of $f,$ we can relate this to slope by dividing by $2k$ on both sides. This gives us $$\frac{f(2x+2k)-f(2x)}{2k}=\frac{f(-x)-f(-x-k)}{k},$$ which means that $f$ is linear.

Let $f(x)=mx+n.$ Plugging our expression into our original equation yields $2ma+2mb+3n=m^2a+m^2b+mn+n,$ and letting $b$ be constant, this can only be true if $2m=m^2 \implies m=0,2.$ If $m=0,$ then $n=0,$ which implies $f(x)=0.$ However, the output is then not all integers, so this doesn't work. If $m=2,$ we have $f(x)=2x+n.$ Plugging this in works, so the answer is $f(x)=2x+c$ for some integer $c.$