You are on page 1of 35

MATH 28 MANUAL

UNIT III. PARTIAL DERIVATIVES

By the end of the unit, you must be able to


✓ sketch the graph of a function of several variables;
✓ determine the partial derivatives of a function of several variables;
✓ determine the directional derivatives of a function of several variables; and
✓ apply Lagrange method in solving optimization problems.

Sections
1. Functions of several variables
2. Contour maps and graphs
* Limits and continuity (an overview)
3. Partial derivatives
4. Higher-order and chain rule for partial differentiation
* Total derivative and differentiability (an overview)
5. Gradient and directional derivative
6. Extrema of functions of several variables
7. Lagrange optimization
8. Tangent plane and total differential

____________________________________________

Section 1. FUNCTION OF SEVERAL VARIABLES

By the end of this section, you must be able to


✓ determine the domain and range of a function of several variables;
✓ draw the region representing the domain of a function; and
✓ sketch the graph of functions from known surfaces.

Review.
• A function from 𝐴 to 𝐵, denoted by 𝑓: 𝐴 ⟶ 𝐵, is a mapping in which each element of 𝐴 is paired
with exactly one element of 𝐵.
• A real-valued function is of the form 𝑓: ℝ ⟶ ℝ where 𝑦 = 𝑓(𝑥). This is a function of a single
variable.
• Geometrically, a function 𝑓: ℝ ⟶ ℝ where 𝑦 = 𝑓(𝑥) describes a curve on the coordinate plane ℝ2
containing the point (𝑥, 𝑓(𝑥)).

We consider functions of several variables of the form 𝑓: ℝ𝑛 ⟶ ℝ where 𝑦 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ). We first


describe the space ℝ𝑛 .

Definition.
The space ℝ𝑛 is the set of all ordered 𝑛 −tuples of real numbers called the 𝒏 −dimensional number
space.
ℝ𝑛 = {(𝑥1 , 𝑥2 , … , 𝑥𝑛 )| 𝑥𝑖 ∈ ℝ}

A point in ℝ𝑛 is of the form (𝑥1 , 𝑥2 , … , 𝑥𝑛 ).

Remarks: ℝ the real number line


ℝ2 = {(𝑥, 𝑦)| 𝑥, 𝑦 ∈ ℝ} the two-dimensional coordinate system or the Cartesian plane
ℝ3 = {(𝑥, 𝑦, 𝑧)| 𝑥, 𝑦, 𝑧 ∈ ℝ} the three-dimensional number space:

In ℝ𝑛 , the distance between two points 𝑃(𝑥1 , 𝑥2 , … , 𝑥𝑛 ) and 𝑄(𝑦1 , 𝑦2 , … , 𝑦𝑛 ) is given by


̅̅̅̅ ) = √((𝑥1 − 𝑦1 )2 + (𝑥2 − 𝑦2 )2 + ⋯ + (𝑥𝑛 − 𝑦𝑛 )2 ) .
𝑑(𝑃, 𝑄) = 𝑙(𝑃𝑄

Illustrations.
1. Given the points 𝑃(1, −2) and 𝑄(−2,3) in Cartesian plane, the distance between 𝑃 and 𝑄 is
2
𝑑(𝑃, 𝑄) = √(1 − (−2)) + (−2 − 3)2 = √34 units.
2. The length of the segment whose endpoints are 𝐴(0,1, −3) and 𝐵(−1, −4,2) in ℝ3 is also the
distance between the two points. So, the length is
2 2
𝑑(𝐴, 𝐵) = √(0 − (−1)) + (1 − (−4)) + (−3 − 2)2 = √51 units.

We now define functions on 𝑛 variables of the form 𝑓: ℝ𝑛 ⟶ ℝ where 𝑦 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ).

Definition.
A real-valued function on 𝒏 variables is a function 𝑓: ℝ𝑛 ⟶ ℝ of the form 𝑤 = 𝑓(𝑃) where 𝑃 ∈ ℝ𝑛
and 𝑤 ∈ ℝ. The domain of 𝑓, denoted by 𝐷𝑓 is the set of admissible values of 𝑃. The range of 𝑓,
denoted by 𝑅𝑓 , is the set of all resulting 𝑤.

Illustrations.
The following are real-valued functions of two and three variables and the corresponding domain and
range.

1. 𝑓(𝑥, 𝑦) = √4 − 𝑥 2 − 𝑦 2
𝐷𝑓 = {(𝑥, 𝑦)| 4 − 𝑥 2 − 𝑦 2 ≥ 0}
= {(𝑥, 𝑦)| 𝑥 2 + 𝑦 2 ≤ 4}
𝑅𝑓 = [0,2]

2. 𝑔(𝑥, 𝑦) = 4 − 𝑥 2 − 𝑦 2
𝐷𝑔 = ℝ2
𝑅𝑔 = (−∞, 4)

1
3. ℎ(𝑥, 𝑦, 𝑧) =
9−𝑥 2 −𝑦 2 −𝑧 2
𝐷ℎ = {(𝑥, 𝑦, 𝑧)| 9 − 𝑥 − 𝑦 2 − 𝑧 2 ≠ 0}
2

= {(𝑥, 𝑦, 𝑧)| 𝑥 2 + 𝑦 2 + 𝑧 2 ≠ 9}
1
𝑅ℎ = [ , +∞)
9

1
4. 𝑢(𝑥, 𝑦, 𝑧) = 𝑙𝑛𝑥 + √𝑦 +
𝑧
𝐷𝑢 = {(𝑥, 𝑦, 𝑧)| 𝑥 > 0, 𝑦 > 0, 𝑧 ≠ 0 }
𝑅𝑢 = ℝ

As an exercise, sketch the indicated domain on the ℝ2 −space or the ℝ3 −space.

Definition.
Given 𝑤 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ), the graph of 𝑓 is the set of all points (𝑥1 , 𝑥2 , … , 𝑥𝑛 , 𝑤) ∈ ℝ𝑛+1 where
(𝑥1 , 𝑥2 , … , 𝑥𝑛 , 𝑤) ∈ 𝐷𝑓 .

Due to geometric limitations, we can only represent objects in spaces up to three dimensions. So, we
can only sketch the graphs of functions of up to two variables.

The graph of a function 𝑦 = 𝑓(𝑥) is a curve in ℝ2 comprised of the points (𝑥, 𝑦).
The graph of a function 𝑧 = 𝑓(𝑥, 𝑦) is a surface on ℝ3 comprised of the points (𝑥, 𝑦, 𝑧).

The graph of a function 𝑤 = 𝑓(𝑥, 𝑦, 𝑧) is an object on ℝ𝑛 . Such an object cannot be represented


geometrically.
Examples.
1. 𝑓(𝑥, 𝑦) = √4 − 𝑥 2 − 𝑦 2

𝐷𝑓 = {(𝑥, 𝑦)| 𝑥 2 + 𝑦 2 ≤ 4}
𝑅𝑓 = [0,4]

To obtain the graph of 𝑓,


we set 𝑧 = √4 − 𝑥 2 − 𝑦 2 .
We obtain 𝑥 2 + 𝑦 2 + 𝑧 2 = 4 which is a sphere.

Note that the principal square root does not allow


for negative values of 𝑧. Hence, we only consider
the hemisphere corresponding to the non-negative
values of 𝑧.

With the graph, verify the indicated domain and range.

2. 𝑔(𝑥, 𝑦) = 4 − 𝑥 2 − 𝑦 2

𝐷𝑔 = ℝ2
𝑅𝑔 = (−∞, 4)

To obtain the graph of 𝑓,


we set 𝑧 = 4 − 𝑥 2 − 𝑦 2 .
This is an equation of a paraboloid.
Refer to Unit 2’s discussion on quadric surfaces

With the graph, verify the indicated domain and range.

In the next section, we discuss the use of contour maps and level curves in graphing functions.

__________________________

Concept Recap
1. What is a function on 𝑛 variables?
2. What is the domain of a function? a range?
3. How can the domain of a functions be obtained? How about its range?
4. What is a graph of a function?
5. Geometrically, why are graphs of functions restricted only up to functions on two variables?

Practice Exercises
Determine the domain and range of the following functions. For the domain, take note of the
appropriate ℝ𝑛 space. You may have to use alternative methods in obtaining the range.

1. 𝑓(𝑥, 𝑦) = 10 − 2𝑥 + 5𝑦
1
2. 𝑔(𝑥, 𝑦) = 2 2
𝑥 +𝑦

3. ℎ(𝑥, 𝑦) = √ 𝑦 − 𝑥 Sketch the region corresponding to the domain.


1
4. 𝜑(𝑥, 𝑦) = Sketch the region corresponding to the domain.
√𝑦−𝑥 2
cos 𝑦
5. 𝜃(𝑥, 𝑦) =
sin 𝑥
1
6. 𝜔(𝑥, 𝑦) = Sketch the region corresponding to the domain.
√𝑥 2 +𝑦 2 −9

7. 𝑓(𝑥, 𝑦, 𝑧) = √ 50 − 𝑥 2 − 𝑦 2 − 𝑧 2 Sketch the solid corresponding to the domain.


8. 𝑔(𝑥, 𝑦, 𝑧) = 3𝑥𝑦 − 𝑦𝑧 + 2𝑥𝑧
𝑧
9. ℎ(𝑥, 𝑦, 𝑧) = Sketch the solid corresponding to the domain.
√4−𝑥 2 −𝑦 2
1 1 1
10. 𝜑(𝑥, 𝑦, 𝑧) = +𝑦+𝑧
𝑥
𝑥+𝑦
11. 𝑓(𝑥, 𝑦, 𝑧, 𝑤) = 2
𝑧 +𝑤2
12. 𝑔(𝑥, 𝑦, 𝑧, 𝑤) = 𝑧 tan 𝑦 + 𝑦𝑒 𝑥 + 𝑥 log 2 𝑤

Sketch the graphs of the following functions on two variables. Do this by expressing the equation in
standard forms. Refer to Unit 2’s discussions on surfaces.
Note: Verify the domain and range of the function with its graph.
13. 𝑓(𝑥, 𝑦) = 2𝑦 − 𝑥 − 4
14. 𝑔(𝑥, 𝑦) = 𝑥 2 + 𝑦 2 − 8
15. ℎ(𝑥, 𝑦) = √𝑥 2 + 𝑦 2 − 16

16. 𝜑(𝑥, 𝑦) = √20 − 4𝑥 2 − 5𝑦 2


17. 𝜔(𝑥, 𝑦) = 9 − 𝑦 2
____________________________________________

Section 2. CONTOUR MAPS and GRAPHS

By the end of this section, you must be able to


✓ draw contour map of a function of two or three variables; and
✓ sketch the graph of a function of two variables using a contour map.

Definitions.
Let 𝑓: ℝ2 ⟶ ℝ where 𝑧 = 𝑓(𝑥, 𝑦) and 𝑘 ∈ ℝ.
A level curve of 𝑓 at 𝑧 = 𝑘 is the curve with equation 𝑓(𝑥, 𝑦) = 𝑘.

A contour map of a function 𝑓 is a collection of level curves on ℝ2 of the function at different function
values of 𝑓. The curves are labeled by the corresponding function values.

How to sketch a graph using a contour map


Given a contour map of a function 𝑧 = 𝑓(𝑥, 𝑦), the curves can be positioned at proper levels of 𝑧 = 𝑘
in ℝ3 . The level curves are cross-sections of the surface defined by the function. Additional lateral
sections or the traces over the 𝑥𝑦 −plane, 𝑥𝑧 −plane and 𝑦𝑧 −plane can also be used to give a better
picture of the graph.

Examples.
1
1. Consider the function 𝑧 = 𝑔(𝑥, 𝑦) = .
𝑥 2 +𝑦 2
2
Note 𝐷𝑔 = ℝ − {(0,0)} and 𝑅𝑔 = {𝑧|𝑧 > 0}.

1
For 𝑘 > 0, the level curve of 𝑔 at 𝑧 = 𝑘 is the circle 𝑥 2 + 𝑦 2 = .
𝑘
The contour map of 𝑓 with level curves Placing the level curves at the corresponding
1 1
at 𝑧 = , , 1,2,4. value of 𝑧, we obtain the following graph:
4 2

2. Consider the function 𝑧 = 𝑓(𝑥, 𝑦) = 𝑦 − 𝑥 2 .


Note 𝐷𝑓 = ℝ2 and 𝑅𝑓 = ℝ.

For 𝑘 ∈ ℝ, the level curve of 𝑓 at 𝑧 = 𝑘 is the parabola 𝑦 = 𝑥 2 + 𝑘.

The contour map of 𝑓 with level curves Placing the level curves at the corresponding
at 𝑧 = −4, −1,0,1,2. value of 𝑧, we obtain the following graph:

Definitions.
Let 𝑓: ℝ3 ⟶ ℝ where 𝑤 = 𝑓(𝑥, 𝑦, 𝑧) and 𝑘 ∈ ℝ.
A level surface of 𝑓 at 𝑤 = 𝑘 is the curve with equation 𝑓(𝑥, 𝑦, 𝑧) = 𝑘.
A contour map of a function 𝑓 is a collection of level surfaces of the function at different function
values of 𝑓. The surfaces are labeled by the corresponding function values.

Due to limitations, we cannot represent geometrically the graph in ℝ4 of a function of three variables.
We only sketch a contour map of the graph. The contour map of 𝑤 = 𝑓(𝑥, 𝑦, 𝑧) is comprised of level
surfaces at different values of 𝑤.
Examples.

1. 𝑤 = 𝑔(𝑥, 𝑦, 𝑧) = 𝑥 2 + 𝑦 2 − 𝑧
𝐷𝑔 = ℝ3 𝑅𝑔 = ℝ.

For 𝑘 ∈ ℝ, the level surface of 𝑓 at 𝑤 = 𝑘


is the paraboloid 𝑧 = 𝑥 2 + 𝑦 2 − 𝑘.

On the right is a contour map with level surfaces


at 𝑤 = −1,0,1,2

2. 𝑤 = 𝑓(𝑥, 𝑦, 𝑧) = 𝑥 2 + 𝑦 2 + 𝑧 2 .
𝐷𝑓 = ℝ3 𝑅𝑓 = {𝑤|𝑤 ≥ 0}.

For 𝑘 > 0, the level surface of 𝑓 at 𝑤 = 𝑘


is the sphere 𝑥 2 + 𝑦 2 + 𝑧 2 = 𝑘.

A contour map of this function is composed of spheres centered at the origin with different radii.

READ ON how contour maps are used in meteorology to create weather maps, in geology for
topographical maps, in statistics for population density maps, and in economics to represent utility
functions and production functions.

__________________________

