TITLE: Why isn't $\int\sin(ix)~dx$ equal to $i\cos(ix)+C$ ?
QUESTION [7 upvotes]: I was playing around with imaginary numbers, and I tried to solve $$\int\sin(ix)~dx$$ and ended up getting  $$i\cos(ix)+C$$
But apparently the answer is $$i\cosh(x)+C$$
I was just wondering, is this correct? And what does the "$h$" stand for/mean? Where did it even come from. Thanks in advance.

REPLY [2 votes]: Using
$$
\sin(x)=\frac{e^{ix}-e^{-ix}}{2i}\quad\text{and}\quad\cos(x)=\frac{e^{ix}+e^{-ix}}{2}
$$
we have
$$
\cos(ix)=\cosh(x)\quad\text{and}\quad\sin(ix)=i\sinh(x)
$$
Thus,
$$
\begin{align}
\sin(x+iy)
&=\sin(x)\cos(iy)+\cos(x)\sin(iy)\\
&=\sin(x)\cosh(y)+i\cos(x)\sinh(y)\\
\end{align}
$$
and
$$
\begin{align}
\cos(x+iy)
&=\cos(x)\cos(iy)-\sin(x)\sin(iy)\\
&=\cos(x)\cosh(y)-i\sin(x)\sinh(y)\\
\end{align}
$$