# how to integrate (x-1)/(x+1)

I want to calculate the integral $$\int\frac{x-1}{x+1}\,\mathrm{d}x.$$ I have tried solving it by differentiating the denominator and substituting it, but I didn't get it. How else can I solve it?

• First, do the division. – David Mitra Aug 23 '15 at 12:13
• How do I do that? – High Zedd Aug 23 '15 at 12:15
• $$\frac{x-1}{x+1}=\frac{x}{x+1}-\frac{1}{x+1}$$ – ParaH2 Aug 23 '15 at 12:16
• @HighZedd $$\frac{x-1}{x+1} = \frac{x+1-2}{x+1} = 1-\frac2{x+1}$$ – peterwhy Aug 23 '15 at 12:16
• $\frac{x-1}{x+1}=\frac{x+1-2}{x+1}=1-\frac{2}{x+1}$ – Claude Leibovici Aug 23 '15 at 12:16

\begin{align*} \int\frac{x-1}{x+1}\ dx &= \int\frac{x+1-2}{x+1}\ dx\\ &= \int\left(1-\frac2{x+1}\right)\ dx\\ &= \int dx - 2\int\frac{dx}{x+1}\\ &= \cdots \end{align*}