Lecture 8: Differentiation using First Principles and Basic Rules

Differentiation Using First Principles and Limit Processes

  • Introduction to Limit Processes:

    • Let y=f(x)y = f(x) be a real-valued and continuous function.

    • The function must be defined at the point x=x0x = x_0.

    • The slope of the function at x=x0x = x_0 is defined by using a limit process.

  • Geometrical Interpretation:

    • Consider the graph of y=f(x)y = f(x) with points P(x0,f(x0))P(x_0, f(x_0)) and Q(x0+h,f(x0+h))Q(x_0 + h, f(x_0 + h)).

    • The line connecting PP and QQ is the Secant Line.

    • The slope of the secant line (msecm_{sec}) is given by the formula:       msec=f(x0+h)−f(x0)hm_{sec} = \frac{f(x_0 + h) - f(x_0)}{h}

    • In this context, hh represents the change in xx (Δx\Delta x), notably x−x0=h=Δxx - x_0 = h = \Delta x.

    • As point QQ moves towards point PP along the graph, the distance hh becomes smaller and smaller (h→0h \rightarrow 0).

    • The secant line gradually limitingly becomes the Tangent Line to the graph at point PP.

    • The limiting value of the secant slope as h→0h \rightarrow 0 is defined as the derivative of y=f(x)y = f(x) at x=x0x = x_0.

Formal Definitions and Notations of the Derivative

  • Notations:

    • The derivative at a point x0x_0 can be denoted by:

      • f′(x0)f'(x_0)

      • dydx(x0)\frac{dy}{dx}(x_0)

      • y′(x0)y'(x_0)

      • Dxf(x0)D_x f(x_0)

  • Mathematical Formulas:

    • f′(x0)=lim⁡x→x0f(x)−f(x0)x−x0f'(x_0) = \lim_{x \rightarrow x_0} \frac{f(x) - f(x_0)}{x - x_0}

    • Alternatively: f′(x0)=lim⁡h→0f(x0+h)−f(x0)hf'(x_0) = \lim_{h \rightarrow 0} \frac{f(x_0 + h) - f(x_0)}{h}

  • Interpretations of f′(x0)f'(x_0):

    • (i) The slope of the tangent line to y=f(x)y = f(x) at x=x0x = x_0.

    • (ii) The slope of the function at the specific point x=x0x = x_0.

  • General Derivative:

    • If the derivative is desired at any arbitrary point xx within the domain of f(x)f(x), the following limit process is used:       f′(x)=lim⁡h→0f(x+h)−f(x)hf'(x) = \lim_{h \rightarrow 0} \frac{f(x + h) - f(x)}{h}

