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

Miscellaneous · Q36: ∫0π/42tan⁡3x dx=1−log⁡2\int_0^{\pi/4}2\tan^3x\,dx=1-\log 2

Miscellaneous ExerciseDefinite integrals with trigonometric identities · Miscellaneous Exercise
The question

Prove that

∫0π/42tan⁡3x dx=1−log⁡2\int_0^{\pi/4} 2\tan^3 x\,dx = 1 - \log 2
Exam answer

Let I=∫0π/42tan⁡3x dxI = \displaystyle\int_0^{\pi/4}2\tan^3 x\,dx⁠.

Using tan⁡2x=sec⁡2x−1\tan^2 x = \sec^2 x - 1⁠,

I=∫0π/42tan⁡x (sec⁡2x−1) dx=∫0π/42tan⁡xsec⁡2x dx−2∫0π/4tan⁡x dx=I1−I2\begin{aligned} I &= \int_0^{\pi/4}2\tan x\,(\sec^2 x - 1)\,dx \\ &= \int_0^{\pi/4}2\tan x\sec^2 x\,dx \\ &\quad - 2\int_0^{\pi/4}\tan x\,dx \\ &= I_1 - I_2 \end{aligned}

In I1I_1⁠, put tan⁡x=t\tan x = t⁠. Then sec⁡2x dx=dt\sec^2 x\,dx = dt⁠.

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

I1=∫012t dt=[t2]01=1I_1 = \int_0^1 2t\,dt = \Big[t^2\Big]_0^1 = 1

Using ∫tan⁡x dx=log⁡∣sec⁡x∣+C\displaystyle\int\tan x\,dx = \log|\sec x| + C⁠,

I2=2[log⁡∣sec⁡x∣]0π/4=2(log⁡2−log⁡1)=log⁡2\begin{aligned} I_2 &= 2\Big[\log|\sec x|\Big]_0^{\pi/4} \\ &= 2\left(\log\sqrt2 - \log 1\right) = \log 2 \end{aligned}

∴ I=1−log⁡2=RHS\therefore\ I = 1 - \log 2 = \text{RHS}⁠. Hence proved.

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

The one idea this problem is built on

Split off one tan⁡x\tan x and turn the remaining tan⁡2x\tan^2 x into sec⁡2x−1\sec^2 x - 1⁠:

tan⁡3x=tan⁡xsec⁡2x−tan⁡x.\tan^3 x = \tan x\sec^2 x - \tan x .

The first piece is "a function of tan⁡x\tan x times the derivative of tan⁡x\tan x", ready for the substitution t=tan⁡xt = \tan x⁠. The second piece is the known integral ∫tan⁡x dx=log⁡∣sec⁡x∣\int\tan x\,dx = \log|\sec x|⁠. The two pieces give the 1 and the log⁡2\log 2 of the claim.

Given, to show, and the plan
Given
I=∫0π/42tan⁡3x dxI = \displaystyle\int_0^{\pi/4} 2\tan^3 x\,dx⁠.
To show
I=1−log⁡2I = 1 - \log 2⁠.
Plan
(1) Continuity. (2) Rewrite tan⁡3x\tan^3 x with tan⁡2x=sec⁡2x−1\tan^2 x = \sec^2 x - 1⁠. (3) First piece by t=tan⁡xt = \tan x⁠. (4) Second piece by ∫tan⁡x dx=log⁡∣sec⁡x∣\int\tan x\,dx = \log|\sec x|⁠. (5) Combine; check the antiderivative by differentiating.

Basics you need

11+tan⁡2x=sec⁡2x1 + \tan^2 x = \sec^2 x

So tan⁡2x=sec⁡2x−1\tan^2 x = \sec^2 x - 1⁠. Basics: trigonometric identities

2ddxtan⁡x=sec⁡2x\frac{d}{dx}\tan x = \sec^2 x

So with t=tan⁡xt = \tan x⁠, dt=sec⁡2x dxdt = \sec^2 x\,dx⁠. Basics: substitution

3∫tan⁡x dx=log⁡∣sec⁡x∣+C\int\tan x\,dx = \log|\sec x| + C

Found in Section 7.3.1, (i), by writing tan⁡x=sin⁡xcos⁡x\tan x = \frac{\sin x}{\cos x} and putting t=cos⁡xt = \cos x⁠. Basics: logarithms and 1/x

4Values at π4\frac{\pi}{4}

tan⁡π4=1\tan\frac{\pi}{4} = 1⁠, sec⁡π4=2\sec\frac{\pi}{4} = \sqrt2⁠, and log⁡2=12log⁡2\log\sqrt2 = \frac12\log 2⁠. Basics: logarithms