Concept Recap
1. What is a contour map?
2. How can a contour map be used to sketch a graph of a function 𝑧 = 𝑓(𝑥, 𝑦)?
3. How does a contour map of a function 𝑤 = 𝑓(𝑥, 𝑦, 𝑧) look like?

Practice Exercises
Draw a contour map of the following functions on two variables using the given values of 𝑧.
Then, using the contour map, give a sketch of the graph of the function.
Note of the domain and the range!

1. 𝑧 = 𝑓(𝑥, 𝑦) = √ 𝑥 + 𝑦 level curves at 𝑧 = 0,1, √2, 2, √5


2. 𝑧 = 𝑔(𝑥, 𝑦) = 𝑥 − 𝑦 2 level curves at 𝑧 = −2, −1,0,1,2
3. 𝑧 = ℎ(𝑥, 𝑦) = √𝑦 − 𝑥 2 level curves at 𝑧 = 0,1, √2, 2, √5
4. 𝑧 = 𝛾(𝑥, 𝑦) = 𝑥𝑦 level curves at 𝑧 = −2, −1,01,2
1
5. 𝑧 = 𝜑(𝑥, 𝑦) = level curves at 𝑧 = −2, −1,1,2,3
𝑥+𝑦
𝑥2 1 1 1
6. 𝑧 = 𝜔(𝑥, 𝑦) = 2 2 level curves at 𝑧 = 0, , , ,1
𝑥 +𝑦 10 5 2

Draw a contour map of the following functions on three variables using the given values of 𝑤.
7. 𝑤 = 𝑓(𝑥, 𝑦, 𝑧) = 2𝑥 + 3𝑦 − 𝑧 level curves at 𝑧 = −6, −2,0,3,6
8. 𝑤 = 𝑔(𝑥, 𝑦, 𝑧) = √𝑥 2 + 𝑦 2 + 𝑧 2 level curves at 𝑧 = 0,1, √2, 2, √5
1 1 1
9. 𝑤 = ℎ(𝑥, 𝑦, 𝑧) = 2 2 2 level curves at 𝑧 = , , 1,2.4
𝑥 +𝑦 +𝑧 4 2
𝑧
10. 𝑧 = 𝜑(𝑥, 𝑦) = level curves at 𝑧 = −2, −1,0,1,2
𝑥+𝑦

____________________________________________
*LIMITS and CONTINUITY (an overview)

Consider a function 𝑧 = 𝑓(𝑥, 𝑦) and a point 𝑃(𝑎, 𝑏) ∈ ℝ2 .

To compute for 𝑙𝑖𝑚 𝑓(𝑥, 𝑦), we can treat this like a usual limit problem for a function of a single
(𝑥,𝑦)→(𝑎,𝑏)
variable. However, it should be taken into consideration that there many ways to approach the point
(𝑎, 𝑏).

For a function of a single variable 𝑦 = 𝑓(𝑥),


to compute for 𝑙𝑖𝑚 𝑓(𝑥), we only consider
𝑥→𝑎
• limit from the right 𝑙𝑖𝑚+ 𝑓(𝑥); and
𝑥→𝑎
• limit from the left 𝑙𝑖𝑚− 𝑓(𝑥).
𝑥→𝑎

For a function of two variables 𝑧 = 𝑓(𝑥, 𝑦),


to compute for 𝑙𝑖𝑚 𝑓(𝑥, 𝑦),
(𝑥,𝑦)→(𝑎,𝑏)
we have to consider the different ways to
approach the point (𝑎, 𝑏) from every possible
directions.

For the limit 𝑙𝑖𝑚 𝑓(𝑥, 𝑦) to exist,


(𝑥,𝑦)→(𝑎,𝑏)
a common value should be obtained upon
computing for the limit from any direction.

This also the case in computing for the limit of


a function 𝑤 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ) on 𝑛 variables.

Definition.
Let 𝑤 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ) be a function of 𝑛 variables and 𝑃 ∈ ℝ𝑛 . Denote by 𝑋 = (𝑥1 , 𝑥2 , … , 𝑥𝑛 ).

Then 𝑓 is continuous at 𝑃 if the following conditions are satisfied:


i. 𝑓(𝑃) is defined;
ii. 𝑙𝑖𝑚 𝑓(𝑋) exists; and
𝑋→𝑃
iii. 𝑙𝑖𝑚 𝑓(𝑋) = 𝑓(𝑃)
𝑋→𝑃

Like in a function 𝑦 = 𝑓(𝑥) on a single variable, continuity of a function 𝑤 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ) can be


interpreted geometrically of the function having a “continuous” graph.

Theorems.
1. Polynomial functions are continuous everywhere.
2. Rational functions are continuous over their respective domains.
3. If f and g are functions on n variables that are continuous at P Rn , then the following are
f
also continuous at P : f + g , f − g , f  g and , provided g ( P )  0 .
g
____________________________________________
Section 3. PARTIAL DERIVATIVES

By the end of this section, you must be able to


✓ state the definition of a partial derivative;
✓ implement the notations for partial derivatives;
✓ determine the partial derivatives of a function of several variables ; and
✓ discuss the geometric interpretation of partial derivative.

REVIEW.
𝑑𝑦
Given 𝑦 = 𝑓(𝑥), recall that the derivative of 𝑓, denoted by , is given by
𝑑𝑥
𝑑𝑦 𝑓(𝑥+ℎ)−𝑓(𝑥)
= 𝑙𝑖𝑚 if this limit exists.
𝑑𝑥 ℎ→0 ℎ

𝑑𝑦
Note that gives the slope of the tangent line to graph of 𝑓 at the point (𝑥, 𝑦).
𝑑𝑥
It is also interpreted as the rate of change of 𝑓 at the particular value 𝑥.

Definitions.
𝜕𝑧
Let 𝑧 = 𝑓(𝑥, 𝑦). The partial derivative of 𝑓 with respect to 𝑥, denoted by , is given by
𝜕𝑥
𝜕𝑧 𝑓(𝑥 + ℎ, 𝑦) − 𝑓(𝑥, 𝑦)
= 𝑙𝑖𝑚
𝜕𝑥 ℎ→0 ℎ
if this limit exists.

𝜕𝑧
Similarly, the partial derivative of 𝑓 with respect to 𝑦, denoted by , is given by
𝜕𝑦
𝜕𝑧 𝑓(𝑥, 𝑦 + ℎ) − 𝑓(𝑥, 𝑦)
= 𝑙𝑖𝑚
𝜕𝑦 ℎ→0 ℎ
if this limit exists.

𝜕𝑦
In general, given 𝑦 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ), The partial derivative of 𝑓 with respect to 𝑥𝑘 , denoted by , is
𝜕𝑥𝑘
given by
𝜕𝑦 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑘 + ℎ, … , 𝑥𝑛 ) − 𝑓(𝑥1 , 𝑥2 , … . , 𝑥𝑛 )
= 𝑙𝑖𝑚
𝜕𝑥𝑘 ℎ→0 ℎ
if this limit exists.

Notations: The following are alternative notations for partial derivatives.

Given 𝑧 = 𝑓(𝑥, 𝑦),


𝜕𝑧 𝜕𝑓
partial derivative of 𝑓 with respect to 𝑥: 𝐷𝑥 𝑓 𝑓𝑥
𝜕𝑥 𝜕𝑥
𝜕𝑧 𝜕𝑓
partial derivative of 𝑓 with respect to 𝑦: 𝐷𝑦 𝑓 𝑓𝑦
𝜕𝑦 𝜕𝑦

Given 𝑦 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 ),
𝜕𝑦 𝜕𝑓
partial derivative of 𝑓 with respect to 𝑥𝑘 : 𝐷𝑥𝑘 𝑓 𝑓𝑥𝑘
𝜕𝑥𝑘 𝜕𝑥𝑘

We first illustrate using the definition to obtain partial derivatives.


Illustration.
Let 𝑓(𝑥, 𝑦) = 𝑥 2 + 𝑥𝑦 + 3𝑦, then the partial derivative of 𝑓 with respect to 𝑥 is given by
𝜕𝑓 𝑓(𝑥 + ℎ, 𝑦) − 𝑓(𝑥, 𝑦)
= 𝑙𝑖𝑚
𝜕𝑥 ℎ→0 ℎ
[(𝑥 + ℎ)2 + (𝑥 + ℎ)𝑦 + 3𝑦] − (𝑥 2 + 𝑥𝑦 + 3𝑦)
= 𝑙𝑖𝑚
ℎ→0 ℎ
[(𝑥 2 + 2𝑥ℎ + ℎ2 ) + (𝑥𝑦 + ℎ𝑦) + 3𝑦] − (𝑥 2 + 𝑥𝑦 + 3𝑦)
= 𝑙𝑖𝑚
ℎ→0 ℎ
2𝑥ℎ + ℎ2 + ℎ𝑦
= 𝑙𝑖𝑚
ℎ→0 ℎ
= 𝑙𝑖𝑚(2𝑥 + ℎ + 𝑦)
ℎ→0
= 2𝑥 + 𝑦.

Similarly, the partial derivative of 𝑓 with respect to 𝑦 is given by

𝜕𝑓 𝑓(𝑥, 𝑦 + ℎ) − 𝑓(𝑥, 𝑦)
= 𝑙𝑖𝑚
𝜕𝑦 ℎ→0 ℎ
[𝑥 2 + 𝑥(𝑦 + ℎ) + 3(𝑦 + ℎ)] − (𝑥 2 + 𝑥𝑦 + 3𝑦)
= 𝑙𝑖𝑚
ℎ→0 ℎ
(𝑥 2 + 𝑥𝑦 + 𝑥ℎ + 3𝑦 + 3ℎ) − (𝑥 2 + 𝑥𝑦 + 3𝑦)
= 𝑙𝑖𝑚
ℎ→0 ℎ
𝑥ℎ + 3ℎ
= 𝑙𝑖𝑚
ℎ→0 ℎ
= 𝑙𝑖𝑚(𝑥 + 3)
ℎ→0
= 𝑥 + 3.

𝜕𝑓 𝜕𝑓
From the computations, = 2𝑥 + 𝑦 and = 𝑥 + 3.
𝜕𝑥 𝜕𝑦

How to compute for partial derivatives

The rules of differentiation in basic calculus can be used to compute for partial derivatives

Given: 𝑤 = 𝑓(𝑥1 , 𝑥2 , … , 𝑥𝑛 )
𝜕𝑤
To solve for , use basic differentiation techniques for functions of a single variable
𝜕𝑥𝑘
with 𝑥𝑘 as the variable and treating other variables as constants.

In particular, for 𝑧 = 𝑓(𝑥, 𝑦),


𝜕𝑧
• the partial derivative can be obtained
𝜕𝑥
by taking the derivative with 𝑥 as the variable and
treating 𝑦 as a constant; and
𝜕𝑧
• the partial derivative can be obtained
𝜕𝑦
by taking the derivative with 𝑦 as the variable and
treating 𝑥 as a constant.

Remember to properly implement chain rule, product rule and quotient rule for differentiation.

Examples. The following are partial derivatives of functions on two variables.


1. 𝑓(𝑥, 𝑦) = 𝑥 2 + 𝑦 2 + 7𝑥 − 11𝑦 + 16
𝜕𝑓
= 2𝑥 + 7
𝜕𝑥
𝜕𝑓
= 2𝑦 − 11
𝜕𝑦
2. 𝑓(𝑥, 𝑦) = 𝑥 3 𝑦 3 + 2𝑥𝑦 − 3𝑥 4 + 2𝑦 − 10
𝜕𝑓
= 3𝑥 2 𝑦 3 + 2𝑦 − 12𝑥 3
𝜕𝑥
𝜕𝑓
= 3𝑥 3 𝑦 2 − 2𝑥 + 2
𝜕𝑦

𝜕𝑓 𝑦
= 𝑦 cos(𝑥𝑦) +
𝜕𝑥 𝑥
𝜕𝑓
= 𝑦 cos(𝑥𝑦) + 𝑙𝑛𝑥
𝜕𝑦

3. 𝑓(𝑥, 𝑦) = 𝑥𝑠𝑖𝑛𝑥 + 𝑥𝑐𝑜𝑠𝑦 + 𝑦𝑒 𝑦


𝜕𝑓
= 𝑥𝑐𝑜𝑠𝑥 + 𝑠𝑖𝑛𝑥 + 𝑐𝑜𝑠𝑦
𝜕𝑥
𝜕𝑓
= −𝑥𝑠𝑖𝑛𝑦 + 𝑦𝑒 𝑦 + 𝑒 𝑦
𝜕𝑦

𝑥−𝑦
4. 𝑓(𝑥, 𝑦) =
𝑥+𝑦
𝜕𝑓 (𝑥 + 𝑦) ∙ 1 − (𝑥 − 𝑦) ∙ 1 2𝑦
= 2
=
𝜕𝑥 (𝑥 + 𝑦) (𝑥 + 𝑦)2
𝜕𝑓 (𝑥 + 𝑦) ∙ (−1) − (𝑥 − 𝑦) ∙ 1 −2𝑥
= 2
=
𝜕𝑦 (𝑥 + 𝑦) (𝑥 + 𝑦)2

Examples. The following are partial derivatives of functions on three variables.

1. 𝑓(𝑥, 𝑦, 𝑧) = sin2 (𝑥 + 𝑦) + cos 2 (𝑦 − 𝑧)


𝜕𝑓
= 2 sin(𝑥 + 𝑦) cos(𝑥 + 𝑦)
𝜕𝑥
𝜕𝑓
= 2 sin(𝑥 + 𝑦) cos(𝑥 + 𝑦) − 2 cos(𝑦 − 𝑧) sin(𝑦 − 𝑧)
𝜕𝑦
𝜕𝑓
= 2 cos(𝑦 − 𝑧) sin(𝑦 − 𝑧)
𝜕𝑧

2. 𝑓(𝑥, 𝑦, 𝑧) = 𝑒 𝑥𝑦𝑧 + 2𝑥 𝑦 − 𝑦𝑙𝑛𝑧


𝜕𝑓
= 𝑒 𝑥𝑦𝑧 𝑦𝑧 + 2𝑥 𝑦𝑙𝑛2
𝜕𝑥
𝜕𝑓
= 𝑒 𝑥𝑦𝑧 𝑥𝑧 + 2𝑥 − 𝑙𝑛𝑧
𝜕𝑦
𝜕𝑓 𝑦
= 𝑒 𝑥𝑦𝑧 𝑥𝑦 + 2𝑥 𝑦 −
𝜕𝑧 𝑧

