Speed at one instant

Drop a stone from a ter­race. How fast is it mov­ing at one exact instant? You can­not time it over zero sec­onds, but you can take its aver­age speed over shorter and shorter inter­vals and see what those aver­ages set­tle on. That lim­it­ing value is the deriv­a­tive. We will define it from first prin­ci­ples, work out the deriv­a­tives of xnx^n, sin⁡x\sin x and cos⁡x\cos x, and prove the sum, prod­uct and quo­tient rules that save you from first prin­ci­ples every time.

The deriv­a­tive

The deriv­a­tive of ff at aa is

f′(a)=lim⁡h→0f(a+h)−f(a)h,\displaystyle f'(a) = \lim_{h \to 0}\frac{f(a + h) - f(a)}{h},

pro­vided the limit exists. On a graph, it is the slope of the tan­gent to y=f(x)y = f(x) at (a,f(a))(a, f(a)). In physics, it is a rate of change at an instant. You will see the deriv­a­tive func­tion writ­ten as f′(x)f'(x), dydx\displaystyle \tfrac{dy}{dx} or ddxf(x)\displaystyle \tfrac{d}{dx}f(x).

Exam­ple 1. A stone falls s=4.9t2s = 4.9t^2 m in tt s. To get its speed at t=3t = 3, com­pute lim⁡h→04.9[(3+h)2−9]h=lim⁡4.9(6+h)=29.4\displaystyle \lim_{h \to 0}\tfrac{4.9[(3 + h)^2 - 9]}{h} = \lim 4.9(6 + h) = 29.4 m/s.

Graph of s = 4.9t squared for t from 0 to 4.6 s, with the point (3, 44.1) marked; dashed secants for h = 1 and h = 0.5 close in on the tangent at t = 3, whose slope is 29.4.
Exam­ple 1: secant slopes approach the tan­gent slope 29.4 m/s at t = 3

Exam­ple 2 (from first prin­ci­ples). f(x)=1x\displaystyle f(x) = \tfrac{1}{x}: f(x+h)−f(x)h=1h⋅x−(x+h)x(x+h)=−1x(x+h)→−1x2\displaystyle \tfrac{f(x + h) - f(x)}{h} = \tfrac{1}{h}\cdot\tfrac{x - (x + h)}{x(x + h)} = -\tfrac{1}{x(x + h)} \to -\tfrac{1}{x^2}.

Exam­ple 3. f(x)=sin⁡xf(x) = \sin x: sin⁡(x+h)−sin⁡xh=2cos⁡(x+h/2)sin⁡(h/2)h→cos⁡x\displaystyle \tfrac{\sin(x + h) - \sin x}{h} = \tfrac{2\cos(x + h/2)\sin(h/2)}{h} \to \cos x. In just the same way you can show ddxcos⁡x=−sin⁡x\displaystyle \tfrac{d}{dx}\cos x = -\sin x.

The rules that do the work

ddxxn=nxn−1,ddxc=0\displaystyle \frac{d}{dx}x^n = nx^{n-1}, \qquad \frac{d}{dx}c = 0
(u±v)′=u′±v′,(cu)′=cu′(u \pm v)' = u' \pm v', \qquad (cu)' = cu'
(uv)′=u′v+uv′(product rule)(uv)' = u'v + uv' \quad \text{(product rule)}
(uv)′=u′v−uv′v2(quotient rule)\displaystyle \left(\frac{u}{v}\right)' = \frac{u'v - uv'}{v^2} \quad \text{(quotient rule)}

Why the prod­uct rule holds. Add and sub­tract one clever term, and u(x+h)v(x+h)−u(x)v(x)h=u(x+h)−u(x)hv(x+h)+u(x)v(x+h)−v(x)h→u′v+uv′\displaystyle \tfrac{u(x + h)v(x + h) - u(x)v(x)}{h} = \tfrac{u(x + h) - u(x)}{h}v(x + h) + u(x)\tfrac{v(x + h) - v(x)}{h} \to u'v + uv'.

Put the quo­tient rule to work on sine and cosine and you get the rest of the fam­ily: ddxtan⁡x=sec⁡2x\displaystyle \tfrac{d}{dx}\tan x = \sec^2 x, ddxcot⁡x=−csc⁡2x\displaystyle \tfrac{d}{dx}\cot x = -\csc^2 x, ddxsec⁡x=sec⁡xtan⁡x\displaystyle \tfrac{d}{dx}\sec x = \sec x\tan x, ddxcsc⁡x=−csc⁡xcot⁡x\displaystyle \tfrac{d}{dx}\csc x = -\csc x \cot x.

