Nothing Special   »   [go: up one dir, main page]

Partial Derivatives

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

Partial Derivatives

P. Sam Johnson

August 30, 2019

P. Sam Johnson Partial Derivatives August 30, 2019 1/117


Overview

The calculus of several variables is similar to single-variable calculus


applied to several variables one at a time. When we hold all but one of the
independent variables of a function constant and differentiate with respect
to that one variable, we get a partial derivative.

In this lecture, we see how partial derivatives are defined and interpreted
geometrically, and how to calculate them by applying the rules for
differentiating functions of a single variable.

The idea of differentiability for functions of several variables requires more


than the existence of the partial derivatives, but we will see that
differentiable functions of several variables behave in the same way as
differentiable single-variable functions.

P. Sam Johnson Partial Derivatives August 30, 2019 2/117


Partial Derivatives of a Function of Two Variables

If (x0 , y0 ) is a point in the domain of a function f (x, y ), the vertical plane


y = y0 will cut the surface z = f (x, y ) in the curve z = f (x, y0 ).

The picture shows that the intersec-


tion of the plane y = y0 with the sur-
face z = f (x, y ), viewed from above
the first quadrant of the xy -plane.

P. Sam Johnson Partial Derivatives August 30, 2019 3/117


Partial Derivatives of a Function of Two Variables

This curve is the graph of the func-


tion z = f (x, y0 ) in the plane y =
y0 . The horizontal coordinate in this
plane is x; the vertical coordinate is
z. The y -value is held constant at
y0 , so y is not a variable.

P. Sam Johnson Partial Derivatives August 30, 2019 4/117


Partial Derivatives of a Function of Two Variables

We define the partial derivative of f with respect to x at the point (x0 , y0 )


as the ordinary derivative of f (x, y0 ) with respect to x at the point x = x0 .

To distinguish partial derivatives from ordinary derivatives we use the


symbol ∂ rather than the d previously used. The partial derivative symbol
is variously pronounced as “del”, “partial dee”, “doh”, or “dabba”.

In the definition, h represents a real number, positive or negative.


Definition 1.
The partial derivative of f(x,y) with respect to x at the point (x0 , y0 )
is

∂f f (x0 + h, y0 ) − f (x0 , y0 )
= lim ,
∂x (x0 ,y0 ) h→0 h

provided the limit exists.


P. Sam Johnson Partial Derivatives August 30, 2019 5/117
Partial Derivatives of a Function of Two Variables

An equivalent expression for the partial derivative is



d
f (x, y0 ) .
dx x=x0

The slope of the curve z = f (x, y0 ) at the point P(x0 , y0 , f (x0 , y0 )) in the
plane y = y0 is the value of the partial derivative of f with respect to x at
(x0 , y0 ).

The tangent line to the curve at P is the line in the plane y = y0 that
passes through P with this slope. The partial derivative ∂f /∂x at (x0 , y0 )
gives the rate of change of f with respect to x when y is held fixed at the
value y0 .

P. Sam Johnson Partial Derivatives August 30, 2019 6/117


Partial Derivatives of a Function of Two Variables

We use several notations for the partial derivative:



∂f ∂z ∂f ∂z
(x0 , y0 ) or fx (x0 , y0 ), , and fx , , zx , or .
∂x ∂x (x0 ,y0 )
∂x ∂x
The definition of the partial derivative of f (x, y ) with respect to y at a
point (x0 , y0 ) is similar to the definition of the partial derivative of f with
respect to x. We hold x fixed at the value x0 and take the ordinary
derivative of f (x0 , y ) with respect to y at y0 .
Definition 2.
The partial derivative of f(x,y) with respect to y at the point (x0 , y0 )
is

∂f d f (x0 , y0 + h) − f (x0 , y0 )
= f (x0 , y ) = lim ,
∂y (x0 ,y0 )
dy y =y0 h→0 h

provided the limit exists.


P. Sam Johnson Partial Derivatives August 30, 2019 7/117
Partial Derivatives of a Function of Two Variables

The intersection of the plane x = x0


with the surface z = f (x, y ), viewed
from above the first quadrant of the
xy -plane.

P. Sam Johnson Partial Derivatives August 30, 2019 8/117


Partial Derivatives of a Function of Two Variables

The slope of the curve z = f (x0 , y ) at the point P(x0 , y0 , f (x0 , y0 )) in the
vertical plane x = x0 is the partial derivative of f with respect to y at
(x0 , y0 ). The tangent line to the curve at P is the line in the plane x = x0
that passes through P with this slope. The partial derivative gives the rate
of change of f with respect to y at (x0 , y0 ) when x is held fixed at the
value x0 .

The partial derivative with respect to y is denoted the same way as the
partial derivative with respect to x:
∂f ∂f
(x0 , y0 ), fy (x0 , y0 ), , fy .
∂y ∂y

P. Sam Johnson Partial Derivatives August 30, 2019 9/117


Partial Derivatives of a Function of Two Variables

The partial derivatives of f at (a, b) are the slopes of the tangents to C1


and C2 .

P. Sam Johnson Partial Derivatives August 30, 2019 10/117


Partial Derivatives of a Function of Two Variables

The graph of f is the paraboloid z = 4 − x 2 − 2y 2 and the vertical plane


y = 1 intersects it in the parabola z = 2 − x 2 , y = 1. The slope of the
tangent line to this parabola at the point (1, 1, 1) is fx (1, 1) = −2.

Similarly, the curve C2 in which the plane x = 1 intersects the paraboloid


is the parabola z = 3 − 2y 2 , x = 1, and the slope of the tangent line at
(1, 1, 1) is fy (1, 1) = −4.

P. Sam Johnson Partial Derivatives August 30, 2019 11/117


Partial Derivatives of a Function of Two Variables

The following figures are computer-drawn counterparts to the last figures.


Part (a) shows the plane y = 1 intersecting the surface to form the curve
Ci and part (b) shows the curve Ci and the tangent line Ti , i = 1, 2.

P. Sam Johnson Partial Derivatives August 30, 2019 12/117


Partial Derivatives of a Function of Two Variables

Notice that we now have two tangent lines associated with the surface
z = f (x, y ) at the point P(x0 , y0 , f (x0 , y0 )).

The tangent lines at the point


(x0 , y0 , f (x0 , y0 )) determine a plane
that, in this picture at least, appears
to be tangent to the surface.

Is the plane they determine tangent to the surface at P? We will see that
it is for the differentiable functions, we will learn how to find the tangent
plane. First we have to learn more about partial derivatives themselves.

P. Sam Johnson Partial Derivatives August 30, 2019 13/117


Calculations

The definitions of ∂f /∂x and ∂f /∂y give us two different ways of


differentiating f at a point: with respect to x in the usual way while
treating y as a constant and with respect to y in the usual way while
treating x as a constant. As the following examples show, the values of
these partial derivatives are usually different at a given point (x0 , y0 ).

Example 3.
Find the values of ∂f /∂x and ∂f /∂y at the point (4, −5) if

f (x, y ) = x 2 + 3xy + y − 1.
Solution : To find ∂f /∂x, we treat y as a constant and differentiate with
respect to x:
∂f ∂ 2
= (x + 3xy + y − 1) = 2x + 3 · 1 · y + 0 − 0 = 2x + 3y .
∂x ∂x
The value of ∂f /∂x at (4, −5) is 2(4) + 3(−5) = −7.
P. Sam Johnson Partial Derivatives August 30, 2019 14/117
Solution (contd...)

To find ∂f /∂y , we treat x as a constant and differentiate with respect to


y:
∂f ∂ 2
= (x + 3xy + y − 1) = 0 + 3 · x · 1 + 1 − 0 = 3x + 1.
∂y ∂y
The value of ∂f /∂y at (4, −5) is 3(4) + 1 = 13.
Example 4.
Find ∂f /∂y as a function if f (x, y ) = y sin xy .

Solution : We treat x as a constant and f as a product of y and sin xy :


∂f ∂ ∂ ∂
= (y sin xy ) = y sin xy + (sin xy ) (y )
∂y ∂y ∂y ∂y

= (y cos xy ) (xy ) + sin xy = xy cos xy + sin xy .
∂y
P. Sam Johnson Partial Derivatives August 30, 2019 15/117
Example
Example 5.
2y
Find fx and fy as functions if f (x, y ) = y +cos x .

Solution : We treat f as a quotient. With y held constant, we get


∂ ∂
∂ 2y (y + cos x) ∂x (2y ) − 2y ∂x (y + cos x)
fx = ( )= 2
∂x y + cos x (y + cos x)
(y + cos x)(0) − 2y (− sin x) 2y sin x
= 2
= .
(y + cos x) (y + cos x)2
With x held constant, we get
∂ ∂
∂ 2y (y + cos x) ∂y (2y ) − 2y ∂y (y + cos x)
fy = ( )=
∂y y + cos x (y + cos x)2
(y + cos x)(2) − 2y (1) 2 cos x
= 2
= .
(y + cos x) (y + cos x)2
P. Sam Johnson Partial Derivatives August 30, 2019 16/117
Solution

Implicit differentiation works for partial derivatives the way it works for
ordinary derivatives, as the next example illustrates.
Example 6.
Find ∂z/∂x if the equation yz − ln z = x + y defines z as a function of the
two independent variables x and y and the partial derivative exists.

We differentiate both sides of the equation with respect to x, holding y


