Class 12 Maths, Worked in Full Past papersGet updates
Chapter 7 · Integrals

Miscellaneous · Q29: ∫0π/4sin⁡x+cos⁡x9+16sin⁡2x dx\int_0^{\pi/4}\frac{\sin x+\cos x}{9+16\sin 2x}\,dx

Miscellaneous ExerciseDefinite integrals by substitution · Miscellaneous Exercise
The question

Evaluate the definite integral

∫0π/4sin⁡x+cos⁡x9+16sin⁡2x dx\int_0^{\pi/4} \frac{\sin x + \cos x}{9 + 16\sin 2x}\,dx
Exam answer

Let I=∫0π/4sin⁡x+cos⁡x9+16sin⁡2x dxI = \displaystyle\int_0^{\pi/4}\frac{\sin x + \cos x}{9 + 16\sin 2x}\,dx⁠.

Put sin⁡x−cos⁡x=t\sin x - \cos x = t⁠. Then (cos⁡x+sin⁡x) dx=dt(\cos x + \sin x)\,dx = dt⁠.

Also t2=1−2sin⁡xcos⁡xt^2 = 1 - 2\sin x\cos x =1−sin⁡2x= 1 - \sin 2x⁠, so

9+16sin⁡2x=9+16(1−t2)=25−16t2\begin{aligned} 9 + 16\sin 2x &= 9 + 16(1 - t^2) \\ &= 25 - 16t^2 \end{aligned}

When x=0x = 0⁠, t=−1t = -1⁠; when x=π4x = \frac{\pi}{4}⁠, t=0t = 0⁠.

Using ∫dta2−t2\displaystyle\int\frac{dt}{a^2 - t^2} =12alog⁡∣a+ta−t∣+C= \frac{1}{2a}\log\left|\frac{a + t}{a - t}\right| + C with a=54a = \frac54⁠,

I=∫−10dt25−16t2=116∫−10dt(54)2−t2=116⋅25[log⁡∣54+t54−t∣]−10=140[log⁡∣5+4t5−4t∣]−10=140(log⁡1−log⁡19)\begin{aligned} I &= \int_{-1}^0\frac{dt}{25 - 16t^2} \\ &= \frac{1}{16}\int_{-1}^0\frac{dt}{\left(\frac54\right)^2 - t^2} \\ &= \frac{1}{16}\cdot\frac25\left[\log\left|\frac{\frac54 + t}{\frac54 - t}\right|\right]_{-1}^0 \\ &= \frac{1}{40}\left[\log\left|\frac{5 + 4t}{5 - 4t}\right|\right]_{-1}^0 \\ &= \frac{1}{40}\left(\log 1 - \log\frac19\right) \end{aligned}

∴ I=140log⁡9\therefore\ I = \dfrac{1}{40}\log 9⁠.

Want the reason behind every step, the basics and the checks?

The one idea this problem is built on

As in Q27, the numerator sin⁡x+cos⁡x\sin x + \cos x is the derivative of t=sin⁡x−cos⁡xt = \sin x - \cos x⁠, and t2=1−sin⁡2xt^2 = 1 - \sin 2x⁠. So sin⁡2x=1−t2\sin 2x = 1 - t^2 and the denominator becomes 9+16(1−t2)=25−16t29 + 16(1 - t^2) = 25 - 16t^2⁠. That is a "constant minus a square", the shape of the special integral ∫dta2−t2\int\frac{dt}{a^2 - t^2} of Section 7.4.

Given, to find, and the plan
Given
I=∫0π/4sin⁡x+cos⁡x9+16sin⁡2x dxI = \displaystyle\int_0^{\pi/4} \frac{\sin x + \cos x}{9 + 16\sin 2x}\,dx⁠.
To find
The exact value of II⁠, and a decimal.
Plan
(1) Continuity on [0,π4][0, \frac{\pi}{4}]⁠. (2) Substitute t=sin⁡x−cos⁡xt = \sin x - \cos x and explain why. (3) Rewrite the denominator and change the limits. (4) Use formula 7.4 (2) with a=54a = \frac54⁠. (5) Check by differentiating. (6) Evaluate, simplify and give a decimal.

Basics you need

1(sin⁡x−cos⁡x)2=1−sin⁡2x(\sin x - \cos x)^2 = 1 - \sin 2x

Expand the square, use sin⁡2x+cos⁡2x=1\sin^2 x + \cos^2 x = 1 and 2sin⁡xcos⁡x=sin⁡2x2\sin x\cos x = \sin 2x⁠. Basics: trigonometric identities

