Class 12 Maths, Worked in Full Past papersGet updates
Chapter 5 · Continuity and Differentiability

Exercise 5.2 · Q4: Differentiate sec⁡(tan⁡x)\sec(\tan\sqrt x)

Exercise 5.2Chain rule with three links · Section 5.3.1
The question

Differentiate the function with respect to xx⁠:

sec⁡(tan⁡(x))\sec\left(\tan\left(\sqrt{x}\right)\right)
Exam answer

Let y=sec⁡(tan⁡x)y = \sec(\tan\sqrt x)⁠. Put u=xu = \sqrt x and v=tan⁡uv = \tan u⁠, so y=sec⁡vy = \sec v⁠.

dydv=sec⁡vtan⁡v,dvdu=sec⁡2u,dudx=12x\begin{aligned} \frac{dy}{dv} &= \sec v\tan v, \\ \frac{dv}{du} &= \sec^2 u, \\ \frac{du}{dx} &= \frac{1}{2\sqrt x} \end{aligned}

By the chain rule,

dydx=dydv⋅dvdu⋅dudx=sec⁡vtan⁡v⋅sec⁡2u⋅12x\begin{aligned} \frac{dy}{dx} &= \frac{dy}{dv}\cdot\frac{dv}{du}\cdot\frac{du}{dx} \\ &= \sec v\tan v\cdot\sec^2 u\cdot\frac{1}{2\sqrt x} \end{aligned}

∴ dydx=12xsec⁡(tan⁡x)\therefore\ \dfrac{dy}{dx} = \dfrac{1}{2\sqrt x}\sec(\tan\sqrt x) ⋅tan⁡(tan⁡x)sec⁡2x\cdot\tan(\tan\sqrt x)\sec^2\sqrt x (for x>0x > 0 in the domain).

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

The one idea this problem is built on

Three functions are stacked: square root, then tangent, then secant. The chain rule extends to any number of links: the overall rate is the product of the rates of all the links, each one evaluated at the value coming into it. So we name every link, differentiate each one, and multiply the three results.