Alternatively, for 𝑧 = 𝑓(𝑥, 𝑦), the partial derivative at the point (𝑎, 𝑏) can also be obtained by the
following:
𝑓(𝑥,𝑏)−𝑓(𝑎,𝑏) 𝑓(𝑎,𝑦)−𝑓(𝑎,𝑏)
𝐷𝑥 𝑓(𝑎, 𝑏) = 𝑙𝑖𝑚 and 𝐷𝑦 𝑓(𝑎, 𝑏) = 𝑙𝑖𝑚 .
𝑥⟶𝑎 𝑥−𝑎 𝑦⟶𝑏 𝑦−𝑎

For 𝑤 = 𝑓(𝑥, 𝑦, 𝑧), the partial derivative at the point (𝑎, 𝑏, 𝑐) can also be obtained by the following:

𝑓(𝑥,𝑏,𝑐)−𝑓(𝑎,𝑏,𝑐)
𝐷𝑥 𝑓(𝑎, 𝑏, 𝑐) = 𝑙𝑖𝑚 ,
𝑥⟶𝑎 𝑥−𝑎
𝑓(𝑎,𝑦,𝑐)−𝑓(𝑎,𝑏,𝑐)
𝐷𝑦 𝑓(𝑎, 𝑏, 𝑐) = 𝑙𝑖𝑚 and
𝑦⟶𝑏 𝑦−𝑎
𝑓(𝑎,𝑏,𝑧)−𝑓(𝑎,𝑏,𝑐)
𝐷𝑧 𝑓(𝑎, 𝑏, 𝑐) = 𝑙𝑖𝑚 .
𝑧⟶𝑐 𝑧−𝑐
These can be generalized for partial derivatives of functions on 𝑛 variables.

Illustration.
Given: 𝑧 = 𝑓(𝑥, 𝑦) = 𝑥 2 + 𝑥𝑦 + 3𝑦

𝑓(𝑥,−1)−𝑓(2,−1)
𝑓𝑥 (2, −1) = lim
𝑥→2 𝑥−2
[𝑥 2 + 𝑥(−1) + 3(−1)] − [22 + 2(−1) + 3(−1)]
= lim
𝑥→2 𝑥−2
(𝑥 2 − 𝑥 − 3) − (−1)
= 𝑙𝑖𝑚 .
𝑥→2 𝑥−2
2
𝑥 −𝑥−2
= 𝑙𝑖𝑚
𝑥→2 𝑥−2
(𝑥 − 2)(𝑥 + 1)
= 𝑙𝑖𝑚
𝑥→2 𝑥−2
= 𝑙𝑖𝑚(𝑥 + 1)
𝑥→2
=3

𝑓(𝑎,𝑦)−𝑓(𝑎,𝑏)
Try computing for 𝑓𝑦 (2, −1) using 𝐷𝑦 𝑓(𝑎, 𝑏) = 𝑙𝑖𝑚 .
𝑦⟶𝑏 𝑦−𝑎

Geometric interpretation of a partial derivative

Review: Given a function 𝑦 = 𝑓(𝑥) and 𝑎 ∈ 𝐷𝑓 ,


𝑑𝑦
= 𝑓′(𝑎) is the slope of the tangent line to the curve 𝑦 = 𝑓(𝑥) at the point 𝑃(𝑎, 𝑓(𝑎)).
𝑑𝑥

Consider the surface given by 𝑧 = 𝑓(𝑥, 𝑦).


Let 𝑓(𝑎, 𝑏) = 𝑐 so that (𝑎, 𝑏, 𝑐) is a point on the surface.

The plane 𝑦 = 𝑏 is parallel to the 𝑥𝑧-plane.

Let 𝐶1 be the curve of intersection of the surface and the


plane 𝑦 = 𝑏. The point (𝑎, 𝑏, 𝑐) is on this curve.

The slope of the tangent line to 𝐶1 at the point (𝑎, 𝑏, 𝑐)


𝜕𝑧
is given by | = 𝑓𝑥 (𝑎, 𝑏)
𝜕𝑥 (𝑎,𝑏)

The plane 𝑥 = 𝑎 is parallel to the 𝑦𝑧-plane.

Let 𝐶2 be the curve of intersection of the surface and the


plane 𝑥 = 𝑎. The point (𝑎, 𝑏, 𝑐) is on this curve.

The slope of the tangent line to 𝐶2 at the point (𝑎, 𝑏, 𝑐)


𝜕𝑧
is given by | = 𝑓𝑦 (𝑎, 𝑏)
𝜕𝑦 (𝑎,𝑏)

__________________________

Concept Recap
1. What is a partial derivative of a function 𝑧 = 𝑓(𝑥, 𝑦)? 𝑤 = 𝑓(𝑥, 𝑦, 𝑧)?
𝜕𝑓 𝜕𝑓
2. How can the partial derivatives and of a function 𝑧 = 𝑓(𝑥, 𝑦) be obtained?
𝜕𝑥 𝜕𝑦
𝜕𝑓 𝜕𝑓 𝜕𝑓
3. How can the partial derivatives , and of a function 𝑤 = 𝑓(𝑥, 𝑦, 𝑧) be obtained?
𝜕𝑥 𝜕𝑦 𝜕𝑧
4. What are the alternative notations in expressing partial derivatives?
𝜕𝑓 𝜕𝑓
5. Geometrically, what does the partial derivatives and of a function 𝑧 = 𝑓(𝑥, 𝑦) represent?
𝜕𝑥 𝜕𝑦
Practice Exercises
𝜕𝑓 𝜕𝑓
Compute for the indicated partial derivatives and of the given function.
𝜕𝑥 𝜕𝑦

1. 𝑓(𝑥, 𝑦) = 5𝑥 3 − 4𝑦 3 − 3𝑥 + 7𝑦 + 5
2. 𝑓(𝑥, 𝑦) = 2𝑥𝑦 − 𝑥 3 𝑦 5 + 4𝑥𝑦 2
𝑥
3. 𝑓(𝑥, 𝑦) = + 𝑦√ 𝑥 − 𝑥𝑒 𝑦
𝑦

4. 𝑓(𝑥, 𝑦) = √𝑥 2 + 𝑦 2
5. 𝑓(𝑥, 𝑦) = sin(𝑥𝑦) + 𝑦 ln 𝑥
6. 𝑓(𝑥, 𝑦) = 𝑒 𝑥𝑦 cos 𝑥 + 𝑒 𝑥 sin(𝑥𝑦) Properly implement product rule here!
7. 𝑓(𝑥, 𝑦) = 2𝑥 𝑥 2 𝑦 + 𝑥𝑦 ln 𝑦 Properly implement product rule here!
1
8. 𝑓(𝑥, 𝑦) =
𝑥 2 −𝑦 2
𝑥𝑦
9. 𝑓(𝑥, 𝑦) = Properly implement quotient rule here!
𝑥 2 +𝑦 2
𝑥 𝑦
10. 𝑓(𝑥, 𝑦) = − Properly implement quotient rule here!
𝑥+𝑦 𝑥−𝑦
𝜕𝑓 𝜕𝑓 𝜕𝑓
Compute for the indicated partial derivatives , and of the given function.
𝜕𝑥 𝜕𝑦 𝜕𝑧
𝑥 3
11. 𝑓(𝑥, 𝑦, 𝑧) = 2 𝑦 sin 𝑧
12. 𝑓(𝑥, 𝑦, 𝑧) = 𝑥𝑒 𝑦 + 𝑦 ln 𝑧
13. 𝑓(𝑥, 𝑦, 𝑧) = 3𝑦𝑧 3 − 𝑥 2 𝑦𝑧 + 5𝑥 2 𝑧
14. 𝑓(𝑥, 𝑦, 𝑧) = ln(𝑥 + 𝑦 + 𝑧)
15. 𝑓(𝑥, 𝑦, 𝑧) = √ 𝑦 2 + 𝑧 (𝑥 2 + 𝑦𝑧) Properly implement product rule here!
2𝑧
16. 𝑓(𝑥, 𝑦, 𝑧) =
𝑥+𝑦
1
17. 𝑓(𝑥, 𝑦, 𝑧) =
𝑥 2 +𝑦 2 +𝑧 2

18. Solve for values of 𝑥 and 𝑦 at which 𝑓𝑥 (𝑥, 𝑦) = 0 and 𝑓𝑦 (𝑥, 𝑦) = 0 simultaneously.
a.) 𝑓(𝑥, 𝑦) = 𝑥 2 + 4𝑥𝑦 + 𝑦 2 − 4𝑥 + 16𝑦 + 3
b.) 𝑓(𝑥, 𝑦) = 3𝑥 3 − 12𝑥𝑦 + 𝑦 3

Solve for the indicated partial derivatives at the given point. Then, give a geometric interpretation of
the obtained value in terms of slope of tangent lines.

19. 𝑓(𝑥, 𝑦) = 𝑥 2 − 3𝑥𝑦 + 𝑦 2 𝑓𝑥 (𝑥, 𝑦) and 𝑓𝑦 (𝑥, 𝑦) at the point (1, −1)

20. 𝑓(𝑥, 𝑦) = √25 − 𝑥 2 − 𝑦 2 𝑓𝑥 (𝑥, 𝑦) and 𝑓𝑦 (𝑥, 𝑦) at the point (3,4)


____________________________________________
Section 4. HIGHER-ORDER AND CHAIN RULE FOR PARTIAL DIFFERENTIATION

By the end of this section, you must be able to


✓ determine the higher order partial derivatives of a function of several variables;
✓ implement notations for higher-order partial derivatives;
✓ apply chain rule to get partial derivatives; and
✓ implement implicit differentiation to obtain partial derivatives of an implicit
function.

HIGHER-ORDER PARTIAL DERIVATIVES

Review:
𝑑𝑛 𝑦
For a function 𝑦 = 𝑓(𝑥), the 𝑛th derivative of 𝑓 is given by 𝑛 = 𝑓 𝑛 (𝑥).
𝑑𝑥
To compute for the 𝑛th derivative, we simply get the derivative of a previous derivative.
𝑑2𝑦
Specifically, = 𝑓 2 (𝑥) is the derivative of 𝑓′(𝑥),
𝑑𝑥 2
𝑑3𝑦
= 𝑓 3 (𝑥) is the derivative of 𝑓 2 (𝑥),
𝑑𝑥 3

𝑑𝑛 𝑦
= 𝑓 𝑛 (𝑥) is the derivative of 𝑓 (𝑛−1) (𝑥).
𝑑𝑥 𝑛

To obtain higher-order partial derivatives, we also differentiate existing partial derivatives.


However, since a function is of several variables, partial derivatives of each order can be with respect
to any of the variables. It is important to properly implement the different notations for partial
differentiation.

Consider a function 𝑧 = 𝑓(𝑥, 𝑦).


𝜕𝑧 𝜕𝑧
From the partial derivatives and , we obtain the second-order partial derivatives:
𝜕𝑥 𝜕𝑦
𝜕2 𝑧 𝜕 𝜕𝑧 𝜕2 𝑧 𝜕 𝜕𝑧
= ( ) = ( )
𝜕𝑥 2 𝜕𝑥 𝜕𝑥 𝜕𝑦 2 𝜕𝑦 𝜕𝑦
𝜕2 𝑧 𝜕 𝜕𝑧 𝜕2 𝑧 𝜕 𝜕𝑧
= ( ) = ( )
𝜕𝑦𝜕𝑥 𝜕𝑦 𝜕𝑥 𝜕𝑥𝜕𝑦 𝜕𝑥 𝜕𝑦

Remark: The order of differentiation depends on the notation being used.


𝜕2 𝑧 𝜕2 𝑧
For instance, = 𝑓𝑥𝑦 (𝑥, 𝑦) = 𝐷𝑥𝑦 𝑓(𝑥, 𝑦) or = 𝑓𝑦𝑥 (𝑥, 𝑦) = 𝐷𝑦𝑥 (𝑥, 𝑦).
𝜕𝑦𝜕𝑥 𝜕𝑥𝜕𝑦
The following are the other notations for second-order partial derivatives:
𝜕2𝑧 𝜕2𝑓
: 𝑓𝑥𝑥 (𝑥, 𝑦) 𝐷𝑥𝑥 𝑓(𝑥, 𝑦)
𝜕𝑥 2 𝜕𝑥 2
𝜕2𝑧 𝜕2𝑓
: 𝑓𝑥𝑦 (𝑥, 𝑦) 𝐷𝑥𝑦 𝑓(𝑥, 𝑦)
𝜕𝑦𝜕𝑥 𝜕𝑦𝜕𝑥
𝜕2𝑧 𝜕2𝑓
: 𝑓𝑦𝑦 (𝑥, 𝑦) 𝐷𝑦𝑦 𝑓(𝑥, 𝑦)
𝜕𝑦 2 𝜕𝑦 2
𝜕2𝑧 𝜕2𝑓
: 𝑓𝑦𝑥 (𝑥, 𝑦) 𝐷𝑦𝑥 (𝑥, 𝑦)
𝜕𝑥𝜕𝑦 𝜕𝑥𝜕𝑦
Example.
Consider the function 𝑧 = 𝑓(𝑥, 𝑦) = 4𝑥 2 − 𝑥 3 𝑦 5 + 2𝑦 7 .
To compute for second-order partial derivatives 𝑓𝑥𝑥 , 𝑓𝑥𝑦 , 𝑓𝑦𝑦 and 𝑓𝑦𝑥 , we first compute for the first-order
partial derivatives.

• 𝑓𝑥 (𝑥, 𝑦) = 8𝑥 − 3𝑥 2 𝑦 5 So, 𝑓𝑥𝑥 (𝑥, 𝑦) = 8 − 6𝑥𝑦 5 and 𝑓𝑥𝑦 (𝑥, 𝑦) = −15𝑥 2 𝑦 4 .

• 𝑓𝑦(𝑥,𝑦) = −5𝑥 3 𝑦 4 + 14𝑦 6 So, 𝑓𝑦𝑥 (𝑥, 𝑦) = −15𝑥 2 𝑦 4 and 𝑓𝑦𝑦 (𝑥, 𝑦) = −20𝑥 3 𝑦 3 + 84𝑦 5 .

From the second-order partial derivatives, we can also obtain the third-order partial derivatives.

For example, from 𝑓𝑥𝑥 , we get 𝑓𝑥𝑥𝑦 (𝑥, 𝑦) = −30𝑥𝑦 4


from 𝑓𝑥𝑦 , we get 𝑓𝑥𝑦𝑦 (𝑥, 𝑦) = −60𝑥 2 𝑦 3
from 𝑓𝑦𝑦 , we get 𝑓𝑦𝑦𝑦 (𝑥, 𝑦) = −60𝑥 2 𝑦 2 + 420𝑦 4

Solve for the other third-order partial derivatives.

