# Homework Help: Integrate 1/(sin(x)+a) dx

1. Jul 15, 2013

### msbell1

1. The problem statement, all variables and given/known data
Integrate ∫dx/(sin(x)+a), where a is a constant.

2. Relevant equations

3. The attempt at a solution
I have been working on this for a while, and for some reason I can't figure it out. The attempt that seemed the most promising to me was to multiply top and bottom by (sin(x)-a), which gave
∫(sin(x)-a)/(sin2(x)-a2) dx.
I could integrate the first term (∫sin(x)/(sin2(x)-a2)dx) by substituting 1-cos2(x) for sin2x, and then using partial fractions. However, the second term (-∫a/(sin2(x)-a2)dx) is causing me some trouble. Actually, with the second term, I again used partial fractions, but then I end up with (sin(x) +/- a) in the denominator, which ends up looking about the same as what I started with. Is there a substitution that would make this problem simple? Thanks.

2. Jul 15, 2013

### ehild

The integrand is a rational function of sin(x): rewrite it in terms of tan(x/2) and use the substitution tan(x/2)=t.
(sin(x)=2tan(x/2)/(1+tan2(x/2), cos(x)=(1-tan2(x/2)/(1+tan2(x/2). )

ehild