The Problem is: Find all possible functions $f : \Bbb R \to \Bbb R$ such that $f$ is infinitely differentiable on $\Bbb R$ and $f$ satisfies an equation: $$ f(y+x)-f(y-x)= 2xf'(y) \text{ for all } x,y\in\Bbb R \text.$$
My attempt: Then, obviously $ f(b) - f(a) = (b-a) f'\left(\frac{a+b}2\right)$ for all $a,b$ and we know that: $$f''(x) = \lim_{h \to 0} \frac{f(c+h) + f(c-h)-2f(c)}{h^2}$$
The answer provided is that $f$ must be polynomial of order at most $2$, then I tried putting values of $f(c+h)$ in the above limit but after that I can't approach properly.
We need only assume that $f$ is once differentiable and the existence of higher derivatives follows because with $x=\frac12$, $$f'(y)=f(y+\tfrac12)-f(y-\tfrac12) $$ and the right hand side is differentiable so that by induction $$f^{(n+1)}(x)=f^{(n)}(x+\tfrac12)- f^{(n)}(x-\tfrac12).$$
By differentiating the functional equation with respect to $x$, we find $$ f'(y+x)+f'(y-x)=2f'(y)$$ and hence if we fix $\epsilon>0$ and let $g(y):=f'(y)-f'(y-\epsilon)$, we have $$ g(y+\epsilon)=g(y).$$ So $g$ is periodic with period $\epsilon$, and is smooth, hence attains local extrema inside each interval of length $>\epsilon$, hence $g'$ has zeroes in such intervals, i.e., $f''$ has equal values a distinct points, and finally by Rolle, $f'''$ has a root in each interval of length $>\epsilon$. As $\epsilon$ was arbitrary, the roots of $f'''$ are dense in $\Bbb R$, and as $f'''$ is continuous, it follows that $f'''$ is identically zero.