In the following example, we use an alternative notation for second-order partial derivatives.

Example.
Let 𝑓(𝑥, 𝑦) = 𝑦𝑙𝑛𝑥 − 𝑦2𝑥𝑦 .
𝜕2 𝑓 𝜕2 𝑓
Solving for and ,
𝜕𝑥 2 𝜕𝑦𝜕𝑥

𝜕𝑓 1 𝑦
= 𝑦 ⋅ − 𝑦2𝑥𝑦 (𝑙𝑛2)𝑦 = − 𝑦 2 2𝑥𝑦 𝑙𝑛2
𝜕𝑥 𝑥 𝑥

𝜕2 𝑓 −1 −𝑦
⟹ =𝑦⋅ − 𝑦 2 2𝑥𝑦 𝑙𝑛2 ⋅ (𝑙𝑛2)𝑦 = − 𝑦 3 2𝑥𝑦 (𝑙𝑛2)2 and
𝜕𝑥 2 𝑥2 𝑥2

𝜕2 𝑓 1 1
= − 𝑦 2 ⋅ 2𝑥𝑦 (𝑙𝑛2)𝑦 + 2𝑥𝑦 𝑙𝑛2 ⋅ 2𝑦 = − 𝑦 3 2𝑥𝑦 𝑙𝑛2 + 2𝑦2𝑥𝑦 𝑙𝑛2
𝜕𝑦𝜕𝑥 𝑥 𝑥

For higher-order partial derivatives of functions of three variables like 𝑤 = 𝑓(𝑥, 𝑦, 𝑧), be careful
in the order in which to compute the partial derivatives. Again, pay attention to the notation being
used. Here are some alternative notations for third- and fourth-order partial derivatives:
𝜕3𝑓
: 𝑓𝑥𝑥𝑦 (𝑥, 𝑦, 𝑧) 𝐷𝑥𝑥𝑦 𝑓 𝐷𝑦 (𝐷𝑥 (𝐷𝑥 𝑓)))
𝜕𝑦𝜕𝑥𝜕𝑥
𝜕3𝑓
: 𝑓𝑦𝑧𝑥 (𝑥, 𝑦, 𝑧) 𝐷𝑦𝑧𝑥 𝑓 𝐷𝑥 (𝐷𝑧 (𝐷𝑦 𝑓))
𝜕𝑥𝜕𝑧𝜕𝑦
𝜕4𝑓
: 𝑓𝑥𝑧𝑧𝑦 (𝑥, 𝑦, 𝑧) 𝐷𝑥𝑧𝑧𝑦 𝑓 𝐷𝑦 (𝐷𝑧 (𝐷𝑧 (𝐷𝑥 𝑓)))
𝜕𝑦𝜕𝑧𝜕𝑧𝜕𝑥
𝜕4𝑓
: 𝑓𝑧𝑦𝑥𝑦 (𝑥, 𝑦, 𝑧) 𝐷𝑧𝑦𝑥𝑦 𝑓 𝐷𝑦 (𝐷𝑥 (𝐷𝑦 (𝐷𝑧 𝑓)))
𝜕𝑦𝜕𝑥𝜕𝑦𝜕𝑧

Examples.
Let 𝑓(𝑥, 𝑦, 𝑧) = 𝑧 2 cos 𝑥 + 𝑦 2 𝑠𝑖𝑛𝑧.
𝜕3 𝑓 𝜕3 𝑓 𝜕3 𝑓 𝜕3 𝑓
Compute for the following third-order partial derivatives. , , and .
𝜕𝑥 3 𝜕𝑥𝜕𝑧𝜕𝑥 𝜕𝑧 3 𝜕𝑥𝜕𝑦𝜕𝑧

𝜕𝑓 𝜕2 𝑓 𝜕3 𝑓
From = −𝑧 2 𝑠𝑖𝑛𝑥, we obtain = −𝑧 2 𝑐𝑜𝑠𝑥. So, = 𝑧 2 𝑠𝑖𝑛𝑥.
𝜕𝑥 𝜕𝑥 2 𝜕𝑥 3

𝜕𝑓 𝜕2 𝑓 𝜕3 𝑓
Also, from , we get = −2𝑧𝑠𝑖𝑛𝑥. So, = −2𝑧𝑐𝑜𝑠𝑥.
𝜕𝑥 𝜕𝑧𝜕𝑥 𝜕𝑥𝜕𝑧𝜕𝑥
𝜕𝑓 𝜕2 𝑓 𝜕3 𝑓
From = 2𝑧𝑐𝑜𝑠𝑥 + 𝑦 2 𝑐𝑜𝑠𝑧, we get = 2𝑐𝑜𝑠𝑥 − 𝑦 2 𝑠𝑖𝑛𝑧. So, = −𝑦 2 𝑐𝑜𝑠𝑧.
𝜕𝑧 𝜕𝑧 2 𝜕𝑧 3

𝜕𝑓 𝜕2 𝑓 𝜕3 𝑓
Also, from , we get = 2𝑦𝑐𝑜𝑠𝑧. So, = 0.
𝜕𝑥 𝜕𝑦𝜕𝑧 𝜕𝑥𝜕𝑦𝜕𝑧

CHAIN RULE

Let 𝑢 be a differentiable function of 2 variables 𝑥 and 𝑦. Also, let 𝑥 and 𝑦 be functions of 𝑟 and
𝑠. Apparently, 𝑢 is composition of several functions. So, how do we get the partial derivatives of 𝑢?
For composite functions of single variable, we use Chain Rule to get the derivatives. Here, we have a
version of this rule which we will call with same name and will enable us to get the partial derivatives
of composition of functions of several variables.

Theorem (Chain Rule).


Let 𝑢 be a differentiable function of 𝑥 and 𝑦 where 𝑥 = 𝑓(𝑟, 𝑠) and 𝑦 = 𝑔(𝑟, 𝑠) such that the partial
derivatives exist. Then, 𝑢 is a function of 𝑟 and 𝑠 and the partial derivatives are given by

𝜕𝑢 𝜕𝑢 𝜕𝑥 𝜕𝑢 𝜕𝑦 𝜕𝑢 𝜕𝑢 𝜕𝑥 𝜕𝑢 𝜕𝑦
= 𝜕𝑥 ∙ + 𝜕𝑦 ∙ 𝜕𝑟 and = 𝜕𝑥 ∙ + 𝜕𝑦 ∙ 𝜕𝑠 .
𝜕𝑟 𝜕𝑟 𝜕𝑠 𝜕𝑠

We illustrate the chain rule by a diagram showing the relations of the variables.

Illustration.
Let 𝑤 = 𝐹(𝑥, 𝑦, 𝑧) where 𝑥 = 𝑓(𝑟, 𝑠, 𝑡), 𝑦 = 𝑔(𝑟, 𝑡) and 𝑧 = ℎ(𝑟, 𝑠).
Here, observe that 𝑤 is a function of 𝑟, 𝑠 and 𝑡.

Using the diagram on the right as guide, the following partial derivatives are obtained.

𝜕𝑤 𝜕𝑤 𝜕𝑥 𝜕𝑤 𝜕𝑦 𝜕𝑤 𝜕𝑧
= + +
𝜕𝑟 𝜕𝑥 𝜕𝑟 𝜕𝑦 𝜕𝑟 𝜕𝑧 𝜕𝑟
𝜕𝑤 𝜕𝑤 𝜕𝑥 𝜕𝑤 𝜕𝑦 𝜕𝑤 𝜕𝑧
= + +
𝜕𝑠 𝜕𝑥 𝜕𝑠 𝜕𝑦 𝜕𝑠 𝜕𝑧 𝜕𝑠
𝜕𝑤 𝜕𝑤 𝜕𝑥 𝜕𝑤 𝜕𝑦
= +
𝜕𝑡 𝜕𝑥 𝜕𝑡 𝜕𝑦 𝜕𝑡

Example.
Let 𝑢 = 3𝑥𝑧 2 − 4𝑧𝑦 2 where 𝑥 = 5𝑟𝑠 + 5𝑟, 𝑦 = 3𝑟 2 − 2𝑠 and 𝑧 = 𝑟 2 − 𝑠 2 .
𝜕𝑢 𝜕𝑢
Solving for and ,
𝜕𝑟 𝜕𝑠

𝜕𝑢 𝜕𝑢 𝜕𝑥 𝜕𝑢 𝜕𝑦 𝜕𝑢 𝜕𝑧
• = 𝜕𝑥 𝜕𝑟 + 𝜕𝑦 𝜕𝑟 + 𝜕𝑧 𝜕𝑟 = 3𝑧 2 (5𝑠 + 5) + 8𝑧𝑦 ⋅ 6𝑟 + (6𝑥𝑧 − 4𝑦 2 )2𝑟
𝜕𝑟

𝜕𝑢 𝜕𝑢 𝜕𝑥 𝜕𝑢 𝜕𝑦 𝜕𝑢 𝜕𝑧
• = 𝜕𝑥 𝜕𝑠 + 𝜕𝑦 𝜕𝑠 + 𝜕𝑧 𝜕𝑠 = 3𝑧 2 ⋅ 5𝑟 + 8𝑦𝑧 ⋅ 6𝑟 + (6𝑥𝑧 − 4𝑦 2 )(−2𝑠)
𝜕𝑠
Implicit differentiation

Not all functions are expressed explicitly in terms of their independent variables. To obtain
partial derivatives for such functions, we use implicit differentiation. This is similar to implicit
differentiation for functions of a single variable.

Theorem.
Let 𝑧 be a function of 𝑥 and 𝑦 implicitly defined by the equation 𝐹(𝑥, 𝑦, 𝑧) = 0.
𝜕𝑧 𝐹 𝜕𝑧 𝐹𝑦
Then = − 𝑥 and =− .
𝜕𝑥 𝐹𝑧 𝜕𝑦 𝐹𝑧

Example.
Given that 𝑧 is a function of 𝑥 and 𝑦, and that 𝑥 2 𝑐𝑜𝑠𝑧 − 𝑦 2 𝑠𝑖𝑛𝑧 = 0,
𝜕𝑧 𝜕𝑧
we compute for and via implicit differentiation.
𝜕𝑥 𝜕𝑦

Let 𝐹(𝑥, 𝑦, 𝑧) = 𝑥 2 𝑐𝑜𝑠𝑧 − 𝑦 2 𝑠𝑖𝑛𝑧 = 0. Then,


𝜕𝑧 𝐹 (𝑥,𝑦,𝑧) 2𝑥𝑐𝑜𝑠𝑧 2𝑥𝑐𝑜𝑠𝑧
• = − 𝑥(𝑥,𝑦,𝑧) = − 2 = and
𝜕𝑥 𝐹𝑧 −𝑥 𝑠𝑖𝑛𝑧−𝑦 2 𝑐𝑜𝑠𝑧 𝑥 2 𝑠𝑖𝑛𝑧+𝑦 2 𝑐𝑜𝑠𝑧
𝜕𝑧 𝐹𝑦 (𝑥,𝑦,𝑧) −2𝑦𝑠𝑖𝑛𝑧 2𝑦𝑠𝑖𝑛𝑧
• = − (𝑥,𝑦,𝑧) = − 2 =− .
𝜕𝑦 𝐹𝑧 −𝑥 𝑠𝑖𝑛𝑧−𝑦 2 𝑐𝑜𝑠𝑧 𝑥 2 𝑠𝑖𝑛𝑧+𝑦 2 𝑐𝑜𝑠𝑧

__________________________

Concept Recap
1. What is a higher-order partial derivative?
2. What are the different notations used for higher-order partial derivatives?
How do these notations differ in the order in which the variables are considered?
3. When is chain rule used in solving for partial derivatives?
How is the chain rule for partial derivative implemented?
4. When is implicit differentiation used in solving for partial derivatives?
How is implicit differentiation for partial derivative implemented?

Practice Exercises

Solve for the indicated higher-order partial derivatives of the following functions.

1. 𝑓(𝑥, 𝑦) = 𝑥 4 − 5𝑥 3 𝑦 2 + 𝑦 3 𝑓𝑥𝑦 , 𝑓𝑦𝑦 , 𝑓𝑥𝑥𝑦 , 𝑓𝑦𝑥𝑦

2. 𝑓(𝑥, 𝑦) = √ 𝑥 2 + 𝑦 2 𝑓𝑥𝑥 , 𝑓𝑦𝑦 , 𝑓𝑥𝑦 , 𝑓𝑦𝑥

3. 𝑓(𝑥, 𝑦) = 𝑒 𝑥 sin 𝑦 + 𝑒 𝑦 cos 𝑥 𝑓𝑦𝑦 , 𝑓𝑥𝑦 , 𝑓𝑦𝑥𝑦 , 𝑓𝑥𝑥𝑦

4. 𝑓(𝑥, 𝑦) = ln(𝑥 − 𝑦) 𝑓𝑥𝑥 , 𝑓𝑥𝑦 , 𝑓𝑦𝑦 , 𝑓𝑦𝑥

𝑥
5. 𝑓(𝑥, 𝑦) = 𝑓𝑥𝑥 , 𝑓𝑥𝑦 , 𝑓𝑦𝑦 , 𝑓𝑦𝑥
𝑥+𝑦
𝜕2 𝑓 𝜕2 𝑓
Show that the following functions satisfy Laplace’s equation + 𝜕𝑦 2 = 0.
𝜕𝑥 2

6. 𝑓(𝑥, 𝑦) = 𝑥 3 𝑦 − 𝑥𝑦 3

7. 𝑓(𝑥, 𝑦) = ln(𝑥 2 + 𝑦 2 )
Given the function and indicated functions defining the other variables, solve for the indicated partial
derivatives. Do this by first drawing a tree diagram showing the relationship of the variables. Also,
indicate the formula that solves for the indicated partial derivatives.
8. Let 𝑢 = √𝑥 2 + 𝑦 2 where 𝑥 = 𝑟 3 − 𝑠 3 and 𝑦 = 𝑟 2 𝑠 + 𝑠𝑟 2 .
𝜕𝑢 𝜕𝑢
Solve for and .
𝜕𝑟 𝜕𝑠

1 𝑠
9. Let 𝑢 = where 𝑥 = 𝑟 2 + 𝑟𝑠 + 𝑠 2 and 𝑦 = .
𝑥+𝑦 𝑟
𝜕𝑢 𝜕𝑢
Solve for and .
𝜕𝑟 𝜕𝑠

10. Let 𝑓(𝑢, 𝑣) = 𝑢3 − 𝑢𝑣 + 𝑣 2 where 𝑢 = sin 𝑥 + cos 𝑦 and 𝑣 = 𝑥𝑒 𝑦 + 𝑦𝑒 𝑥 .


