[Math] How to integrate $\int e^x \cot(x)dx$

integrationsubstitution

I originally was to evaluate
$$
\int \frac{e^{\arctan\left(\sqrt{x}\right)}}{\sqrt{x}+x\sqrt{x}} \ dx
$$

So i took $t = \arctan \sqrt{x}$ and then, $\frac1{1+x} = \frac{dt}{dx}$ and $\tan t= \sqrt x$. I plugged this in and ended up with the following integral
$$
\int e^x\cot x\,dx
$$

I tried integration by parts, but couldn't make it work.

I'm only an undergrad. Could you please suggest a method which I can use?

Best Answer

Your calculation is wrong. The integral of $e^x\cdot\cot(x)dx$ is not elementary.

But, the integral you started does have an antiderivative.

$$\frac d{dx}(\arctan(\sqrt x))=\frac12\cdot\frac1{x^{\frac12}+ x^{\frac32}}.$$

So when $t=\arctan(\sqrt x)$, the integral becomes $2e^t dt$, so the final antiderivative is $$2e^t+C=2e^{\arctan(\sqrt x)} + C.$$