2Substitution with changed limits (Section 7.9)

Put t=g(x)t = g(x)⁠, dt=g′(x) dxdt = g'(x)\,dx⁠, and use g(a)g(a)⁠, g(b)g(b) as the new limits. Basics: substitution

3Special integral 7.4 (2)

∫dta2−t2=12alog⁡∣a+ta−t∣+C\displaystyle\int\frac{dt}{a^2 - t^2} = \frac{1}{2a}\log\left|\frac{a + t}{a - t}\right| + C for t≠±at \ne \pm a⁠. It comes from partial fractions: 1a2−t2=12a(1a−t+1a+t)\frac{1}{a^2 - t^2} = \frac{1}{2a}\left(\frac{1}{a - t} + \frac{1}{a + t}\right)⁠. Lesson: integrals of particular functions

4Laws of logarithms

log⁡1=0\log 1 = 0 and log⁡1p=−log⁡p\log\frac1p = -\log p⁠. Basics: logarithms and 1/x

Solution

  1. The integrand is continuous on [0,π4][0, \frac{\pi}{4}]

    For 0≤x≤π40 \le x \le \frac{\pi}{4}⁠, 0≤2x≤π20 \le 2x \le \frac{\pi}{2}⁠, so 0≤sin⁡2x≤10 \le \sin 2x \le 1 and

    9≤9+16sin⁡2x≤25.9 \le 9 + 16\sin 2x \le 25 .

    The denominator is never zero, so the integrand is continuous on the closed interval.

    Theorem 2 of Section 7.8.3 needs continuity on [a,b][a, b]⁠. A denominator of the form 9+16sin⁡2x9 + 16\sin 2x would vanish where sin⁡2x=−916\sin 2x = -\frac{9}{16}⁠, but on our interval sin⁡2x\sin 2x is never negative.
  2. Substitute t=sin⁡x−cos⁡xt = \sin x - \cos x

    Then

    dt=(cos⁡x+sin⁡x) dx,dt = (\cos x + \sin x)\,dx ,

    which is exactly the numerator times dxdx⁠. Squaring,

    t2=sin⁡2x+cos⁡2x−2sin⁡xcos⁡x=1−sin⁡2x,\begin{aligned} t^2 &= \sin^2 x + \cos^2 x - 2\sin x\cos x \\ &= 1 - \sin 2x , \end{aligned}

    so sin⁡2x=1−t2\sin 2x = 1 - t^2⁠.

    We need a new variable whose differential is the numerator. sin⁡x−cos⁡x\sin x - \cos x is that variable. The choice t=sin⁡x+cos⁡xt = \sin x + \cos x also turns sin⁡2x\sin 2x into t2−1t^2 - 1⁠, but its differential is (cos⁡x−sin⁡x) dx(\cos x - \sin x)\,dx⁠, which is not in the integrand. So only t=sin⁡x−cos⁡xt = \sin x - \cos x fits.
    ddxsin⁡x=cos⁡x\frac{d}{dx}\sin x = \cos x⁠, ddx(−cos⁡x)=sin⁡x\frac{d}{dx}(-\cos x) = \sin x⁠. Basics: substitution
  3. Rewrite the denominator and change the limits

    9+16sin⁡2x=9+16(1−t2)=25−16t2.\begin{aligned} 9 + 16\sin 2x &= 9 + 16(1 - t^2) \\ &= 25 - 16t^2 . \end{aligned}

    Limits: at x=0x = 0⁠, t=0−1=−1t = 0 - 1 = -1⁠; at x=π4x = \frac{\pi}{4}⁠, t=12−12=0t = \frac{1}{\sqrt2} - \frac{1}{\sqrt2} = 0⁠. So

    I=∫−10dt25−16t2.I = \int_{-1}^{0}\frac{dt}{25 - 16t^2} .
    The substitution is valid on the whole interval: dtdx=sin⁡x+cos⁡x>0\frac{dt}{dx} = \sin x + \cos x > 0 for 0≤x≤π40 \le x \le \frac{\pi}{4} (since cos⁡x≥12\cos x \ge \frac{1}{\sqrt2} there), so tt runs steadily from −1-1 up to 0. On [−1,0][-1, 0]⁠, 25−16t225 - 16t^2 lies between 9 and 25, so the new integrand is continuous too.
    sin⁡π4=cos⁡π4=12\sin\frac{\pi}{4} = \cos\frac{\pi}{4} = \frac{1}{\sqrt2}⁠. Lesson: integration by substitution
  4. Bring it to the form 1a2−t2\frac{1}{a^2 - t^2} and integrate

    Take out the 16:

    125−16t2=116⋅1(54)2−t2.\frac{1}{25 - 16t^2} = \frac{1}{16}\cdot\frac{1}{\left(\frac54\right)^2 - t^2} .

    Formula 7.4 (2) with a=54a = \frac54⁠, so 12a=25\frac{1}{2a} = \frac25⁠:

    ∫dt25−16t2=116⋅25log⁡∣54+t54−t∣=140log⁡∣5+4t5−4t∣+C.\begin{aligned} \int\frac{dt}{25 - 16t^2} &= \frac{1}{16}\cdot\frac25\log\left|\frac{\frac54 + t}{\frac54 - t}\right| \\ &= \frac{1}{40}\log\left|\frac{5 + 4t}{5 - 4t}\right| + C . \end{aligned}
    Formula 7.4 (2) needs the coefficient of t2t^2 to be 1, so the 16 must come out first; then 25÷16=(54)225 \div 16 = \left(\frac54\right)^2 gives aa⁠. In the last line we multiplied the top and bottom of the fraction inside the log by 4, which does not change it. The two constants 116\frac{1}{16} and 25\frac25 multiply to 140\frac{1}{40}⁠.
  5. Check: differentiate the antiderivative

    Let G(t)=140(log⁡∣5+4t∣−log⁡∣5−4t∣)G(t) = \frac{1}{40}\big(\log|5 + 4t| - \log|5 - 4t|\big)⁠. Then

    G′(t)=140(45+4t+45−4t)=140⋅4(5−4t)+4(5+4t)25−16t2=140⋅4025−16t2=125−16t2 ✓\begin{aligned} G'(t) &= \frac{1}{40}\left(\frac{4}{5 + 4t} + \frac{4}{5 - 4t}\right) \\ &= \frac{1}{40}\cdot\frac{4(5 - 4t) + 4(5 + 4t)}{25 - 16t^2} \\ &= \frac{1}{40}\cdot\frac{40}{25 - 16t^2} = \frac{1}{25 - 16t^2} \ ✓ \end{aligned}

    valid for t≠±54t \ne \pm\frac54⁠. In terms of xx⁠, the chain rule multiplies by dtdx=sin⁡x+cos⁡x\frac{dt}{dx} = \sin x + \cos x⁠, and 25−16t2=9+16sin⁡2x25 - 16t^2 = 9 + 16\sin 2x⁠, which gives back the original integrand.

    The derivative of log⁡∣5−4t∣\log|5 - 4t| is −45−4t\frac{-4}{5 - 4t}⁠, and the minus sign in front of it turns that into +45−4t+\frac{4}{5 - 4t}⁠. Getting this sign right is what makes the two fractions add rather than cancel.
    ddtlog⁡∣u∣=u′u\frac{d}{dt}\log|u| = \frac{u'}{u}⁠. Basics: logarithms and 1/x
  6. Evaluate between t=−1t = -1 and t=0t = 0

    At t=0t = 0⁠: 140log⁡55=140log⁡1=0\frac{1}{40}\log\frac55 = \frac{1}{40}\log 1 = 0⁠.

    At t=−1t = -1⁠: 140log⁡∣5−45+4∣=140log⁡19=−140log⁡9\frac{1}{40}\log\left|\frac{5 - 4}{5 + 4}\right| = \frac{1}{40}\log\frac19 = -\frac{1}{40}\log 9⁠.

    I=0−(−140log⁡9)=140log⁡9.I = 0 - \left(-\frac{1}{40}\log 9\right) = \frac{1}{40}\log 9 .

    Since log⁡9=2log⁡3\log 9 = 2\log 3⁠, this is also 120log⁡3\frac{1}{20}\log 3⁠. As a decimal, I≈0.054931I \approx 0.054931⁠.

    Theorem 2: upper value minus lower value. Both values of 5+4t5−4t\frac{5 + 4t}{5 - 4t} are positive on [−1,0][-1, 0]⁠, so the absolute value bars change nothing. Size check: the integrand falls from 19≈0.111\frac19 \approx 0.111 at x=0x = 0 to 225≈0.057\frac{\sqrt2}{25} \approx 0.057 at x=π4x = \frac{\pi}{4}⁠, and the interval has length π4≈0.785\frac{\pi}{4} \approx 0.785⁠, so II lies between 0.057×0.785≈0.0440.057 \times 0.785 \approx 0.044 and 0.111×0.785≈0.0870.111 \times 0.785 \approx 0.087⁠. It does.
    log⁡1=0\log 1 = 0⁠, log⁡19=−log⁡9\log\frac19 = -\log 9⁠, log⁡9=log⁡32=2log⁡3\log 9 = \log 3^2 = 2\log 3⁠. Basics: logarithms
Result

∫0π/4sin⁡x+cos⁡x9+16sin⁡2x dx=140log⁡9=120log⁡3≈0.054931\begin{aligned} &\int_0^{\pi/4} \frac{\sin x + \cos x}{9 + 16\sin 2x}\,dx \\ &= \frac{1}{40}\log 9 = \frac{1}{20}\log 3 \\ &\approx 0.054931 \end{aligned} (Textbook answer: 140log⁡9\frac{1}{40}\log 9⁠.)

Check it with numbers

Numerical integration (adaptive quadrature) of the original integrand over [0,π4][0, \frac{\pi}{4}] gives 0.0549306144, and log⁡940\frac{\log 9}{40} ≈2.197224577340\approx \frac{2.1972245773}{40} ≈0.0549306144\approx 0.0549306144 ✓.

Spot check of the new denominator at x=π12x = \frac{\pi}{12}⁠: tt =sin⁡15∘−cos⁡15∘= \sin 15^\circ - \cos 15^\circ ≈0.2588190−0.9659258\approx 0.2588190 - 0.9659258 =−0.7071068= -0.7071068⁠. Exactly, t2=1−sin⁡30∘=12t^2 = 1 - \sin 30^\circ = \frac12 (and 0.70710682≈0.50.7071068^2 \approx 0.5⁠), so 25−16t2=25−8=1725 - 16t^2 = 25 - 8 = 17⁠, and 9+16sin⁡30∘=9+8=179 + 16\sin 30^\circ = 9 + 8 = 17 ✓.

Common mistakes
  1. Using t=sin⁡x+cos⁡xt = \sin x + \cos x⁠. Then 9+16sin⁡2x=16t2−79 + 16\sin 2x = 16t^2 - 7⁠, but the numerator is not dtdt⁠.
  2. Forgetting to factor out the 16 and using a=5a = 5⁠: that gives 110log⁡\frac{1}{10}\log of the wrong fraction.
  3. Mixing up formulas 7.4 (1) and (2). Here the square is subtracted from the constant (a2−t2a^2 - t^2⁠), so the fraction inside the log is a+ta−t\frac{a + t}{a - t}⁠.
  4. Swapping the limits: the lower limit x=0x = 0 gives t=−1t = -1⁠, the upper limit gives t=0t = 0⁠.
What to take away
  1. sin⁡x±cos⁡x\sin x \pm \cos x in the numerator with sin⁡2x\sin 2x in the denominator: substitute t=sin⁡x∓cos⁡xt = \sin x \mp \cos x⁠.
  2. After substituting, look at the shape: 1a2−t2\frac{1}{a^2 - t^2} is formula 7.4 (2); 1a2−t2\frac{1}{\sqrt{a^2 - t^2}} (as in Q27) is formula 7.4 (5).

Every fact used, and where it comes from

FactUsed inSource
A definite integral needs ff continuous on [a,b][a, b]Step 1Theorem 2 and Remark (iv), Section 7.8.3
(sin⁡x−cos⁡x)2=1−sin⁡2x(\sin x - \cos x)^2 = 1 - \sin 2xStep 2Trigonometric functions (Class XI)
Substitution with changed limitsSteps 2, 3Section 7.9 (Lesson: substitution)
∫dta2−t2=12alog⁡∣a+ta−t∣+C\int\frac{dt}{a^2 - t^2} = \frac{1}{2a}\log\left|\frac{a+t}{a-t}\right| + CStep 4Section 7.4, formula (2)
ddtlog⁡∣u∣=u′u\frac{d}{dt}\log|u| = \frac{u'}{u}Step 5Chapter 5, Section 5.4; standard formula (xii), Section 7.2
F(b)−F(a)F(b) - F(a)⁠; laws of logarithmsStep 6Theorem 2, Section 7.8.3
All decimalsStep 6, CheckRecomputed (mpmath quadrature, 30 digits) in the site's verification script
Found an error, or want more?

Tell us if something on this page is wrong or unclear, or if you would like a fuller explanation, another method or a new feature. Send feedback on this problem →