Given, to find, and the plan
Given
y=sec⁡(tan⁡x)y = \sec(\tan\sqrt{x})⁠.
To find
dydx\dfrac{dy}{dx}⁠, and where the formula is valid.
Plan
Put u=xu = \sqrt{x}⁠, v=tan⁡uv = \tan u⁠, y=sec⁡vy = \sec v⁠. Find dudx\frac{du}{dx}⁠, dvdu\frac{dv}{du} and dydv\frac{dy}{dv} (deriving (sec⁡v)′(\sec v)' from the quotient rule), multiply, and substitute back.

Basics you need

1Chain rule for three functions

If yy depends on vv⁠, vv on uu⁠, and uu on xx⁠, then dydx=dydv⋅dvdu⋅dudx\dfrac{dy}{dx} = \dfrac{dy}{dv}\cdot\dfrac{dv}{du}\cdot\dfrac{du}{dx}⁠. The textbook states this extension right after Theorem 4 in Section 5.3.1. Lesson: the chain rule

2Power rule for x\sqrt{x}

x=x1/2\sqrt{x} = x^{1/2}⁠, so ddxx=12x−1/2=12x\frac{d}{dx}\sqrt{x} = \frac12 x^{-1/2} = \dfrac{1}{2\sqrt{x}} for x>0x > 0⁠. At x=0x = 0 this has a zero denominator: the graph of x\sqrt x starts with a vertical tangent there. Basics: derivative rules

3Secant and tangent

sec⁡v=1cos⁡v\sec v = \dfrac{1}{\cos v} and tan⁡v=sin⁡vcos⁡v\tan v = \dfrac{\sin v}{\cos v}⁠, both defined only where cos⁡v≠0\cos v \ne 0⁠. Also (tan⁡u)′=sec⁡2u(\tan u)' = \sec^2 u (Table 5.3). Basics: trigonometric identities

4Quotient rule

(pq)′=p′q−pq′q2\left(\dfrac{p}{q}\right)' = \dfrac{p'q - pq'}{q^2} wherever q≠0q \ne 0 (rule (3), Section 5.3). We use it to find the derivative of sec⁡\sec⁠, which is not in Table 5.3. Basics: derivative rules

Solution

  1. Where is the function defined?

    Working from the inside out:

    • x\sqrt{x} needs x≥0x \ge 0⁠.
    • tan⁡(x)\tan(\sqrt{x}) needs cos⁡x≠0\cos\sqrt{x} \ne 0⁠, that is x\sqrt{x} not an odd multiple of π2\frac{\pi}{2}⁠.
    • sec⁡(tan⁡x)\sec(\tan\sqrt{x}) needs cos⁡(tan⁡x)≠0\cos(\tan\sqrt{x}) \ne 0⁠, that is tan⁡x\tan\sqrt{x} not an odd multiple of π2\frac{\pi}{2}⁠.

    For example, the function is defined on 0≤x<1.0077…0 \le x < 1.0077\ldots⁠; the first excluded point is where tan⁡x=π2\tan\sqrt x = \frac{\pi}{2}⁠, that is x=tan⁡−1π2≈1.00388\sqrt{x} = \tan^{-1}\frac{\pi}{2} \approx 1.00388⁠, x≈1.00778x \approx 1.00778⁠.

    A derivative can only exist where the function itself is defined. Listing the conditions now tells us where the final formula is meaningful, and the same conditions will reappear as "denominator ≠0\ne 0" conditions in the derivative.
    sec⁡\sec and tan⁡\tan are undefined exactly where cosine is zero, at odd multiples of π2\frac{\pi}{2}⁠. Basics: trigonometric identities
  2. Name the three links

    u=x,v=tan⁡u,y=sec⁡v.u = \sqrt{x}, \qquad v = \tan u, \qquad y = \sec v.
    x u = √x v = tan u y = sec v square root du/dx = 1/(2√x) take tan dv/du = sec²u take sec dy/dv = sec v tan v overall rate dy/dx = product of the link rates
    Three machines in a row. The overall rate of change of yy with xx is the product of the three link rates, each evaluated at the value entering that link.
    On a calculator you would press  \sqrt{\ } first, then tan, then sec (that is, 1/cos⁡1/\cos⁠). The order in which the functions are applied gives the order of the links, innermost first.
    Composite of three functions. Basics: composite functions
  3. Derive ddv(sec⁡v)\frac{d}{dv}(\sec v) with the quotient rule

    Write sec⁡v=1cos⁡v\sec v = \dfrac{1}{\cos v}⁠, with numerator p=1p = 1 (p′=0p' = 0⁠) and denominator q=cos⁡vq = \cos v (q′=−sin⁡vq' = -\sin v⁠). Where cos⁡v≠0\cos v \ne 0⁠:

    ddv(sec⁡v)=0⋅cos⁡v−1⋅(−sin⁡v)cos⁡2v=sin⁡vcos⁡2v=1cos⁡v⋅sin⁡vcos⁡v=sec⁡v tan⁡v.\begin{aligned} \frac{d}{dv}(\sec v) &= \frac{0\cdot\cos v - 1\cdot(-\sin v)}{\cos^2 v} \\ &= \frac{\sin v}{\cos^2 v} = \frac{1}{\cos v}\cdot\frac{\sin v}{\cos v} \\ &= \sec v\,\tan v. \end{aligned}

    So dydv=sec⁡vtan⁡v\dfrac{dy}{dv} = \sec v\tan v⁠.

    Table 5.3 lists only xnx^n⁠, sin⁡\sin⁠, cos⁡\cos and tan⁡\tan⁠. Every other trigonometric derivative follows from these by the quotient rule, so we derive the one we need instead of quoting it from memory. Splitting sin⁡vcos⁡2v\frac{\sin v}{\cos^2 v} into two factors shows the familiar form sec⁡vtan⁡v\sec v\tan v⁠.
    Quotient rule (3), Section 5.3, valid where the denominator cos⁡v≠0\cos v \ne 0⁠. Basics: derivative rules
  4. The other two link rates

    dvdu=ddu(tan⁡u)=sec⁡2u,dudx=ddx x1/2=12x.\begin{aligned} \frac{dv}{du} &= \frac{d}{du}(\tan u) = \sec^2 u, \\ \frac{du}{dx} &= \frac{d}{dx}\,x^{1/2} = \frac{1}{2\sqrt{x}}. \end{aligned}

    The first holds wherever cos⁡u≠0\cos u \ne 0⁠; the second needs x>0x > 0⁠.

    (tan⁡u)′=sec⁡2u(\tan u)' = \sec^2 u is in Table 5.3. For the square root, the power rule with n=12n = \frac12 gives 12x−1/2\frac12 x^{-1/2}⁠, and x−1/2=1xx^{-1/2} = \frac{1}{\sqrt x}⁠. At x=0x = 0 this is not a real number, so x\sqrt x is not differentiable at 00 and the chain rule cannot be applied there.
    Power rule (xn)′=nxn−1(x^n)' = nx^{n-1}⁠, here with n=12n = \frac12 and x>0x > 0 (the textbook uses it this way in Example 39). Basics: derivative rules
  5. Multiply the three rates and substitute back

    dydx=dydv⋅dvdu⋅dudx=sec⁡vtan⁡v⋅sec⁡2u⋅12x.\begin{aligned} \frac{dy}{dx} &= \frac{dy}{dv}\cdot\frac{dv}{du}\cdot\frac{du}{dx} \\ &= \sec v\tan v\cdot\sec^2 u\cdot\frac{1}{2\sqrt{x}}. \end{aligned}

    Now put back u=xu = \sqrt{x} and v=tan⁡xv = \tan\sqrt{x}⁠:

    dydx=sec⁡(tan⁡x) tan⁡(tan⁡x) sec⁡2 ⁣x2x.\frac{dy}{dx} = \frac{\sec(\tan\sqrt{x})\,\tan(\tan\sqrt{x})\,\sec^2\!\sqrt{x}}{2\sqrt{x}}.
    Each rate is evaluated at the value entering its link: the secant link sees v=tan⁡xv = \tan\sqrt x⁠, so its rate is sec⁡(tan⁡x)tan⁡(tan⁡x)\sec(\tan\sqrt x)\tan(\tan\sqrt x)⁠; the tangent link sees u=xu = \sqrt x⁠, so its rate is sec⁡2x\sec^2\sqrt x⁠. That is why tan⁡\tan appears applied twice in the answer.
    Chain rule for three functions, Section 5.3.1 (after Theorem 4). Lesson: the chain rule
  6. State where the formula holds

    The formula is valid at every x>0x > 0 at which the function is defined (Step 1). At those points every link is differentiable, and every denominator in the answer is non-zero: x≠0\sqrt x \ne 0⁠, cos⁡x≠0\cos\sqrt x \ne 0⁠, cos⁡(tan⁡x)≠0\cos(\tan\sqrt x) \ne 0⁠.

    At x=0x = 0 the chain rule cannot be used, because the first link x\sqrt x has no derivative there. (Going deeper: the function still has a right-hand derivative at 00⁠, equal to 12\frac12⁠, because near 00 we have tan⁡(tan⁡x)≈x\tan(\tan\sqrt x)\approx\sqrt x and the formula tends to 12\frac12⁠. Proving that needs a separate limit argument, and the textbook's answer, like ours, is meant for x>0x > 0⁠.)
Result

For x>0x > 0 in the domain of the function,

ddxsec⁡(tan⁡x)=sec⁡(tan⁡x) tan⁡(tan⁡x) sec⁡2 ⁣x2x.\begin{aligned} &\frac{d}{dx}\sec(\tan\sqrt{x}) \\ &\quad= \frac{\sec(\tan\sqrt{x})\,\tan(\tan\sqrt{x})\,\sec^2\!\sqrt{x}}{2\sqrt{x}}. \end{aligned}

(Textbook answer: the same expression, printed as sec⁡(tan⁡x).tan⁡(tan⁡x).sec⁡2x\sec(\tan\sqrt x).\tan(\tan\sqrt x).\sec^2\sqrt x over 2x2\sqrt x⁠.)

Check it with numbers

Take x=0.5x = 0.5⁠. Then u=0.5≈0.7071068u = \sqrt{0.5} \approx 0.7071068 and v=tan⁡u≈0.8545104v = \tan u \approx 0.8545104⁠. The four factors are

sec⁡v≈1.5230255,tan⁡v≈1.1487413,sec⁡2u≈1.7301881,12x≈0.7071068,\begin{aligned} \sec v &\approx 1.5230255, & \tan v &\approx 1.1487413, \\ \sec^2 u &\approx 1.7301881, & \tfrac{1}{2\sqrt{x}} &\approx 0.7071068, \end{aligned}

and their product is about 2.1404632.140463⁠. A difference quotient of sec⁡(tan⁡x)\sec(\tan\sqrt x) with h=0.0001h = 0.0001 on each side of 0.50.5 gives 2.140462.14046⁠. They agree.

Common mistakes
  1. Stopping after two links. Writing sec⁡(tan⁡x)tan⁡(tan⁡x)sec⁡2x\sec(\tan\sqrt x)\tan(\tan\sqrt x)\sec^2\sqrt x forgets the innermost rate 12x\frac{1}{2\sqrt x}⁠.
  2. Evaluating a rate at the wrong value. The secant link's rate is sec⁡vtan⁡v\sec v\tan v with v=tan⁡xv = \tan\sqrt x⁠, not sec⁡xtan⁡x\sec x\tan x or sec⁡xtan⁡x\sec\sqrt x\tan\sqrt x⁠.
  3. Misremembering (sec⁡v)′(\sec v)'⁠. It is sec⁡vtan⁡v\sec v\tan v⁠, not sec⁡2v\sec^2 v (that is the derivative of tan⁡v\tan v⁠). Deriving it from 1cos⁡v\frac{1}{\cos v} settles any doubt.
  4. Ignoring x=0x = 0⁠. The formula has x\sqrt x in the denominator, so it says nothing at x=0x = 0⁠.
What to take away
  1. For a chain of any length, differentiate from the outside in, keeping each inner expression unchanged inside its outer derivative, and multiply all the factors.
  2. (sec⁡v)′=sec⁡vtan⁡v(\sec v)' = \sec v\tan v and (x)′=12x(\sqrt x)' = \frac{1}{2\sqrt x} (for x>0x > 0⁠) are worth knowing by heart, but both follow in one line from the basic rules.

Every fact used, and where it comes from

FactUsed inSource
sec⁡\sec⁠, tan⁡\tan defined where cos⁡≠0\cos \ne 0Step 1Definitions of sec and tan (Class XI)
Quotient ruleStep 3Rule (3), Section 5.3
(cos⁡v)′=−sin⁡v(\cos v)' = -\sin v⁠, (tan⁡u)′=sec⁡2u(\tan u)' = \sec^2 u⁠, (xn)′=nxn−1(x^n)' = nx^{n-1}Steps 3, 4Table 5.3, Section 5.3
Chain rule for three functionsStep 5Section 5.3.1, extension after Theorem 4 (Lesson: the chain rule)
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 →