Professional Documents
Culture Documents
1013L1 Chapter3
1013L1 Chapter3
f (a + h) f (a) f (a + h) f (a)
mh = =
(a + h) a h
Let h approach 0, then this straight-line will get closer and closer to the tangent line at
(a, f (a)). Therefore, the slope of tangent at (a, f (a)) can be thought as the limit of mh as h ! 0.
To conclude, the slope of tangent to the graph y = f (x) at the point (a, f (a)) is given by:
f (a + h) f (a)
lim .
h!0 h
80 Differentiation (Part I)
p
⌅ Example 3.1 Find the slope of tangent to the graph y = x at the point (1, 1). Write down
the equation of this tangent.
p
⌅ Solution Let f (x) = x, Based on the above discussion, the required slope is given by:
p
f (1 + h) f (1) 1+h 1
lim = lim
h!0 h h!0 h
p p
1+h 1 1+h+1
= lim ·p
h!0 h 1+h+1
1+h 1
= lim p
h!0 h( 1 + h + 1)
1
= lim p
h!0 1+h+1
1 1
=p = .
1+0+1 2
Now we know the slope of the required tangent is 12 , and this tangent passes through (1, 1).
Therefore, the equation of the tangent is:
y 1 1 1 1
= , or equivalently, y = x + .
x 1 2 2 2
f (a + h) f (a)
lim ,
h!0 h
we have a special name and symbol for it:
Definition 3.1 — Derivative. Let f : D ! R be a function, and a 2 D. We denote:
f (a + h) f (a)
f 0 (a) = lim
h!0 h
and it is called the derivative of f at a.
f (a + h) f (a)
f 0 (a) = lim
h!0 h
(a + h)2 a2
= lim
h!0 h
a2 + 2ah + h2 a2
= lim
h!0 h
2ah + h2
= lim
h!0 h
= lim 2a + h
h!0
= 2a.
Using this result, to find the slope of tangent at (⇡, f (⇡)), we do not need to compute the
limit again. We may simply substitute a = ⇡, then we get: f 0 (⇡) = 2⇡ and it will be the slope of
the required tangent.
Therefore, the given value a can be regarded as the input of f 0 , and the output f 0 (a) is the
slope of tangent at a. As such, f 0 (a) can be regarded as a function of a. The generic symbol for
3.1 Definition of Derivatives 81
f (x + h) f (x)
f 0 (x) = lim
h!0 h
Since f 0 can be regarded as a function derived from f , we call f 0 the derivative of f . The
process of finding f 0 from f is called differentiation. The problem of finding the derivative
of f is usually rephrased as: Differentiate the function f .
Proof.
d n (x + h)n xn
x = lim
dx h!0 h
xn + C1n xn 1 h + C2n xn 2 h2 + . . . + hn xn
= lim
h!0 h
xn + nxn 1 h + C2n xn 2 h2 + . . . + hn xn
= lim
h!0 h
nxn 1 h + C2n xn 2 h2 + C3n xn 3 h3 + . . . + hn
= lim
h!0 h
= lim nxn 1 + C2n xn 2 h + C3n xn 3 h2 + . . . + hn 1
h!0
= nxn 1
Proposition 3.2
d
c=0 (3.2)
dx
for any real constant c.
82 Differentiation (Part I)
d
c = f 0 (x)
dx
f (x + h) f (x)
= lim
h!0 h
c c
= lim
h!0 h
0
= lim
h!0 h
= lim 0
h!0
= 0.
i When h ! 0, the value of h is regarded to be very close to 0 but is not yet equal to 0.
Therefore, the fraction h0 as h ! 0 is regarded as a genuine 0, and so we have:
0
lim = lim 0.
h!0 h h!0
Proposition 3.3
d p 1
x= p for x > 0 (3.3)
dx 2 x
Proof.
p p
d p x+h x
x = lim
dx h!0 h
p p p p
x+h x x+h+ x
= lim ·p p
h!0 h x+h+ x
p 2 p 2
x+h ( x) 1
= lim ·p p
h!0 h x+h+ x
x+h x
= lim p p
h!0 h x+h+ x
h
= lim p p
h!0 h x+h+ x
1
= lim p p
h!0 x+h+ x
1
=p p
x+0+ x
1
= p
2 x
⌅ Exercise 3.1 ✓ ◆
d 1 1
= for x 6= 0 (3.4)
dx x x2
3.1 Definition of Derivatives 83
Unless otherwise is stated, we can make use of (3.1)-(3.4) without re-proving them. A more
careful look into these rules reveal that they have the same pattern:
d n
x = nxn 1
for any positive integer n
dx
d 0 d
x = 1 = 0 = 0 · x0 1
dx dx
d 1 d p 1 1 1 1 1
x2 = x = p = · x 2 = · x1 2
dx dx 2 x 2 2
✓ ◆
d d 1 1
x 1 = = = ( 1)x 1 1
dx dx x x2
We speculate that whether the rule dx x = axa 1 is true in general for any real number a. It is
d a
indeed true but the proof will be postponed after we introduce the chain rule. Let’s first state it
as a theorem:
Theorem 3.4 — Power Rule.
d a
x = axa 1
(3.5)
dx
for any a 2 R.
ah 1
lim = ln a (3.6)
h!0 h
We will use this result to derive the following rule:
Theorem 3.5 — Exponential Rule. For any a > 1, we have:
d x
a = ax ln a (3.7)
dx
xex."
e
u"
In particular,
=
1
d x
e = ex . (3.8)
x
= &
dx
Proof. ah
"
Let a 1 gt 1 =
y
= -
。 哈
“
h- →
,
y → 0 h =
logalyts }
d x ax+h ax
0
“
=
dx
a = lim
h!0 h mg
瓷肚州冰您
ax ah a x
= lim
h
“
h!0
w
= lim
x h
a (a 1) 以凸
h!0 h
a h
1 ”
= ax lim
lua
場
h!0 h =
i By observing the rules (3.7) and (3.8), we see that the exponential function ex behaves
most naturally among other exponential functions ax under differentiation. Therefore, we
call the number e to be the natural number.
d 1
loga x = for x > 0 (3.9)
dx x ln a
In particular when a = e, we have:
d 1
ln x = for x > 0 (3.10)
dx x
Proof.
d loga (x + h) loga x
loga x = lim
dx h!0 h
✓ ◆
1 x+h
= lim loga
h!0 h x
✓ ◆1
h h
= lim loga 1 +
h!0 x
✓ ◆y
1 x x 1 y
= lim loga 1 + (Let y = , then = )
y!1 y h h x
✓ ◆y
1 1
= lim loga 1 +
y!1 x y
✓ ◆y
1 1
= loga lim 1 + (since loga is continuous)
x y!1 y
1
= loga e
x
1 ln e 1
= = .
x ln a x ln a
⌅
i In HKDSE M2, the exam papers often use the term “from first principles” to mean finding
f (x + h) f (x)
f 0 (x) from the limit lim . Note that this particular limit is not really called
h!0 h
“first principles”. The term “first principles” has a much broader meaning, and it means that
you need work out the problem from scratch without using any well established theorems
or rules. In the context of finding derivatives, it means you cannotp use any rules such as
product rule, quotient rule, chain rule, etc. If one asks that “Prove 10 is irrational from p
first principles”, it means that your proof cannot use other established results such as 2
being irrational or other advanced theorems in number theory. It doesn’t mean you need to
prove it by finding derivatives from the above limit.
d d
sin x = cos x cos x = sin x
dx dx
sin x
lim = 1,
x!0 x
d sin(x + h) sin x
sin x = lim
dx h!0 h
sin x cos h + cos x sin h sin x
= lim
h!0 h
✓ ◆
(cos h 1) sin h
= lim sin x · + cos x ·
h!0 h h
(cos h 1)
We claim that lim = 0. To show this, we use the half-angle formula:
h!0 h
cos h 1 2 sin2 h2
lim = lim
h!0 h h!0 h
2 h
sin
= lim h 2
h!0
2
sin h2 h
= lim h
· sin
h!0
2
2
= 1 · 0 = 0.
d
sin x = sin x · 0 + cos x · 1 = cos x.
dx
d cos(x + h) cos x
cos x = lim
dx h!0 h
cos x cos h sin x sin h cos x
= lim
h!0 h
✓ ◆
cos h 1 sin h
= lim cos x · sin x ·
h!0 h h
= cos x · 0 sin x · 1 = sin x.
⌅
86 Differentiation (Part I)
Alternatively, one can derive the above results using sum-to-product formula instead:
A+B A B
sin A sin B = 2 cos sin ,
2 2
A+B A B
cos A cos B = sin sin .
2 2
Using these, one can write
(x + h) + x (x + h) x 2x + h h
sin(x + h) sin x = 2 cos sin = 2 cos sin ,
2 2 2 2
(x + h) + x (x + h) x 2x + h h
cos(x + h) cos x = 2 sin sin = 2 sin sin .
2 2 2 2
We leave it as an exercise for readers to complete the rest of the proof.
⌅ Exercise 3.3 — Source: modified from HKDSE M2 past exams, 2012-2022. Find the derivative
f 0 (x) of the following
p functions from first principles:
(a) f (x) = 2x
(b) f (x) = e2x
(c) f (x) = sin 2x
(d) f (x) = x3 3x
(e) f (x) = x 5
r+4
3
(f) f (x) =
x
1
(g) f (x) =
cos(6x)
(h) f (x) = (x2 1)ex
10x
(i) f (x) =
7 + 3x2
x
(j) f (x) = p , where x > 2.
2+x
1
(k) f (x) = 2
3x + 4
1
(l) f (x) = p , where x > 0.
5x + 4
f( x
) =
fanx =
sx
fx osxtx =
)
( =
seixa
=
x
3.2 Differentiability 87
3.2 Differentiability
Recall that the derivative f 0 of a function f is defined by the limit:
f (x + h) f (x)
f 0 (x) = lim .
h!0 h
We have seen some examples of limits that may not exist, especially when the function in-
volved is piecewise defined. Therefore, f 0 (x) which is defined by a limit may not always
exist.
Definition 3.2 — Differentiable Functions. Given a function f : R ! R, if the limit:
f (a + h) f (a)
lim
h!0 h
exists, then we say the f is differentiable at a.
Furthermore, if f is differentiable at every point a in an interval I, then we say that
f is differentiable on I. If f is differentiable on R, we may also say f is differentiable
everywhere.
f (0 + h) f (0)
f 0 (0) = lim
h!0 h
|h|
= lim
h!0 h
However, the left- and right-hand limits are not equal, since:
|h| h
lim = lim (since h < 0 when h ! 0 )
h!0 h h!0 h
= 1
|h| h
lim = lim+ (since h > 0 when h ! 0+ )
h!0+ h h!0 h
= 1.
( a h) ( a) h
f 0 (a) = lim = lim = 1.
h!0 h h!0 h
Similarly, one can also show f 0 (a) = 1 if a > 0. Therefore, f is differentiable at any a 6= 0.
⌅ Exercise 3.4 Given that f (x) = |x|, show that f 0 (a) = 1 for any a > 0.
88 Differentiation (Part I)
Since checking whether f 0 (a) exists often require us to verify if the following left- and
right-limits are equal:
f (a + h) f (a) f (a + h) f (a)
lim and lim ,
h!0+ h h!0 h
0 f (a + h) f (a)
f+ (a) = lim+
h!0 h
f (a + h) f (a)
f 0 (a) = lim
h!0 h
which is called the right-hand and left-hand derivatives respectively. f is differentiable at a if
and only if both f+0
(a) and f 0 (a) exist and they are equal.
Geometrically, f+ 0
(a) is the slope of tangent from the right while f 0 (a) is the slope of tangent
from the left. If they don’t match, the graph of the function will have a sharp corner at a. See the
graph of |x| as an example.
⌅ Solution
0 f (1 + h) f (1)
f+ (1) = lim
h!0+ h
2(1 + h) 1 12
= lim+ (as h ! 0+ , we have 1 + h > 0)
h!0 h
2h
= lim+ = lim+ 2
h!0 h h!0
= 2.
f (1 + h) f (1)
f 0 (1) = lim
h!0 h
2
(1 + h) 12
= lim (as h ! 0 , we have 1 + h < 0)
h!0 h
1 + 2h + h2 1
= lim = lim (2 + h)
h!0 h h!0
= 2.
Since f+
0
(1) = f 0 (1) = 2, f is differentiable at x = 1 with f 0 (1) = 2.
3.2 Differentiability 89
f (0 + h) f (0)
lim
h!0 h
p3
h 0
= lim
h!0 h
h1/3
= lim
h!0 h
1
= lim 2/3
h!0 h
=1
Therefore, f is not differentiable at 0. The geometric intuition here is that the tangent at 0 is
vertical.
p
⌅ Exercise 3.6 Show that for any p 2 (0, 1), the function f (x) = |x| is not differentiable at
x = 0. Is it differentiable at any x = a, where a 6= 0?
f (a + h) f (a)
lim
h!0 h
exists.
90 Differentiation (Part I)
f (x) f (a)
lim · lim (x a) = lim f (x) f (a)
x!a x a x!a x!a
Therefore, f is continuous at a. ⌅
i Note that the converse of Theorem 3.8 is NOT true. If f is continuous at a, it may not
imply f is differentiable at a. A counterexample is f (x) = |x|: f is continuous at 0, but not
differentiable there.
⌅ Solution From the given information about f , we can first find out:
Given that f is differentiable at 2, it is also continuous at 2. Hence the limit lim f (x) exists,
x!2
and:
lim f (x) = f (2) .
| {z } |{z}
x!2
=a
=9
Therefore, a = 9.
Again, using the fact that lim f (x) exists, we have:
x!2
i
is differentiable
f
Given
f( π ) = -
f (π )
ranstant
' =
3
gx )
: =
{ fgtxt
≤π if x
osx if x >π
Given :
is continwous at X =π
g
-
la Fiadk
上
Ib Is diff at x =π ?
g
Am :
(a) g (
x) =
g ( x)
=
g (π )
( gi cts at π )
+ asx =π f + xtk )= (
f
( a ) tatk ( f is diff "
→ f os → 1 f(
π x ) =
f( )
π
1 = f Ha) tatk
1 = -
1 tatk
k = -
πth
(b gi = —
g
π) 0
( 了⼀州⼀州
⼼
π
= —
h
。+∞洲
s
= = 0
,
i i
sitmUtAtLMM
微
点
tmtG了
形
f
'例t
(
1 =
3+ 1 =
4 ( Fom definitionof [ f
)
π
)
# (π )
g +
∴ g
f (2 + h) f (2)
f 0 (2) = lim
h!0 h
2(2 + h) + 5 9
= lim
h!0 h
2h
= lim
h!0 h
=2
0 b(2 + h)2 + c 9
f+ (2) = lim+
h!0 h
4b + 4bh + bh2 + c 9
= lim+
h!0 h
4bh
= lim+ (from 4b + c = 9)
h!0 h
= 4b.
⌅ Example 3.4 — Source: Modifed from HKALE Pure Math 2012, Paper 2, Q1. Given that
f : R ! R is a differentiable function satisfying f (⇡) = 1 and f 0 (⇡) = 3. Let k be a real
constant and g : R ! R be defined by
(
f (x) + x + k if x ⇡
g(x) = .
cos x if x > ⇡
1+⇡+k = 1 =) k = ⇡.
92 Differentiation (Part I)
0 g(⇡ + h) g(⇡)
g+ (⇡) = lim+
h!0 h
cos(⇡ + h) (f (⇡) + x + k)
= lim+
h!0 h
cos h ( 1 + ⇡ ⇡)
= lim+
h!0 h
1 cos h 2 sin2 h2
= lim = lim
h!0+ h h!0+ h
h
h sin 2
= lim+ sin · h
h!0 2 2
0
= sin · 1 = 0.
2
g(⇡ + h) g(⇡)
g 0 (⇡) = lim
h!0 h
f (⇡ + h) + (⇡ + h) + k f (⇡) + ⇡ + k
= lim
h!0 h
f (⇡ + h) f (⇡) + h
= lim
h!0 h
✓ ◆
f (⇡ + h) f (⇡)
= lim , 1
h!0 h
= f 0 (⇡) ⼈ 1=3 ) 1 = 2.
细⼭
Therefore, g+
0
(⇡) 6= g 0 (⇡). This shows g is not differentiable at x = ⇡.
⌅ Exercise 3.7 — Source: Modified from HKALE Pure Math 2008, Paper 2, Q2. Let a and b be real
constants, and f : R ! R be defined as
8 p
<2 + a 1 x
if x < 0
f (x) = x .
:
1 + b tan x8 if x 0
⌅ Exercise 3.8 — Source: HKALE Pure Math 2004, Paper 2, Q2. Let a and b be real constants, and
f : R ! R be defined as (
x2 + ax + b if x 1
f (x) = .
sin ⇡x
⇡ if x > 1
Given that f is differentiable at x = 1, find a and b.
⌅ Exercise 3.9 — Source: HKALE Pure Math 1999, Paper 2, Q5. Let a and b be real constants and
f : R ! R be defined as (
x2 cos x1 if x > 0
f (x) = .
ax + b if x 0
Given that f is differentiable at x = 0, find a and b.
Eracia 3
If f[ a) =
gx) on Ia b ]
,
g
(x ) on ( a
,
b)
3.2 Differentiability 93
⌅ Example 3.5 — Source: Extracted from HKALE Pure Math 2003, Paper 2, Q8. Let f : R ! R be
a non-constant function satisfying two conditions:
(1) f (x + y) = f (x) + f (y) + f (x)f (y) for all x, y 2 R; and
f (h)
(2) lim = a, where a 2 R is a constant.
h!0 h
Show that f is differentiable everywhere.
f (x + h) f (x)
= lim
h!0 h
f (x) + f (h) + f (x)f (h) f (x)
= lim (by (1))
h!0 h
f (h) 1 + f (x)
= lim
h!0 h
f (h)
= lim · (1 + f (x))
h!0 h
= a(1 + f (x)),
where the last step follows from (2), and that x is regarded as a constant when h ! 0.
Therefore f (x) is differentiable at any x 2 R, with f 0 (x) = a(1 + f (x)).
⌅ Exercise 3.10 — Source: Extracted/Modified from HKALE Pure Math 2012, Paper 2, Q8. Let
f : R ! R be a function satisfying the following conditions:
(1) f (x + y) = f (x)f (y) f (x) f (y) + 2 for all x, y 2 R; and
(2) there exists a unique real number r such that f (r) = 2.
Answer the following questions:
(a) Show that if there exists a 2 R such that f (a) = 1, then f is a constant function.
(b) Show that f (0) = 2.
(c) Show that f is injective. [Hint: suppose f (x) = f (y) for some x, y 2 R, then consider
f (x y) + y .]
(d) Given that f is differentiable at x = 0. Show that f is differentiable everywhere, and
f 0 (x) = f 0 (0)(f (x) 1)
⌅ Exercise 3.11 — Source: Modified from HKALE Pure Math 1992, Paper 2, Q7. Let f be a
differentiable function such that
x2 + 1
f (x) = .
x3+x+1
In this section, we will discuss several rules that allow us to differentiate a function in a more
efficient way. These rules are listed below:
Theorem 3.9 — Rules for Differentiation. Given two functions f and g, then at a point x where
they are both differentiable, we have:
d d d
(f (x) + g(x)) = f (x) + g(x)
dx dx dx
d d d
(f (x) g(x)) = f (x) g(x)
dx dx dx
d d
(cf (x)) = c f (x) where c is any real constant
dx dx
d
f (x)g(x) = f 0 (x)g(x) + f (x)g 0 (x) (Product Rule)
dx ✓ ◆
d f (x) g(x)f 0 (x) f (x)g 0 (x)
= if g(x) 6= 0 (Quotient Rule)
dx g(x) g(x)2
Proof. The proof is basically by rearranging the terms in the limit definition of derivatives (first
principles).
The last step follows from the fact that f and g are differentiable at x.
The rules
d d d d d
(f (x) g(x)) = f (x) g(x) and (cf (x)) = c f (x)
dx dx dx dx dx
can be proved in similar ways.
For the product rule, we consider:
d f (x + h)g(x + h) f (x)g(x)
f (x)g(x) = lim
dx h!0 h
f (x + h)g(x + h) f (x)g(x + h) + f (x)g(x + h) f (x)g(x)
= lim
h!0 h
✓ ◆
f (x + h) f (x) g(x + h) g(x)
= lim · g(x + h) + f (x) · .
h!0 h h
and then apply the product rule to derive the quotient rule.
1 1
d 1 g(x+h) g(x)
= lim
dx g(x) h!0 h
1 g(x) g(x + h)
= lim ·
h!0 h g(x)g(x + h)
g(x + h) g(x) 1 1
= lim · ·
h!0 h g(x) g(x + h)
d 1 1 1 g 0 (x)
= g 0 (x) · · = .
dx g(x) g(x) g(x) g(x)2
d f (x) d 1
= f (x) ·
dx g(x) dx g(x)
1 d 1
= f 0 (x) · + f (x)
g(x) dx g(x)
f 0 (x) g 0 (x)
= f (x) ·
g(x) g(x)2
f (x)g(x) f (x)g 0 (x)
0
=
g(x)2
as desired. ⌅
⌅ Exercise 3.12 Derive, from the definition of derivative, that for a differentiable function f ,
we have
d 1 2f 0 (x)
= .
dx f (x)2 f (x)3
⌅ Exercise 3.13 Using the product rule and induction, show that if f is differentiable, then
d n 1 0
f (x)n = n f (x) f (x)
dx
for any n 2 N.
d n 1 0
Hence, prove also that f (x) n = ( n) f (x) f (x) for any n 2 N.
dx
d n 1 0
[Remark: Combining the results, this show the rule f (x)n = n f (x) f (x) for any
dx
n 2 Z. Note that the result is trivial when n = 0.]
96 Differentiation (Part I)
ln x
3. h(x) = p
x
⌅ Solution
d d
(x3 + x + 1) dx (x2 + 1) (x2 + 1) dx (x3 + x + 1)
f 0 (x) =
(x3 + x + 1)2
(x + x + 1)(2x) (x2 + 1)(3x2 + 1)
3
=
(x3 + x + 1)2
2x + 2x + 2x 3x4 x2 3x2 1
4 2
=
(x3 + x + 1)2
4 2
x 2x + 2x 1
=
(x + x + 1)2
3
d x d
g 0 (x) = x e + ex x
dx dx
= xex + ex · 1
= (x + 1)ex
p d d p
x dx ln x ln x · dx x
h0 (x) = p 2
( x)
p 1 1
x · x ln x · 2p x
=
x
p1 ln x
· p1
x 2 x
=
x
p1 1 ln x
x 2
=
x
ln x
1 2
= .
x3/2
⌅ Example 3.7 Suppose f and g are two functions which are differentiable everywhere. Using
the information below:
x2 f (x)
⌅ Solution Be careful that we have to substitute x = 1 after we differentiate the fraction g(x) .
3.3 Differentiation Rules 97
If you substitute then differentiate, you will get a constant and so the derivative would be zero!
✓ ◆ d 2 d
d x2 f (x) g(x) dx x f (x) x2 f (x) dx g(x)
= 2
dx g(x) g(x)
g(x)(2xf (x) + x2 f 0 (x)) x2 f (x)g 0 (x)
=
g(x)2
Substitute x = 1, we get:
✓ 2 ◆
d x f (x) g(1)(2f (1) + f 0 (1)) f (1)g 0 (1)
=
dx g(x) x=1 g(1)2
3 ⇥ (2 ⇥ 8 + 1) 8 ⇥ 2
=
32
35
=
9
d d
sin x = cos x csc x = csc x cot x
dx dx
d d
cos x = sin x sec x = sec x tan x
dx dx
d d
tan x = sec2 x cot x = csc2 x
dx dx
d d 1
csc x =
dx dx sin x
d
sin x
= dx
(sin x)2
cos x
=
sin2 x
cos x 1
= ·
sin x sin x
= cot x csc x
The proofs of the remaining two are left as exercises. ⌅
⌅ Solution Since f 0 (a) is the slope of tangent at (a, f (a)), we need to find all a’s such that
f (a) = 0. First we derive the formula for f 0 (x):
0
✓ ◆
0 d sec x
f (x) =
dx 1 + tan x
d d
(1 + tan x) · sec x sec x · dx
dx (1 + tan x)
= 2
(1 + tan x)
(1 + tan x) sec x tan x sec x · sec2 x
=
(1 + tan x)2
sec x · (tan x + tan2 x sec2 x)
=
(1 + tan x)2
sec x · (tan x + sec2 x 1 sec2 x)
=
(1 + tan x)2
sec x · (tan x 1)
=
(1 + tan x)2
sec a · (tan a 1) = 0
We have already learned how to differentiate sin u and x2 + 1. The chain rule, stated below, tells
us how to deal with this f :
Theorem 3.11 — Chain Rule. Let f be a differentiable function of u, and u is a differentiable
function of x (so f is ultimately a function of x). Then, f is a differentiable function of x, and
we have:
df df du
= ·
dx du dx
i Although symbolically the chain rule is just like cancelling out du, conceptually we cannot
think it this way. The proof of the chain rule is quite technical (hence omitted here).
d d
sin(x2 + 1) = sin u (Let u = x2 + 1)
|dx {z } dx
df
dx
d du
= sin u ·
| {z } dx
du
df
du
d d 2
= sin u · (x + 1)
du dx
= cos u · 2x
= 2x cos(x2 + 1)
⌅ Solution First think of a function u(x) so that f can be regarded as a function of u and that
df
both du and du
dx are easy to find. One suitable choice here is:
u = x3 + 2x2 + 1.
df df du
= ·
dx du dx
d 5 d 3
= u · (x + 2x2 + 1)
du dx
= 5u4 · (3x2 + 4x)
= 5(3x2 + 4x) (x3 + 2x2 + 1)4
| {z }
u4
df df du
= ·
dx du dx
a
= eu ·
x
aea ln x
= .
x
After getting familiar with the chain rule, you may skip writing “Let u = . . .” and simply write:
d 3 d d 3
(x + 2x2 + 1)5 = (x3 + 2x2 + 1)5 · (x + 2x2 + 1)
dx d(x3 + 2x2 + 1) dx
= 5(x3 + 2x2 + 1)4 (3x2 + 4x)
Likewise, we may apply the chain rule for following functions without explicitly writing the
function u:
d d d 2
sin(x2 + 1) = 2
sin(x2 + 1) · (x + 1)
dx d(x + 1) dx
= cos(x2 + 1) · 2x
d a ln x d d
e = ea ln x · a ln x
dx d(a ln x) dx
a
= ea ln x ·
x
We can also apply the chain rule when the “chain” of variables is longer. For instance, the
function
f = sin(cos(tan x))
df
can be regarded as f = sin u, where u = cos v and v = tan x. To find dx , we can do:
df df du dv
= · ·
dx du dv dx
= cos u · ( sin v) · sec2 x
= cos(cos(tan x)) · sin(tan x) · sec2 x
Equivalently, we can also apply the chain rule without writing down the u and v explicitly:
d d d d
sin(cos(tan x)) = sin(cos(tan x)) · cos(tan x) · tan x
dx d(cos(tan x)) d(tan x) dx
= cos(cos(tan x)) · ( sin(tan x)) · sec2 x
which gives the same answer as the above.
⌅ Exercise 3.18 Let a > 0 be a constant, and u(x) be a differentiable function of x. Show that
d u(x) du
a = au(x) ln a .
dx dx
Suppose further that a 6= 1 and u(x) > 0 for all x, show that
d 1 du
loga u = .
dx u(x) ln a dx
f (u(x)) = (f u)(x).
For instance, the function sin(x2 + 1) can be regarded (f u)(x) by letting f (u) = sin u and
u(x) = x2 + 1.
Many textbooks also include the following form for the chain rule (which is equivalent to the
one we discussed):
(f u)0 (x) = f 0 (u) · u0 (x) .
| {z } | {z } | {z }
df df du
dx du dx
⌅ Example 3.11 Given f and g are two differentiable functions, and that:
Substitute x = 1, we have g 0 (x) = g 0 (1) = 9. However, what is f 0 (g)? From the given fact that
g(1) = 2, we know that g = 2 when x = 1, and so f 0 (g) = f 0 (2) = 10. Therefore,
i Be careful when you substitute. The most common mistake is that some students substitute
the same value (like 1 in the above example) into both f 0 and g 0 :
(f g)0 (1) = f 0 (1) · g 0 (1) INCORRECT!
To remind yourself not making this kind o mistakes, write the chain rule as:
(f g)0 (x) = f 0 (g(x)) · g 0 (x),
so that in this example, we have:
(f g)0 (1) = f 0 (g(1)) · g 0 (1) = f 0 (2) · g 0 (1).
102 Differentiation (Part I)
f (x) f (a)
f 0 (a) = lim .
x!a x a
By rearrangement, and noting that f (a) is just a constant, we get
✓ ◆
f (x) f (a) 0 f (x) f (a) f 0 (a)(x a)
0 = lim f (a) = lim .
x!a x a x!a x a
We could interpret the above limit as saying “as x ! a, the denominator f (x) f (a) f 0 (a)(x a)
is very small when compared to x a”, and we write:
For example, if we take f (x) = sin x, then f 0 (x) = cos x and so f 0 (0) = 1, then one can interpret
the above as saying sin x is approximately equal to the linear graph:
sin x ⇠ 0 + 1 · (x 0) = x when x ⇠ 0.
Since y = f (a) + f 0 (a)(x a) is a straight line (noting that a is a constant), and in fact it is the
tangent line to y = f (x) at the point (a, f (a)), we call f (a)+f 0 (a)(x a) the linear approximation
of f near a.
Note that given two differentiable functions f (x) and g(u). Then consider that f can be
linearly approximated by:
Therefore, the composite function g f (x) can be linearly approximated by a straight line with
slope g 0 (f (a))f 0 (a) when x ⇠ a.
This suggests that the slope of tangent of the graph y = g(f (x)) at x = a should be equal to
g 0 (f (a))f 0 (a). It casually (not rigorously) explains why we have
d
g(f (x)) = g 0 (f (a))f 0 (a),
dx x=a
which is exactly the chain rule. Surely, the above is not really a rigorous proof, but the formal
proof is roughly inline of the above thought.
⌅ Exercise 3.19 Given two functions f and g which are differentiable at x = a, write down the
linear approximations of f and g, and multiply them together. Try to explain the product rule
in this way.
3.4 Implicit Differentiation 103
The method of implicit differentiation is another way of doing this kind of problems. Take
the above example: consider the circle x2 + y 2 = 25, we may first regard y as a function of x
without explicitly finding the function. Then, by differentiating both sides of x2 + y 2 = 25 with
respect to x, we get:
d d
x2 + y 2 = (25)
dx dx
d 2
2x + y =0
dx
d 2 dy
2x + y · =0 (chain rule)
dy dx
dy
2x + 2y =0
dx
dy 2x x
= =
dx 2y y
Therefore,
dy 3
= .
dx (x,y)=(3,4) 4
i You might think that it is problematic for regarding y as a function x, since the circle does
not pass the vertical line test. However, as we are trying to findp
the slope of tangent at (3, 4),
we can ignore the lower-half circle. Then y can be regarded as 25 x2 which is a function
of x.
104 Differentiation (Part I)
Likewise,
p if we want to find the slope of tangent at (3, 4), then it lies on the part of circle
y= 25 x2 so that y near the point (3, 4) can also be regarded as a function of x.
To conclude, unless we hit a bad point such as (5, 0) or ( 5, 0), one can often locally regard
y as a function of x around that point. The method of implicit differentiation will be fully
justified in MATH 3033 (Real Analysis). In this freshmen Calculus course, we may simply
assume that this method works.
The method of implicit differentiation can be extremely useful when dealing curves such as
x3 + y 3 = 6xy
where it is very difficult to solve y in terms x explicitly. Let’s consider this curve as an exam-
ple:
⌅ Example 3.12 Consider the curve x3 + y 3 = 6xy. Find all points at which the tangent to this
curve is horizontal.
dy
⌅ Solution We need to solve for all (x, y) on this curve such that = 0. Using implicit
dx
dy
differentiation to find dx , we differentiate both sides of x + y = 6xy with respect to x:
3 3
d d
x3 + y 3 = (6xy)
dx dx✓ ◆
dy dx dy
3x2 + 3y 2 =6 ·y+x· (chain rule on LHS, product rule on RHS)
dx dx dx
dy dy
x2 + y 2 = 2y + 2x
dx dx
dy dy
y2 2x = 2y x2
dx dx
dy
y 2 2x = 2y x2
dx
dy 2y x2
=
dx y2 2x
dy
(x, y) = 0 () 2y = x2 .
dx
Be careful that we also require (x, y) to be on the curve x3 + y 3 = 6xy, so both of the equations
3.4 Implicit Differentiation 105
x2
The first equation implies y = 2 , and by substituting y into the second equation, we get:
✓ ◆3
3 x2 x2
x + = 6x ·
2 2
x6
x3 + = 3x3
8
x6 16x3 = 0
x3 (x3 16) = 0
p x2
Therefore, we get x = 0 or x = 3
16. Using y = 2 , we get:
✓ ◆
162/3
(x, y) = (0, 0) or 161/3 , .
2
sin y =x
d dx
sin y =
dx dx
dy
cos y · =1
dx
dy 1
=
dx cos y
1
= 1
cos(sin x)
p
By standard trigonmetry (sketch a right-angled triangle to see it) that cos(sin 1 (x)) = 1 x2 .
d 1 d 1
Therefore, we have: sin 1 x = p . Likewise, we can also show: cos 1 x = p .
dx 1 x2 dx 1 x2
Let’s look at y = tan 1 x:
1
tan y = x
x
d dx
tan y = xin ( x)
dx dx )
2
sec y ·
dy
=1 -
1
dx
dy 1 1
= =
dx 2
sec y 1 + tan2 y
1 1
= =
1 + tan2 (tan 1 x) 1 + x2
Therefore, we have:
d 1 1
tan x= .
dx 1 + x2
106 Differentiation (Part I)
To summarize, we have:
d 1 1
sin x= p
dx x2
1
d 1 1
cos x= p
dx 1 x2
d 1 1
tan x=
dx 1 + x2
Although this formula looks like taking reciprocal, it is conceptually incorrect to say so because
dy
dx and dy are not fractions.
dx
d 1 1 d 1 1 d 1 1
sec x= p csc x= p cot x=
dx |x| x2 1 dx |x| x2 1 dx 1 + x2
d 1
For any x 6= 0, we have: ln |x| = .
dx x
Using the chain rule, we can further generalize the above rule to the following proposition
(which will be extremely useful later on when dealing with tedious differentiation).
Proposition 3.12 Given any differentiable function f (x), then at any point x such that f (x) 6= 0,
we have:
d f 0 (x)
ln |f (x)| = .
dx f (x)
g(x) = ln |x| ,
d d d
g(f (x)) = g(f ) · f (x)
dx df dx
d
= ln |f | · f 0 (x)
df
1
= · f 0 (x)
f (x)
f 0 (x) 1 1 d (x2 + 1) d
dx (3x+ 2)
= + · dx 2 3·
f (x) 3x 2 x +1 3x + 2
1 x 9
= + 2
3x x + 1 3x + 2
Therefore,
✓ ◆
1 x 9
f 0 (x) = f (x) + 2
3x x + 1 3x + 2
1/3
p ✓ ◆
x x2 + 1 1 x 9
= +
(3x + 2)3 3x x2 + 1 3x + 2
108 Differentiation (Part I)
⌅ Solution Consider:
ln f (x) = ln xx = x ln x.
Differentiate both sides, we get:
f 0 (x) 1
= 1 · ln x + x ·
f (x) x
f 0 (x) = f (x) (ln x + 1)
= xx (ln x + 1)
(x + 4)3
⌅ Exercise 3.21 — Source: Extracted from HKDSE M2 2020, Q9. Let f (x) = , where x 6= 4.
(x 4)2
d 0
Try using logarithmic differentiation to find f 0 (x) and f 00 (x). Recall that f 00 (x) = f (x).
dx
[Caution: Not sure if logarithmic differentiation is allowed in DSE M1/M2. Be warned if you
use it to tutor DSE kids or use it to retake DSE again.]
⌅ Exercise 3.22 Let f (x) = x2/3 (6 x)1/3 . Find f 0 (x) and f 00 (x) where x 6= 0, 6.
⌅ Exercise 3.24 Find the derivative of each function below (for x > 0):
x x x x e e x e
xx , ex , xe , xe , xe , ex , ee , ee .
⌅ Exercise 3.25 Derive a general differentiation rule for f (x)g(x) where f and g are differen-
tiable functions, and f (x) > 0 for all x 2 R.
f ( ) xxx
x
=
λ70
lulfix ) 1
: xu 1 x 1
( * ) ulxl x +
是
* -
X
(luxt ) ux
*
1 +
= x
啦了
IlxPeunt *
= x
x"
f
(
(
x)xx=
3.5 Higher-Order Differentiations 109
d 0 d2 f
f 00 (x) := f (x) alternative notation: .
dx dx2
For example:
f (x) = sin x
d
f 0 (x) = sin x = cos x
dx
d 0 d
f 00 (x) = f (x) = cos x = sin x
dx dx
Certainly, one may continue differentiating f 00 (x) and obtain the third-order, fourth-order, and
more generally n-th order derivatives:
d 00 d 000 d (n
f 000 (x) := f (x), f (4) (x) := f (x), f (n) (x) := f 1)
(x), 8n 2.
dx dx dx
By convention, we often denote f (0) (x) := f (x). Alternatively, we can also denote these higher-
order derivatives by
dn f
:= f (n) (x).
dxn
⌅ Example 3.15 Find the n-th derivative of the function f (x) = eax where a 2 R is a constant.
⌅ Solution
d ax
f 0 (x) = e = aeax
dx
d 0 d ax
f 00 (x) = f (x) = ae = a · aeax = a2 eax
dx dx
d 00 d 2 ax
f 000 (x) = f (x) = a e = a3 eax .
dx dx
One would be able to guess that f (n) (x) = an eax . It can be further verified by induction:
Let P (n) : f (n) (x) = an eax . Certainly P (1) is true. Now assume P (n) is true for some
n 2 N, then we have
f (n) (x) = an eax .
Consider the (n + 1)-th derivative:
d (n) d n ax
f (n+1) (x) = f (x) = a e = an · aeax = an+1 eax .
dx dx
This shows P (n + 1) is true. By induction, we conclude that f (n) (x) = an eax for any n 2 N.
110 Differentiation (Part I)
1
⌅ Example 3.16 Let f (x) = where a, b are constants, and a 6= 0. Find f (n) (x) for any
ax + b
n 2 N.
⌅ Solution
1
f (x) =
ax + b
a
f 0 (x) =
(ax + b)2
2a2
f 00 (x) =
(ax + b)3
(3)(2)a3
f 000 (x) =
(ax + b)4
(4)(3)(2)a4
f (4) (x) =
(ax + b)5
( 1)n n!an
f (n) (x) = .
(ax + b)n+1
dn 1 ( 1)n n!an
= 8n 2 N.
dxn ax + b (ax + b)n+1
dn ⇣ n⇡ ⌘
sin x = sin + x 8n 2 N.
dxn 2
dn k
⌅ Example 3.17 Let k 2 N, find x where n 2 N.
dxn
⌅ Solution
d k
x = kxk 1
dx
d2 k
x = k(k 1)xk 2
dx2
d3 k
x = k(k 1)(k 2)xk 3
dx3
..
.
dk 1 k
x = k(k 1)(k 2) · · · (3)(2)xk (k 1)
= k(k 1)(k 2) · · · (3)(2)x
dxk 1
dk k
x = k(k 1)(k 2) · · · (3)(2)(1) = k!
dxk
3.5 Higher-Order Differentiations 111
k+1
Note that k! is a constant, so dx
d
k+1 x
k
= 0. To summarize, we have
(
dn k k(k 1)(k 2) · · · (k (n 1))xk n if n = 1, 2, · · · , k
x = .
dxn 0 if n k + 1
k!
Note that the coefficient k(k 1)(k 2) · · · (k (n 1)) can be rewritten as , if you
(k n)!
prefer.
⌅ Exercise 3.29 Let f (x) = (2x + 3)k where k 2 N. Find f (n) (x) for any n 2 N.
⌅ Exercise 3.30 Let f (x) = (x 1)k where k 2 N. Show that for any n 2 N, we have
(
(n) k! if n = k
f (1) =
0 if n 6= k
Functions whose n-th derivative f (n) (x) exist are called n-times differentiable functions
(and when n = 2 we often call them twice differentiable functions). Note that a function
f (x) which is differentiable, i.e. f 0 (x) exists, does not always imply f 00 (x) exist, and so on. We
will see later in this section that some functions are, for instance, differentiable but not twice
differentiable.
⌅ Exercise 3.31 — Source: Extracted from HKALE Pure Math 2003, Paper 2, Q9. Let u : R ! R be
a twice differentiable function satisfying the following conditions
(1) u00 (x) = u(x) for any x 2 R,
(2) u(0) = 0, and
(3) u0 (0) = 1.
Define v(x) = u(x) sin x for all x 2 R. By considering the derivative of
d
f (x)g(x) = f 0 (x)g(x) + f (x)g 0 (x),
dx
1
X
Ck1 f (1 k)
(x)g (k) (x) = C01 f 0 (x)g(x) + C11 f (x)g 0 (x) = f 0 (x)g(x) + f (x)g 0 (x).
k=0
X n
dn
n
f (x)g(x) = Ckn f (n k)
(x)g (k) (x).
dx
k=0
dn+1
f (x)g(x)
dxn+1
✓ n ◆ n
d d d X n (n k)
= f (x)g(x) = Ck f (x)g (k) (x)
dx dxn dx
k=0
n
X d n (n k)
= C f (x)g (k) (x)
dx k
k=0
Xn
= Ckn f (n k+1)
(x)g (k) (x) + f (n k)
(x)g (k+1) (x)
k=0
n
X n+1
X
= Ckn f (n+1 k)
(x)g (k) (x) + Ckn 1 f (n k+1)
(x)g (k) (x) (change of index)
k=0 k=1
n
X
= C0n f (n+1) (x)g(x) + Ckn f (n+1 k)
(x)g (k) (x)
k=1
n
X
+ Ckn 1 f (n k+1)
(x)g (k) (x) + Cnn f (n (n+1)+1)
(x)g (n+1) (x)
k=1
n
X
= f (n+1) (x)g(x) + (Ckn + Ckn 1 )f (n k+1)
(x)g (k) (x)
k=1
(n+1)
+ f (x)g (x)
n
X
= C0n+1 f (n+1) (x)g(x) + Ckn+1 f (n k+1)
(x)g (k) (x)
k=1
n+1 (n+1)
+ Cn+1 f (x)g (x)
n+1
X
= Ckn+1 f (n k+1)
(x)g (k) (x),
k=0
which is exactly the RHS of (3.11) for n + 1 is in place of n. By induction, (3.11) is proved for
any n 2 N. ⌅
⌅ Example 3.18 — Source: Extracted from HKALE Pure Math 2012, Paper 2, Q2. Consider the
function f : R ! R defined by
sin x
f (x) = .
1 + 4x2
n⇡
Show that f (n+2) (0) = 4(n + 2)(n + 1)f (n) (0) sin for any n 2 N.
2
⌅ Solution The first guess may be to apply (3.11) on the functions sin x and However, 1+4x2 .
1
the k-th derivative of is very difficult to obtain. However, the k-th derivative of 1 + 4x2
1
1+4x2
is much easier. Therefore, we consider:
dn+2
f (x)(1 + 4x2 )
dxn+2
n+2
X
= Ckn+2 f (n+2 k) (x)(1 + 4x2 )(k)
k=0
=f (n+2)
(x)(1 + 4x2 ) + (n + 2)f (n+1) (x) · 8x + C3n+2 f (n) (x) · 8 + 0 + 0 + · · · + 0
= (1 + 4x2 )f (n+2) (x) + 8(n + 2)xf (n+1) (x) + 8C2n+2 f (n) (x).
On the other hand, recall that f (x)(1 + 4x2 ) = sin x, hence we also have
✓ ◆
dn+2 2 dn+2 (n + 2)⇡
f (x)(1 + 4x ) = sin x = sin x + .
dxn+2 dxn+2 2
We conclude that
✓ ◆
(n + 2)⇡
(1 + 4x )f 2 (n+2)
(x) + 8(n + 2)xf (n+1)
(x) + 8C2n+2 f (n) (x) = sin x + .
2
Put x = 0, we get:
⌅ Exercise 3.32 — Source: Modified from HKALE Pure Math 2011, Paper 2, Q3. Let f : R ! R be
defined by
1
f (x) = p .
x2 + 2x + 5
(a) Prove that (x2 + 2x + 5)f 0 (x) + (x + 1)f (x) = 0 for any x 2 R.
(b) Hence, prove that
for any x 2 R, n 2 N.
⌅ Exercise 3.33 — Source: Extracted from HKALE Pure Math 2009, Paper 2, Q3. Let f : R ! R be
defined by
3
f (x) = (25 + x2 ) 2 .
(a) Prove that (25 + x )f (x) =2 0
3xf (x) for any x 2 R.
(b) Hence, prove that
for any x 2 R, n 2 N.
Show that f 0 (x) exists for any x 2 R, but f 00 (0) does not exist.
f (x + h) f (x)
f 0 (x) = lim .
h!0 h
When x 6= 0, and when h is very close to 0, we have x + h 6= 0 too, so we have both
1
f (x + h) = (x + h)3 sin x+h and f (x) = x3 sin x1 when h ! 0 and x 6= 0. Therefore, we have
1
(x + h)3 sin x+h x3 sin x1
f 0 (x) = lim (when x 6= 0),
h!0 h
which is no different from sin x1 . Therefore, we can compute directly that when x 6= 0:
d 3
dx x
✓ ◆
0 d 3 1 2 1 3 1 1 1 1
f (x) = x sin = 3x sin + x cos = 3x2 sin x cos .
dx x x x2 x x x
However, one should find f 0 (0) from the definition since f (0 + h) and f (0) are defined
differently as h ! 0 (recall that h ! 0 infers that h 6= 0):
f (0 + h) f (0)
f 0 (0) = lim
h!0 h
h3 sin h1 0
= lim
h!0 h
2 1
= lim h sin .
h!0 h
1 1
By squeeze theorem, lim 3h sin = 0, but lim cos does not exist because 1
h ! 1 and cos x
h!0 h h!0 h
oscillates between 1 and 1 when x ! 1. Therefore, the limit
✓ ◆
1 1
lim 3h sin cos
h!0 h h
does not exist, and neither does f 00 (0). In other words, f is not twice differentiable at x = 0.
⌅ Example 3.20 — Source: Modified from HKALE Pure Math 1997, Paper 2, Q6. Consider the
function f : R ! R defined by f (x) = x |x|.
(a) Find f 0 (x) for any x 2 R.
(b) Determine whether or not f 0 : R ! R is continuous at x = 0.
(c) Determine whether or not f 00 (0) exists.
(x + h)2 x2 d 2
f 0 (x) = lim = x = 2x.
h!0 h dx
Similarly, when x < 0 and h ! 0, x + h is negative so f (x + h) = (x + h)2 and f (x) = x2 .
Therefore,
(x + h)2 ( x2 ) d
f 0 (x) = lim = ( x2 ) = 2x.
h!0 h dx
When x = 0 and h ! 0, x + h could be positive or negative depending on whether h ! 0+ and
h ! 0 . That gives us a hint that we should consider f+
0
(0) and f 0 (0):
0 f (0 + h) f (0) h |h| 0
f+ (0) = lim+ = lim+
h!0 h h!0 h
2
h
= lim+ = lim+ h = 0
h!0 h h!0
f (0 + h) f (0) h( h) 0
f 0 (0) = lim = lim
h!0 h h!0 h
= lim ( h) = 0.
h!0
As f+
0
(0) = f 0 (0) = 0, we conclude that f 0 (0) exists and f 0 (0) = 0.
To summarize, we have
8
< 2x if x 2 ( 1, 0)
>
0
f (x) = 0 if x = 0 .
>
:
2x if x 2 (0, 1)
(b) We need to determine whether or not lim f 0 (x) = f 0 (0). Note that
x!0
f 0 (0 + h) f 0 (0)
f 00 (0) = lim .
h!0 h
Again, how is f 0 (0 + h) defined depends on whether h is positive or negative. We need to work
with its left- and right-limits again:
f 0 (0 + h) f 0 (0) 2h 0
lim+ = lim+ =2
h!0 h h!0 h
f 0 (0 + h) f 0 (0) 2h 0
lim = lim = 2
h!0 h h!0 h
f 0 (0 + h) f 0 (0)
Its left- and right-limits do not agree. Hence, lim does not exist. In other
h!0 h
words, f (0) does not exist (equivalently we may say f (x) is not differentiable at x = 0, or
00 0
Show that f 0 (x) and f 00 (x) exist for all x 2 R, but f 000 (x) does not exist for some x 2 R.
⌅
p Source: Modified from HKALE Pure Math 2004, Paper 2, Q7. Consider the
Exercise 3.35 —
function f : R\{ 3 2} ! R defined by
|x| x3
f (x) = .
x3 2
p
(a) Find f 0 (x) for any x 6= 3 2.
(b) Determine whether or not f 00 (0) exists.
⌅ Exercise 3.36 — Source: Modified from HKALE PUre Math 2003, Paper 2, Q7. Consider the
function f : R\{ 2} ! R defined by
x |x + 1|
f (x) = .
x+2
(a) Find f 0 (x) for any x 6= 1, 2.
(b) Determine whether or not f 0 ( 1) exists.
(c) Do you agree with the following statement? “f 00 (x) does not exist for any x 2 R.”
In many of the above examples and exercises, the functions are piecewise defined in the form
of: 8
<g(x) if x < 0
>
f (x) = a if x = 0 .
>
:
k(x) if x > 0
We explained that if g and h are differentiable functions, then one can find f 0 (x) for x < 0
or x > 0 by computing the derivatives of g and k respectively. However, we always find f 0 (0)
from the definition of derivative since f (0 + h) can be either g(h) or k(h) depending on whether
h ! 0+ or h ! 0 .
It is not correct to find f 0 (0) by simply “plugging in x = 0” into g 0 (x) or k 0 (x), or letting
x ! 0 for g 0 (x) and k 0 (x). By doing so, you are attempting to find lim f 0 (x) instead, not f 0 (0).
x!0
The following example shows lim f 0 (x) and f 0 (0) could be different!
x!0
f (x) f (0)
f 0 (0) = lim
x!0 x 0
x2 sin x1 0
= lim
x!0 x
1
= lim x sin
x!0 x
=0
“Let f (x) = x1/3 . Since f 0 (x) = 3x12/3 for any x 6= 0, and f 0 (x) tends to 1 when
x ! 0, therefore f 0 (0) does not exist.”