𝜕𝑓 𝜕𝑓
Solve for and .
𝜕𝑥 𝜕𝑦

𝑟2
11. Let 𝑤 = 𝑥 2 𝑦 + 𝑦𝑧 − 𝑥𝑧 2 where 𝑥 = 𝑠 2 − 𝑟 , 𝑦 = and 𝑧 = 𝑠 + 𝑡 2 .
𝑡
𝜕𝑤 𝜕𝑤 𝜕𝑤
Solve for , and .
𝜕𝑟 𝜕𝑠 𝜕𝑡

𝑦 𝑥+𝑦
12. Let 𝑓(𝑢, 𝑣, 𝑤) = √ 𝑢2 − 𝑣 2 + 2𝑤 where 𝑢 = , 𝑣 = 𝑥𝑦𝑧 and 𝑤 = .
𝑥+𝑧 𝑧
𝜕𝑓 𝜕𝑓 𝜕𝑓
Solve for , and .
𝜕𝑥 𝜕𝑦 𝜕𝑧

Solve the indicated partial derivatives by implicit differentiation.

13. Suppose 𝑧 is a function of 𝑦 and 𝑧, and 𝑒 𝑥 sin 𝑧 + 𝑒 𝑦 cos 𝑧 = 0.


𝜕𝑧 𝜕𝑧
Solve for and .
𝜕𝑥 𝜕𝑦

14. Suppose 𝑧 is a function of 𝑦 and 𝑧, and 𝑥 2 + 𝑦 2 + 𝑧 2 = 𝑥𝑒 𝑧 + 𝑦𝑒 𝑥 + 𝑧𝑒 𝑦 .


𝜕𝑧 𝜕𝑧
Solve for and .
𝜕𝑥 𝜕𝑦

15. Let 𝑤𝑢2 − 𝑢𝑣 + 𝑤𝑣 2 = 𝑢𝑣𝑤.


𝜕𝑤
a.) Suppose 𝑤 is a function of 𝑢 and 𝑣. Solve for .
𝜕𝑢
𝜕𝑢
b.) Suppose 𝑢 is a function of 𝑣 and 𝑤. Solve for .
𝜕𝑣
𝜕𝑣
c.) Suppose 𝑣 is a function of 𝑢 and 𝑤. Solve for .
𝜕𝑤

____________________________________________

*TOTAL DERIVATIVE and DIFFERENTIABILITY (an overview)

Definition.
A function 𝑧 = 𝑓(𝑥, 𝑦) is said to be differentiable at a point (𝒂, 𝒃) if

𝑓(𝑎 + ℎ1 , 𝑏 + ℎ2 ) = 𝑓(𝑎, 𝑏) + ℎ1 ∙ 𝑓𝑥 (𝑎, 𝑏) + ℎ2 ∙ 𝑓𝑦 (𝑎, 𝑏) + ℎ1 ∙ 𝜀1 (ℎ1 , ℎ2 ) + ℎ2 ∙ 𝜀2 (ℎ1 , ℎ2 )

where lim 𝜀1 (ℎ1 , ℎ2 ) = 0 and lim 𝜀2 (ℎ1 , ℎ2 ) = 0.


(ℎ1 ,ℎ2 )⟶(0,0) (ℎ1 ,ℎ2 )⟶(0,0)
Theorem.

Let 𝑃0 (𝑎, 𝑏) and 𝑧 = 𝑓(𝑥, 𝑦) such that 𝑓𝑥 and 𝑓𝑦 exist on an open disk 𝐵(𝑃0 ; 𝑟) for some 𝑟 > 0.

If 𝑓𝑥 and 𝑓𝑦 are continuous at 𝑃0 , then 𝑓 is differentiable at 𝑃0 .

Theorems.
1. Polynomial functions are differentiable everywhere.
2. Rational functions are differentiable over their respective domains.
3. If f and g are functions on n variables that are differentiable at P Rn , then the following are
f
also differentiable at P : f + g , f − g , f  g and , provided g ( P )  0 .
g

Definition.
Let 𝑧 = 𝑓(𝑥, 𝑦). The total differential of 𝑓 at (𝑥, 𝑦) by x and y is given by
𝑑𝑓(𝑥, 𝑦, ∆𝑥, ∆𝑦) = 𝑓𝑥 (𝑥, 𝑦) ∙ ∆𝑥 + 𝑓𝑦(𝑥, 𝑦) ∙ ∆𝑦.

Remarks: 1. 𝑑𝑓(𝑥, 𝑦, ∆𝑥, ∆𝑦) ≈ ∆𝑓(𝑥, 𝑦, ∆𝑥, ∆𝑦)


approximate value actual value
2. 𝑓(𝑥 + ∆𝑥, 𝑦 + ∆𝑦) ≈ 𝑓(𝑥, 𝑦) + 𝑑𝑓(𝑥, 𝑦, ∆𝑥, ∆𝑦)
z z
3. If z = f (x , y ) , then dz = f x dx + f y dy or dz = dx + dy .
x y

4. In general, if w = f ( x1 , x 2 , . . . , x n ) ,
w w w
then dw =
dx1 + dx 2 + . . . + dx n .
x1 x 2 x n
____________________________________________

Section 5. GRADIENT AND DIRECTIONAL DERIVATIVE

By the end of this section, you must be able to


✓ discuss basic properties of a gradient of a function of several variables;
✓ explain the geometric interpretation of a directional derivative
✓ solve for gradient and directional derivatives of a function of several variables;
and
✓ interpret a gradient and a directional derivative in relation to a function.

THE GRADIENT

For a function of several variables, its gradient is the vector composed of its partial derivatives.

Definition.
Given 𝑧 = 𝑓(𝑥, 𝑦), the gradient of 𝑓, denoted by 𝛻𝑓, is given by
∇𝑓(𝑥, 𝑦) = 𝑓𝑥 (𝑥, 𝑦)𝑖 + 𝑓𝑦 (𝑥, 𝑦)𝑗 = 〈𝑓𝑥 (𝑥, 𝑦), 𝑓𝑦 (𝑥, 𝑦)〉.

Given 𝑤 = 𝑔(𝑥, 𝑦, 𝑧), the gradient of 𝑔, denoted by 𝛻𝑔, is given by


∇𝑔(𝑥, 𝑦, 𝑧) = 𝑔𝑥 (𝑥, 𝑦, 𝑧)𝑖 + 𝑔𝑦 (𝑥, 𝑦, 𝑧)𝑗 + 𝑔𝑧 (𝑥, 𝑦, 𝑧)𝑘 = 〈𝑔𝑥 (𝑥, 𝑦, 𝑧), 𝑔𝑦 (𝑥, 𝑦, 𝑧), 𝑔𝑧 (𝑥, 𝑦, 𝑧)〉 .
Remark:
Gradients can be used to determine the optimal value of the directional derivative.
• The maximum value of 𝐷𝑢 (𝑎, 𝑏) is ‖∇𝑓(𝑎, 𝑏)‖.
This value is attained when the direction of 𝑢 is the same as the direction of ∇𝑓(𝑎, 𝑏).
• The minimum value of 𝐷𝑢 (𝑎, 𝑏) is −‖∇𝑓(𝑎, 𝑏)‖.
This value is attained when the direction of 𝑢 is opposite that of ∇𝑓(𝑎, 𝑏).
• ∇𝑓(𝑎, 𝑏) points in the direction of steepest ascent or descent.

Example.
Consider the function 𝑓(𝑥, 𝑦) = 𝑥 3 − 𝑥𝑦 2 at the point 𝑃(1,1).
Using its gradient, we can determine the direction where 𝑓 changes most rapidly from point 𝑃.

The gradient vector is ∇𝑓(𝑥, 𝑦) = 〈3𝑥 2 − 𝑦 2 , −2𝑥𝑦〉.


Hence, ∇𝑓(1,1) = 〈2, −2〉 and ‖𝛻𝑓(1,1)‖ = √22 + (−2)2 = √8 = 2√2.

At the point 𝑃(1,1), the function 𝑓 increases most rapidly in the direction of 〈2, −2〉 at the rate of 2√2.
Also, the function 𝑓 decreases most rapidly in the direction opposite the gradient which is 〈−2,2〉 and
at a rate of −2√2.

DIRECTIONAL DERIVATIVE

Notion. A directional derivative is the rate of change of a function at a particular point towards a
given direction.

In the figure on the right, the surface is defined by


some function 𝑧 = 𝑓(𝑥, 𝑦). Let 𝑓(𝑎, 𝑏) = 𝑐.

At the point 𝑃(𝑎, 𝑏, 𝑐) on the surface, the function


value changes depending on the direction from point 𝑃.

Let 𝜃 (a polar angle) be a given direction. The rate


of change of the function value at point 𝑃 in the direction 𝜃
can be computed using directional derivative.

𝜕𝑧
In particular, for the function 𝑧 = 𝑓(𝑥, 𝑦), the partial derivative is the rate of change of the
𝜕𝑥
𝜕𝑧
function at a point in the direction 𝜃 = 0. The partial derivative is the rate of change of the function
𝜕𝑦
𝜋
at a point in the direction 𝜃 = .
2

A directional derivative is simply the dot product of the gradient and a unit vector in the
considered direction.

Theorem. (for a function of two variables)


Consider a function 𝑧 = 𝑓(𝑥, 𝑦).
1. Let 𝜃 be a given direction with 𝑈𝜃 = 〈𝑐𝑜𝑠𝜃, 𝑠𝑖𝑛𝜃〉 the unit vector in the direction of 𝜃.
The directional derivative of 𝑓 in the direction 𝜃, denoted by 𝐷𝑈𝜃 𝑓(𝑥, 𝑦), is given by
𝐷𝑈𝜃 𝑓(𝑥, 𝑦) = ∇𝑓(𝑥, 𝑦) ∙ 𝑈𝜃 .

2. Let vector 𝐴 be a given direction with 𝑈𝐴 the unit vector in the direction of 𝐴.
The directional derivative of 𝑓 in the direction 𝐴, denoted by 𝐷𝑈𝐴 𝑓(𝑥, 𝑦), is given by
𝐷𝑈𝐴 𝑓(𝑥, 𝑦) = ∇𝑓(𝑥, 𝑦) ∙ 𝑈𝐴 .
Theorem. (for a function of three variables)
Consider a function 𝑤 = 𝑓(𝑥, 𝑦, 𝑧).
Let vector 𝐴 be a given direction with 𝑈𝐴 the unit vector in the direction of 𝐴.
The directional derivative of 𝑓 in the direction 𝐴, denoted by 𝐷𝑈𝐴 𝑓(𝑥, 𝑦, 𝑧), is given by
𝐷𝑈𝐴 𝑓(𝑥, 𝑦, 𝑍) = ∇𝑓(𝑥, 𝑦, 𝑧) ∙ 𝑈𝐴 .

Remarks: Given a function 𝑓 at a point 𝑃 and in the direction of vector 𝐴,


• if 𝐷𝑈𝐴 𝑓 > 0, then the function is increasing at 𝑃 in the direction of 𝐴,
• if 𝐷𝑈𝐴 𝑓 < 0, then the function is decreasing at 𝑃 in the direction of 𝐴, and
• if 𝐷𝑈𝐴 𝑓 = 0, then there is no change in function value at 𝑃 in the direction of 𝐴.

Example.
Consider 𝑓(𝑥, 𝑦) = 4 − 2𝑥 2 − 𝑦 2 .
𝜋 𝜋 𝜋 1 √3
(a) The unit vector in the direction of 𝜃 = is 𝑈 = 〈𝑐𝑜𝑠 , 𝑠𝑖𝑛 〉 = 〈 , 〉.
3 3 3 2 2
Hence, at a point (𝑥, 𝑦), the directional derivative is given by
1 √3
𝐷𝑈 𝑓(𝑥, 𝑦) = 〈−4𝑥, −2𝑦〉 ⋅ 〈 , 〉 = −2𝑥 − √3𝑦.
2 2

(b) In the direction 𝜃 = 𝜋, the corresponding unit vector is 𝑈 = 〈𝑐𝑜𝑠𝜋, 𝑠𝑖𝑛𝜋〉 = 〈−1,0〉.
Hence, at a point (𝑥, 𝑦), the directional derivative is given by
𝐷𝑈 𝑓(𝑥, 𝑦) = 〈−4𝑥, −2𝑦〉 ⋅ 〈−1,0〉 = 4𝑥

𝐷𝑈 𝑓(𝑎, 𝑏) is the rate of change of 𝑓 at the point (𝑎, 𝑏) in the direction of the unit vector 𝑈.
Given 𝑓(𝑥, 𝑦) = 4 − 2𝑥 2 − 𝑦 2 .
𝜋
The directional derivative at the point 𝑃(1,1) in the direction 𝜃 = is
3
𝐷𝑈 𝑓(1,1) = −2(1) − √3(1) = −2 − √3 .
Note 𝑓(1,1) = 1.
𝜋
So, 𝐷𝑈 𝑓(1,1) = −2 − √3 is the rate of change of 𝑓 at the point (1,1,1) in the direction of 𝜃 = .
3

Visually, in the perspective of a “mountain climber”


on the surface defined by 𝑓,
𝐷𝑈 𝑓(1,1) = −2 − √3
is the rate at change on the surface at (1,1,1) in the
𝜋
direction 𝜃 = .
3
The negative rate indicates a descent.

In the same manner, in the direction 𝜃 = 𝜋,


𝐷𝑈 𝑓(1,1) = 4.
This indicates that on the surface, there is an
ascent from the point (1,1,1) in the direction 𝜃 = 𝜋.

Example.
𝜋
Find the directional derivative of 𝑔(𝑥, 𝑦) = 𝑐𝑜𝑠𝑥 + 𝑒 𝑦 at the point ( , 0) in the direction 𝐴 = 〈1,2〉.
6

The gradient is given by ∇𝑔(𝑥, 𝑦) = 〈−𝑠𝑖𝑛𝑥, 𝑒 𝑦 〉.


𝐴 〈1,2〉 〈1,2〉 1 2
The unit vector in the direction 𝐴 is 𝑈 =
‖𝐴‖
= 2 2 = =〈 , 〉.
√1 +2 √5 √5 √5
1 2 1 2
Hence, 𝐷𝑈 𝑔(𝑥, 𝑦) = ∇𝑓(𝑥, 𝑦) ∙ 𝑈 = 〈−𝑠𝑖𝑛𝑥, 𝑒 𝑦 〉 ⋅ 〈 , 〉=− 𝑠𝑖𝑛𝑥 + 𝑒𝑦.
√5 √5 √5 √5

