Solutions for the integral $\int\frac{e^x+e^{-x}}{e^x-e^{-x}}dx$

96 Views Asked by At

I have a quick question to do with a specific integral.

Does $$\int\frac{e^x+e^{-x}}{e^x-e^{-x}}dx$$ equal both

$\ln(e^{2x}-1)-x+c$

and

$\ln(1-e^{2x})-x+c$

If so, why? I know it has to do with natural logarithms but my mind is just blank today.

2

There are 2 best solutions below

3
On

The indefinite integral actually equals $$\ln \color{red} |e^{2x}-1\color{red} |-x+C=\begin{cases} \ln(e^{2x}-1) -x+C_1,& x\ge 0 \\ \ln(1-e^{2x})-x+C_2, & x\lt 0 \end{cases}$$

0
On

Note that the primitives of $\frac{1}{x}$ are given by $\ln|x|+C$. So you are only missing the absolute value.