Solution

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

    tan⁡x=sin⁡xcos⁡x\tan x = \frac{\sin x}{\cos x} is continuous wherever cos⁡x≠0\cos x \ne 0⁠. On [0,π4][0, \frac{\pi}{4}]⁠, cos⁡x≥12>0\cos x \ge \frac{1}{\sqrt2} > 0⁠, so tan⁡x\tan x⁠, and with it 2tan⁡3x2\tan^3 x⁠, is continuous on the closed interval.

    tan⁡x\tan x blows up at x=π2x = \frac{\pi}{2}⁠; our interval stops well before that. Continuity on [a,b][a, b] is what Theorem 2 of Section 7.8.3 needs.
  2. Rewrite tan⁡3x\tan^3 x

    2tan⁡3x=2tan⁡x⋅tan⁡2x=2tan⁡x (sec⁡2x−1)=2tan⁡xsec⁡2x−2tan⁡x.\begin{aligned} 2\tan^3 x &= 2\tan x\cdot\tan^2 x \\ &= 2\tan x\,(\sec^2 x - 1) \\ &= 2\tan x\sec^2 x - 2\tan x . \end{aligned}

    So

    I=∫0π/42tan⁡xsec⁡2x dx−∫0π/42tan⁡x dx.\begin{aligned} I &= \int_0^{\pi/4} 2\tan x\sec^2 x\,dx \\ &\quad - \int_0^{\pi/4} 2\tan x\,dx . \end{aligned}
    This is the same trick as for an odd power of sine (Q35): keep one factor aside and convert the even power with a Pythagorean identity. Here sec⁡2x\sec^2 x appears, which is exactly the derivative of tan⁡x\tan x⁠, so the first piece becomes a substitution. The split into two integrals uses the linearity of the integral.
    tan⁡2x=sec⁡2x−1\tan^2 x = \sec^2 x - 1⁠. Basics: trigonometric identities
  3. First piece: substitute t=tan⁡xt = \tan x

    Put t=tan⁡xt = \tan x⁠, dt=sec⁡2x dxdt = \sec^2 x\,dx⁠. At x=0x = 0⁠, t=0t = 0⁠; at x=π4x = \frac{\pi}{4}⁠, t=1t = 1⁠:

    ∫0π/42tan⁡xsec⁡2x dx=∫012t dt=[t2]01=1.\begin{aligned} \int_0^{\pi/4} 2\tan x\sec^2 x\,dx &= \int_0^1 2t\,dt \\ &= \Big[t^2\Big]_0^1 = 1 . \end{aligned}
    The substitution is valid on the whole interval: tan⁡x\tan x is differentiable and increasing on [0,π4][0, \frac{\pi}{4}] (its derivative sec⁡2x>0\sec^2 x > 0⁠), so it maps [0,π4][0, \frac{\pi}{4}] onto [0,1][0, 1] once.
    Section 7.9; power rule. Lesson: integration by substitution
  4. Second piece: ∫tan⁡x dx=log⁡∣sec⁡x∣\int\tan x\,dx = \log|\sec x|

    ∫0π/42tan⁡x dx=2[log⁡∣sec⁡x∣]0π/4=2(log⁡2−log⁡1)=2⋅12log⁡2=log⁡2.\begin{aligned} \int_0^{\pi/4} 2\tan x\,dx &= 2\Big[\log|\sec x|\Big]_0^{\pi/4} \\ &= 2\left(\log\sqrt2 - \log 1\right) \\ &= 2\cdot\tfrac12\log 2 = \log 2 . \end{aligned}
    sec⁡0=1\sec 0 = 1⁠, so log⁡sec⁡0=0\log\sec 0 = 0⁠; sec⁡π4=2\sec\frac{\pi}{4} = \sqrt2⁠, and log⁡2=log⁡21/2=12log⁡2\log\sqrt2 = \log 2^{1/2} = \frac12\log 2⁠. On [0,π4][0, \frac{\pi}{4}]⁠, sec⁡x≥1>0\sec x \ge 1 > 0⁠, so the absolute value bars change nothing.
    Section 7.3.1, (i): ∫tan⁡x dx=log⁡∣sec⁡x∣+C\int\tan x\,dx = \log|\sec x| + C⁠. Basics: logarithms and 1/x
  5. Combine, and check by differentiating

    I=1−log⁡2≈0.306853.I = 1 - \log 2 \approx 0.306853 .

    This is the required result. The antiderivative used is F(x)=tan⁡2x−2log⁡∣sec⁡x∣F(x) = \tan^2 x - 2\log|\sec x| (from t2t^2 with t=tan⁡xt = \tan x⁠, and 2log⁡∣sec⁡x∣2\log|\sec x|⁠). Differentiate:

    F′(x)=2tan⁡xsec⁡2x−2⋅sec⁡xtan⁡xsec⁡x=2tan⁡x (sec⁡2x−1)=2tan⁡3x ✓\begin{aligned} F'(x) &= 2\tan x\sec^2 x - 2\cdot\frac{\sec x\tan x}{\sec x} \\ &= 2\tan x\,(\sec^2 x - 1) = 2\tan^3 x \ ✓ \end{aligned}

    valid wherever cos⁡x≠0\cos x \ne 0⁠. Directly: F(π4)−F(0)F(\frac{\pi}{4}) - F(0) =(1−2log⁡2)−(0−0)= (1 - 2\log\sqrt2) - (0 - 0) =1−log⁡2= 1 - \log 2 ✓.

    The chain rule on log⁡∣sec⁡x∣\log|\sec x| gives sec⁡xtan⁡xsec⁡x=tan⁡x\frac{\sec x\tan x}{\sec x} = \tan x⁠. Another correct antiderivative is sec⁡2x−2log⁡∣sec⁡x∣\sec^2 x - 2\log|\sec x|⁠; it differs from FF by the constant 1 (because sec⁡2x=tan⁡2x+1\sec^2 x = \tan^2 x + 1⁠), and the constant cancels in F(b)−F(a)F(b) - F(a)⁠. Size check: 2tan⁡3x2\tan^3 x rises from 0 to 2 on an interval of length π4≈0.785\frac{\pi}{4} \approx 0.785⁠, staying small at first, so a value near 0.31 is reasonable.