𝜋 1 𝜋 2 1 2 3
Thus, 𝐷𝑈 𝑔 ( , 0) = − 𝑠𝑖𝑛 6 + 𝑒 0 = − 2√5 + = 3√5.
6 √5 √5 √5

Give an interpretation of this result.

Example.
Consider ℎ(𝑥, 𝑦, 𝑧) = √𝑥 2 + 𝑦 2 + 𝑧 2 .
Determine 𝐷𝑈 ℎ(−3,0,4) in the direction of 〈−2, −1,2〉.
𝑥 𝑦 𝑧
The gradient is given by ∇ℎ(𝑥, 𝑦, 𝑧) = 〈 , , 〉.
√𝑥 2 +𝑦 2 +𝑧 2 √𝑥 2 +𝑦2 +𝑧 2 √𝑥 2 +𝑦 2 +𝑧 2
3 4
So, ∇ℎ(−3,0,4) = 〈− , 0, 5 〉.
5

2
The unit vector in the direction of 〈−2, −1,2〉 is 𝑈 = 〈−
3
, − 13 , 23 〉.

Thus, the desired directional derivative is given by


3 4 2 1 2 14
𝐷𝑈 ℎ(−3,0,4) = ∇ℎ(−3,0,4) ∙ 𝑈 = 〈− , 0, 5 〉 ∙ 〈− 3 , − 3 , 3 〉 = 15 .
5

Give an interpretation of this result.

__________________________

Concept Recap
1. What is a gradient of a function?
2. For a given function, what does a gradient indicate?
3. What is a directional derivative?
4. How can a directional derivative of a function be obtained?
5. How is a directional derivative of a function interpreted?

Practice Exercises

Solve for the gradient of the following functions.


1. 𝑓(𝑥, 𝑦) = 𝑥 3 𝑦 − 𝑥 2 𝑦 2 + 𝑥𝑦 3
2. 𝑓(𝑥, 𝑦) = 𝑒 𝑥 cos 𝑦 + 𝑒 𝑦 sin 𝑥
𝑥+𝑦
3. 𝑓(𝑥, 𝑦) =
𝑥 2 +𝑦 2

4. 𝑓(𝑥, 𝑦, 𝑧) = 𝑥 2 𝑒 𝑧 + 𝑥𝑦𝑧 3 + 𝑧𝑒 𝑦
5. 𝑓(𝑥, 𝑦, 𝑧) = ln(𝑥 2 − 𝑦 2 + 𝑧 2 )
𝑧
6. 𝑓(𝑥, 𝑦, 𝑧) =
𝑥+𝑦

For the following functions at the given points, solve for the maximum and minimum rate of change of
the function. Also, identify the direction at which these occur.

7. 𝑓(𝑥, 𝑦) = 9 − 𝑥 2 − 𝑦 2 at the point a.) (3,2) b.) (2, −1)


8. 𝑓(𝑥, 𝑦) = 𝑥 3 + 𝑥𝑦 + 𝑦 3 at the point a.) (−1,1) b.) (3,0)
Solve for the directional derivative of the following functions at the given point and direction.
Then, give an interpretation of the obtained directional derivative in terms of the change in the
function in the given direction.

9. 𝑓(𝑥, 𝑦) = 𝑥 3 + 𝑦 3 − 3𝑥 2 + 3𝑦 2 + 𝑥 − 𝑦 + 2
𝜋 3𝜋
at the point (−1,1) in the direction a.) 𝜃 = b.) 𝜃 = c.) 𝜃 = 𝜋
2 4

10. 𝑓(𝑥, 𝑦) = 𝑥𝑦 2 − 𝑦𝑥 2 + 𝑥𝑦
at the point (2,1) in the direction a.) 〈3, −4〉 b.) 〈−5,0〉 c.) 〈2,1〉

11. 𝑓(𝑥, 𝑦, 𝑧) = 𝑥 2 + 𝑦 2 + 𝑧 2
at the point (1, −1,1) in the direction a.) 〈−2,1,2〉 b.) 〈0,3, −4〉

12. 𝑓(𝑥, 𝑦, 𝑧) = 𝑥𝑒 𝑦 + 𝑥 sin 𝑧 + 𝑥 2 𝑦


𝜋
at the point (2,0, ) in the direction a.) 〈3,0,4〉 b.) 〈−1,2,2〉 c.) 〈1, −2, −2〉
4

13. A surface is given by the function 𝑓(𝑥, 𝑦) = 𝑥 2 − 𝑦 2 + 4.


a.) At the point (2, −1,7) on the surface, determine the direction of the steepest descent and the
direction of the steepest descent.
b.) At the point (2, −1,7) in the direction 〈3,4〉, determine whether the surface is ascending or
descending.

4
14. The temperature at a point (𝑥, 𝑦, 𝑧) on the coordinate space is given by 𝑓(𝑥, 𝑦, 𝑧) = .
𝑥 2 +𝑦 2 +𝑧 2 +1
a.) At the point (1,1,1), determine the direction of the greatest and least change in temperature.
b.) At the point (1,1,1), determine whether the temperature is ascending or descending
in the direction i.) 〈2, −1,2〉 ii.) 〈3,0,4〉

____________________________________________

Section 6. EXTREMA OF FUNCTIONS OF TWO VARIABLES

By the end of this section, you must be able to


✓ illustrate relative maximum, relative minimum and saddle point of a function of two
variables;
✓ implement the Second Derivative Test to determine relative extrema and saddle points;
✓ determine extreme values and saddle points of a function of two variables; and
✓ conclude the absolute extrema of a function of two variables.

Definitions. (Relative extrema)


Let 𝑧 = 𝑓(𝑥, 𝑦) be a function defined on a region
containing (𝑎, 𝑏).

The function 𝑓 has a relative maximum at (𝑎, 𝑏) if there


is a circular region 𝑅 centered at (𝑎, 𝑏) such that
𝑓(𝑥, 𝑦) ≤ 𝑓(𝑎, 𝑏) for all (𝑥, 𝑦) in 𝑅.

The function 𝑓 has a relative minimum at (𝑎, 𝑏) if there


is a circular region 𝑅 centered at (𝑎, 𝑏) such that
𝑓(𝑥, 𝑦) ≥ 𝑓(𝑎, 𝑏) for all (𝑥, 𝑦) in 𝑅.
Definition. (Saddle point)
Let 𝑧 = 𝑓(𝑥, 𝑦) be a function defined on a region containing
(𝑎, 𝑏) and let 𝑓(𝑎, 𝑏) = 𝑐.

The function 𝑓 has a saddle point at (𝑎, 𝑏, 𝑐)


if ∇𝑓(𝑎, 𝑏) = 〈0,0〉 but 𝑓 does not attain a relative extremum
at (𝑎, 𝑏).

To solve for relative extrema, we first compute for critical points of the function. The Second
Derivative Test can then be used to determine the relative maximum, relative minimum or saddle
point.

Definition. (Critical points)


Let 𝑧 = 𝑓(𝑥, 𝑦) be a function of two variables. A point 𝑃(𝑎, 𝑏) is a critical point if one 𝑓𝑥 (𝑎, 𝑏) or
𝑓𝑦 (𝑎, 𝑏) is undefined or
𝑓𝑥 (𝑎, 𝑏) = 0 or 𝑓𝑦 (𝑎, 𝑏) = 0

Examples.

1. 𝑓(𝑥, 𝑦) = 𝑥 3 + 𝑦 2 − 6𝑥 2 + 6𝑦 − 1

𝑓𝑥 (𝑥, 𝑦) = 3𝑥 2 − 12𝑥 = 0 𝑓𝑦 (𝑥, 𝑦) = 2𝑦 + 6 = 0


⇒ 3𝑥(𝑥 − 4) = 0 ⇒ 𝑦 = −3
⇒ 𝑥 = 0 or 𝑥 = 4

Thus, the critical points are (0, −3) and (4, −3).

2. 𝑔(𝑥, 𝑦) = 𝑒 𝑥𝑦

𝑔𝑥 (𝑥, 𝑦) = 𝑦𝑒 𝑥𝑦 = 0 𝑔𝑦 (𝑥, 𝑦) = 𝑥𝑒 𝑥𝑦 = 0
⇒𝑦=0 ⇒𝑥=0

Thus, the only critical point is (0,0).

3. ℎ(𝑥, 𝑦) = 𝑥 3 − 3𝑥 2 𝑦 − 𝑦 2

ℎ𝑥 (𝑥, 𝑦) = 3𝑥 2 − 6𝑥𝑦 = 0 ℎ𝑦 (𝑥, 𝑦) = −3𝑥 2 − 2𝑦 = 0


⇒ 3𝑥(𝑥 − 2𝑦) = 0
⇒ 3𝑥 = 0 or 𝑥 − 2𝑦 = 0
⇒ 𝑥 = 0 or 𝑥 = 2𝑦

Case 1. 𝑥 = 0
From −3𝑥 2 − 2𝑦 = 0, we obtain −2𝑦 = 0. So, 𝑦 = 0.
Hence, (0,0) is a critical point.

Case 2. 𝑥 = 2𝑦
From −3𝑥 2 − 2𝑦 = 0, we obtain −3(2𝑦)2 − 2𝑦 = 0.
⇒ −12𝑦 2 − 2𝑦 = 0
⇒ −2𝑦(6𝑦 + 1) = 0
⇒ 𝑦 = 0 or 𝑦 = −1/6

Case 2.1. 𝑦 = 0 From 𝑥 = 2𝑦, we obtain 𝑥 = 0.


So, (0,0) is a critical point.
Case 2.1. 𝑦 = −1/6 From 𝑥 = 2𝑦, we obtain 𝑥 = −1/3.
−1 −1
So, ( , ) is a critical point.
3 6

−1 −1
Thus, the critical points of ℎ(𝑥, 𝑦) = 𝑥 3 − 3𝑥 2 𝑦 − 𝑦 2 are (0,0) and ( , ).
3 6

To identify the relative maximum, relative minimum and critical points of a function, we use
the Second Derivative Test.

Theorem. (Second Derivative Test)


Let 𝑧 = 𝑓(𝑥, 𝑦) and 𝑃(𝑎, 𝑏) be a critical point of 𝑓.
2
Define the Hessian of 𝑓 at (𝑎, 𝑏) as 𝐷(𝑎, 𝑏) = 𝑓𝑥𝑥 (𝑎, 𝑏) ⋅ 𝑓𝑦𝑦 (𝑎, 𝑏) − [𝑓𝑥𝑦 (𝑎, 𝑏)] .
i. If 𝐷(𝑎, 𝑏) > 0 and 𝑓𝑥𝑥 (𝑎, 𝑏) > 0 then 𝑓 has relative minimum at (𝑎, 𝑏)
and the relative minimum value of 𝑓(𝑎, 𝑏).
ii. If 𝐷(𝑎, 𝑏) > 0 and 𝑓𝑥𝑥 (𝑎, 𝑏) < 0 then 𝑓 has relative maximum at (𝑎, 𝑏)
and the relative maximum value of 𝑓(𝑎, 𝑏).
iii. If 𝐷(𝑎, 𝑏) < 0, then 𝑓 has a saddle point at 𝑓(𝑎, 𝑏, 𝑓(𝑎, 𝑏)).
iv. No conclusion regarding relative extrema if 𝐷(𝑎, 𝑏) = 0.

Examples. Use the Second Derivative Test to determine the relative extrema.

1. 𝑓(𝑥, 𝑦) = 𝑥 3 + 𝑦 2 − 6𝑥 2 + 6𝑦 − 1

Recall that the critical points of this function are (0, −3) and (4, −3).

𝑓𝑥 (𝑥, 𝑦) = 3𝑥 2 − 12𝑥 ⇒ 𝑓𝑥𝑥 (𝑥, 𝑦) = 6𝑥 − 12 and 𝑓𝑥𝑦 (𝑥, 𝑦) = 0


𝑓𝑦 (𝑥, 𝑦) = 2𝑦 + 6 ⇒ 𝑓𝑦𝑦 (𝑥, 𝑦) = 2

The table below shows the values of the second-order partial derivatives at the critical
points. At the fifth column, we can see the value of the Hessian for each critical point. While at the
last column, we can see the conclusions that were drawn using the Second Derivative Test.

Critical Point:
𝑓𝑥𝑥 (𝑎, 𝑏) 𝑓𝑦𝑦 (𝑎, 𝑏) 𝑓𝑥𝑦 (𝑎, 𝑏) 𝐷(𝑎, 𝑏) Conclusion
(𝑎, 𝑏)
(0, −3) 12 2 0 −24 𝑓 has no relative extremum
(4, −3) 12 2 0 24 f has a relative minimum

Thus, 𝑓 has a relative minimum value of


𝑓(4, −3) = 43 + (−3)2 + 6(4)2 + 6(−3) − 1 = −42.
Furthermore, the graph of 𝑓 has a saddle point at (0, −3, −10).

2. 𝑔(𝑥, 𝑦) = 𝑒 𝑥𝑦

The critical point of 𝑔 is (0,0).

𝑔𝑥 (𝑥, 𝑦) = 𝑦𝑒 𝑥𝑦 ⇒ 𝑔𝑥𝑥 (𝑥, 𝑦) = 𝑦 2 𝑒 𝑥𝑦 and 𝑔𝑥𝑦 (𝑥, 𝑦) = 𝑒 𝑥𝑦 (𝑥𝑦 + 1)


𝑔𝑦 (𝑥, 𝑦) = 𝑥𝑒 𝑥𝑦 ⇒ 𝑔𝑦𝑦 (𝑥, 𝑦) = 𝑥 2 𝑒 𝑥𝑦

Critical Point:
𝑔𝑥𝑥 (𝑎, 𝑏) 𝑔𝑦𝑦 (𝑎, 𝑏) 𝑓𝑥𝑦 (𝑎, 𝑏) 𝐷(𝑎, 𝑏) Conclusion
(𝑎, 𝑏)
(0,0) 0 0 1 −1 𝑔 has no relative extremum

Therefore, the graph of 𝑔 has a saddle point at (0,1,1).


3. ℎ(𝑥, 𝑦) = 𝑥 3 − 3𝑥 2 𝑦 − 𝑦 2

−1 −1
Note that this function has (0,0) and ( , ) as critical points.
3 6

ℎ𝑥 (𝑥, 𝑦) = 3𝑥 2 − 6𝑥𝑦 ⇒ ℎ𝑥𝑥 (𝑥, 𝑦) = 6𝑥 − 6𝑦 and ℎ𝑥𝑦 (𝑥, 𝑦) = −6𝑥


ℎ𝑦 (𝑥, 𝑦) = −3𝑥 2 − 2𝑦 ⇒ 𝑓𝑦𝑦 (𝑥, 𝑦) = −2