constant and treating z as a differentiable function of x:
∂ ∂ ∂x ∂y
(yz) − ln z = +
∂x  ∂x ∂x ∂x
1 ∂z
y− =1
z ∂x
∂z z
= .
∂x yz − 1
P. Sam Johnson Partial Derivatives August 30, 2019 17/117
Example
Example 7.
The plane x = 1 intersects the paraboloid z = x 2 + y 2 in a parabola. Find
the slope of the tangent to the parabola at (1, 2, 5).

The tangent to the curve of intersec-


tion of the plane x = 1 and surface
z = x 2 + y 2 at the point (1, 2, 5).

P. Sam Johnson Partial Derivatives August 30, 2019 18/117


Solution

The slope is the value of the partial derivative ∂z/∂y at (1, 2):

∂z ∂ 2 2

= (x + y ) = 2y |(1,2) = 2(2) = 4.
∂y (1,2)
∂y (1,2)

As a check, we can treat the parabola as the graph of the single-variable


function z = (1)2 + y 2 = 1 + y 2 in the plane x = 1 and ask for the slope
at y = 2. The slope, calculated now as an ordinary derivative, is

dz d 2

= (1 + y ) = 2y |y =2 = 4.
dy y =2
dy y =2

P. Sam Johnson Partial Derivatives August 30, 2019 19/117


Functions of More Than Two Variables

The definitions of the partial derivatives of functions of more than two


independent variables are like the definitions for functions of two variables.
They are ordinary derivatives with respect to one variable, taken while the
other independent variables are held constant.
Example 8.
If x, y , and z are independent variables and

f (x, y , z) = x sin(y + 3z),

then
∂f ∂ ∂
= [x sin(y + 3z)] = x sin(y + 3z)
∂z ∂z ∂z

= x cos(y + 3z) (y + 3z) = 3x cos(y + 3z).
∂z

P. Sam Johnson Partial Derivatives August 30, 2019 20/117


Example
Example 9.
If resistors of R1 ,R2 , and R3 ohms are connected in parallel to make an
R-ohm resistor, the value of R can be found from the equation
1 1 1 1
= + + .
R R1 R2 R3
Find the value of ∂R/∂R2 when R1 = 30, R2 = 45, and R3 = 90 ohms.

Resistors arranged this way are said to be connected


in parallel. Each resistor lets a portion of the current
through. Their equivalent resistance R is calculated
with the formula
1 1 1 1
= + + .
R R1 R2 R3

P. Sam Johnson Partial Derivatives August 30, 2019 21/117


Solution

To find ∂R/∂R2 , we treat R1 and R3 as constants and, using implicit


differentiation, differentiate both sides of the equation with respect to R2 :
   
∂ 1 ∂ 1 1 1
= + +
∂R2 R ∂R2 R1 R2 R3
1 ∂R 1
− 2 =0− 2 +0
R ∂R2 R2
2
 2
∂R R R
= 2 = .
∂R2 R2 R2

P. Sam Johnson Partial Derivatives August 30, 2019 22/117


Solution (contd...)

When R1 = 30, R2 = 45, and R3 = 90,


1 1 1 1 3+2+1 6 1
= + + = = = ,
R 30 45 90 90 90 15
so R = 15 and
 2  2  
∂R 15 1 1
= = = .
∂R2 45 3 9

Thus at the given values, a small change in the resistance R2 leads to a


change in R about 1/9th as large.

P. Sam Johnson Partial Derivatives August 30, 2019 23/117


Partial Derivatives and Continuity

A function f (x, y ) can have partial derivatives with respect to both


x and y at a point without the function being continuous there.

This is different from functions of a single variable, where the


existence of a derivative implies continuity.

We shall see that if the partial derivatives of f (x, y ) exist and are
continuous throughout a disk centered at (x0 , y0 ), however, then f is
continuous at (x0 , y0 ).

P. Sam Johnson Partial Derivatives August 30, 2019 24/117


