How to show that $f$ is an odd function?

An entire function $f$ takes real $z$ to real and purely imaginary to purely imaginary. We need to show that $f$ is an odd function. well, $f=\sum_{n=0}^{\infty}a_nz^n$ what I can say is $f(\mathbb{R})\subseteq\mathbb{R}$ and $f(\mathbb{iR})\subseteq\mathbb{iR}$

How to proceed, please give me hint.


Solution 1:

I am writing, enlarging and enhancing (hopefully...) Mex's answer to his own question (kudos!) and I'll be happy to erase this answer of mine if he decides to write down his.

We have that $$f(z)=\sum_{n=0}^\infty a_nz^n$$ because $\,f\,$ is entire, and by the given conditions we have$$(1)\,\,f(r)=\sum_{n=0}^\infty a_nr^n\in\mathbb{R}\,,\,\,\,r\in\mathbb{R}$$$$(2)\,\,f(ir)=\sum_{n=0}^\infty a_n(ir)^n\in i\mathbb{R}\,\,,\,\,r\in\mathbb{R}$$but we have that $$\sum_{n=0}^\infty a_n(ir)^n=\sum_{n=0}^\infty i^n (a_nr^n)=\sum_{n=0}^\infty (-1)^na_{2n}r^{2n}+i\sum_{n=0}^\infty (-1)^na_{2n+1}r^{2n+1} $$and as the above is purely imaginary we get that $\,a_{2n}=0\,,\,\forall n\in\mathbb{N}\,$ , so the power series of the function has zero coefficients for the even powers of $\,z\,$ and is thus a sum of odd powers and trivially then an odd function.