# Thread: Explain the integral of tan...

1. ## Explain the integral of tan...

Hi

my book says the integral of tan x = ln |sec x|

When i do it:

tan x = sin x/cos x

integral sinx/cos x dx

let u = cos x
du = -sin x dx
- du = sin x dx

integral: -(1/u) du

= ln u = -ln cos x

but sec x = 1/cos x

...?

Edit:

Nvm figured it out -.-

- ln cos x = ln cos x^-1
= ln sec x

so they are equivalent....duh

2. There is nothing wrong with your mathematics, so your book must be wrong: integral tanx dx - Wolfram|Alpha

Looks like you are right.

3. The book is saying the same thing he is and the same thing Wolfram is:
$-ln|cos(x)|= ln|\frac{1}{cos(x)}|= ln|sec(x)|$
(Plus a constant, of course.)