Find $i\log(x-i)+i^2\pi+i^3\log(x+i)+i^4(2\arctan x)$, if $x>0$
The equation can be written as $$y=i\log(x-i)-\pi-i\log(x+i)+2\arctan x$$ $$y=i\log\frac{x-i}{x+i}-\pi+2\arctan x$$ Let $x+i=re^{i\theta}$ so $x-i=re^{-i\theta}$. $$y=i\log(e^{-2i\theta})-\pi+2\arctan x$$ $\theta=\arctan\frac{1}{x}=\cot^{-1}x$ $$y=2\cot^{-1}x-\pi+2\tan^{-1}x=2\cdot\frac{\pi}{2}-\pi=0$$
Is this correct?