Partial Derivatives and Continuity
Example 10.
(
0, xy 6= 0
Let f (x, y ) =
1, xy = 0.
(a) Find the limit of f as (x, y ) approaches (0, 0) along the line y = x.
(b) Prove that f is not continuous at the origin.
(c) Show that both partial derivatives ∂f /∂x and ∂f /∂y exist at the
origin.

(
0, xy 6= 0
The graph of f (x, y ) = consists of
1, xy = 0
the linesL1 and L2 and the four open quadrants of
the xy -plane. The function has partial derivatives
at the origin but is not continuous there.

P. Sam Johnson Partial Derivatives August 30, 2019 25/117


Solution

(a) Since f (x, y ) is constantly zero along the line y = x (except at the
origin), we have


lim f (x, y ) = lim 0 = 0.
(x,y )→(0,0) y =x (x,y )→(0,0)

(b) Since f (0, 0) = 1, the limit in part (a) proves that f is not continuous
at (0, 0).
(c) To find ∂f /∂x at (0, 0), we hold y fixed at y = 0. Then f (x, y ) = 1
for all x, and the graph of f is the line L1 in the figure. The slope of
this line at any x is ∂f /∂x = 0. In particular, ∂f /∂x = 0 at (0, 0).
Similarly, ∂f /∂y is the slope of line L2 at any y , so ∂f /∂y = 0 at
(0, 0).

P. Sam Johnson Partial Derivatives August 30, 2019 26/117


Relation Between Differentiability and Continuity

The above example suggests that we need a stronger requirement


for differentiability in higher dimensions than the mere existence of
the partial derivatives.

We shall define differentiability for functions of two variables (which


is slightly more complicated than for single-variable functions) and
then revisit the connection to continuity.

P. Sam Johnson Partial Derivatives August 30, 2019 27/117


Second-Order Partial Derivatives

When we differentiate a function f (x, y ) twice, we produce its


second-order derivatives. These derivatives are usually denoted by
∂2f ∂2f ∂2f ∂2f
or fxx , or fyy , or fyx , and or fxy .
∂x 2 ∂y 2 ∂x∂y ∂y ∂x
The defining equations are
∂2f ∂2f
   
∂ ∂f ∂ ∂f
2
= , = ,
∂x ∂x ∂x ∂x∂y ∂x ∂y
and so on.

Notice the order in which the mixed partial derivatives are taken:
∂2f
Differentiate first with respect to y , then with respect to x.
∂x∂y
fyx = (fy )x Means the same thing.

P. Sam Johnson Partial Derivatives August 30, 2019 28/117


Example
Example 11.
If f (x, y ) = x cos y + ye x , find the second-order derivatives

∂2f ∂2f ∂2f ∂2f


, , , and .
∂x 2 ∂y ∂x ∂y 2 ∂x∂y

Solution : The first step is to calculate both first partial derivatives.


∂f ∂ ∂f ∂
= (x cos y + ye x ) = (x cos y + ye x )
∂x ∂x ∂y ∂y
x
= cos y + ye = − x sin y + e x
Now we find both partial derivatives of each first partial:

∂2f ∂2f
   
∂ ∂f ∂ ∂f
= = − sin y + e x = = − sin y + e x
∂y ∂x ∂y ∂x ∂x∂y ∂x ∂y
∂2f ∂2f
   
∂ ∂f ∂ ∂f
= = ye x . = = −x cos y .
∂x 2 ∂x ∂x ∂y 2 ∂y ∂y

P. Sam Johnson Partial Derivatives August 30, 2019 29/117


The Mixed Derivative Theorem

We have noticed in the above example that the mixed second-order partial
derivatives
∂2f ∂2f
and
∂y ∂x ∂x∂y
are equal. This is not a coincidence. They must be equal whenever
f , fx , fy , fxy , and fyx are continuous, as stated in the following theorem.

Theorem 12 (The Mixed Derivative Theorem).


If f (x, y ) and its partial derivatives fx , fy , fxy , and fyx are defined
throughout an open region containing a point (a, b) and are all continuous
at (a, b), then

fxy (a, b) = fyx (a, b).

P. Sam Johnson Partial Derivatives August 30, 2019 30/117


Clairaut’s Theorem

The Mixed Derivative Theorem is also known as Clairaut’s Theorem,


named after the French mathematician Alexis Clairaut who discovered it.

The Mixed Derivative Theorem says that to calculate a mixed


second-order derivative, we may differentiate in either order, provided the
continuity conditions are satisfied. This ability to proceed in different order
sometimes simplifies our calculations.
Example 13.
Find ∂ 2 w /∂x∂y if

ey
w = xy + .
y2 + 1

P. Sam Johnson Partial Derivatives August 30, 2019 31/117


Solution

The symbol ∂ 2 w /∂x∂y tells us to differentiate first with respect to y and


then with respect to x. However, if we interchange the order of
differentiation and differentiate first with respect to x we get the answer
more quickly. In two steps,

∂w ∂2w
=y and = 1.
∂x ∂y ∂x

If we differentiate first with respect to y , we obtain ∂ 2 w /∂x∂y = 1 as


well. We can differentiate in either order because the conditions of “The
Mixed Derivative Theorem” hold for w at all points (x0 , y0 ).

P. Sam Johnson Partial Derivatives August 30, 2019 32/117


Partial Derivatives of Still Higher Order

Although we will deal mostly with first- and second-order partial


derivatives, because these appear the most frequently in applications, there
is no theoretical limit to how many times we can differentiate a function as
long as the derivatives involved exist. Thus, we get third- and fourth-order
derivatives denoted by symbols like

∂3f
= fyyx ,
∂x∂y 2
∂4f
= fyyxx ,
∂x 2 ∂y 2
and so on. As with second-order derivatives, the order of differentiation is
immaterial as long as all the derivatives through the order in question are
continuous.

P. Sam Johnson Partial Derivatives August 30, 2019 33/117


Example 14.
Find fyxyz if f (x, y , z) = 1 − 2xy 2 z + x 2 y .

Solution : We first differentiate with respect to the variable y , then x,


then y again, and finally with respect to z:

fy = −4xyz + x 2
fyx = −4yz + 2x
fyxy = −4z
fyxyz = −4.

P. Sam Johnson Partial Derivatives August 30, 2019 34/117


Differentiability

The starting point for differentiability is not the difference quotient we saw
in studying single-variable functions, but rather the idea of increment.
Recall that if y = f (x) is differentiable at x = x0 , then the change in the
value of f that results from changing x from x0 to x0 + ∆x is given by an
equation of the form

∆y = f 0 (x0 )∆x + ε∆x

in which ε → 0 as ∆x → 0.

For functions of two variables, the analogous property becomes the


definition of differentiability.

P. Sam Johnson Partial Derivatives August 30, 2019 35/117


Increment Theorem for Functions of Two Variables
Theorem 15 (The Increment Theorem for Functions of Two
Variables).
Suppose that the first partial derivatives of f (x, y ) are defined throughout
an open region R containing the point (x0 , y0 ) and that fx and fy are
continuous at (x0 , y0 ). Then the change

∆z = f (x0 + ∆x, y0 + ∆y ) − f (x0 , y0 )

in the value of f that results from moving from (x0 , y0 ) to another point
(x0 + ∆x, y0 + ∆y ) in R satisfies an equation of the form

∆z = fx (x0 , y0 )∆x + fy (x0 , y0 )∆y + ε1 ∆x + ε2 ∆y

in which each of ε1 , ε2 → 0 as both ∆x, ∆y → 0.

P. Sam Johnson Partial Derivatives August 30, 2019 36/117


Differentiable Functions
Definition 16.
A function z = f (x, y ) is differentiable at (x0 , y0 ) if fx (x0 , y0 ) and
fy (x0 , y0 ) exist and ∆z satisfies an equation of the form

∆z = fx (x0 , y0 )∆x + fy (x0 , y0 )∆y + ε1 ∆x + ε2 ∆y

in which each of ε1 , ε2 → 0 as both ∆x, ∆y → 0. We call f


differentiable if it is differentiable at every point in its domain, and say
that its graph is a smooth surface.

Because of this definition, an immediate corollary of “Increment Theorem


for Functions of Two Variables” is that a function is differentiable at
(x0 , y0 ) if its first partial derivatives are continuous there.

P. Sam Johnson Partial Derivatives August 30, 2019 37/117


Differentiable Functions
Corollary 17.
If the partial derivatives fx and fy of a function f (x, y ) are continuous
throughout an open region R, then f is differentiable at every point of R.

If z = f (x, y ) is differentiable, then the definition of differentiability


assures that ∆z = f (x0 + ∆x, y0 + ∆y ) − f (x0 , y0 ) approaches 0 as ∆x
and ∆y approach 0. This tells us that a function of two variables is
continuous at every point where it is differentiable.

Theorem 18 (Differentiability Implies Continuity).


If a function f (x, y ) is differentiable at (x0 , y0 ), then f is continuous at
(x0 , y0 ).

P. Sam Johnson Partial Derivatives August 30, 2019 38/117


Remark

A function f (x, y ) must be continuous at a point (x0 , y0 ) if fx and fy are


continuous throughout an open region containing (x0 , y0 ).

Remember, however, that it is still possible for a function of two variables


to be discontinuous at a point where its first partial derivatives exist.

Existence alone of the partial derivatives at that point is not enough, but
continuity of the partial derivatives guarantees differentiability.

P. Sam Johnson Partial Derivatives August 30, 2019 39/117


Recall

The Chain Rule for functions of a single variable says that when

w = f (x) is a differentiable function of x, and


x = g (t) is a differentiable function of t,

then

w is a differentiable function of t, and


dw dw dx
dw /dt can be calculated by the formula dt = dx dt .

For functions of two or more variables, the Chain Rule has several forms.
The form depends on how many variables are involved, but once this is
taken into account, it works like the Chain Rule for functions of a single
variable.

P. Sam Johnson Partial Derivatives August 30, 2019 40/117


Functions of Two Variables

The Chain Rule formula for a differentiable function w = f (x, y ) when


x = x(t) and y = y (t) are both differentiable functions of t is given in the
following theorem.

Theorem 19 (Chain Rule for Functions of Two Independent


Variables).
If w = f (x, y ) is differentiable and if x = x(t),y = y (t) are differentiable
functions of t, then the composite w = f (x(t), y (t)) is a differentiable
function of t and
dw
= fx (x(t), y (t)) · x 0 (t) + fy (x(t), y (t)) · y 0 (t),
dt
or
dw ∂f dx ∂f dy
= + .
dt ∂x dt ∂y dt

P. Sam Johnson Partial Derivatives August 30, 2019 41/117


Branch Diagram : Functions of Two Variables

Often we write ∂w /∂x for the


partial derivative ∂f /∂x, so
we can rewrite the Chain Rule
in the form
dw ∂w dx ∂w dy
= + .
dt ∂x dt ∂y dt

P. Sam Johnson Partial Derivatives August 30, 2019 42/117


Functions of Three Variables

We can now probably predict the Chain Rule for functions of three
variables, as it only involves adding the expected third term to the
two-variable formula.
Theorem 20 (Chain Rule for Functions of Three Independent
Variables).
If w = f (x, y , z) is differentiable and x, y , and z are differentiable
functions of t, then w is a differentiable function of t and
dw ∂w dx ∂w dy ∂w dz
= + + .
dt ∂x dt ∂y dt ∂z dt

P. Sam Johnson Partial Derivatives August 30, 2019 43/117


Branch Diagram : Functions of Two Variables

P. Sam Johnson Partial Derivatives August 30, 2019 44/117


Functions Defined on Surfaces

If we are interested in the temperature w = f (x, y , z) at points (x, y , z) on


the earth’s surface, we might prefer to think of x, y , and z as functions of
the variables r and s that give the point’s longitudes and latitudes.

If x = g (r , s), y = h(r , s),


and z = k(r , s), we could then
express the temperature as a
function of r and s with the
composite function

w = f (g (r , s), h(r , s), k(r , s)).

P. Sam Johnson Partial Derivatives August 30, 2019 45/117


Functions Defined on Surfaces

Under the conditions stated below, w has partial derivatives with respect
to both r and s that can be calculated in the following way.

Theorem 21 (Chain Rule for Two Independent Variables and


Three Intermediate Variables).
Suppose that w = f (x, y , z), x = g (r , s), y = h(r , s), and z = k(r , s). If
all four functions are differentiable, then w has partial derivatives with
respect to r and s, given by the formulas
∂w ∂w ∂x ∂w ∂y ∂w ∂z
= + +
∂r ∂x ∂r ∂y ∂r ∂z ∂r
∂w ∂w ∂x ∂w ∂y ∂w ∂z
= + + .
∂s ∂x ∂s ∂y ∂s ∂z ∂s

P. Sam Johnson Partial Derivatives August 30, 2019 46/117


∂w ∂w ∂x ∂w ∂y ∂w ∂z
Branch Diagram for ∂r = ∂x ∂r + ∂y ∂r + ∂z ∂r

P. Sam Johnson Partial Derivatives August 30, 2019 47/117


∂w ∂w ∂x ∂w ∂y ∂w ∂z
Branch Diagram for ∂s = ∂x ∂s + ∂y ∂s + ∂z ∂s

P. Sam Johnson Partial Derivatives August 30, 2019 48/117


∂w ∂w ∂x ∂w ∂y
Branch Diagram for ∂r = ∂x ∂r + ∂y ∂r

If f is a function of two variables instead of


three, each equation in the above Theorem
becomes correspondingly one term shorter.
If w = f (x, y ), x = g (r , s), and y = h(r , s),
then
∂w ∂w ∂x ∂w ∂y
= +
∂r ∂x ∂r ∂y ∂r
and
∂w ∂w ∂x ∂w ∂y
= + .
∂s ∂x ∂s ∂y ∂s

P. Sam Johnson Partial Derivatives August 30, 2019 49/117


Branch Diagram

If f is a function of x alone, our equations are


even simpler.

If w = f (x, y ), x = g (r , s), and y = h(r , s),


then
∂w dw ∂x
=
∂r dx ∂r
and
∂w dw ∂x
= .
∂s dx ∂s

P. Sam Johnson Partial Derivatives August 30, 2019 50/117


Functions Defined on Surfaces
Theorem 22 (A Formula for Implicit Differentiation).
Suppose that F (x, y ) is differentiable and that the equation F (x, y ) = 0
defines y as a differentiable function of x. Then at any point where
Fy 6= 0,

dy Fx
=− .
dx Fy

P. Sam Johnson Partial Derivatives August 30, 2019 51/117


Functions Defined on Surfaces

The result in Theorem 22 is easily extended to three variables.

Suppose that the equation F (x, y , z) = 0 defines the variable z implicitly


as a function z = f (x, y ). Then for all all (x, y ) in the domain of f , we
have
F (x, y , f (x, y )) = 0.
Assuming that F and f are differentiable functions, we can use the Chain
Rule to differentiate the equation F (x, y , z) = 0 with respect to the
independent variables x and y . Hence we get
∂z Fx ∂z Fy
=− and =− . (1)
∂x Fy ∂y Fz

P. Sam Johnson Partial Derivatives August 30, 2019 52/117


Implicit Function Theorem

An important result from advanced calculus, called the Implicit Function


Theorem, states the conditions for which our results in Equations (1) are
valid.

If the partial derivatives Fx , Fy , and Fz are continuous throughout an open


region R in space containing the point (x0 , y0 , z0 ), and if for some
constant c, F (x0 , y0 , z0 ) = c and Fz (x0 , y0 , z0 ) 6= 0, then the equation
F (x, y , z) = c defines z implicitly as a differentiable function of x and y
near (x0 , y0 , z0 ), and the partial derivatives of z are given by Equations (1).

P. Sam Johnson Partial Derivatives August 30, 2019 53/117


Functions of Many Variables

We have seen several different forms of the Chain Rule in this section, but
each one is just a special case of one general formula. When solving
particular problems, it may help to draw the appropriate branch diagram
by placing the dependent variable on top, the intermediate variables in the
middle, and the selected independent variable at the bottom.

To find the derivative of the dependent variable with respect to the


selected independent variable, start at the dependent variable and read
down each route of the branch diagram to the independent variable,
calculating and multiplying the derivatives along each route. Then add the
products found for the different routes.

P. Sam Johnson Partial Derivatives August 30, 2019 54/117


Functions of Many Variables

In general, suppose that w = f (x, y , . . . , v ) is a differentiable function of


the variables x, y , . . . , v (a finite set) and the x, y , . . . , v are differentiable
functions of p, q, . . . , t (another finite set).

Then w is a differentiable function of the variables p through t, and the


partial derivatives of w with respect to these variables are given by
equations of the form
∂w ∂w ∂x ∂w ∂y ∂w ∂v
= + + ... + .
∂p ∂x ∂p ∂y ∂p ∂v ∂p
The other equations are obtained by replacing p by q, · · · , t, one at a time.

P. Sam Johnson Partial Derivatives August 30, 2019 55/117


Functions of Many Variables

One way to remember this equation is to think of the right-hand side as


the dot product of two vectors with components
complex number
z }| {
x
|{z} + iy
|{z}
real imaginary
   
∂w ∂w ∂w ∂x ∂y ∂v
, ,..., and , ,..., .
∂x ∂y ∂v ∂p ∂p ∂p
| {z } | {z }
Derivatives of w with Derivatives of the
respect to the intermediate variables with
intermediate variables respect to the selected
independent variable

P. Sam Johnson Partial Derivatives August 30, 2019 56/117


Calculating First-Order Partial Derivatives
Exercise 23.
Find ∂f /∂x and ∂f /∂y .
1. f (x, y ) = tan−1 (y /x)
2. f (x, y ) = (x 3 + (y /2))2/3
3. f (x, y ) = (x + y )/(xy − 1)
4. f (x, y ) = e −x sin(x + y )
5. f (x, y ) = sin2 (x − 3y )
Z y
6. f (x, y ) = g (t)dt (g continuous for all t)
x

X
7. f (x, y ) = (xy )n (|xy | < 1)
n=0

P. Sam Johnson Partial Derivatives August 30, 2019 57/117


Solution for (1),(2),(3) and (4) in Exercise 23
∂f 1 ∂ y y y
1. ∂x = 2 · ∂x ( x ) = − x 2 [1+( y 2 = − 2
) ] x +y 2
,
1+( yx ) x
∂f 1 ∂ y 1 x
∂y = 2 · ∂y ( x ) = x[1+( yx )2 ]
= x 2 +y 2
1+( yx )
∂f 2
2. = q 2x ∂f
, ∂y = q 1
∂x
x +( y2 )
3 3
3 3 x 3 +( y2 )
(xy −1)(1)−(x+y )(y ) −y 2 −1 ∂f
3. ∂f
∂x = (xy −1)2
= (xy ,
−1)2 ∂y
= (xy −1)(1)−(x+y
(xy −1)2
)(x) −x 2 −1
= (xy −1)2
4. ∂f
∂x = −e −x sin(x + y ) + e −x cos(x + y ), ∂y = e −x cos(x + y )
∂f

P. Sam Johnson Partial Derivatives August 30, 2019 58/117


Solution for (5),(6) and (7) in Exercise 23
∂f ∂
5. ∂x = 2 sin(x − 3y ) · ∂x sin(x − 3y ) =

2 sin(x − 3y ) cos(x − 3y ) · ∂x (x − 3y ) = 2 sin(x − 3y ) cos(x − 3y ),
∂f ∂
∂y = 2 sin(x − 3y ) · ∂y sin(x − 3y ) =

2 sin(x − 3y ) cos(x − 3y ) · ∂y (x − 3y ) = −6 sin(x − 3y ) cos(x − 3y )
∂f ∂f
6. ∂x= −g (x), ∂y = g (y )

(xy )n ,
P
7. f (x, y ) =
n=0
1 ∂f 1 ∂ y
|xy | < 1 ⇒ f (x, y ) = 1−xy ⇒ ∂x = − (1−xy )2 · ∂x (1 − xy ) = (1−xy )2
∂f 1 ∂ x
and ∂y = − (1−xy )2
· ∂y (1 − xy ) = (1−xy )2

P. Sam Johnson Partial Derivatives August 30, 2019 59/117


Exercises
Exercise 24.
Find fx , fy and fz .
1. f (x, y , z) = 1 + xy 2 − 2z 2
2. f (x, y , z) = (x 2 + y 2 + z 2 )−1/2
3. f (x, y , z) = sin−1 (xyz)
4. f (x, y , z) = ln(x + 2y + 3z)
5. f (x, y , z) = tanh(x + 2y + 3z)
6. f (x, y , z) = sinh(xy − z 2 )

P. Sam Johnson Partial Derivatives August 30, 2019 60/117


Solution for Exercise 24

1. fx = y 2 , fy = 2xy , fz = −4z
2. fx = −x(x 2 + y 2 + z 2 )−3/2 , fy = −y (x 2 + y 2 + z 2 )−3/2 ,
fz = −z(x 2 + y 2 + z 2 )−3/2
3. fx = √ yz2 2 2 , fy = √ xz2 2 2 , fz = √ xy2 2 2
1−x y z 1−x y z 1−x y z
1 2 3
4. fx = x+2y +3z , fy = x+2y +3z , fz = x+2y +3z
5. fx = sech2 (x + 2y + 3z), fy = 2 sech2 (x + 2y + 3z),
fz = 3 sech2 (x + 2y + 3z)
6. fx = y cosh(xy − z 2 ), fy = x cosh(xy − z 2 ), fz = −2z cosh(xy − z 2 )

P. Sam Johnson Partial Derivatives August 30, 2019 61/117


Exercises
Exercise 25.
Find the partial derivative of the function with respect to each variable.
1. f (t, α) = cos(2πt − α)
2. g (r , θ, z) = r (1 − cos θ) − z
3. Work done by the heart

V δv 2
W (P, V , δ, v , g ) = PV +
2g
4. Wilson lot size formula
km hq
A(c, h, k, m, q) = + cm +
q 2

P. Sam Johnson Partial Derivatives August 30, 2019 62/117


Solution for Exercise 25
∂f ∂f
1. ∂t = −2π sin(2πt − α), ∂α = sin(2πt − α)
∂g ∂g ∂g
2. ∂r = 1 − cos θ, ∂θ = r sin θ, ∂z = −1
δv 2 Vv 2 2V δv V ∂v
3. Wp = V , Wv = P + 2g , Wδ = 2g , Wv = 2g = g ,
2
Wg = − V2gδv2
4. ∂A
∂c = m, ∂A
∂h = q2 , ∂A
∂k = m ∂A
q , ∂m = k
q + c, ∂A
∂q = − km
q2
+ h
2

P. Sam Johnson Partial Derivatives August 30, 2019 63/117


Exercises
Exercise 26.
Find all the second-order partial derivatives of the functions.
1. f (x, y ) = x + y + xy
2. h(x, y ) = xe y + y + 1
3. w = x 2 tan(xy )
x−y
4. w = x 2 +y

P. Sam Johnson Partial Derivatives August 30, 2019 64/117


Solution for (1), (2) and (3) in Exercise 26
∂f ∂f ∂2f ∂2f ∂2f ∂2f
1. ∂x = 1 + y, ∂y = 1 + x, ∂x 2
= 0, ∂y 2
= 0, ∂y ∂x = ∂x∂y =1
∂h ∂h ∂2h ∂2h ∂2h ∂2h
2. ∂x = ey , ∂y = xe y + 1, ∂x 2
= 0, ∂y 2
= xe y , ∂y ∂x = ∂x∂y = ey
3. ∂w
∂x
= 2x tan(xy ) + x 2 sec2 (xy ) · y = 2x tan(xy ) + x 2 y sec2 (xy ),
∂w
∂y
= x 2 sec2 (xy ) · x = x 3 sec2 (xy ),
2
∂ w
∂x 2
= 2 tan(xy ) + 2x sec2 (xy ) · y + 2xy sec2 (xy ) + x 2 y (2 sec(xy ) sec(xy ) tan(xy ) · y) =
2 tan(xy ) + 4xy sec2 (xy ) + 2x 2 y 2 sec2 (xy ) tan(xy ),
∂2w
∂y 2
= x 3 (2 sec(xy ) sec(xy ) tan(xy ) · x) = 2x 4 sec2 (xy ) tan(xy )
∂2w ∂2w
∂y ∂x
= ∂x∂y = 3x 2 sec2 (xy ) + x 3 (2 sec(xy ) sec(xy ) tan(xy ) · y ) =
3x sec (xy ) + x 3 y sec2 (xy ) tan(xy ).
2 2

P. Sam Johnson Partial Derivatives August 30, 2019 65/117


Solution for (4) in Exercise 26
(x 2 +y )−(x−y )(2x) 2
4. ∂w
∂x = (x 2 +y )2
= −x(x+2xy +y
2 +y )2 ,
(x 2 +y )(−1)−(x−y ) 2
∂w
∂y = (x 2 +y )2
= (x−x2 +y−x)2 ,
∂2w (x +y ) (−2x+2y )−(−x 2 +2xy +y )2(x 2 +y )(2x)
2 2 2(x 3 −3x 2 y −3xy +y 2 )
∂x 2 = 2 2 2 = (x 2 +y )3
,
[(x +y ) ]
2 2 2 −x)2(x 2 +y )·1
∂2w
∂y 2
= (x +y ) ·0−(−x = (x 2x 2 +2x
2 +y )3 ,
[(x 2 +y )2 ]2
2 2 (x 2 +y )2 (2x+1)−(−x 2 +2xy +y )2(x 2 +y )·1 3 2 −2xy −y
∂ w ∂ w
∂y ∂x = ∂x∂y = = 2x +3x
[(x 2 +y )2 ]2 (x 2 +y )3

P. Sam Johnson Partial Derivatives August 30, 2019 66/117


Mixed Partial Derivatives
Exercise 27.
1. Verify that wxy = wyx .
(a) w = e x + x ln y + y ln x
(b) w = x sin y + y sin x + xy
2. Which order of differentiation will calculate fxy faster: x first or y
first? try to answer without writing anything down.
(a) f (x, y ) = x sin y + e y
(b) f (x, y ) = y + x 2 y + 4y 3 − ln(y 2 + 1)
(c) f (x, y ) = x ln xy

P. Sam Johnson Partial Derivatives August 30, 2019 67/117


Solution for Exercise 27
∂w x y ∂w x ∂2w 1 1 ∂2w 1 1
1. (a) ∂x = e + ln y + x , ∂y = y + ln x, ∂y ∂x = y + x , and ∂x∂y = y + x
∂w ∂w
(b) ∂x = sin y + y cos x + y , ∂y = x cos y + sin x + x,
2
∂ w ∂2w
∂y ∂x = cos y + cos x + 1, and ∂x∂y = cos y + cos x + 1
2. (a) x first
(b) x first
(c) y first

P. Sam Johnson Partial Derivatives August 30, 2019 68/117


Exercises
Exercise 28.
The fifth-order partial derivative ∂ 5 f /∂x 2 ∂y 3 is zero for each of the
following functions. To show this as quickly as possible, which variable
would you differentiate with respect to first: x or y ? Try to answer
without writing anything down.
1. f (x, y ) = y 2 + y (sin x − x 4 )
2 /2
2. f (x, y ) = xe y

P. Sam Johnson Partial Derivatives August 30, 2019 69/117


Solution for Exercise 28

1. y first three times


2. x first twice

P. Sam Johnson Partial Derivatives August 30, 2019 70/117


Using the Partial Derivative Definition
Exercise 29.
Use the limit definition of partial derivative to compute the partial
derivatives of the functions at the specified points.
∂f ∂f
1. f (x, y ) = 1 − x + y − 3x 2 y , ∂x and ∂y at (1, 2)
√ ∂f ∂f
2. f (x, y ) = 2x + 3y − 1, ∂x and ∂y at (−2, 3)

P. Sam Johnson Partial Derivatives August 30, 2019 71/117


Solution for Exercise 29
f (1+h,2)−f (1,2) [1−(1+h)+2−6(1+h)2 ]−(2−6)
1. fx (1, 2) = lim h = lim h =
h→0 h→0
2 )+6
lim −h−6(1+2h+h
2
h lim −13h−6h
h = lim (−13 − 6h) = −13,
h→0 h→0 h→0
fy (1, 2) = lim f (1,2+h)−f h
(1,2)
= lim [1−1+(2+h)−3(2+h)]−(2−6)
h =
h→0 h→0
lim (2−6−2h)−(2−6)
h = lim (−2) = −2
h→0 h→0
√ √
f (−2+h,3)−f (−2,3) 2(−2+h)+9−1− −4+9−1
2. fx (−2, 3) = lim h = lim h
√ h→0 √ √ h→0 
2h+4−2 2h+4−2 √2h+4+2 2
= lim h = lim h 2h+4+2
= lim √2h+4+2 = 12 ,
h→0 h→0 h→0
fy (−2, 3) = lim f (−2,3+h)−f h
(−2,3)
=
√ h→0
√ √
−4+3(3+h)−1− −4+9−1 3h+4−2
= lim h = lim h =
h→0
√ √  h→0
3h+4−2 √3h+4+2 3
lim h 3h+4+2
= lim √2h+4+2 = 34
h→0 h→0

P. Sam Johnson Partial Derivatives August 30, 2019 72/117


Exercises
Exercise 30.
1. Let f (x, y ) = 2x + 3y − 4. Find the slope of the line tangent to this
surface at the point (2, −1) and lying in the a. plane x = 2 b. plane
y = −1.
2. Let f (x, y ) = x 2 + y 3 . Find the slope of the line tangent to this
surface at the point (−1, 1) and lying in the a. plane x = −1 b.
plane y = 1.
3. Three variables : Let w = f (x, y , z) be a function of three
independent variables and write the formal definition of the partial
derivative ∂f /∂z at (x0 , y0 , z0 ). Use this definition to find ∂f /∂z at
(1, 2, 3) for f (x, y , z) = x 2 yz 2 .
4. Three variables : Let w = f (x, y , z) be a function of three
independent variables and write the formal definition of the partial
derivative ∂f /∂y at (x0 , y0 , z0 ). Use this definition to find ∂f /∂y at
(−1, 0, 3) for f (x, y , z) = −2xy 2 + yz 2 .
P. Sam Johnson Partial Derivatives August 30, 2019 73/117
Solution for Exercise 30
1. (a) In the plane x = 2 ⇒ fy (x, y ) = 3 ⇒ fy (2, −1) = 3 ⇒ m = 3
(b) In the plane y = −1 ⇒ fx (x, y ) = 2 ⇒ fy (2, −1) = 2 ⇒ m = 2
2. (a) In the plane
x = −1 ⇒ fy (x, y ) = 3y 2 ⇒ fy (−1, 1) = 3(1)2 = 3 ⇒ m = 3
(b) In the plane
y = 1 ⇒ fx (x, y ) = 2x ⇒ fy (−1, 1) = 2(−1) = −2 ⇒ m = −2
f (x0 ,y0 ,z0 +h)−f (x0 ,y0 ,z0 )
3. fz (x0 , y0 , z0 ) = lim h ;
h→0
2
fz (1, 2, 3) = lim f (1,2,3+h)−f
h
(1,2,3)
= lim 2(3+h)h −2(9) =
h→0 h→0
12h+2h2
lim h = lim (12 + 2h) = 12
h→0 h→0
f (x0 ,y0 +h,z0 )−f (x0 ,y0 ,z0 )
4. fy (x0 , y0 , z0 ) = lim h ;
h→0
2
fy (−1, 0, 3) = lim f (−1,h,3)−f h
(−1,0,3)
= lim (2h +5h)−0
h =
h→0 h→0
lim (2h + 9) = 9
h→0

P. Sam Johnson Partial Derivatives August 30, 2019 74/117


Differentiating Implicitly
Exercise 31.
1. Find the value of ∂z/∂x at the point (1, 1, 1) if the equation

xy + z 3 x − 2yz = 0

defines z as a function of the two independent variables x and y and


the partial derivative exists.
2. Find the value of ∂x/∂z at the point (1, −1, −3) if the equation

xz + y ln x − x 2 + 4 = 0

defines x as a function of the two independent variables y and z and


the partial derivative exists.

P. Sam Johnson Partial Derivatives August 30, 2019 75/117


Solution for Exercise 31
∂z ∂z ∂z
1. y + 3z 2 ∂x x + z 3 − 2y ∂x = 0 ⇒ (3xz 2 − 2y ) ∂x = −y − z 3 ⇒ at

∂z ∂z
(1, 1, 1) we have (3 − 2) ∂x = −1 − 1 or ∂x = −2
y  ∂x y
2. ∂x ∂x ∂x

∂z z + x + x ∂z − 2x ∂z = 0 ⇒ (z + x − 2x) ∂z = −x ⇒ at
(1, −1, −3) we have (−3 − 1 − 2) ∂x ∂x
∂z = −1 or ∂z = 6
1

P. Sam Johnson Partial Derivatives August 30, 2019 76/117


Exercises
Exercise 32.
The following exercises are about the triangle shown here.

1. Express A implicitly as a function of a, b, and c and calculate ∂A/∂a


and ∂A/∂b.
2. Express a implicitly as a function of A, b, and B and calculate ∂a/∂A
and ∂a/∂B.

P. Sam Johnson Partial Derivatives August 30, 2019 77/117


Solution for Exercise 32

1. a2 = b 2 + c 2 − 2bc cos A ⇒ 2a = (2bc sin A) ∂A ∂A


∂a ⇒ ∂a =
a
bc sin A ; also
∂A
0 = 2b − 2c cos A + (2bc sin A) ∂b ⇒ 2c cos A − 2b =
(2bc sin A) ∂A ∂A c cos A−b
∂b ⇒ ∂b ⇒= bc sin A
∂a
a b (sin A) ∂A −a cos A ∂a
2. sin A = sin B ⇒ sin A = 0 ⇒ (sin A) ∂x − a cos A = 0⇒
∂a a cos A
∂A = ; also
1
 sin
∂a
A
∂a
sin A ∂B = b(− csc B cot B) ⇒ ∂B = −b csc B cot B sin A

P. Sam Johnson Partial Derivatives August 30, 2019 78/117


Exercises
Exercise 33.
1. Express vx in terms of u and y if the equations x = v ln u and
y = u ln v define u and v as functions of the independent variables x
and y , and if vx exists.
(Hint : Differentiate both equations with respect to x and solve for vx
by eliminating ux .)
2. Two dependent variables: Find ∂x/∂u and ∂y /∂u if the equations
u = x 2 − y 2 and v = x 2 − y define x and y as functions of the
independent variables u and v , and the partial derivatives exist. Then
let s = x 2 + y 2 and find ∂s/∂u.

P. Sam Johnson Partial Derivatives August 30, 2019 79/117


Solution for Exercise 33
1. Differentiating each equation implicitly gives 1 = vx ln u + vu ux and 0 = ux ln v + u
 
v
vx
or v  
1 v
(ln u)vx + ux = 1 u
0 ln v

u

ln v

u ⇒ vx = v = (ln u)(ln v )−1
vx + (ln v )ux = 0
 ln u u
u
v
v
ln v
2. Differentiating each equation implicitly

gives

1 = (2x)xu − (2y )yu and 0 = (2x)xu − yu or
) 1
−2y
(2x)xu − (2y )yu = 1 0

−1

−1 1
⇒ xu = =
(−2x+4xy )
= 2x−4xy and
(2x)xu − yu = 0 2x −2y

2x −1



2x 1

2x 0

−2x
yu = −2x+4xy = −2x+4xy = 2x = 1−2y 1 ∂s
; next s = x 2 + y 2 ⇒ ∂u ∂x
= 2x ∂u + 2y ∂y
    2x−4xy ∂u
1 1 1 2y 1+2y
2x 2x−4xy + 2y 1−2y = 1−2y + 1−2y = 1−2y

P. Sam Johnson Partial Derivatives August 30, 2019 80/117


Exercises
Exercise 34.
(
y 3, y ≥0
1. Let f (x, y ) = 2
−y , y < 0.
Find fx , fy , fxy , and fyx , and state the domain for each partial
derivative. (√
x, x ≥ 0
2. Let f (x, y ) = 2
x , x < 0.
Find fx , fy , fxy , and fyx , and state the domain for each partial
derivative.

P. Sam Johnson Partial Derivatives August 30, 2019 81/117


Solution for Exercise 34
(
0 if y ≥ 0
1. fx (x, y ) = ⇒ fx (x, y ) = 0 for all points (x, y ); at y = 0,
0 if y < 0
f (x,0+h)−f (x,0) f (x,h)−0 f (x,h)
fy (x, 0) = lim h
= lim h
= lim h
= 0 because
h→0 h→0 h→0
f (x,h) h3
lim h
= lim h
= 0 and
h→0− h→0− (
f (x,h) h2 3y 2 ify ≥ 0
lim h
= lim = 0 ⇒ fy (x, y ) = ; fyx (x, y ) = fxy (x, y ) = 0 for all
h→0+ h→0+ h −2y ify < 0
points (x, y ).
f (0+h,y )−f (0,y ) f (h,y )−0 f (h,y )
2. At x = 0, fx (0, y ) = lim h
= lim h
= lim h
which does not exist
h→0 h→0 h→0
f (h,y ) 2
because lim h
= lim hh = 0 and
h→0− h→0− (
√ 1
f (h,y ) √ ifx > 0
lim h
= = lim √1 = +∞ ⇒ fx (x, y ) = 2 x
lim hh ;
h→0+ h→0 + h→0 + h 2x ifx < 0
(
0 ifx ≥ 0
fy (x, y ) = ⇒ fy (x, y ) = 0 for all points (x, y ); fyx (x, y ) = 0 for all points
0 ifx < 0
(x, y ), while fxy (x, y ) = 0 for all points (x, y ) such that x 6= 0.

P. Sam Johnson Partial Derivatives August 30, 2019 82/117


Exercises
Exercise 35.
Show that each function satisfies a Laplace equation.
1. f (x, y , z) = 2z 3 − 3(x 2 + y 2 )z
2. f (x, y ) = tan−1 x
y
3. f (x, y , z) = e 3x+4y cos 5z

P. Sam Johnson Partial Derivatives August 30, 2019 83/117


Solution for Exercise 35
∂f ∂f ∂f 2 2 2 ∂2f
1. ∂x = −6xz, ∂y = −6yz, ∂z = 6z − 3(x + y ), ∂x 2 = −6z,
∂2f ∂2f ∂2f ∂2f ∂2f
∂y 2
= −6z, ∂z 2
= 12z ⇒ ∂x 2 + ∂y 2 + ∂z 2 = −6z − 6z + 12z =0
∂f 1/y y −x/y 2 −x
2. ∂x =  2 = , ∂f
y 2 +x 2 ∂y
=  2 = y 2 +x 2
,
1+ yx 1+ yx
2 2 )·0−y ·2x (y 2 +x 2 )·0−(−x)·2y
∂2f ∂2f
∂x 2
= (y +x(y 2 +x 2 )2
= (y−2xy
2 +x 2 )2 , ∂y 2 = (y 2 +x 2 )2
= (y 22xy
+x 2 )2

∂2f ∂2f −2xy 2xy
∂x 2
+ ∂y 2 = (y 2 +x 2 )2 + (y 2 +x 2 )2 = 0
∂f 3x+4y cos 5z, ∂f = 4e 3x+4y cos 5z, ∂f = −5e 3x+4y sin 5z;
3. ∂x = 3e ∂y ∂z
2
∂ f
= 9e 3x+4y cos 5z, ∂ 2 f = 16e 3x+4y cos 5z,
∂x 2 ∂y 2
∂2f 3x+4y ∂2f ∂2f ∂2f
∂z 2
= −25e cos 5z ⇒ ∂x 2 + ∂y 2 + ∂z 2 =

9e 3x+4y cos 5z + 16e 3x+4y cos 5z − 25e 3x+4y cos 5z = 0

P. Sam Johnson Partial Derivatives August 30, 2019 84/117


Exercises
Exercise 36.
Show that the functions are all solutions of the wave equation

∂2w 2
2∂ w
= c ,
∂t 2 ∂x 2
where w is the wave height, x is the distance variable, t is the time
variable, and c is the velocity with which the waves are propagated.
1. w = cos(2x + 2ct)
2. w = ln(2x + 2ct)
3. w = f (u), where f is a differentiable function of u, and u = a(x + ct), where a is a
constant.
4. Does a function f (x, y ) with continuous first partial derivatives throughout an open region
R have to be continuous on R? Give reasons for your answer.
5. If a function f (x, y ) has continuous second partial derivatives throughout an open region
R, must the first-order partial derivatives of f be continuous on R? Give reasons for your
answer.

P. Sam Johnson Partial Derivatives August 30, 2019 85/117


Solution for (1), (2) and (3) in Exercise 36
∂w ∂w
1. ∂x = −2 sin(2x + 2ct), ∂t = −2c sin(2x + 2ct);
2
∂ w
∂x 2
= −4 cos(2x + 2ct),
∂2w 2 2
∂t 2
= −4c 2 cos(2x + 2ct) ⇒ ∂∂tw2 = c 2 [−4 cos(2x + 2ct)] = c 2 ∂∂xw2
∂w 1 ∂w c ∂2w −1
2. ∂x = x+ct , ∂t = x+ct ; ∂x 2h = (x+ct)2,
i
∂2w −c 2 ∂2w −1 2
∂t 2
= (x+ct)2 ⇒ ∂t 2 = c 2 (x+ct)2 = c 2 ∂∂xw2
∂w ∂f ∂u ∂f ∂2w ∂2f 2 2 ∂2f
3. ∂t = ∂u ∂t = ∂u (ac) ⇒ ∂t 2 =(ac) ∂u
 2 (ac) = a c ∂u 2 ;
∂w ∂f ∂u ∂f ∂2w ∂2f 2 ∂2f ∂2w
∂x = ∂u ∂x = ∂u · a ⇒ ∂x 2 = a ∂u 2 · a = a ∂u 2 ⇒ ∂t 2 =
 
a2 c 2 ∂2f ∂2f
= c 2 a2 ∂u
2
= c 2 ∂∂xw2
∂u 2 2

P. Sam Johnson Partial Derivatives August 30, 2019 86/117


Solution for (4) and (5) in Exercise 36

1. If the first partial derivatives are continuous throughout an open


region R, then by Theorem 3 in this section of the text,
f (x, y ) = f (x0 , y0 ) + fx (x0 , y0 )∆x + fy (x0 , y0 )∆y + 1 ∆x + 2 ∆y ,
where 1 , 2 → 0 as ∆x, ∆y → 0. Then as (x, y ) → (x0 , y0 ), ∆x → 0
and ∆y → 0 ⇒ lim f (x, y ) = f (x0 , y0 ) ⇒ f is continuous at
(x,y )→(x0 ,y0 )
every point (x0 , y0 ) in R.
2. Yes, since fxx , fyy , fxy , and fyx are all continuous on R, use the same
reasoning as in Exercise 76 with
fx (x, y ) = fx (x0 , y0 ) + fxx (x0 , y0 )∆x + fxy (x0 , y0 )∆y + 1 ∆x + 2 ∆y
and
fy (x, y ) = fy (x0 , y0 ) + fyx (x0 , y0 )∆x + fyy (x0 , y0 )∆y + 1 ∆x + 2 ∆y .
Then lim fx (x, y ) = fx (x0 , y0 ) and
(x,y )→(x0 ,y0 )
lim fy (x, y ) = fy (x0 , y0 ).
(x,y )→(x0 ,y0 )

P. Sam Johnson Partial Derivatives August 30, 2019 87/117


The heat equation
Exercise 37.
An important partial differential equation that describes the distribution of
heat in a region at time t can be represented by the one-dimensional heat
equation

∂f ∂2f
= .
∂t ∂x 2
Show that u(x, t) = sin(αx) · e −βt satisfies the heat equation for
constants α and β.

P. Sam Johnson Partial Derivatives August 30, 2019 88/117


Solution for Exercise 37

To find α and β so that ut = uxx ⇒ ut = −β sin(αx)e −βt and


ux = α cos(αx)e −βt ⇒ uxx = −α2 sin(αx)e −βt ; then
ut = uxx ⇒ −β sin(αx)e −βt = −a2 sin(ax)e −βt , thus ut = uxx only if
β = α2

P. Sam Johnson Partial Derivatives August 30, 2019 89/117


Exercises
Exercise 38.
xy 2
(
x 2 +y 4
, (x, y ) 6= (0, 0)
1. Let f (x, y ) =
0, (x, y ) = (0, 0).
Show that fx (0, 0) and fy (0, 0) exist, but f is not differentiable at
(0, 0).
(Hint:Show that f is not continuous at (0, 0).)
(
0, x 2 < y < 2x 2
2. Let f (x, y ) =
1, otherwise.
Show that fx (0, 0) and fy (0, 0) exist, but f is not differentiable at
(0, 0).

P. Sam Johnson Partial Derivatives August 30, 2019 90/117


Solution for Exercise 38
h02 −0
f (0+h,0)−f (0,0) h2 +04 0
1. fx (0, 0) = lim h
= lim h
= lim = 0;
h→0 h→0 h→0 h
0h2 −0
f (0,0+h)−f (0,0) 02 +h4 0
fy (0, 0) = lim h
= lim = h
= lim = 0;
h→0 h→0 h→0 h
2 2 4
(ky )y
lim f (x, y ) = lim 2 2 4 = lim 2 ky4 4 = lim 2
k
= k
k 2 +1
⇒ different limits
(x,y )→(0,0) y →0 (ky ) +y y →0 k y +y y →0 k +1
alongx=ky 2
for different values of k ⇒ lim f (x, y ) does not exist ⇒ f (x, y ) is not continuous at
(x,y )→(0,0)
(0, 0) ⇒ by Theorem 18 (Differentiability Implies Continuity), f (x, y ) is not differentiable
at (0, 0).
f (0+h,0)−f (0,0) f (h,0)−1 1−1
2. fx (0, 0) = lim h
= lim h
= lim h
= 0;
h→0 h→0 h→0
f (0,0+h)−f (0,0) f (0,h)−1
fy (0, 0) = lim h
= lim h
= lim 1−1 = 0;
h→0 h→0 h→0 h
lim f (x, y ) = lim 0 = 0 but lim f (x, y ) = lim 1 = 1 ⇒ lim f (x, y )
(x,y )→(0,0) y →0 (x,y )→(0,0) y →0 (x,y )→(0,0)
alongy =x 2 alongy =1.5x 2
does not exist ⇒ f (x, y ) is not continuous at (0, 0) ⇒ by Theorem 18 (Differentiability
Implies Continuity), f (x, y ) is not differentiable at (0, 0).

P. Sam Johnson Partial Derivatives August 30, 2019 91/117


Extra Notes on Differentiability

An informal definition of differentiability of a function f (x, y ) at a point


(a, b) is that the function f (x, y ) is well-approximated by a linear function
L(x, y ) near (a, b). The function L(x, y ) is called the local linearization
of f (x, y ) near (a, b). We now focus on the precise meaning of the phrase
“well-approximated.”

By looking at examples, we shall see that local linearity requires the


existence of partial derivatives, but they do not tell the whole story.

In particular, existence of partial derivatives at a point is not sufficient to


guarantee local linearity at that point.

P. Sam Johnson Partial Derivatives August 30, 2019 92/117


Extra Notes on Differentiability

As an illustration, take a sheet of paper, crumple it into a ball and smooth


it out again. Wherever there is a crease it would be difficult to approximate
the surface by a plane — these are points of nondifferentiability of the
function giving the height of the paper above the floor. Yet the sheet of
paper models a graph which is continuous — there are no breaks.

As in the case of one-variable calculus, continuity does not imply


differentiability. But differentiability does require continuity: there cannot
be linear approximations to a surface at points where there are abrupt
changes in height.
P. Sam Johnson Partial Derivatives August 30, 2019 93/117
Extra Notes on Differentiability

For a function of two variables, as for a function of one variable, we define


differentiability at a point in terms of the error in a linear
approximation as we move from the point to a nearby point.

If the point is (a,√


b) and a nearby point is (a + h, b + k), the distance
between them is h2 + k 2 .

P. Sam Johnson Partial Derivatives August 30, 2019 94/117


Extra Notes on Differentiability
Definition 39.
A function f (x, y ) is differentiable at the point (a, b) if there is a linear
function L(x, y ) = f (a, b) + m(x − a) + n(y − b) such that if the error
E (x, y ) is defined by

f (x, y ) = L(x, y ) + E (x, y ),


E (a+h,b+k)
and if h = x − a, k = y − b, then the relative error √
h2 +k 2
satisfies

E (a + h, b + k)
lim √ = 0.
(h,k)→(0,0) h2 + k 2
The function f is differentiable if it is differentiable at each point of its
domain. The function L(x, y ) is called the local linearization of f (x, y )
near (a, b).

P. Sam Johnson Partial Derivatives August 30, 2019 95/117


Extra Notes on Differentiability

A function f (x, y ) is differentiable at the point (a, b) if there is a linear


function L(x, y ) = f (a, b) + m(x − a) + n(y − b) such that if the error
E (x, y ) is defined by f (x, y ) = L(x, y ) + E (x, y ), and if
h = x − a, k = y − b, then the relative error E (a+h,b+k)√
h2 +k 2
satisfies
E (a + h, b + k)
lim √ = 0.
(h,k)→(0,0) h2 + k 2

P. Sam Johnson Partial Derivatives August 30, 2019 96/117


Extra Notes on Differentiability

In the next example, we show that this definition of differentiability is


consistent with our previous notion — that is, that m = fx and n = fy and
that the graph of L(x, y ) is the tangent plane.

Theorem 40.
Show that if f is a differentiable function with local linearization

L(x, y ) = f (a, b) + m(x − a) + n(y − b),

then m = fx (a, b) and n = fy (a, b).

Proof : Since f is differentiable, we know that the relative error in L(x, y )


tends to 0 as we get close to (a, b).

P. Sam Johnson Partial Derivatives August 30, 2019 97/117


Solution (contd...)

Suppose h > 0 and k = 0. Then we know that

E (a + h, b) E (a + h, b)
0 = lim √ = lim
h→0 h2 + k 2 h→0 h
f (a + h, b) − L(a + h, b)
= lim
h→0 h
f (a + h, b) − f (a, b) − mh
= lim
h→0 h
 f (a + h, b) − f (a, b) 
= lim −m
h→0 h
= fx (a, b) − m.

A similar result holds if h < 0, so we have m = fx (a, b). The result


n = fy (a, b) is found in a similar manner.

P. Sam Johnson Partial Derivatives August 30, 2019 98/117


Extra Notes on Differentiability

The previous result says that if a function is differentiable at a point, it


has partial derivatives there.

Therefore, if any of the partial derivatives fail to exist, then the function
cannot be differentiable.

This is what happens in the following example of a cone.


Example 41.
Consider the function p
f (x, y ) = x 2 + y 2.
Is f differentiable at the origin?

P. Sam Johnson Partial Derivatives August 30, 2019 99/117


Extra Notes on Differentiability
p
The function f (x, y ) = x 2 + y 2 is not locally linear at (0, 0).

Zooming in around (0, 0) does not make the graph look like a plane.

p
If we zoom in on the graph of the function f (x, y ) = x 2 + y 2 at the
origin, as shown in the figure, the sharp point remains; the graph never
flattens out to look like a plane. Near its vertex, the graph does not look
like it is well approximated (in any reasonable sense) by any plane.

P. Sam Johnson Partial Derivatives August 30, 2019 100/117


Solution

Judging from the graph of f , we would not expect f to be differentiable at


(0, 0). Let us check this by trying to compute the partial derivatives of f
at (0, 0):

f (h, 0) − f (0, 0) h2 + 0 − 0 |h|
fx (0, 0) = lim = lim = lim .
h→0 h h→0 h h→0 h

Since |h|/h = ±1, depending on whether h approaches 0 from the left or


right, this limit does not exist and so neither does the partial derivative
fx (0, 0).

Thus, f cannot be differentiable at the origin. If it were, both of the


partial derivatives, fx (0, 0) and fy (0, 0), would exist.

P. Sam Johnson Partial Derivatives August 30, 2019 101/117


Alternate Solution

Alternatively, we could show directly that there is no linear approximation


near (0, 0) that satisfies the small relative error criterion for differentiability.

Any plane passing through the point (0, 0, 0) has the form

L(x, y ) = mx + ny

for some constants m and n.

If E (x, y ) = f (x, y ) − L(x, y ), then


p
E (x, y ) = x 2 + y 2 − mx − ny .

Then for f to be differentiable at the origin, we would need to show that



h2 + k 2 − mh − nk
lim √ = 0.
(h,k)→(0,0) h2 + k 2

P. Sam Johnson Partial Derivatives August 30, 2019 102/117


Alternate Solution (contd...)

Taking k = 0 gives

|h| − mh h
lim = 1 − m lim .
h→0 |h| h→0 |h|

This limit exists only if m = 0 for the same reason as before. But then the
value of the limit is 1 and not 0 as required. Thus, we again conclude f is
not differentiable.

In the above example the partial derivatives fx and fy did not exist at the
origin and this was sufficient to establish nondifferentiability there. We
might expect that if both partial derivatives do exist, then f is
differentiable. But the next example shows that this not necessarily true:
the existence of both partial derivatives at a point is not sufficient to
guarantee differentiability.

P. Sam Johnson Partial Derivatives August 30, 2019 103/117


Example
Example 42.
Consider the function
f (x, y ) = x 1/3 y 1/3 .
Show that the partial derivatives fx (0, 0) and fy (0, 0) exist, but that f is
not differentiable at (0, 0).

P. Sam Johnson Partial Derivatives August 30, 2019 104/117


Solution

We have f (0, 0) = 0 and we compute the partial derivatives using the


definition:
f (h, 0) − f (0, 0)
lim fx (0, 0) = lim = lim 0 − 0 = 0,
h→0 h→0 h h→0

and similarly
fy (0, 0) = 0.
So, if there did exist a linear approximation near the origin, it would have
to be L(x, y ) = 0. But we can show that this choice of L(x, y ) does not
result in the small relative error that is required for differentiability.

In fact, since E (x, y ) = f (x, y ) − L(x, y ) = f (x, y ), we need to look at the


limit
h1/3 k 1/3
lim √ .
(h,k)→(0,0) h2 + k 2

P. Sam Johnson Partial Derivatives August 30, 2019 105/117


Solution (contd...)

If this limit exists, we get the same value no matter how h and k approach
0. Suppose we take k = h > 0. Then the limit becomes

h1/3 h1/3 h2/3 1


lim √ = lim √ = lim √ .
h→0 h2 + k 2 h→0 h 2 h→0 h1/3 2
But this limit does not exist, since small values for h will make the fraction
arbitrarily large. So the only possible candidate for a linear approximation
at the origin does not have a sufficiently small relative error.

Thus, this function is not differentiable at the origin, even though the
partial derivatives fx (0, 0) and fy (0, 0) exist. The figure confirms that near
the origin the graph of z = f (x, y ) is not well approximated by any plane.

In the above example, the function f was continuous at the point


where it was not differentiable.

P. Sam Johnson Partial Derivatives August 30, 2019 106/117


Summary

If a function is differentiable at a point, then both partial derivatives


exist there.
Having both partial derivatives at a point does not guarantee that a
function is differentiable there.

P. Sam Johnson Partial Derivatives August 30, 2019 107/117


Continuity and Differentiability

We know that differentiable functions of one variable are continuous.


Similarly, it can be shown that if a function of two variables is
differentiable at a point, then the function is continuous there. The
following example shows that even if the partial derivatives of a function
exist at a point, the function is not necessarily continuous at that point if
it is not differentiable there.
Example 43.
Suppose that f is the function of two variables defined by
(
xy
2 2, (x, y ) 6= (0, 0)
f (x, y ) = x +y
0, (x, y ) = (0, 0).

One can show that f (x, y ) is not continuous at the origin. Show that the
partial derivatives fx (0, 0) and fy (0, 0) exist. Could f be differentiable at
(0, 0)?

P. Sam Johnson Partial Derivatives August 30, 2019 108/117


Solution

From the definition of the partial derivative we see that

f (h, 0) − f (0, 0) 1 0  0
fx (0, 0) = lim = lim . 2 2
= lim = 0,
h→0 h h→0 h h + 0 h→0 h

and similarly fy (0, 0) = 0.

So, the partial derivatives fx (0, 0) and fy (0, 0) exist.

However, f cannot be differentiable at the origin since it is not continuous


there.

P. Sam Johnson Partial Derivatives August 30, 2019 109/117


Summary

If a function is differentiable at a point, then it is continuous there.


Having both partial derivatives at a point does not guarantee that a
function is continuous there.

P. Sam Johnson Partial Derivatives August 30, 2019 110/117


How Do We Know If a Function Is Differentiable?

Question : Can we use partial derivatives to tell us if a function is


differentiable?

As we have seen from the last two examples, it is not enough that the
partial derivatives exist.

However, the following condition does guarantee differentiability:

Theorem 44 (Condition for Differentiability).


If the partial derivatives, fx and fy , of a function f exist and are
continuous on a small disk centered at the point (a, b), then f is
differentiable at (a, b).

P. Sam Johnson Partial Derivatives August 30, 2019 111/117


Condition for Differentiability

We will not prove this fact, although it provides a criterion for


differentiability which is often simpler to use than the definition.

It turns out that the requirement of continuous partial derivatives is more


stringent than that of differentiability, so there exist differentiable
functions which do not have continuous partial derivatives.

However, most functions we encounter will have continuous partial


derivatives.

The class of functions with continuous partial derivatives is given the name
C 1.

P. Sam Johnson Partial Derivatives August 30, 2019 112/117


Example
Example 45.
Show that the function f (x, y ) = ln(x 2 + y 2 ) is differentiable everywhere
in its domain.

Solution : The domain of f is all of 2-space except for the origin. We


shall show that f has continuous partial derivatives everywhere in its
domain (that is, the function f is in C 1 ). The partial derivatives are

2x 2y
fx = and fy = .
x2 + y2 x2 + y2
Since each of fx and fy is the quotient of continuous functions, the partial
derivatives are continuous everywhere except the origin (where the
denominators are zero). Thus, f is differentiable everywhere in its domain.

P. Sam Johnson Partial Derivatives August 30, 2019 113/117


The three-dimensional Laplace equation
Exercise 46.
∂ f ∂ f ∂ f2 2 2
The three-dimensional Laplace equation ∂x 2 + ∂y 2 + ∂z 2 = 0 is

satisfied by steady-state temperature distributions T = f (x, y , z) in space,


by gravitational potentials, and by electrostatic potentials. The
∂2f ∂2f
two-dimensional Laplace equation ∂x 2 + ∂y 2 = 0, obtained by dropping

the ∂ 2 f /∂z 2 term from the previous equation, describes potentials and
steady-state temperature distributions in a plane (see the accompanying
figure). The plane (a) may be treated as a thin slice of the solid (b)
perpendicular to the z-axis.
∂2f ∂2f
(a). ∂x 2 + ∂y 2 = 0
∂2f ∂2f ∂2f
(b). ∂x 2
+ ∂y 2
+ ∂z 2
=0

P. Sam Johnson Partial Derivatives August 30, 2019 114/117


The Wave Equation
Exercise 47.
If we stand on an ocean shore and take a snapshot of the waves, the
picture shows a regular pattern of peaks and valleys in an instant of time.
We see periodic vertical motion in space, with respect to distance. If we
stand in the water, we can feel the rise and fall of the water as the waves
go by. We see periodic vertical motion in time. In physics, this beautiful
symmetry is expressed by the one-dimensional wave equation

∂2w 2
2∂ w
= c ,
∂t 2 ∂x 2
where w is the wave height, x is the distance variable, t is the time
variable, and c is the velocity with which the waves are propagated.
In our example, x is the distance across the ocean’s surface, but in other
applications, x might be the distance along a vibrating string, distance
through air (sound waves), or distance through space (light waves). The
number c varies with the medium and type of wave.
P. Sam Johnson Partial Derivatives August 30, 2019 115/117
Summary

Most functions built up from elementary functions have continuous partial


derivatives, except perhaps at a few obvious points.

Thus, in practice, we can often identify functions as being C 1 without


explicitly computing the partial derivatives.

P. Sam Johnson Partial Derivatives August 30, 2019 116/117


References

1. M.D. Weir, J. Hass and F.R. Giordano, Thomas’ Calculus, 11th


Edition, Pearson Publishers.
2. N. Piskunov, Differential and Integral Calculus, Vol I & II (Translated
by George Yankovsky).
3. S.C. Malik and Savitha Arora, Mathematical Analysis, New Age
Publishers.
4. R. G. Bartle, D. R. Sherbert, Introduction to Real Analysis, Wiley
Publishers.

P. Sam Johnson Partial Derivatives August 30, 2019 117/117

You might also like