Worked Examples: Limit Processes for finding Slopes and Equations

  • Example 1: Quadratic Function:

    • Let y=x2+9y = x^2 + 9.

    • (i) Find f′(2)f'(2) using method 1:

      • f(2)=22+9=13f(2) = 2^2 + 9 = 13

      • f′(2)=lim⁡x→2(x2+9)−13x−2=lim⁡x→2x2−4x−2f'(2) = \lim_{x \rightarrow 2} \frac{(x^2 + 9) - 13}{x - 2} = \lim_{x \rightarrow 2} \frac{x^2 - 4}{x - 2}

      • Using factorization: lim⁡x→2(x−2)(x+2)x−2=lim⁡x→2(x+2)=4\lim_{x \rightarrow 2} \frac{(x - 2)(x + 2)}{x - 2} = \lim_{x \rightarrow 2} (x + 2) = 4

    • (ii) Find f′(2)f'(2) using method 2 (h→0h \rightarrow 0):

      • f(2+h)=(2+h)2+9=4+4h+h2+9=13+4h+h2f(2 + h) = (2 + h)^2 + 9 = 4 + 4h + h^2 + 9 = 13 + 4h + h^2

      • f′(2)=lim⁡h→0(13+4h+h2)−13h=lim⁡h→04h+h2h=lim⁡h→0(4+h)=4f'(2) = \lim_{h \rightarrow 0} \frac{(13 + 4h + h^2) - 13}{h} = \lim_{h \rightarrow 0} \frac{4h + h^2}{h} = \lim_{h \rightarrow 0} (4 + h) = 4

    • (iii) Equation of the tangent line at x=2x = 2:

      • Point: (2,13)(2, 13). Slope: m=4m = 4.

      • Using y−y1=m(x−x1)y - y_1 = m(x - x_1): y−13=4(x−2)→y−13=4x−8→y=4x+5y - 13 = 4(x - 2) \rightarrow y - 13 = 4x - 8 \rightarrow y = 4x + 5.

  • Example 2: Reciprocal Function:

    • Let f(x)=1xf(x) = \frac{1}{x} for x≠0x \neq 0.

    • Step 1: Compute f′(x)f'(x):

      • f′(x)=lim⁡h→01x+h−1xh=lim⁡h→0x−(x+h)x(x+h)hf'(x) = \lim_{h \rightarrow 0} \frac{\frac{1}{x+h} - \frac{1}{x}}{h} = \lim_{h \rightarrow 0} \frac{\frac{x - (x + h)}{x(x + h)}}{h}

      • f′(x)=lim⁡h→0−hh⋅x(x+h)=lim⁡h→0−1x(x+h)=−1x2f'(x) = \lim_{h \rightarrow 0} \frac{-h}{h \cdot x(x + h)} = \lim_{h \rightarrow 0} \frac{-1}{x(x + h)} = -\frac{1}{x^2}

    • Step 2: Evaluate f′(1)f'(1):

      • f′(1)=−112=−1f'(1) = -\frac{1}{1^2} = -1

    • Step 3: Equation of tangent at (1,1)(1, 1):

      • Point: (1,1)(1, 1). Slope: m=−1m = -1.

      • y−1=−1(x−1)→y=−x+2y - 1 = -1(x - 1) \rightarrow y = -x + 2.

  • Example 3: General Quadratic Polynomial:

    • Let y=2+3x−3x2y = 2 + 3x - 3x^2. Find f′(2)f'(2).

    • f(2)=2+3(2)−3(2)2=8−12=−4f(2) = 2 + 3(2) - 3(2)^2 = 8 - 12 = -4

    • f(2+h)=2+3(2+h)−3(2+h)2=2+6+3h−3(4+4h+h2)f(2 + h) = 2 + 3(2 + h) - 3(2 + h)^2 = 2 + 6 + 3h - 3(4 + 4h + h^2)

    • f(2+h)=8+3h−12−12h−3h2=−4−9h−3h2f(2 + h) = 8 + 3h - 12 - 12h - 3h^2 = -4 - 9h - 3h^2

    • f′(2)=lim⁡h→0(−4−9h−3h2)−(−4)h=lim⁡h→0−9h−3h2h=lim⁡h→0(−9−3h)=−9f'(2) = \lim_{h \rightarrow 0} \frac{(-4 - 9h - 3h^2) - (-4)}{h} = \lim_{h \rightarrow 0} \frac{-9h - 3h^2}{h} = \lim_{h \rightarrow 0} (-9 - 3h) = -9

  • Example 4: Square Root Function:

    • Let f(x)=xf(x) = \sqrt{x} for x>0x > 0.

    • Find f′(x)f'(x) using colonization/rationalization:

      • f′(x)=lim⁡h→0x+h−xhf'(x) = \lim_{h \rightarrow 0} \frac{\sqrt{x + h} - \sqrt{x}}{h}

      • Multiply by the conjugate: x+h−xh⋅x+h+xx+h+x=(x+h)−xh(x+h+x)\frac{\sqrt{x + h} - \sqrt{x}}{h} \cdot \frac{\sqrt{x + h} + \sqrt{x}}{\sqrt{x + h} + \sqrt{x}} = \frac{(x + h) - x}{h(\sqrt{x + h} + \sqrt{x})}

      • f′(x)=lim⁡h→0hh(x+h+x)=lim⁡h→01x+h+x=12xf'(x) = \lim_{h \rightarrow 0} \frac{h}{h(\sqrt{x + h} + \sqrt{x})} = \lim_{h \rightarrow 0} \frac{1}{\sqrt{x + h} + \sqrt{x}} = \frac{1}{2\sqrt{x}}

