How to find constant $a$ and real function $f$ such that: $\Im f(a+ix)=\ln(x)$

72 Views Asked by At

I have a question. Given a real function $g(x)$, is it possible to find some constant $a$ and a real function $f$ such that

$$\Im f(a+ix)=g(x)$$ For example,

$$f(x)=e^x,~~~~\Im f(ix)=\Im e^{ix}=\sin x=g(x)$$

and

$$f(x)=\ln(1+x),~~~\Im f(ix)=\arctan x=g(x)$$

It seems this works because $\sin x$ and $\arctan x$ are odd functions, but I can't rigorously prove it.

If $g(x)$ is not an odd function, for example, $g(x)=\ln x$, is it possible to find a constant $a$ and a real function $f$ such that

$$\Im f(a+ix)=\ln x$$