Integrate \((x - \frac{1}{x})^{2}\) with respect to x.

A.

\(\frac{1}{3}(x - \frac{1}{x})^{3} + c\)

B.

\(\frac{x^{3}}{3} - x\sqrt{\frac{1}{x^{3}}} + c\)

C.

\(\frac{x^{3}}{3} - 2x + \frac{1}{x^{3}} + c\)

D.

\(\frac{x^3}{3} - 2x - \frac{1}{x} + c\)

Correct answer is D

\((x - \frac{1}{x})^{2} = x^2 - 2 + \frac{1}{x^2}\)

\(\int (x^2 + \frac{1}{x^2} - 2) \mathrm {d} x\)

= \(\int (x^2 + x^{-2} - 2) \mathrm {d} x\)

= \(\frac{x^3}{3} - 2x - \frac{1}{x}\)