Result

∫0π/42tan⁡3x dx=[tan⁡2x−2log⁡∣sec⁡x∣]0π/4=1−log⁡2≈0.306853,\begin{aligned} &\int_0^{\pi/4} 2\tan^3 x\,dx \\ &= \Big[\tan^2 x - 2\log|\sec x|\Big]_0^{\pi/4} \\ &= 1 - \log 2 \approx 0.306853, \end{aligned} as was to be proved.

Check it with numbers

Numerical integration (adaptive quadrature) of 2tan⁡3x2\tan^3 x over [0,π4][0, \frac{\pi}{4}] gives 0.3068528194, and 1−log⁡21 - \log 2 ≈1−0.6931471806\approx 1 - 0.6931471806 =0.3068528194= 0.3068528194 ✓.

The two pieces separately: ∫0π/42tan⁡xsec⁡2x dx\int_0^{\pi/4} 2\tan x\sec^2 x\,dx ≈1.0000000000\approx 1.0000000000 and ∫0π/42tan⁡x dx\int_0^{\pi/4} 2\tan x\,dx ≈0.6931471806\approx 0.6931471806⁠, which is log⁡2\log 2 to ten places ✓.

Common mistakes
  1. Writing ∫tan⁡3x dx=tan⁡4x4\int\tan^3 x\,dx = \frac{\tan^4 x}{4}⁠. That would need a factor sec⁡2x\sec^2 x⁠, which is only present after the rewrite.
  2. Using tan⁡2x=1−sec⁡2x\tan^2 x = 1 - \sec^2 x (wrong sign). The identity is sec⁡2x=1+tan⁡2x\sec^2 x = 1 + \tan^2 x⁠.
  3. ∫tan⁡x dx=sec⁡2x\int\tan x\,dx = \sec^2 x: that is the derivative, not the integral. The integral is log⁡∣sec⁡x∣\log|\sec x|⁠.
  4. Forgetting the factor 2 on the second piece, giving 1−12log⁡21 - \frac12\log 2⁠.
What to take away
  1. For tan⁡nx\tan^n x⁠: replace tan⁡2x\tan^2 x by sec⁡2x−1\sec^2 x - 1 to bring in sec⁡2x=ddxtan⁡x\sec^2 x = \frac{d}{dx}\tan x⁠.
  2. ∫tan⁡x dx=log⁡∣sec⁡x∣+C=−log⁡∣cos⁡x∣+C\int\tan x\,dx = \log|\sec x| + C = -\log|\cos x| + C is worth knowing by heart.

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
1+tan⁡2x=sec⁡2x1 + \tan^2 x = \sec^2 xStep 2Trigonometric functions (Class XI)
Linearity of the integralStep 2Properties (III), (IV), (V), Section 7.2.1
Substitution with changed limits; ddxtan⁡x=sec⁡2x\frac{d}{dx}\tan x = \sec^2 xStep 3Section 7.9; standard formula (iv), Section 7.2
∫tan⁡x dx=log⁡∣sec⁡x∣+C\int\tan x\,dx = \log|\sec x| + CStep 4Section 7.3.1, (i)
F(b)−F(a)F(b) - F(a)Steps 3–5Theorem 2, Section 7.8.3
All decimalsStep 5, 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 →