M2504 Lec 05

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 12

Calculus 2B (M2504)

Dr. Khaphetsi Joseph Mahasa


National University of Lesotho
Department of Mathematics and Computer Science

April 11, 2022

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 1 / 12


Total Differentials and Chain Rules

The objective of this lesson is to understand the:


Total differentials,
Chain Rules.

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 2 / 12


Total Differentials and Chain Rules: Definitions
Let z = f (x, y), dx = ∆x, and dy = ∆y. The total differential of z
is the expression
∂z ∂z
dz = dx + dy = fx (x, y)dx + fy (x, y)dy.
∂x ∂y

A function z = f (x, y) is differentiable at the point (x0 , y0 ) if ∆z


can be written in the form
∆z = fx (x0 , y0 )∆x + fy (x0 , y0 )∆y + ε1 ∆x + ε2 ∆y, where ε1 and ε2
tend to zero as (∆x, ∆y) → (0, 0).
Let w be a function of x and y, and assume that x and y are both
functions of t. Then, w is a function of t, and the Chain Rule says
that
dw ∂w dx ∂w dy
= + .
dt ∂x dt ∂y dt

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 3 / 12


Total Differentials and Chain Rules: Definitions
General Chain Rule
Let z be a function of x and y, and assume that x and y are both
functions of u and v, respectively. Here, note that x and y are not
depending explicitly on the time t as assumed before, but on other
variables u and v (which may depend on t or other variables as well).
Then, z is a function of u and u, and the Chain Rule says that
∂z ∂z ∂x ∂z ∂y
= + ,
∂u ∂x ∂u ∂y ∂u
∂z ∂z ∂x ∂z ∂y
= + .
∂v ∂x ∂v ∂y ∂v

There are many other chain rules in multivariable calculus, but we will
not need them in this course.
Notice in the chain rule that some of the derivatives are ordinary
derivatives, and others are partial derivatives.
khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 4 / 12
Total Differentials and Chain Rules

Example 1
Compute the differentials of the following functions:

(a) f (x, y) = x2 e5y (b) z = x sin(xy) (c) f (x, y) = x cos(2x)

Solution
(a) Since fx (x, y) = 2xe5y and fy (x, y) = 5x2 e5y , we have

df = 2xe5y dx + 5x2 e5y dy.


∂z ∂z
(b) Since ∂x = sin(xy) + xy cos(xy) and ∂x = x2 cos(xy), we have

dz = (sin(xy) + xy cos(xy))dx + x2 cos(xy)dy.

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 5 / 12


Total Differentials and Chain Rules

(c) Since fx (x, y) = cos(2x) − 2x sin(2x) and fy (x, y) = 0, we have

df = (cos(2x) − 2x sin(2x))dx + 0dy = (cos(2x) − 2x sin(2x))dx.

Example 2
The density ρ (in g/cm3 ) of carbon dioxide gas CO2 depends upon its
temperature T (in ◦ C) and pressure P (in atmospheres). The ideal gas
model for CO2 gives what is called the state equation:
0.5363P
ρ= .
T + 273.15
Compute the differential dρ. Explain the signs of the coefficients of dT
and dP .

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 6 / 12


Total Differentials and Chain Rules

Solution
The differential for ρ = f (T, P ) is

−0.5363P 0.5363
dρ = fT (T, P )dT + fP (T, P )dP = 2
dT + dP.
(T + 273.15) T + 273.15

The coefficient of dT is negative because increasing the temperature


expands the gas (if the pressure is kept constant) and therefore decreases
its density. The coefficient of dP is positive because increasing the
pressure compresses the gas (if the temperature is kept constant) and
therefore increases its density.

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 7 / 12


Total Differentials and Chain Rules

Example 3
Use the total differential
p to approximate the change in the function
z = f (x, y) = 4 − x2 − y 2 as (x, y) changes from (1, 1) to (1.01, 0.97).
Solution
We have (x, y) = (1, 1), dx = ∆x = 0.01 and dy = ∆y = −0.03.
−1/2
∂z
The partial derivatives are ∂x = 21 4 − x2 − y 2 (−2x) = √ −x2 2
4−x −y
and ∂z
∂y = √ −y . So,
4−x2 −y 2

∂z ∂z −x −y
∆z ≈ dz = ∆x + ∆y = p ∆x + p ∆y
∂x ∂y 2
4−x −y 2 4 − x2 − y 2
−1 −1
≈ (0.01) + (−0.03) when x = y = 1
2 2
≈ 0.0141

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 8 / 12


Total Differentials and Chain Rules

This compares favorably with the exact change:


q p
∆z = f (1.01, 0.97) − f (1, 1) = 4 − (1.01)2 − (0.97)2 − 4 − 12 − 12
≈ 1.4279 − 1.4142 ≈ 0.0137.

Example 4
∂w ∂w
Let w = x2 ey , x = 4u, and y = 3u2 − 2v. Compute ∂u and ∂v using the
chain rule.
Solution
We have,
∂w ∂w ∂x ∂w ∂y
= + = 2xey (4) + x2 ey (6u) = (8x + 6x2 u)ey
∂u ∂x ∂u ∂y ∂u
2 −2v
= (32u + 96u3 )e3u .

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 9 / 12


Total Differentials and Chain Rules
Similarly,
∂w ∂w ∂x ∂w ∂y
= + = 2xey (0) + x2 ey (−2) = −2x2 ey
∂v ∂x ∂v ∂y ∂v
2 −2v
= −32u2 e3u .
Exercises
1 A quantity z can be expressed either as a function of x and y, so that
z = f (x, y), or as a function of u and v, so that z = g(u, v). The two
coordinate systems are related by
x = u + v, y = u − v.

(a) ∂z ∂z ∂z ∂z
Use the chain rule to express ∂u and ∂v in terms of ∂x and ∂y .
(b) Solve the equations in part (a) for ∂z ∂z
∂x and ∂y .
(c) Show that the expressions we get in part (b) are the same as we get by
expressing u and v in terms of x and y and using the chain rule.
khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 10 / 12
Exercises

(2) Use the chain rule to find dz


dt , and check the result by expressing z as
a function of t and differentiating directly.

z = x3 y 2 , x = t3 , y = t2 .

∂w ∂w
(3) Use the chain rule to find ∂ρ and ∂θ , given that

w = x2 + y 2 − z 2 ,

and

x = ρ sin φ cos θ, y = ρ sin φ sin θ, z = ρ cos φ.

(4) Use the total differential to approximate the quantity


(2.01)2 (9.02) − 22 (9).

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 11 / 12


THANK YOU

khaphetsimahasa@gmail.com: Lecture 05: NUL Calculus 2B (M2504) April 11, 2022 12 / 12

You might also like