Tangent Lines and Normal Lines

  • Definitions:

    • Tangent Line: A line that touches the curve at a specific point x=x0x = x_0.

    • Normal Line: A line drawn perpendicular to the tangent line at the same point x=x0x = x_0.

  • Slopes:

    • Slope of tangent line at x0x_0 is mt=f′(x0)m_t = f'(x_0).

    • Slope of normal line at x0x_0 is the negative reciprocal: mn=−1f′(x0)m_n = -\frac{1}{f'(x_0)}.

  • Equations:

    • Tangent Line Equation at (x0,y0)(x_0, y_0):       y−y0=f′(x0)(x−x0)y - y_0 = f'(x_0)(x - x_0)

    • Normal Line Equation at (x0,y0)(x_0, y_0):       y−y0=−1f′(x0)(x−x0)y - y_0 = -\frac{1}{f'(x_0)}(x - x_0), provided f′(x0)≠0f'(x_0) \neq 0

Rules of Differentiation for Monomials and Constants

  • Constant Function Rule:

    • If f(x)=cf(x) = c (where cc is a constant), then f′(x)=0f'(x) = 0.

    • The slope of a constant horizontal line is zero at any point.

  • Power Rule for Differentiation:

    • If f(x)=xnf(x) = x^n, where n∈Rn \in \mathbb{R}, then:       f′(x)=nxn−1f'(x) = nx^{n-1}

    • Derivation of the Power Rule:

      • Expand (x+h)n(x + h)^n using the Binomial Theorem:         (x+h)n=(n0)xn+(n1)xn−1h+(n2)xn−2h2+...+hn(x + h)^n = \binom{n}{0}x^n + \binom{n}{1}x^{n-1}h + \binom{n}{2}x^{n-2}h^2 + ... + h^n

      • (x+h)n=xn+nxn−1h+n(n−1)2!xn−2h2+...+hn(x + h)^n = x^n + nx^{n-1}h + \frac{n(n-1)}{2!}x^{n-2}h^2 + ... + h^n

      • Subtracting xnx^n and dividing by hh:         (x+h)n−xnh=nxn−1+n(n−1)2!xn−2h+...+hn−1\frac{(x+h)^n - x^n}{h} = nx^{n-1} + \frac{n(n-1)}{2!}x^{n-2}h + ... + h^{n-1}

      • Taking the limit as h→0h \rightarrow 0, all terms with hh vanish, leaving:         f′(x)=nxn−1f'(x) = nx^{n-1}

  • Monomial Examples:

    • If f(x)=5f(x) = 5, then f′(x)=0f'(x) = 0.

    • If f(x)=πf(x) = \pi, then f′(x)=0f'(x) = 0.

    • If f(x)=−15f(x) = -15, then Dx(−15)=0D_x(-15) = 0.

    • If f(x)=x3f(x) = x^3, then f′(x)=3x2f'(x) = 3x^2.

    • If f(x)=xf(x) = x, then f′(x)=1x0=1f'(x) = 1x^0 = 1.

    • If f(x)=x−4f(x) = x^{-4}, then f′(x)=−4x−5f'(x) = -4x^{-5}.

    • If f(x)=x=x12f(x) = \sqrt{x} = x^{\frac{1}{2}}, then f′(x)=12x−12f'(x) = \frac{1}{2}x^{-\frac{1}{2}}.

General Power Rules for Differentiation

  • Summary of Power Laws:

    • 1. f(x)=xn⇒f′(x)=nxn−1f(x) = x^n \Rightarrow f'(x) = nx^{n-1}

    • 2. f(x)=cxn⇒f′(x)=cnxn−1f(x) = cx^n \Rightarrow f'(x) = cnx^{n-1}

    • 3. f(x)=x−n⇒f′(x)=−nx−n−1f(x) = x^{-n} \Rightarrow f'(x) = -nx^{-n-1}

    • 4. f(x)=1x⇒f′(x)=−1x2f(x) = \frac{1}{x} \Rightarrow f'(x) = -\frac{1}{x^2}

    • 5. f(x)=xnm=xnm⇒f′(x)=nmxnm−1f(x) = \sqrt[m]{x^n} = x^{\frac{n}{m}} \Rightarrow f'(x) = \frac{n}{m}x^{\frac{n}{m} - 1}

  • Worked Power Rule Applications:

    • Let f(x)=3x4f(x) = \frac{3}{x^4}. Rewrite as 3x−43x^{-4}. f′(x)=3(−4)x−5=−12x−5f'(x) = 3(-4)x^{-5} = -12x^{-5}.

    • Let f(x)=4x5f(x) = \frac{4}{x^5}. Rewrite as 4x−54x^{-5}. f′(x)=4(−5)x−6=−20x−6f'(x) = 4(-5)x^{-6} = -20x^{-6}.

    • Let f(x)=x23f(x) = \sqrt[3]{x^2}. Rewrite as x23x^{\frac{2}{3}}. Thus for 6x236\sqrt[3]{x^2}, f′(x)=6(23)x−13=4x−13f'(x) = 6(\frac{2}{3})x^{-\frac{1}{3}} = 4x^{-\frac{1}{3}}.

Differentiation of Polynomials

  • Formula:

    • Let f(x)=anxn+...+a2x2+a1x+a0f(x) = a_n x^n + ... + a_2 x^2 + a_1 x + a_0.

    • Then f′(x)=an(nxn−1)+...+a2(2x)+a1(1)+0f'(x) = a_n(nx^{n-1}) + ... + a_2(2x) + a_1(1) + 0.

  • Examples:

    • (i) f(b)=b3+4b+8⇒f′(b)=3b2+4f(b) = b^3 + 4b + 8 \Rightarrow f'(b) = 3b^2 + 4.

    • (ii) f(x)=5x3+4x2−3x+10⇒f′(x)=15x2+8x−3f(x) = 5x^3 + 4x^2 - 3x + 10 \Rightarrow f'(x) = 15x^2 + 8x - 3.

    • (iii) f(b)=6b3−4b2+21⇒f′(b)=18b2−8bf(b) = 6b^3 - 4b^2 + 21 \Rightarrow f'(b) = 18b^2 - 8b.

Differentiation of Exponential Functions

  • Basic Rules:

    • If y=exy = e^x, then dydx=ex\frac{dy}{dx} = e^x.

    • If y=e−xy = e^{-x}, then dydx=−e−x\frac{dy}{dx} = -e^{-x}.

    • e≈2.71828e \approx 2.71828 and ln⁡(e)=1\ln(e) = 1.

  • General Exponential Rule:

    • If y=axy = a^x (where aa is a positive constant), then:       y′=axln⁡(a)y' = a^x \ln(a)

    • Example: y=5x⇒y′=5xln⁡(5)y = 5^x \Rightarrow y' = 5^x \ln(5).

  • Generalized Rules (Chain Rule Extension):

    • (i) If y=au(x)y = a^{u(x)}, then y′=au(x)⋅u′(x)⋅ln⁡(a)y' = a^{u(x)} \cdot u'(x) \cdot \ln(a).

    • (ii) If y=eu(x)y = e^{u(x)}, then y′=eu(x)⋅u′(x)y' = e^{u(x)} \cdot u'(x).

    • (iii) If y=[u(x)]v(x)y = [u(x)]^{v(x)}, then:       f′(x)=[u(x)]v(x)[v′(x)ln⁡u(x)+v(x)u′(x)u(x)]f'(x) = [u(x)]^{v(x)} [v'(x) \ln u(x) + v(x) \frac{u'(x)}{u(x)}]

  • Worked Examples:

    • 1. f(t)=et2f(t) = e^{t^2}. Let u(t)=t2u(t) = t^2, u′(t)=2tu'(t) = 2t. Result: f′(t)=2tet2f'(t) = 2te^{t^2}.

    • 2. f(t)=5t3f(t) = 5^{t^3}. u(t)=t3u(t) = t^3, u′(t)=3t2u'(t) = 3t^2. Result: f′(t)=3t2⋅5t3⋅ln⁡(5)f'(t) = 3t^2 \cdot 5^{t^3} \cdot \ln(5).

    • 3. f(x)=xx2f(x) = x^{x^2}. u(x)=xu(x) = x, v(x)=x2v(x) = x^2. Result: f′(x)=xx2[2xln⁡(x)+x2⋅1x]=xx2[2xln⁡(x)+x]f'(x) = x^{x^2} [2x \ln(x) + x^2 \cdot \frac{1}{x}] = x^{x^2} [2x \ln(x) + x].

Differentiation of Logarithmic Functions

  • Basic Forms (Base ee):

    • If y=ln⁡(x)y = \ln(x), then y′=1xy' = \frac{1}{x}.

  • Arbitrary Base (base abase \, a):

    • If f(x)=log⁡a(x)f(x) = \log_a(x), where a≠1a \neq 1, then f′(x)=1xln⁡(a)f'(x) = \frac{1}{x \ln(a)}.

  • General Forms (Chain Rule Extension):

    • (i) If y=ln⁡u(x)y = \ln u(x), then y′=u′(x)u(x)y' = \frac{u'(x)}{u(x)}.

    • (ii) If y=log⁡au(x)y = \log_a u(x), then y′=u′(x)u(x)ln⁡(a)y' = \frac{u'(x)}{u(x) \ln(a)}.

  • Worked Examples:

    • 1. f(x)=log⁡2(x2+2x+1)f(x) = \log_2(x^2 + 2x + 1). u(x)=x2+2x+1u(x) = x^2 + 2x + 1, u′(x)=2x+2u'(x) = 2x + 2.       Result: f′(x)=2x+2(x2+2x+1)ln⁡(2)f'(x) = \frac{2x + 2}{(x^2 + 2x + 1) \ln(2)}.

    • 2. f(x)=ln⁡(x2+2x+1)f(x) = \ln(x^2 + 2x + 1).       Result: f′(x)=2x+2x2+2x+1f'(x) = \frac{2x + 2}{x^2 + 2x + 1}.

Existence Conditions for the Derivative

  • Main Conditions for f′(x0)f'(x_0) to exist:

    • (i) x0x_0 must be in the domain of f(x)f(x). (Function defined at x0x_0).

    • (ii) f(x)f(x) is continuous at x=x0x = x_0. lim⁡x→x0−f(x)=lim⁡x→x0+f(x)=f(x0)\lim_{x \rightarrow x_0^-} f(x) = \lim_{x \rightarrow x_0^+} f(x) = f(x_0).

    • (iii) The graph of y=f(x)y = f(x) has no sharp edges, kinks, or cusps at x=x0x = x_0.

    • (iv) There is No vertical tangent at x=x0x = x_0.

    • (v) There is No vertical asymptote at x=x0x = x_0.

  • Examples where the derivative does not exist (DNE):

    • At holes/discontinuities where x0x_0 is not defined.

    • At points of jump discontinuity.

    • At a cusp or sharp corner/edge.

    • At points with a vertical tangent.

    • At points with a vertical asymptote.

Differentiation of Trigonometric Functions

  • Basic Formulas:

    • ddxsin⁡(x)=cos⁡(x)\frac{d}{dx} \sin(x) = \cos(x)

    • ddxcos⁡(x)=−sin⁡(x)\frac{d}{dx} \cos(x) = -\sin(x)

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

    • ddxsec⁡(x)=sec⁡(x)tan⁡(x)\frac{d}{dx} \sec(x) = \sec(x) \tan(x)

  • Generalized Formulas (Chain Rule):

    • (i) ddxsin⁡(u(x))=cos⁡(u(x))⋅u′(x)\frac{d}{dx} \sin(u(x)) = \cos(u(x)) \cdot u'(x)

    • (ii) ddxcos⁡(u(x))=−sin⁡(u(x))⋅u′(x)\frac{d}{dx} \cos(u(x)) = -\sin(u(x)) \cdot u'(x)

    • (iii) ddxtan⁡(u(x))=sec⁡2(u(x))⋅u′(x)\frac{d}{dx} \tan(u(x)) = \sec^2(u(x)) \cdot u'(x)

    • (iv) ddxsec⁡(u(x))=sec⁡(u(x))tan⁡(u(x))⋅u′(x)\frac{d}{dx} \sec(u(x)) = \sec(u(x)) \tan(u(x)) \cdot u'(x)

  • Worked Examples:

    • 1. y=esin⁡(x)y = e^{\sin(x)}. Here u(x)=sin⁡(x)u(x) = \sin(x), u′(x)=cos⁡(x)u'(x) = \cos(x). Result: y′=cos⁡(x)esin⁡(x)y' = \cos(x)e^{\sin(x)}.

    • 2. y=cos⁡(2x+1)y = \cos(2x + 1). Here u(x)=2x+1u(x) = 2x + 1, u′(x)=2u'(x) = 2. Result: y′=−2sin⁡(2x+1)y' = -2 \sin(2x + 1).

    • 3. y=tan⁡(3x2+1)y = \tan(3x^2 + 1). Here u(x)=3x2+1u(x) = 3x^2 + 1, u′(x)=6xu'(x) = 6x. Result: y′=6xsec⁡2(3x2+1)y' = 6x \sec^2(3x^2 + 1).

Higher Order Derivatives

  • Notations:

    • First Order: y′=dydx=f′(x)=Dxf(x)y' = \frac{dy}{dx} = f'(x) = D_x f(x).

    • Second Order: y′′=d2ydx2=f′′(x)=Dx2f(x)y'' = \frac{d^2y}{dx^2} = f''(x) = D_x^2 f(x).

    • Third Order: y′′′=d3ydx3=f′′′(x)=Dx3f(x)y''' = \frac{d^3y}{dx^3} = f'''(x) = D_x^3 f(x).

    • Fourth Order: y(4)=d4ydx4=f(4)(x)=Dx4f(x)y^{(4)} = \frac{d^4y}{dx^4} = f^{(4)}(x) = D_x^4 f(x).

    • n-th Order: y(n)=dnydxn=f(n)(x)=Dxnf(x)y^{(n)} = \frac{d^ny}{dx^n} = f^{(n)}(x) = D_x^n f(x).

  • Definition: If a function is infinitely differentiable, all orders of differentiation exist for all n∈Nn \in \mathbb{N}.

More Rules: Sum and Difference Rules

  • Sum Rule:

    • ddx[f(x)+g(x)]=f′(x)+g′(x)\frac{d}{dx} [f(x) + g(x)] = f'(x) + g'(x)

    • Example: F(x)=e2x+sin⁡(3x)F(x) = e^{2x} + \sin(3x). F′(x)=2e2x+3cos⁡(3x)F'(x) = 2e^{2x} + 3 \cos(3x).

  • Difference Rule:

    • ddx[f(x)−g(x)]=f′(x)−g′(x)\frac{d}{dx} [f(x) - g(x)] = f'(x) - g'(x)

    • Example: F(x)=4x5−ex2+1=4x52−ex2+1F(x) = 4\sqrt{x^5} - e^{x^2+1} = 4x^{\frac{5}{2}} - e^{x^2+1}.       F′(x)=4(52)x32−2xex2+1=10x32−2xex2+1F'(x) = 4(\frac{5}{2})x^{\frac{3}{2}} - 2x e^{x^2+1} = 10x^{\frac{3}{2}} - 2x e^{x^2+1}.

  • Comprehensive Example with Higher Order:

    • Let y(v)=aev+cv2=aev+cv−2y(v) = ae^v + \frac{c}{v^2} = ae^v + cv^{-2}. (where a,ca, c are constants).

    • First Derivative: y′(v)=aev−2cv−3y'(v) = ae^v - 2cv^{-3}.

    • Second Derivative: y′′(v)=ddv(aev−2cv−3)=aev+6cv−4y''(v) = \frac{d}{dv} (ae^v - 2cv^{-3}) = ae^v + 6cv^{-4}.

    • Third Derivative: y′′′(v)=ddv(aev+6cv−4)=aev−24cv−5y'''(v) = \frac{d}{dv} (ae^v + 6cv^{-4}) = ae^v - 24cv^{-5}.