Exam­ple 4. ddx(3x4−5x2+7x−2)=12x3−10x+7\displaystyle \tfrac{d}{dx}(3x^4 - 5x^2 + 7x - 2) = 12x^3 - 10x + 7.

Exam­ple 5. ddx(x2sin⁡x)=2xsin⁡x+x2cos⁡x\displaystyle \tfrac{d}{dx}(x^2 \sin x) = 2x\sin x + x^2\cos x.

Exam­ple 6. ddxx+1x−1=(x−1)−(x+1)(x−1)2=−2(x−1)2\displaystyle \tfrac{d}{dx}\frac{x + 1}{x - 1} = \frac{(x - 1) - (x + 1)}{(x - 1)^2} = -\frac{2}{(x - 1)^2}.

Exam­ple 7. ddxsin⁡x1+cos⁡x=cos⁡x(1+cos⁡x)+sin⁡2x(1+cos⁡x)2=11+cos⁡x\displaystyle \tfrac{d}{dx}\frac{\sin x}{1 + \cos x} = \frac{\cos x(1 + \cos x) + \sin^2 x}{(1 + \cos x)^2} = \frac{1}{1 + \cos x}.

Try these your­self

  1. Find the deriv­a­tive of each from first prin­ci­ples: x2+3xx^2 + 3x; x\sqrt{x}; cos⁡x\cos x.
  2. Find f′(2)f'(2) for f(x)=5x3−4xf(x) = 5x^3 - 4x.
  3. Dif­fer­en­ti­ate each: x−3+2x1/2x^{-3} + 2x^{1/2}; (2x+1)(x2−4)(2x + 1)(x^2 - 4); (x−1)3(x - 1)^3.
  4. Dif­fer­en­ti­ate each: x2x+3\displaystyle \frac{x^2}{x + 3}; 1+sin⁡xcos⁡x\displaystyle \frac{1 + \sin x}{\cos x}; xtan⁡xx\tan x.
  5. Dif­fer­en­ti­ate each: sin⁡2x\sin^2 x (as sin⁡x⋅sin⁡x\sin x \cdot \sin x); sec⁡x−tan⁡x\sec x - \tan x.
  6. Find the slope of the tan­gent to y=x3−3x+1y = x^3 - 3x + 1 at x=2x = 2. Where is the tan­gent hor­i­zon­tal?
  7. The area of a cir­cle is A=πr2A = \pi r^2. How quickly does AA change with rr when r=5r = 5?
  8. If f(x)=1+x+x2+⋯+x50f(x) = 1 + x + x^2 + \cdots + x^{50}, find f′(1)f'(1).
  9. Derive ddxtan⁡x=sec⁡2x\displaystyle \tfrac{d}{dx}\tan x = \sec^2 x from the quo­tient rule.
  10. Find ddx(ax+bcx+d)\displaystyle \tfrac{d}{dx}\left(\frac{ax + b}{cx + d}\right).

Answers to check against

Show answers
  1. 2x+32x + 3; 12x\displaystyle \tfrac{1}{2\sqrt{x}} (the trick is to mul­ti­ply by the con­ju­gate); −sin⁡x-\sin x.
  2. f′(x)=15x2−4f'(x) = 15x^2 - 4; 5656.
  3. −3x−4+x−1/2-3x^{-4} + x^{-1/2}; 6x2+2x−86x^2 + 2x - 8; 3(x−1)23(x - 1)^2.
  4. x2+6x(x+3)2\displaystyle \tfrac{x^2 + 6x}{(x + 3)^2}; cos⁡2x+sin⁡x(1+sin⁡x)cos⁡2x=1+sin⁡xcos⁡2x\displaystyle \tfrac{\cos^2 x + \sin x(1 + \sin x)}{\cos^2 x} = \tfrac{1 + \sin x}{\cos^2 x}; tan⁡x+xsec⁡2x\tan x + x\sec^2 x.
  5. 2sin⁡xcos⁡x2\sin x\cos x; sec⁡xtan⁡x−sec⁡2x\sec x\tan x - \sec^2 x.
  6. 3x2−3=93x^2 - 3 = 9; the tan­gent is hor­i­zon­tal at x=±1x = \pm 1.
  7. 2πr=10π2\pi r = 10\pi.
  8. 1+2+⋯+50=12751 + 2 + \cdots + 50 = 1275.
  9. cos⁡xcos⁡x+sin⁡xsin⁡xcos⁡2x\displaystyle \tfrac{\cos x\cos x + \sin x\sin x}{\cos^2 x}.
  10. ad−bc(cx+d)2\displaystyle \tfrac{ad - bc}{(cx + d)^2}.