Professional Documents
Culture Documents
MA1511 2021S1 Chapter 1 Partial Derivatives
MA1511 2021S1 Chapter 1 Partial Derivatives
MA1511
Any point (𝑥, 𝑦) in the domain 𝐷 will be mapped to a point 𝑃(𝑥, 𝑦, 𝑓(𝑥, 𝑦)) in the three-dimensional
space, with 𝑧 = 𝑓(𝑥, 𝑦) the 𝑧-coordinate of the point 𝑃.
When all such points are plotted, we get the graph of the function f. We call this graph a surface.
Graph of 𝒛 = 𝒇(𝒙, 𝒚)
(a surface)
Dr NG Wee Seng
Page 2
MA1511
A familiar example of a surface is the graph of the linear function 𝑧 = 5 – 𝑥 − 𝑦 . In the vector form,
this equation can be written as 𝐫 • (𝐢 + 𝐣 + 𝐤) = 𝟓 where 𝐫 = 𝑥 𝐢 + 𝑦𝐣 + 𝑧𝐤,
showing that the graph is a plane perpendicular to the vector i + j + k.
Level Curves
Geometrically, for any constant 𝑘, the horizontal plane 𝑧 = 𝑘 intersects the surface 𝑧 = 𝑓(𝑥, 𝑦)
along a curve, called a contour curve of height 𝒌, whose equation is 𝑓(𝑥, 𝑦) = 𝑘.
The projection of the contour curve onto the 𝑥𝑦 − plane is a level curve of 𝑓. Hence, a level curve
consists of the set of points (𝑥, 𝑦) for which 𝑓(𝑥, 𝑦) has a constant value.
An example:
Dr NG Wee Seng
Page 3
MA1511
Remark
Functions of three or more variables, 𝑧 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ) can be defined on some domain, 𝐷 of
points (𝑥1 , 𝑥2 , … , 𝑥𝑛 ) in a 𝑛 − dimensinal space . 𝑥1 , 𝑥2 , … , 𝑥𝑛 are the independent variables and z
is the dependent variable. The graph of 𝑓 is the set of points (𝑥1 , 𝑥2 , … , 𝑥𝑛 , 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ) ) in a
(n+1) - dimensional space.
Dr NG Wee Seng
Page 4
MA1511
The vertical plane whose equation is 𝑦 = 𝑏 intersects the surface 𝑧 = 𝑓(𝑥, 𝑦) along a curve on
this plane whose equation is 𝑧 = 𝑓(𝑥, 𝑏) (obtained by substituting 𝑦 = 𝑏 in = 𝑓(𝑥, 𝑦) ).
The gradient of the tangent line to this curve at the point 𝑃(𝑎, 𝑏, 𝑓(𝑎, 𝑏)) is called the partial
derivative of 𝒇 at (𝑎, 𝑏) with respect to 𝒙.
We denote this quantity by 𝑓𝑥 (𝑎, 𝑏). The subscript 𝑥 indicates that 𝑥 is the variable.
𝑓𝑥 (𝑎, 𝑏) gives the rate of change of 𝑓 at the point P (𝑎, 𝑏, 𝑓(𝑎, 𝑏)) in the direction of the 𝑥-axis.
Remark
We recall the mathematical definition of a derivative with respect to a single variable :
𝑓(𝑎 + ℎ, 𝑏) − 𝑓(𝑎, 𝑏)
𝑓𝑥 (𝑎, 𝑏) = lim
ℎ→0 ℎ
Dr NG Wee Seng
Page 5
MA1511
The vertical plane whose equation is 𝑥 = 𝑎 intersects the surface 𝑧 = 𝑓(𝑥, 𝑦) along a curve on
the plane whose equation is 𝑧 = 𝑓(𝑎, 𝑦) (obtained by substituting 𝑥 = 𝑎 in = 𝑓(𝑥, 𝑦) ).
The gradient of the tangent line to this curve at the point 𝑃(𝑎, 𝑏, 𝑓(𝑎, 𝑏)) is called the partial
derivative of 𝒇 at (𝑎, 𝑏) with respect to 𝒚.
We denote this quantity by 𝑓𝑦 (𝑎, 𝑏). The subscript 𝑦 indicates that 𝑦 is the variable.
𝑓𝑦 (𝑎, 𝑏) gives the rate of change of 𝑓 at the point where 𝑃 (𝑎, 𝑏, 𝑓(𝑎, 𝑏)) in the direction of the 𝑦-axis
Remark
We recall the mathematical definition of a derivative with respect to a single variable :
𝑓(𝑎, 𝑏 + ℎ) − 𝑓(𝑎, 𝑏)
𝑓𝑦 (𝑎, 𝑏) = lim
ℎ→0 ℎ
Notations
𝜕𝑓
The partial derivatives , 𝑓𝑥 (𝑎, 𝑏) and 𝑓𝑦 (𝑎, 𝑏) are also commonly denoted by 𝜕𝑥 (𝑎, 𝑏) and
𝜕𝑓
(𝑎, 𝑏) respectively. As a function of 𝑥 and 𝑦, with no reference to any specific point, the partial
𝜕𝑦
𝜕𝑓 𝜕𝑓
derivatives can be written as 𝑓𝑥 , , 𝑓𝑦 , .
𝜕𝑥 𝜕𝑦
𝜕𝑓 𝜕𝑓
The use of the symbol 𝜕 instead of 𝑑 in or indicates that the derivative is a partial
𝜕𝑥 𝜕𝑦
derivative of a function in more than one independent variable.
Dr NG Wee Seng
Page 6
MA1511
𝜕𝑓
For example, if 𝑓(𝑥, 𝑦) = 2𝑥 2 + 3𝑦 2 , then = 6𝑦 since the partial derivative of 3𝑦 2 with
𝜕𝑦
𝜕𝑓
respect to 𝑦 is 6𝑦 while the partial derivative of 2𝑥 2 with respect to y is zero. Similarly, = 4𝑥.
𝜕𝑥
Partial derivatives for functions of three or more variables can be defined and determined in a similar
fashion.
For example, if 𝑓(𝑥, 𝑦, 𝑧) = 2𝑥 + 𝑦 2 𝑧, then 𝑓𝑥 = 2, 𝑓𝑦 = 2𝑦𝑧 and 𝑓𝑧 = 𝑦 2 .
Since we are performing differentiation with respect to a single variable, the usual derivative formulae
and differentiation rules we have learnt from a single-variable Calculus course can be used.
For example, we shall need the following rules of differentiation for functions in one variable:
Rules of Differentiation
The following example illustrates the use of some of the above rules.
Video Example 1.2.1
Find the first order partial derivatives of
(a) 𝑓(𝑥, 𝑦) = 𝑥 3 + 𝑐𝑜𝑠𝑦
(b) 𝑔(𝑥, 𝑦) = 𝑥 3 𝑐𝑜𝑠𝑦
(c) ℎ(𝑥, 𝑦) = 2𝑦 3 cos(𝑥𝑦)
Dr NG Wee Seng
Page 7
MA1511
Differentiation of these functions produces the so-called second order partial derivatives of f
Notations we use are:
𝜕2 𝑓 𝜕 𝜕𝑓 𝜕𝑓
or 𝑓𝑥𝑥 denotes ( ) the partial derivative of w.r.t. 𝑥
𝜕𝑥 2 𝜕𝑥 𝜕𝑥 𝜕𝑥
𝜕2 𝑓 𝜕 𝜕𝑓 𝜕𝑓
or 𝑓𝑥𝑦 denotes ( ) the partial derivative of w.r.t. 𝑦
𝜕𝑦𝜕𝑥 𝜕𝑦 𝜕𝑥 𝜕𝑥
𝜕2 𝑓 𝜕 𝜕𝑓 𝜕𝑓
or 𝑓𝑦𝑥 denotes ( ) the partial derivative of w.r.t. 𝑥
𝜕𝑥𝜕𝑦 𝜕𝑥 𝜕𝑦 𝜕𝑦
𝜕2 𝑓 𝜕 𝜕𝑓 𝜕𝑓
or 𝑓𝑦𝑦 denotes ( ) the partial derivative of w.r.t. 𝑦
𝜕𝑦 2 𝜕𝑦 𝜕𝑦 𝜕𝑦
Second order partial derivatives will be required in subsequent topics such as the calculation of
extreme values (maxima or minima) of functions (in Chapters 1.7 & 1.8).
Dr NG Wee Seng
Page 8
MA1511
In the preceding example, the second order partial derivatives 𝑓𝑥𝑦 and 𝑓𝑦𝑥 are identical. It turns
out that this result holds for most commonly encountered function such as polynomials, exponential
and trigonometric functions.
Remarks
1. We shall assume that the above result holds for all functions we consider in this course.
2. Repeated differentiation of second order partial derivatives will produce partial derivatives of
order 3 and above. For example,
𝜕3 𝑓 𝜕 𝜕2 𝑓 𝜕2 𝑓
or 𝑓𝑥𝑦𝑦 denotes ( ) , the partial derivative of w.r.t. 𝑦
𝜕𝑦𝜕𝑦𝜕𝑥 𝜕𝑦 𝜕𝑦𝜕𝑥 𝜕𝑦𝜕𝑥
3. Higher order derivatives for functions of three or more variables can be defined in similar fashion.
For example, 𝑓(𝑥, 𝑦, 𝑧) = 2𝑥 + 𝑦 2 𝑧, then 𝑓𝑥 = 2, 𝑓𝑦 = 2𝑦𝑧 and 𝑓𝑧 = 𝑦 2 , so
𝜕 2𝑓 𝜕 𝜕𝑓 𝜕
or 𝑓𝑦𝑧 = ( )= ( 2𝑧𝑦) = 2𝑦
𝜕𝑧𝜕𝑦 𝜕𝑧 𝜕𝑦 𝜕𝑧
and so on.
Dr NG Wee Seng
Page 9
MA1511
𝑓𝑥 (𝑎, 𝑏)
Let 𝑃(𝑎, 𝑏, 𝑓(𝑎, 𝑏)) be a point on the surface 𝑧 = 𝑓(𝑥, 𝑦). It can be shown1 that the vector (𝑓𝑦 (𝑎, 𝑏))
−1
is a normal to the tangent plane at 𝑃. Hence, the vector equations of the tangent plane and normal line
at 𝑃 can be determined.
3
For example, if P has coordinates (1, 2, 3) and a normal vector at P is found to be the vector ( 2 ),
−1
then a vector equation of the tangent plane is
3 1 3
𝐫 ( 2 ) = (2 ) ( 2 )
−1 3 −1
𝑥
where 𝐫 = (𝑦) is the position vector of any point on the plane, and a vector equation for the
𝑧
normal line through P is
1 3
𝐫 = (2) + ( 2 ) 𝑡, 𝑡 ∈ 𝐑
3 −1
𝑥
where 𝐫 = (𝑦) is the position vector of any point on the normal line.
𝑧
1
Refer to the proof in LUMINUS > Files > Supplementary Slides folder
Dr NG Wee Seng
Page 10
MA1511
𝑓𝑥 (𝑎, 𝑏) 𝑎 𝑓𝑥 (𝑎, 𝑏)
𝐫 (𝑓𝑦 (𝑎, 𝑏)) = ( 𝑏 ) • (𝑓𝑦 (𝑎, 𝑏))
−1 𝑓(𝑎, 𝑏) −1
𝑥
where 𝐫 = (𝑦).
𝑧
Equivalently, a Cartesian equation of the plane is
𝑧 = 𝑓𝑥 (𝑎, 𝑏) ∙ (𝑥 − 𝑎) + 𝑓𝑦 (𝑎, 𝑏) ∙ (𝑦 − 𝑏) + 𝑓(𝑎, 𝑏)
Result 1.4B
The equation of the normal line at 𝑃 (which is the line passing through P and perpendicular to the
tangent plane ) is
𝑎 𝑓𝑥 (𝑎, 𝑏)
𝐫 = ( 𝑏 ) + (𝑓𝑦 (𝑎, 𝑏)) 𝑡, 𝑡 ∈ 𝐑
𝑓(𝑎, 𝑏) −1
𝑥 2 −12
Answers: tangent plane : 𝑧 = −12𝑥 − 8𝑦 + 48; Normal line : (𝑦) = ( 1 ) + ( −8 ) 𝑡 , 𝑡∈𝑹
𝑧 16 −1
Dr NG Wee Seng
Page 11
MA1511
One way to remember result 1.5A is to draw the following tree diagram :
Given that 𝑧 = 3𝑥 2 + 𝑦 2 , 𝑥 = 𝑡 3 −𝑒 𝑡 and 𝑦 = 𝑒 𝑡 + 𝑡 , use the chain rule to find the value of
𝑑𝑧
when 𝑡 = 0
𝑑𝑡
Answer: 10
Dr NG Wee Seng
Page 12
MA1511
One typical application of the above rule is the calculation of rate of change of a function in two
variables.
For example, if we know that the length 𝑥 and breadth 𝑦 of a rectangle are both increasing at 2 cm s-1,
we can easily find the rate of change of the area, 𝑧 = 𝑥𝑦 of the rectangle for any (𝑥, 𝑦), say 𝑥 = 2
cm and 𝑦 = 3 cm, by using the chain rule:
𝑑𝑧 𝜕𝑧 𝑑𝑥 𝜕𝑧 𝑑𝑦
= × + × = 2𝑦 + 2𝑥 = 10 cm2 s-1
𝑑𝑡 𝜕𝑥 𝑑𝑡 𝜕𝑦 𝑑𝑡
Dr NG Wee Seng
Page 13
MA1511
We can extend the chain rule on 𝑓(𝑥, 𝑦) by allowing x and y to depend on more than one independent
variable.
Chain Rule with Two Independent Variables
Result 1.5B
If 𝑧 is a function of 𝑥 and 𝑦, and both 𝑥 and 𝑦 are functions of two independent variables
s , 𝑡, then
𝜕𝑧 𝜕𝑧 𝜕𝑥 𝜕𝑧 𝜕𝑦
= × + ×
𝜕𝑠 𝜕𝑥 𝜕𝑠 𝜕𝑦 𝜕𝑠
𝜕𝑧 𝜕𝑧 𝜕𝑥 𝜕𝑧 𝜕𝑦
= × + ×
𝜕𝑡 𝜕𝑥 𝜕𝑡 𝜕𝑦 𝜕𝑡
One way to remember result 1.5B is to draw the following tree diagrams:
𝝏𝒛 𝝏𝒛
𝒅𝒔 𝒅𝒕
2 2
Answer: 8𝑠𝑡 − 6𝑡 ; 4𝑠 − 12𝑠𝑡
Dr NG Wee Seng
Page 14
MA1511
Directional Derivative
Given a surface 𝑧 = 𝑓(𝑥, 𝑦), a point 𝑃(𝑎, 𝑏, 𝑓(𝑎, 𝑏)) on the surface and a direction unit vector u =
𝑢1 i + 𝑢2 j , the vertical plane containing P and parallel to u intersects the surface along a curve . The
gradient of the tangent to this curve at 𝑃 is called the directional derivative of 𝑓(𝑥, 𝑦) at (𝑎, 𝑏) in
the direction of u. We denote this derivative by 𝐷𝐮 𝑓(𝑎, 𝑏).
We can interpret 𝐷𝐮 𝑓(𝑎, 𝑏) as the rate of change of the function 𝑓(𝑥, 𝑦) when (𝑥, 𝑦) lies on the line
passing through 𝑄(𝑎, 𝑏) and in the direction of the vector u.
tangent at P
Remark
For any unit vector u = 𝑢1 i + 𝑢2 j , the mathematical definition of derivative gives
f (a hu1 , b hu 2 ) f (a, b)
𝐷𝐮 𝑓(𝑎, 𝑏) = lim
h 0 h
Dr NG Wee Seng
Page 15
MA1511
The following result2 provides us with an efficient way to compute directional derivatives.
Result 1.6A
For any unit vector u = 𝑢1 i + 𝑢2 j ,
𝑓𝑥 (𝑎, 𝑏) 𝑢1
𝐷𝐮 𝑓(𝑎, 𝑏) = 𝑢1 𝑓𝑥 (𝑎, 𝑏) + 𝑢2 𝑓𝑦 (𝑎, 𝑏) = ( ) (𝑢 )
𝑓𝑦 (𝑎, 𝑏) 2
Remarks
1. If the given direction vector 𝑢1 i + 𝑢2 j is not a unit vector, we can normalise the vector to
get a unit vector:
1
u= (𝑢1 i + 𝑢2 j )
2
√𝑢1 +𝑢2 2
𝐷𝐮 𝑓(𝑎, 𝑏) = ∇𝑓(𝑎, 𝑏) 𝐮
3. The first order partial derivatives of 𝑓 are special cases of directional derivatives. Specifically,
4. Directional derivatives for functions of three or more variables can be defined in a similar
fashion.
𝑓𝑥 (𝑎, 𝑏, 𝑐) 𝑢1
𝐷𝐮 𝑓(𝑎, 𝑏, 𝑐) = 𝑢1 𝑓𝑥 (𝑎, 𝑏, 𝑐) + 𝑢2 𝑓𝑦 (𝑎, 𝑏, 𝑐) + 𝑢3 𝑓𝑧 (𝑎, 𝑏, 𝑐) 𝑓
= (𝑦 (𝑎, 𝑏, 𝑐) 𝑢
) ( 2)
𝑓𝑧 (𝑎, 𝑏, 𝑐) 𝑢3
2
Refer to the proof in LUMINUS > Files > Supplementary Slides folder
Dr NG Wee Seng
Page 16
MA1511
−4 4
13
Answers (i) − (ii) (√17 √17
1 ) , ( −1 )
5
√17 √17
Dr NG Wee Seng
Page 17
MA1511
Local Maximum
𝑓 has a local maximum at (𝑎, 𝑏) if 𝑓(𝑎, 𝑏) ≥ 𝑓(𝑥, 𝑦) for all (𝑥, 𝑦) in some open subset of 𝐷
containing (𝑎, 𝑏)
Local Minimum
𝑓 has a local minimum at (𝑎, 𝑏) if 𝑓(𝑎, 𝑏) ≤ 𝑓(𝑥, 𝑦) for all (𝑥, 𝑦) in some open subset of 𝐷
containing (𝑎, 𝑏)
We recall from single−variable calculus that if a differentiable function 𝑓(𝑥) in one variable has a
local maximum/minimum at 𝑥 = 𝑐, then 𝑓 ′ (𝑐) = 0. An analogous result holds for functions in two
variables.
Result 1.7A
If 𝑓 has a local maximum/minimum at an interior point (𝑎, 𝑏) of its domain, then
𝑓𝑥 (𝑎, 𝑏) = 0 and 𝑓𝑦 (𝑎, 𝑏) = 0
Critical Point
MA1511
Result 1.7A says that a local maximum or a local minimum occurs only at a critical point. Hence, to
locate local maximum or local minimum of 𝑓(𝑥, 𝑦), we will solve the simultaneous equations
𝑓𝑥 = 0 and 𝑓𝑦 = 0
for all possible critical points. The nature (local maximum or local minimum, or neither) can be
determined using the following derivative test
Remarks
2
1. The term 𝐷 = 𝑓𝑥𝑥 (𝑎, 𝑏)𝑓𝑦𝑦 (𝑎, 𝑏) − (𝑓𝑥𝑦 (𝑎, 𝑏)) is known as a discriminant
Dr NG Wee Seng
Page 19
MA1511
Dr NG Wee Seng
Page 20
MA1511
Dr NG Wee Seng
Page 21
MA1511
Given a function 𝑓(𝑥, 𝑦), we seek the extreme values of 𝑓 when (𝑥, 𝑦) is subject to one constraint
given by an equation of the form
𝑔(𝑥, 𝑦) = 0
Geometrically, we find the maximum/minimum values of 𝑓(𝑥, 𝑦) for points (𝑥, 𝑦) lying on the curve
whose equation is 𝑔(𝑥, 𝑦) = 0.
To find largest/smallest
value of f along this curve
Result 1.8A
Dr NG Wee Seng
Page 22
MA1511
Remarks
Geometrically, the equations
𝑓𝑥 = λ𝑔𝑥 , 𝑓𝑦 = λ𝑔𝑦 ,
indicate that the maximum or minimum occurs at a point where the gradient vector of 𝑓 is parallel to
the gradient vector of 𝑔, as depicted in the diagram below.
Dr NG Wee Seng
Page 23
MA1511
Dr NG Wee Seng
Page 24
MA1511
𝑔(𝑥1 , 𝑥2 , … , 𝑥𝑛 ) = 0
for some constant λ , called the Lagrange multiplier
End of Chapter 1
“Mathematics is the art of giving the same name to different things.” – Henri Poincaré
Dr NG Wee Seng