# Calculate integral y = (tgx-1)/(sinx+cosx) times cos x, 0<x<pie/4

Since it is a definite integral, evaluate at 0 and `pi/4` to get `1/(ln(sin(pi/4)+cos(pi/4)))-1/(ln(sin(0)+cos(0)))=1/(ln(sqrt(2)))-1/ln(0)=1/(ln(sqrt(2)))~~-.34657`

Approved by eNotes Editorial Team

You need to evaluate the following indefinite integral, such that:

`int ((tan x - 1)*cos x)/(sin x + cos x) dx`

You need to re-write the integrand converting the tangent into the fraction `sin x/cos x` , such that:

`int ((sin x/cos x - 1)*cos x)/(sin x + cos x) dx`

You need to expand the numerator, such that:

`int (sin x/cos x*cos x - cos x)/(sin x + cos x) dx `

Reducing duplicate factors yields:

`int (sin x - cos x)/(sin x + cos x) dx `

You should come up with the following substitution, such that:

`sin x + cos x = t => (cos x - sin x)dx = dt => (sin x - cos x)dx = -dt`

Replacing the variable yields:

`int -dt/t = -ln|t| + c`

Replacing back `sin x + cos x` for t yields:

`int (sin x - cos x)/(sin x + cos x) dx = -ln|sin x + cos x| + c`

Since `x in (0,pi/4)` , hence `{(sin x>0),(cos x>0),(sin x + cos x>0):} => |sin x + cos x| = sin x + cos x` .

`int (sin x - cos x)/(sin x + cos x) dx = -ln(sin x + cos x) + c`

`int (sin x - cos x)/(sin x + cos x) dx = ln (sin x + cos x)^(-1) + c`

`int (sin x - cos x)/(sin x + cos x) dx = ln (1/(sin x + cos x)) + c`

Hence, evaluating the given indefinite integral, yields `int (sin x - cos x)/(sin x + cos x) dx = ln (1/(sin x + cos x)) + c.`

Approved by eNotes Editorial Team