# How do you find int sec^2x/(tan^2x - 3tanx + 2) dx using partial fractions?

Oct 29, 2015

$\ln | \frac{\tan x - 2}{\tan x - 1} | + C$

#### Explanation:

Factor the denominator

$\int \left({\sec}^{2} \frac{x}{\left(\tan x - 1\right) \left(\tan x - 2\right)}\right) \mathrm{dx}$

Perform a u-substitution

Let $u = \tan x$ then $\mathrm{du} = {\sec}^{2} x \mathrm{dx}$

Make the substitution into the integral

$\int \frac{1}{\left(u - 1\right) \left(u - 2\right)} \mathrm{du}$

Now we want to do partial fraction decomposition on this

$\frac{1}{\left(u - 1\right) \left(u - 2\right)} = \frac{A}{u - 1} + \frac{B}{u - 2}$

$1 = A \left(u - 2\right) + B \left(u - 1\right)$

$1 = A u - 2 A + B u - B$

$1 = u \left(A + B\right) - 2 A - B$

Equating coefficients

$A + B = 0$ and $- 2 A - B = 1$

Solving this system you get

$A = - 1$ and $B = 1$

Our integral becomes

$\int - \frac{1}{u - 1} + \frac{1}{u - 2} \mathrm{du}$

Rewrite

$\int \frac{1}{u - 2} - \frac{1}{u - 1} \mathrm{du}$

Integrating we get

$\ln | \tan x - 2 | - \ln | \tan x - 1 | + C$

Using properties of logarithms this can be rewritten as

$\ln | \frac{\tan x - 2}{\tan x - 1} | + C$