# U-substitution check

• Apr 30th 2009, 12:23 PM
Fallen186
U-substitution check
Problem:
$\displaystyle \int\frac{sin(x)}{cos(x)}*dx$ from 0 to $\displaystyle \pi/4$

Attempt:
Quote:

$\displaystyle u = cos(x)$
$\displaystyle du = -sin(x) dx$
$\displaystyle dx = \frac{du}{-sin(x)}$

$\displaystyle \int\frac{sin(x)}{-sin(x)*u}*du$

$\displaystyle -\int\frac{du}{u}$

$\displaystyle -\int\frac{du}{u} = -ln|u|$

$\displaystyle -ln|cos(x)|$

$\displaystyle -ln|cos(\pi/4)| + ln|cos(0)|$

$\displaystyle -ln(\frac{\sqrt{2}}{2})$

$\displaystyle \frac{ln|2|}{2}$

Can someone tell me where I went wrong?
• Apr 30th 2009, 12:29 PM
redsoxfan325
You didn't do anything wrong. They're the same answer.

$\displaystyle -\ln\left|\frac{\sqrt{2}}{2}\right| = -\ln\left|\frac{1}{\sqrt{2}}\right| = -\ln\left|2^{-1/2}\right| = -\frac{1}{2}\cdot-\ln|2| = \frac{\ln|2|}{2}$
• Apr 30th 2009, 12:33 PM
derfleurer
Edit: Might as well have read the whole post. $\displaystyle -ln|\frac {\sqrt 2}{2}| = ln|\sqrt 2| = 1/2ln|2|$

$\displaystyle \int \frac{sinx}{cosx}dx$

u = cosx
du = -sinxdx

$\displaystyle \int \frac{du}{u} = ln|u|$

$\displaystyle -\int \frac{du}{u} = -ln|cosx|$