# Thread: Integration problem involving trig

1. ## Integration problem involving trig

The question:

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

My attempt:
Let $u = tanx$
$du = sec^2x dx$

$\int{u^{n-2} \ du}$

= $(n-2)u^{n-1}$
= $(n-2)tan^{n-1}x$

The answer in my text is:

$\frac{tan^{n-1}x}{n-1}$

Where have I gone wrong? Thanks.

2. $\int u^{n-2}du = \frac{u^{n-1}}{n-1}+C$

3. Oops! >_< Thanks.