<s>[INST] How do I show $\int_0^\infty \frac{x}{(x+1)^2}dx$ diverges I did $$\int_0^\infty \frac{x}{(x+1)^2}dx=\int_0^\infty \frac{1}{(x+2+\frac1x)}dx\le\int_0^\infty \frac{1}{x}dx$$ but $\int_0^\infty \frac{1}{x}dx$ diverges. So my logic fails.
 [/INST] Let $c$ be the upper limit of the integral and take the limit as $c$ goes to infinity.
$$I = \int_0^\infty \frac{x}{(x+1)^2}dx = \lim_{c \rightarrow \infty} \int_0^c \frac{x}{(x+1)^2}dx.$$
Then compute the definite integral as normal;
$$I = \lim_{c \rightarrow \infty}\int_0^c \frac{x}{(x+1)^2} = \lim_{c\rightarrow\infty}\left[\log(x + 1) - \frac{1}{x+1}\right]_0^c = 1 + \lim_{c \rightarrow \infty} \left(\log(c+1) - \frac{1}{c+1}\right).$$
The logarithm diverges as its argument gets arbitrarily large and the $\frac{1}{c+1}$ term vanishes. Hence,
$$\lim_{c \rightarrow \infty} \int_0^c \frac{x}{(x+1)^2}dx = \infty$$
and we conclude that $I$ diverges.
</s>