Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How do I compute the integral $$\int_0^{\pi/2} \cfrac 1 {12\cos x + 9 \sin x} dx?$$

Please can you help.

share|cite|improve this question
This isn't something you can break up into partial fractions (unless you can pull some chicanery that I'm not seeing). – Cameron Buie Oct 25 '12 at 17:11
It can be done with partial fractions. See my answer below. – Michael Hardy Oct 25 '12 at 18:05


Rewrite $12 \cos(x) + 9 \sin(x)$ as $$15 \left(\dfrac{12}{15} \cos(x) + \dfrac{9}{15} \sin(x) \right) = 15 \cos(x + \theta)$$ where $\tan(\theta) = - \dfrac9{12}$. (Note that $15 = \sqrt{9^2 + 12^2}$.) This is similar to the problem here.

share|cite|improve this answer

This is a solution from WolframAlpha, I still don't know if this kind of thing is allowed here on MSE.

The solution is indefinite, you can compute the definite integral after.

share|cite|improve this answer

If all else fails, the Weierstrass substitution will do it.

However, let's try something that begins with what Marvin suggested in his answer. First notice that $12^2+9^2=15^2$, so $\left(\frac{12}{15}\right)^2+\left(\frac{9}{15}\right)^2=1$. Hence we can find $\theta$ such that $\cos\theta=12/15$ and $\sin\theta=9/15$. Then $$ 12\cos x + 9\sin x = 15\left(\frac{12}{15}\cos x+\frac{9}{15}\sin x\right) = 15(\cos\theta\cos x + \sin\theta\sin x) = 15\cos(x-\theta). $$ Therefore $$ \int\frac{dx}{12\cos x+9\sin x} = \int \frac{dx}{15\cos(x-\theta)}= \int \frac{\cos(x-\theta)\,dx}{15(\cos(x-\theta))^2} = \frac{1}{15}\int \frac{\cos(x-\theta)\,dx}{1- (\sin(x-\theta))^2} $$ $$ = \frac{1}{15}\int \frac{du}{1-u^2} = \frac{1}{15}\int \frac{A}{1-u} + \frac{B}{1+u} \, du. $$ Then use partial fractions.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.