Critical Point:
ℎ𝑥𝑥 (𝑎, 𝑏) ℎ𝑦𝑦 (𝑎, 𝑏) ℎ𝑥𝑦 (𝑎, 𝑏) 𝐷(𝑎, 𝑏) Conclusion
(𝑎, 𝑏)
(0,0) 0 -2 0 0 No conclusion can be made
−1 −1
( , ) -1 -2 2 -2 ℎ has no relative extremum
3 6

−1 −1 −1
Therefore, the graph of h has a saddle point at ( , , ).
3 6 108

We now focus our attention to finding absolute extrema. We will limit the discussion to finding
absolute extrema over a closed and bounded region. There is a simple procedure that we can use to
do this.

Definition. (Absolute extrema)


Let 𝑧 = 𝑓(𝑥, 𝑦) be defined on a region 𝑅 containing (𝑥0 , 𝑦0 ).
The function 𝑓 has an absolute maximum at (𝑥0 , 𝑦0 ) over 𝑅 if 𝑓(𝑥0 , 𝑦0 ) is the maximum function
value of 𝑓 over the region 𝑅.
The function 𝑓 has an absolute minimum at (𝑥0 , 𝑦0 ) over 𝑅 if 𝑓(𝑥0 , 𝑦0 ) is the minimum function value
of 𝑓 over the region 𝑅.

Illustrations.
We present some surfaces with and without absolute extrema over their respective domains.

How to determine absolute extrema of a function

Let 𝑧 = 𝑓(𝑥, 𝑦) be defined on a closed and bounded region 𝑅.


To determine the absolute extrema of 𝑓 over the region 𝑅,
1. Identify all critical points in the interior of 𝑅.
2. Identify all critical points along the boundary of 𝑅.
3. Identify the “corner” points of the region 𝑅.
3. Compute for the function values at the critical points from (1) and (2) and the corner points
from (3).
4. Compare the function values.
The maximum among these values is the maximum value of the function over the region 𝑅.
The minimum among these values is the minimum value of the function over the region 𝑅.
Example.

Consider the function 𝑓(𝑥, 𝑦) = 2𝑥 2 − 4𝑥 + 𝑦 2 − 4𝑦 + 1


over the triangular region plate in the First Quadrant
bounded by the lines: 𝑦 = 0, 𝑥 = 0, and 𝑦 = −𝑥 + 2.

We implement the prior procedures to determine the absolute extrema.

• We first determine the critical points inside the region or at the interior.
𝑓𝑥 (𝑥, 𝑦) = 4𝑥 − 4 = 0 ⇒ 𝑥 = 1
𝑓𝑦 (𝑥, 𝑦) = 2𝑦 − 4 = 0 ⇒ 𝑦 = 2
Since (1, 2) is not in the given region, it will not be considered.

• Next, we get the critical points along the boundaries. We start at the boundary 𝑦 = 0.
𝑓(𝑥, 0) = 2𝑥 2 − 4𝑥 + 1
⇒ 𝑓𝑥 (𝑥, 0) = 4𝑥 − 4 = 0 ⇒ 𝑥 = 1
Hence, along the boundary 𝑦 = 0, the critical point is (1,0).

• Now, we get the critical points along the boundary 𝑥 = 0.


𝑓(0, 𝑦) = 𝑦 2 − 4𝑦 + 1
⇒ 𝑓𝑦 (0, 𝑦) = 2𝑦 − 4 = 0 ⇒ 𝑦 = 1
Thus, the critical point is (0,2) along 𝑥 = 0.

• Finally, we get the critical numbers along 𝑦 = −𝑥 + 2.


𝑓(𝑥) = 3𝑥 2 − 4𝑥 − 3
⇒ 𝑓 ′ (𝑥) = 6𝑥 − 4 = 0 ⇒ 𝑥 = 2/3
2 4
Thus, the critical point along 𝑦 = −𝑥 + 2 is ( , ).
3 3

• Getting the values of the function at these critical points, we have the following.
2 4 −13
𝑓(1,0) = −1 𝑓( , ) = 𝑓(2,0) = 1
3 3 3
𝑓(0,2) = −3 𝑓(0,0) = 1

Therefore, after comparing the values we obtained, we conclude that 𝑓 has an absolute minimum
−13 2 4
value of at the point ( , ) and an absolute maximum value of 1 at the points (2,0) and (0,0).
3 3 3

__________________________

Concept Recap
1. What is a relative extremum of a function? an absolute extremum?
2. From the graph of a function, how can the relative maximum, relative minimum and saddle point
be identified?
3. How can the critical points of a function be obtained?
4. How can the Second Derivative Test be used to identify the relative maximum, relative minimum
and saddle point of a function?
5. How can an absolute extremum of a function be identified?
Practice Exercises
Determine the critical points of the following functions.
Then, using the Second Derivative Test, identify the relative extrema and saddle points.

1. 𝑓(𝑥, 𝑦) = (𝑥 − 2)2 + (𝑦 + 3)2


2. 𝑓(𝑥, 𝑦) = 𝑥 2 − 𝑦 2 − 8𝑥 + 10𝑦 − 20

3. 𝑓(𝑥, 𝑦) = 𝑥 2 + 2𝑦 2 − 6𝑥 − 28𝑦 + 5

4. 𝑓(𝑥, 𝑦) = 𝑥 3 + 𝑦 3 − 3𝑥 2 − 3𝑦 + 10

5. 𝑓(𝑥, 𝑦) = 𝑥 2 − 3𝑥𝑦 − 𝑦 2

6. 𝑓(𝑥, 𝑦) = 𝑦 3 − 3𝑥𝑦 + 6𝑥

7. Determine and compare the critical points of the functions


𝑓(𝑥, 𝑦) = √ 𝑥 2 + 𝑦 2 − 2𝑥 and 𝑔(𝑥, 𝑦) = 𝑥 2 + 𝑦 2 − 2𝑥.

8. Given 𝑓(𝑥, 𝑦) = 𝐴 − (𝑥 2 + 𝐵𝑥 + 𝑦 2 + 𝐶𝑦) , determine values of 𝐴, 𝐵 and 𝐶 for which 𝑓 has a


relative maximum value of 15 at the point (−2,1).

9. A company manufactures two products: Product A and Product B.


Product A is produced at quantity 𝑞1 (in thousands of units).
Product B is produced at quantity 𝑞2 (in thousands of units).
The total revenue for the two products is found out to be
𝑅(𝑞1 , 𝑞2 ) = −5𝑞1 2 − 8𝑞2 2 − 2𝑞1 𝑞2 + 42𝑞1 + 102𝑞2 .
Determine 𝑞1 and 𝑞2 that maximize the revenue.

10. A handcraft store makes wooden storage boxes. Each box is rectangular in shape, has an open
top and volume of 6 cubic feet. Material costs are P15 per square feet for the base and P10 per
square foot for the sides. Determine the dimensions of the box that minimizes the material cost of
producing a box. Also, what is the minimum cost?
Hint: Identify a function 𝐶(𝑥, 𝑦) that gives the cost of the box in terms of 𝑥 for base width and 𝑦 for
base length. Note that the volume of the box is fixed at 6 cu.ft

For the following, use the method in solving for absolute extrema.

11. Determine the maximum and minimum values of the function 𝑓(𝑥, 𝑦) = 𝑥 2 − 4𝑥 + 𝑦 2 − 2𝑦 over the
triangular region bounded by 𝑦 = 𝑥, 𝑥 = 3 and the 𝑥 −axis.
9
12. Determine the maximum and minimum values of the function 𝑓(𝑥, 𝑦) = 𝑥 3 − 𝑥 2 + 6𝑥 + 𝑦 3 − 3𝑦 2
2
over the rectangular region bounded by the lines 𝑥 = 3, 𝑦 = 3, the 𝑥 −axis and the 𝑦 −axis.

13. Determine the maximum and minimum values of the function 𝑓(𝑥, 𝑦) = 𝑥 2 − 6𝑥 + 𝑦 2 + 10𝑦 over
the circle 𝑥 2 + 𝑦 2 = 40 and its interior.

____________________________________________
Section 7. LAGRANGE OPTIMIZATION

By the end of this section, you must be able to


✓ identify objective function and constraint of a constrained optimization problem;
✓ discuss the procedures of the Lagrange method of optimization;
✓ implement the Lagrange method of optimization; and
✓ conclude the absolute extrema of a constrained optimization problem using Lagrange
optimization.

There are two types of extrema problems for functions of several variables:

(1) non-constrained optimization in which we determine relative extrema of a function using the
Second Derivative Test; and
(2) constrained optimization in which we maximize or minimize a function under an additional
condition (or a constraint) using the Lagrange method.

In constrained optimization, we maximize or minimize an objective function, say 𝑧 = 𝑓(𝑥, 𝑦),


subject to a constraint, say 𝑔(𝑥, 𝑦) = 0. A constraint describes the set under consideration where the
function is either maximized or minimized.

Lagrange method of optimization

Problem: maximize or minimize a function 𝒛 = 𝒇(𝒙, 𝒚) such that 𝒈(𝒙, 𝒚) = 𝟎

Note that here 𝑧 = 𝑓(𝑥, 𝑦) is the objective function and 𝑔(𝑥, 𝑦) = 0 is the constraint.

1. Form the auxiliary function 𝐹 of three variables 𝑥, 𝑦 and 𝜆 where

𝐹(𝑥, 𝑦, 𝜆) = 𝑓(𝑥, 𝑦) + 𝜆 ⋅ 𝑔(𝑥, 𝑦).

The additional variable 𝜆 is called Lagrange multiplier.

𝜕𝐹 𝜕𝐹 𝜕𝐹
2. Solve for the partial derivatives , and .
𝜕𝑥 𝜕𝑦 𝜕𝜆

3. Find the critical points of 𝐹 by solving the following system of equations:


𝜕𝐹
=0
𝜕𝑥
𝜕𝐹
=0
𝜕𝑦
𝜕𝐹
{ 𝜕𝜆 = 0

4. To determine the maximum or minimum, compare function values at the critical points.
The Second Derivative Test can also be applied to 𝑧 = 𝑓(𝑥, 𝑦) considering the critical points
from (3).

Examples.

1. We use the Lagrange method to identify the greatest and the smallest values of the function
𝑥2 𝑦2
𝑓(𝑥, 𝑦) = 𝑥𝑦 along the ellipse + = 1.
8 2

𝑥2 𝑦2
Set 𝑔(𝑥, 𝑦) = + − 1 = 0.
8 2
𝑥2 𝑦2
We form the function 𝐹(𝑥, 𝑦, 𝜆) = 𝑥𝑦 + 𝜆 ( + − 1).
8 2
𝜕𝐹 𝜆𝑥 𝜕𝐹 𝜕𝐹 𝑥2 𝑦2
Then, =𝑦+ , = 𝑥 + 𝜆𝑦 and = + −1.
𝜕𝑥 4 𝜕𝑦 𝜕𝜆 8 2

We now form the system:


𝜆𝑥
𝑦+ =0 (1)
4
𝑥 + 𝜆𝑦 = 0 (2) .
𝑥2 𝑦2
{8 + 2
− 1 = 0 (3)

−4𝑦
Solving 𝜆 in (1), we get 𝜆 = . (4)
𝑥
Substituting (4) to (2), we have
−4𝑦
𝑥 + ( ) 𝑦 = 0 ⇔ 𝑥 2 − 4𝑦 2 = 0 ⇔ 𝑥 2 = 4𝑦 2 . (5)
𝑥

We now substitute (5) to (3) and get


4𝑦 2 𝑦2 2𝑦 2
+ =1⇔ = 1 ⇔ 𝑦 = ±1 . (6)
8 2 2

From (5), when 𝑦 = 1, 𝑥 = ±2 and when 𝑦 = −1, 𝑥 = ±2 also.

Thus, we have the following critical points: (1,2), (1, −2), (−1,2), and (−1, −2).

Note that 𝑓(1,2) = 2, 𝑓(−1, −2) = 2, 𝑓(1, −2) = 2 and 𝑓(−1,2) = −2.

Hence, the greatest values of the function is 2 and the smallest value of the function is −2.
.

2. A manufacturing company produces television: 𝑥 units of model A and 𝑦 units of model B per
week, at cost 𝑓(𝑥, 𝑦) = 6𝑥 2 + 12𝑦 2 . If it is necessary that 𝑥 + 𝑦 = 90, how many of each type of
set should be manufactures per week to minimize cost?

We want to minimize the cost function 𝑓(𝑥, 𝑦) = 6𝑥 2 + 12𝑦 2


subject to the constraint 𝑔(𝑥, 𝑦) = 𝑥 + 𝑦 − 90 = 0.

Let 𝐹(𝑥, 𝑦, 𝜆) = 6𝑥 2 + 12𝑦 2 + 𝜆(𝑥 + 𝑦 − 90).


Then,
𝐹𝑥 (𝑥, 𝑦, 𝜆) = 12𝑥 + 𝜆, 𝐹𝑥 (𝑥, 𝑦, 𝜆) = 24𝑦 + 𝜆 and 𝐹𝜆 (𝑥, 𝑦, 𝜆) = 𝑥 + 𝑦 − 90 .

We form the system:


12𝑥 + 𝜆 = 0 (1)
{ 24𝑦 + 𝜆 = 0 (2) .
𝑥 + 𝑦 = 90 (3)
−𝜆 −𝜆
Solving for 𝑥 and 𝑦 in (1) and (2), respectively, we have 𝑥= and 𝑦= .
12 24
Substituting these equations to (3), we have
−𝜆 −𝜆
+ 24 = 90 ⇔ 3𝜆 = −2160 ⇔ 𝜆 = −720 .
12
−(−720) −(−720)
Hence, 𝑥 = = 60 and 𝑦 = = 30.
12 24

This means that (60,30) is the only critical point we have.

To determine whether this point gives us a minimum or a maximum value, we consider another
point in the constraint, say (40,50). Observe that 𝑓(60,30) = 6(60)2 + 12(30)2 = 3,240 and
𝑓(4,5) = 6(40)2 + 12(50)2 = 3,960. Since 𝑓(6,3) < 𝑓(4,5), the critical point gives the minimum
value for the function.
We conclude that 60 and 30 units of models A and B should be produced, respectively, to keep
the cost at the minimum.
Remark:
The Lagrange method can still be applied to function of three variables and to function of two
variables with two constraints. Here are the modifications that need to be done in dealing with such
constraint-optimization problems.

To maximize or minimize 𝑧 = 𝑓(𝑥, 𝑦, 𝑧) subject to the constraint 𝑔(𝑥, 𝑦, 𝑧) = 0, form the function
𝐹(𝑥, 𝑦, 𝑧, 𝜆) = 𝑓(𝑥, 𝑦, 𝑧) + 𝜆 ⋅ 𝑔(𝑥, 𝑦, 𝑥)
and solve the following system of equations:
𝜕𝐹
=0
𝜕𝑥
𝜕𝐹
=0
𝜕𝑦
𝜕𝐹
=0
𝜕𝑧
𝜕𝐹
{ 𝜕𝜆 = 0

To maximize or minimize 𝑧 = 𝑓(𝑥, 𝑦) subject to the constraints 𝑔(𝑥, 𝑦) = 0 and ℎ(𝑥, 𝑦) = 0, form the
function 𝐹(𝑥, 𝑦, 𝜆, 𝜇) = 𝑓(𝑥, 𝑦) + 𝜆 ⋅ 𝑔(𝑥, 𝑦) + 𝜇 ⋅ ℎ(𝑥, 𝑦)
and solve the following system of equations:
𝜕𝐹
=0
𝜕𝑥
𝜕𝐹
=0
𝜕𝑦
𝜕𝐹
=0
𝜕𝜆
𝜕𝐹
=0
{ 𝜕𝜇

__________________________

Concept Recap
1. What is a constrained optimization problem?
2. What is an objective function and a constraint of an optimization problem?
3. How do you form the Lagrange equation for solving constrained optimization problem?
4. How is the Lagrange method implemented in solving constrained optimization problem?
5. How is an absolute extrema established from the Lagrange method?

Practice Exercises
Use the Lagrange method to determine the absolute extrema of the following functions over the given
constraints.
1. 𝑓(𝑥, 𝑦) = 𝑥 + 𝑦 constraint: 𝑥 2 + 𝑦 2 = 1
2. 𝑓(𝑥, 𝑦) = 2𝑥 + 2𝑥𝑦 + 𝑦 constraint: 2𝑥 + 𝑦 = 100
3. 𝑓(𝑥, 𝑦) = 𝑥 2 − 4𝑥𝑦 constraint: 𝑥 + 𝑦 = 100
4. 𝑓(𝑥, 𝑦) = 𝑥𝑦 constraint: 2𝑥 + 𝑦 = 4
2 2
5. 𝑓(𝑥, 𝑦) = 𝑥 + 𝑦 constraint: 2𝑥 + 4𝑦 = 5
6. 𝑓(𝑥, 𝑦) = 2𝑥 + 𝑦 constraint: 𝑥𝑦 = 32
2 2
7. 𝑓(𝑥, 𝑦) = 𝑥 − 𝑦 constraint: 2𝑦 = 𝑥 2
8. 𝑓(𝑥, 𝑦) = 𝑥 2 + 𝑦 constraint: 𝑥 2 − 𝑦 2 = 1
Use the Lagrange method to determine the absolute extrema of the following functions over the given
constraints. Properly setup the Lagrange equation for functions of three variables.
9. 𝑓(𝑥, 𝑦, 𝑧) = 2𝑥 2 + 3𝑦 2 + 2𝑧 2 constraint: 𝑥 + 𝑦 + 𝑧 = 24
10. 𝑓(𝑥, 𝑦, 𝑧) = 𝑥 + 𝑦 + 𝑧 constraint: 𝑥 2 + 𝑦 2 + 𝑧 2 = 1

Properly setup the Lagrange equation for constrained optimization with two constraints..
11. 𝑓(𝑥, 𝑦, 𝑧) = 𝑥𝑦 + 𝑦𝑧 constraints: 𝑥 + 2𝑦 = 6, 𝑥 − 3𝑧 = 0
12. 𝑓(𝑥, 𝑦, 𝑧) = 𝑥 2 + 𝑦 2 + 𝑧 2 constraint: 𝑥 + 2𝑦 = 8, 𝑥 + 𝑧 = 4

13. Determine the nearest point of the line 2𝑥 − 3𝑦 = 6 from the point (3, −1).
Here, minimize the distance of a point (𝑥, 𝑦) from (3, −1) with the constraint 2𝑥 − 3𝑦 = 6

14. Determine the nearest point of the parabola (𝑦 + 2)2 − 𝑥 + 3 = 0 from the origin (0,0).

15. Determine the nearest point of the plane 𝑥 + 3𝑦 − 2𝑧 = 6 from the origin (0,0,0).
Here, minimize the distance of a point (𝑥, 𝑦, 𝑧) from (0,0,0) with the constraint 𝑥 + 3𝑦 − 2𝑧 = 6.

16. The production function for a company in given by 𝑓(𝑥, 𝑦) = 100𝑥 0.25 𝑦 0.75 where 𝑥 is the number
of units of labor and 𝑦 is the number of units of capital. The labor cost is P48 per unit and capital
cost is P36 per unit. Given that the total cost of labor and capital is limited to P100,000, what is
the maximum production level for the company?

17. A manufacturing company produces two models of a television set, 𝑥 units of Model A and 𝑦 units
of Model B per week, at a cost of 𝐶(𝑥, 𝑦) = 6𝑥 2 + 12𝑦 2 . If it is necessary (because of shipping
considerations) that 𝑥 + 𝑦 = 90, how many of each type of set should be manufactured per week
to minimize cost? What is the minimum cost?

18. The number of grams of an ice cream flavor can be modeled by


𝐺(𝑥, 𝑦, 𝑧) = 0.05𝑥 2 + 0.16𝑥𝑦 + 0.25𝑧 2
where 𝑥 is the number of fat grams, 𝑦 is the number of carbohydrates grams and 𝑧 is the number
of protein grams. Assume that there are 9 calories per fat gram, 4 calories per carbohydrate gram
and 4 calories per protein gram.
Determine the maximum number of grams of ice cream that can be consumed with a total of
exactly 400 calories.

____________________________________________

Section 8. TANGENT PLANES AND NORMAL LINES

By the end of this section, you must be able to


✓ illustrate a tangent plane and a normal line to a surface;
✓ determine the equation of the tangent plane to a given surface; and
✓ obtain the parametric equations of the normal line to a given surface.

In this section, we will see how gradient will be used


to get the equation of a plane that is tangent to a surface and
to get the equations of the line normal to a surface. a, b, c

Tangent Planes

Review:
Given a point (𝑥0 , 𝑦0 , 𝑧0 ) on a plane
and a normal vector 〈𝑎, 𝑏, 𝑐〉 to the plane,
the equation of the plane is given by
𝑎(𝑥 − 𝑥0 ) + 𝑏(𝑦 − 𝑦0 ) + 𝑐(𝑧 − 𝑧0 ) = 0.
To obtain a tangent plane to a surface, we consider a normal vector to the surface. This
normal vector is conveniently given by the gradient of the function defining the surface.

Theorem. Let 𝑆 be a surface with equation 𝐹(𝑥, 𝑦, 𝑧) = 0 and 𝑃0 be a point on 𝑆.


Then, 𝛻𝐹(𝑃0 ) is orthogonal to the surface 𝑆 at 𝑃0 .

From the above theorem, ∇𝐹(𝑃0 ) is the necessary normal vector to the tangent plane to 𝑆 at
𝑃0 . So, we have the following theorem that gives the equation of the tangent plane.

Theorem.
Let 𝑆 be a surface with equation 𝐹(𝑥, 𝑦, 𝑧) = 0 and 𝑃0 (𝑥0 , 𝑦0 , 𝑧0 ) be a point on 𝑆 with ∇𝐹(𝑃0 ) = 〈𝑎, 𝑏, 𝑐〉,.
The tangent plane to the surface at 𝑃0 (𝑥0 , 𝑦0 , 𝑧0 ) is given by the equation

𝑎(𝑥 − 𝑥0 ) + 𝑏(𝑦 − 𝑦0 ) + 𝑐(𝑧 − 𝑧0 ) = 0 .

Example.
Consider the surface defined by the function 𝑓(𝑥, 𝑦, 𝑧) = 𝑥 2 + 𝑦 2 + 𝑧 − 9 = 0.
We find the equation of the tangent plane to the given surface at the point 𝑃(1,2,4).

Note that ∇𝐹(𝑥, 𝑦, 𝑧) = 〈2𝑥, 2𝑦, 1〉.


Hence, ∇𝐹(1,2,4) = 〈2(1),2(2),1〉 = 〈2,4,1〉.

The plane has a standard equation 2(𝑥 − 1) + 4(𝑦 − 2) + (𝑧 − 4) = 0.


Its general equation is 2𝑥 + 4𝑦 + 𝑧 − 14 = 0.

Normal Lines f ( P )

Review:
Given a point 𝑃0 (𝑥0 , 𝑦0 , 𝑧0 ) on a line and a vector 〈𝑎, 𝑏, 𝑐〉
parallel to the line, the following are the parametric
equations of the line
𝑥 = 𝑥0 + 𝑎𝑡
{ 𝑦 = 𝑦0 + 𝑏𝑡
𝑧 = 𝑧0 + 𝑐𝑡

A normal line to the surface is a line through the surface that is perpendicular to a tangent
plane, i.e. in the direction of a normal vector.

Theorem. Given a surface 𝑆 with equation 𝐹(𝑥, 𝑦, 𝑧) = 0 and a point 𝑃0 (𝑥0 , 𝑦0 , 𝑧0 ) on 𝑆


with ∇𝐹(𝑃0 ) = 〈𝑎, 𝑏, 𝑐〉 which is not the zero vector,
𝑥 = 𝑥0 + 𝑎𝑡
the normal line to the surface at point 𝑃0 is given by the equation { 𝑦 = 𝑦0 + 𝑏𝑡 .
𝑧 = 𝑧0 + 𝑐𝑡

Example.
Consider the surface defined by the surface 𝑓(𝑥, 𝑦, 𝑧) = 𝑦𝑠𝑖𝑛𝑥 + 2𝑦𝑧 + 𝑧 = 0.
We find the parametric equations of the normal line to the given surface at the point 𝑃(0,1, −1).

Note that ∇𝐹(𝑥, 𝑦, 𝑧) = 〈𝑦𝑐𝑜𝑠𝑥, 𝑠𝑖𝑛𝑥 + 2𝑧, 2𝑦 + 1〉.


Solving for the vector that gives the direction for the line, we have
∇𝐹(0,1, −1) = 〈(−1)cos(0), sin(0) + 2(−1),2(1) + 1〉 = 〈1, −2,3〉.
Hence, the parametric equati1ons of the desired normal line are given by
𝑥 = 𝑡, 𝑦 − 1 = −2𝑡, and 𝑧 + 1 = 3𝑡 for 𝑡 ∈ ℝ.

__________________________
Concept Recap
1. What is a tangent plane to a surface? normal line to a surface?
2. How do you obtain the equation of a tangent plane to a surface at a given point?
3. How do you obtain the parametric equations of a normal line to a surface at a given point?

Practice Exercises
For each of the following, determine a.) the equation of the tangent plane and b.) parametric
equations of the normal line to the surface at the given point.

1. 𝑥 2 + 𝑦 2 + 𝑧 2 = 35 at the point (3, −5,1)


Show that the normal line passes through the origin.

2. 𝑥 2 − 𝑦 2 + 𝑧 2 = 4 at the point (2,1,1)

𝑥2 𝑦2
3. 𝑧 = + at the point (3,2,2)
9 4

𝜋
4. 𝑥 2 sin 𝑧 + 𝑦 cos 2𝑧 = 4 at the point (2,4, )
6

1⁄ 1⁄
5. 𝑧 = 𝑥 2 +𝑦 2 at the point (1,4,3)

6. Find a point on the surface 𝑧 = 𝑥 2 + 𝑦 2 where the tangent plane


is parallel to the plane 2𝑥 − 𝑦 − 2𝑧 = 1.

7. Find a point on the surface 𝑥 2 + 𝑦 2 + 𝑧 2 = 10 where the normal line


is parallel to the line with parametric equations: 𝑥 = 1 − 2𝑡, 𝑦 = 3𝑡, 𝑧 = 2 − 𝑡.
1 3
8. Show that the surfaces 𝑧 = 𝑥 2 𝑦 and 𝑦 = 𝑥 2 + intersect at the point (1,1,1).
4 4
Then, show that the tangent planes to the surfaces at (1,1,1) are perpendicular.

𝑥2 𝑦2 𝑦2
9. Show that the equation of the tangent plane to the ellipsoid + 𝑏2 + 𝑐 2 = 1
𝑎2
𝑥𝑜 𝑥 𝑦𝑜 𝑦 𝑧𝑜 𝑧
at the point (𝑥𝑜 , 𝑦𝑜 , 𝑧𝑜 ) can be written in the form + + = 1.
𝑎2 𝑏2 𝑐2

10. Find all points on the surface 𝑧 = 𝑥 2 − 2𝑥𝑦 − 𝑦 2 + 4𝑥 − 8𝑦


where the normal lines area parallel to the 𝑧 −axis.

____________________________________________

UNIT EXAM

Note: This unit exam should be answered in at most 60 minutes.

I. Fill in the blanks. Provide what is asked. You only need to give your answers.

For items 1 to 3, consider the function f ( x , y ) = 49 − x2 − y2 .

1. The domain of f is _________________. 3. The graph of f is a/an ________________.

2. The range of f is _________________.


xy2
For items 4 and 5, consider z = .
x2 − 4

z z
4. is given by __________________. 5. is given by ___________________.
x y

w
6. If w = x 2 z + e y z + x sin z , then is given by ______________________.
z

7. The gradient of h ( x, y, z ) = x2 y + yz3 + y2z2 is given by h ( x , y , z ) =


______________________.

1 3
For items 8-10, consider the function f ( x , y ) = x + y 2 − 2x 2 + 4 .
3

8. The critical point/s of f is/are _________________________.

9. The function has relative minimum at the point/s _________________________.


No need for z-components.

10. The function has saddle points at _________________________. No need for z-components.

II. Computations and graphing. Do as you will be asked.


1 1
A. On the given coordinate plane, draw a contour map of z = using levels at z = ,1, 2 .
2 2
y−x

On the given coordinate space, draw the surface using the level curves.

2 3
 g  g
B. Does the function g (x , y ) = e cos y − y sin x satisfy the equation
x
+ = 0 ? Justify
x2 yxy

your answer!
C. An ant is at the point ( 3, 2, −1) on the surface f ( x, y ) = x3 − xy + y2 . Using directional

derivatives,determine if the ant will ascend or descend on the surface if it will move in the
direction 4 ,−3 .

D. Consider the function f ( x, y ) = x2 + 3xy + y2 − x + 3y . Use Lagrange optimization to solve for the
maximum and minimum of the function over the hyperbola given by g ( x, y ) = x2 − y2 + 1 = 0 .

~ END OF EXAM ~

You might also like