# How do you integrate int xsec^2x by integration by parts method?

Aug 1, 2016

$x \tan x + \ln | \cos x | + C$

#### Explanation:

$\int x {\sec}^{2} x \mathrm{dx}$

Integration by parts: $\int f \left(x\right) g ' \left(x\right) \mathrm{dx} = f \left(x\right) g \left(x\right) - \int f ' \left(x\right) g \left(x\right) \mathrm{dx}$

In this example: $f \left(x\right) = x \to f ' \left(x\right) = 1$
and $g ' \left(x\right) = {\sec}^{2} x \to g \left(x\right) = \tan x$

Therefore: $\int x {\sec}^{2} x \mathrm{dx} = x \tan x - \int \left(1 \cdot \tan x\right) \mathrm{dx}$

$\int x {\sec}^{2} x \mathrm{dx} = x \tan x - \int \tan x \mathrm{dx}$

$= x \tan x + \ln | \cos x | + C$ (Standard integral)