0% found this document useful (0 votes)
5 views56 pages

Functions of Several Variables

The document discusses functions of several variables, explaining their representations, domains, ranges, and graphical interpretations in multi-dimensional space. It covers concepts such as evaluating functions, limits, continuity, and the use of level curves and surfaces for visualization. Additionally, it provides examples and definitions related to interior and boundary points, as well as the conditions under which limits exist or do not exist.

Uploaded by

mlagazaabd
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views56 pages

Functions of Several Variables

The document discusses functions of several variables, explaining their representations, domains, ranges, and graphical interpretations in multi-dimensional space. It covers concepts such as evaluating functions, limits, continuity, and the use of level curves and surfaces for visualization. Additionally, it provides examples and definitions related to interior and boundary points, as well as the conditions under which limits exist or do not exist.

Uploaded by

mlagazaabd
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 56

SEVERAL VARIABLES

CALCULUS FOR
NON-MAJORS

Presented by Dr Mureithi
Functions of Several Variables

A function of one variable can be represented


as y = f (x) where y is the dependent variable
and x the independent variables. The graph of
this function is a line or curve on a plane. We
extend this idea to a function of two or more
independent variables.

A function of two variables is represented as


z = f (x, y). Graphically z = f (x, y) represents
a surface in a 3-dimensional space.

A function z = f (x, y) of two variables x and


y is a rule that assigns to each ordered pair
(x, y) in a given set D ∈ R2 (called the domain),
unique value of z.

Examples: f (x, y) = xy 2, g(x, y) = y 2 − ex etc.

Similarly, a function of three variables is a rule


that assigns a real number f (x, y, z) to each
ordered triple of real numbers (x, y, z) in the
domain D ∈ R3 of the function.
Examples: f (x, y, z) = x2 +y 2 +z 2 −2, g(x, y) =
xyez etc.

In general a function of n variables is a rule that


assigns a real unique number w = f (x1, x2, · · · , xn)
to each n-tuple of real numbers (x1, x2, · · · , xn)
in the domain D ∈ Rn of the function.

Example: h(x1, x2, x3, x4) = ex1 − x2 + 4x3 + x4


is a function of 4 variables.

The set of w-values taken on by f is the func-


tion’s range. Here f is a function of n inde-
pendent variables xi, i = 1, 2, · · · , n and w is
the dependent variable.

Evaluating a function:
q
The value of f (x, y) = 9 − x2 − y 2 at the
√ √
point (1, 1) is f (1, 1) = 9 − 1 − 1 = 7.

Domains, ranges and graphs

In defining domains for functions of more that


one variables, we follow the usual practice of
excluding any inputs xi that lead to complex
numbers or division by zero.
q
For example if f (x, y) = y − x2, the domain
is defined such that y − x2 ≥ 0 or y ≥ x2. With
this domain, the range is f > 0.

If f (x, y) = 1/(xy) then xy 6= 0. The domain


is x, y ∈ R except x 6= 0 and y 6= 0. i.e the x−
and y- axis are excluded. The range all real
value except f 6= 0.
Examples: Find the domain and the range for
the following:

1. g(x, y) = 3x 2 .
y−x
Solution: g is defined except on y = x2.
Hence the domain of g is {(x, y)|y 6= x2}.
i.e. the entire plane with the parabola y =
x2 removed.
Range: g ∈ R.

2. h(x, y) = x ln y.
Domain: h is defined if y > 0. Hence the
domain is {(x, y)|y > 0}, i.e. the upper
half-plane.
Range: all real numbers: h ∈ R.

q
3. f (x, y, z) = 9 − x2 − y 2 − z 2.
Domain: 9−x2 −y 2 −z 2 ≥ 0 or x2 +y 2 +z 2 ≤
9. i.e. the sphere of radius 3 centred at
the origin and its interior. Range: [0, 3].

Definition: The graph of a function of two vari-


ables is the set of (x, y, z) for which z = f (x, y)
and (x, y) is the domain of f . Geometrically a
graph is a surface in 3-dimensional space.
q
Consider the function f (x, y) = 25 − x2 − y 2.
Find the domain and the range of f . Describe
the graph of f .

The domain is 25−x2 −y 2 ≥ 0, i.e. x2 +y 2 ≤ 25


in the circle of radius 5 and its interior.


Range: All values such that 0 ≤ z ≤ 25.

Graph:
q The set of points x, y, z such that z =
25 − x2 − y 2.
Squaring both sides: z 2 = 25 − x2 − y 2 or x2 +
y 2 + z 2 = 25 which is the graph of a sphere of
radius 5 centred at (0, 0, 0).

To sketch the graph by hand it helps to use


traces in planes parallel to the coordinates planes.
For q
example: Find the traces of the surface
z = 25 − x2 − y 2 in the planes z = 0, x = 0,
y=0
1. The trace in xy-plane: z = 0:
x2 + y 2 = 25, a circle of radius 5 in the
x, y-plane.

2. The qtrace in yz-plane: x = 0:


z = 25 − y 2 or y 2 + z 2 = 25, a circle of
radius 5 in the yz-plane.

3. The qtrace in xz-plane: y = 0:


z = 25 − x2 or x2 + z 2 = 25, a circle of
radius 5 in the xz-plane.

Level curves and contours

A second way to visualize a function of two


variables is to use level curves or contour lines
along which f (x, y) is a constant.
q
1. Consider the hemisphere f (x, y) = 25 − x2 − y 2.

q
The level curves are where z = 25 − x2 − y 2 =
c.
Level curve for z = c = 0: x2 + y 2 = 25, a
circle of radius 5

Level curve: z = c = 4: x2 + y 2 = 9, a circle


of radius 3 centred at (0, 0, 4).

The level curves are x2 + y 2 = c are concentric


circles in the xy-plane.

2. Consider surface z = y 2 − x2. Sketch the


contour map for the surface.

The level curves are given as y 2 − x2 = c.For


each value of c we have a hyperbola:
In a weather map level curves represent points
of equal temperature (isotherms).

Level curves representing points with equal elec-


tric potentials are called equipotential lines.

The graph of w = f (x, y, z) is the set of all


points (x, y, z, w) for which the ordered triple
(x, y, z) is in the domain. The graph of w =
f (x, y, z) is in 4 dimensions.

Note: We cannot draw a graph of any function


with 3 or more independent variables.

Level surfaces:
The set of points (x, y, z) in space where the
function f (x, y, z) = c, has a constant value, is
called a level surface of f .

Example: Describe q the level surfaces of the


function f (x, y, z) = x2 + y 2 + z 2

The
q level surfaces are f (x, y, z) = c:
x2 + y 2 + z 2 = c > 0. These are hemispheres
centred about the origin of radius c.
Interior and boundary points

Using the formula for the distance between two


points (x, y) and (a, b) we can define the δ-
neighbourhood to be the disc centred at (a, b)
with radius δ > 0
 q 
(x, y) : (x − a)2 + (y − b)2 < δ

This represents an open disc while (’less’))


q
{(x, y) : (x − a)2 + (y − b)2 ≤ δ}
represents a closed disk (less than or equal
to).

Definition: A point (a, b) in a region R in the


xy-plane is an interior point of R if there is δ-
neighbourhood about (a, b) that lies entirely in
R. If every point of R is an interior point then
R is open. A point (a, b) is called a boundary
point of R if every δ-neighbourhood centred at
(a, b) contains points in R and points outside R.
A region is closed if it contains all its boundary
points.

Example: x2 + y 2 < 1 is the interior of circle


(open); x2 + y 2 = 1 is a boundary of a unit
disk/circle; x2 + y 2 ≤ 1 is a closed disk as it
contains all the boundary points.

Limits and continuity

Definition:We say that a function f (x, y) ap-


proaches the limit L as (x, y) approaches (x0, y0)
and write

lim f (x, y) = L
(x,y)→(x0 ,y0 )
if for every ǫ > 0, there exists a corresponding
number δ > 0 such that for all (x, y) in the
domain of f ,

|f (x, y) − L| < ǫ
q
whenever 0< (x − x0)2 + (y − y0)2 < δ
i.e. the distance between f (x, y) and L be-
comes arbitrarily small whenever the distance
from (x, y) to (x0, y0) is made sufficiently small.

For a function of a single variable if the left


and the right limit are equal then the limit is
said to exist. For a function of two variables
the statement (x, y) → (x0, y0) means that the
point (x, y) is allowed to approach (x0, y0) from
any direction along any path. If the value of

lim f (x, y)
(x,y)→(x0 ,y0 )
for all possible paths to (x0, y0) is the same,
then the limit exists.

The limit combination theorem

If

lim f (x, y) = L1 and


(x,y)→(x0 ,y0)

lim g(x, y) = L2
(x,y)→(x0 ,y0)

Then

(i)

lim [f (x, y) ± g(x, y)] = L1 ± L2


(x,y)→(x0 ,y0 )

(ii)

lim [f (x, y)g(x, y)] = L1L2


(x,y)→(x0 ,y0 )
(iii)
lim [kf (x, y)] = kL1
(x,y)→(x0 ,y0)

(iv)
" #
f (x, y) L
lim = 1
(x,y)→(x0 ,y0 ) g(x, y) L2

Examples:
Evaluate the limits, if they exist:

(a)
3x2 + 2xy
lim
(x,y)→(1,1) 5xy + 3
This is the limit of a rational function. Since
the limit of the denominator is non-zero we
have
3x2 + 2xy 3(1) + 2(1)(1) 5
lim = =
(x,y)→(1,1) 5xy + 3 5(1)(1) + 3 8
by direct substitution.

(b)
q q
lim x2 + y 2 = 32 + (−4)2 = 5
(x,y)→(3,−4)
Obtained by direct substitution.

(c)
x2 − xy
lim √ √
(x,y)→(0,0) x − y
Since the denominator approaches zero we
rationalize it by multiplying top and bot-
√ √
tom by x + y to get
√ √
x(x − y)( x + y)
lim √ √ √ √
(x,y)→(0,0) ( x − y)( x + y)
√ √
x(x − y)( x + y)
= lim
(x,y)→(0,0) x−y
√ √
= lim (x( x + y) = 0
(x,y)→(0,0)

Note: We can cancel the factor x − y since the


path y = x is not in the domain of the original
2 −xy
function √xx− √
y

For some functions its easy to see that the


limit does not exist e.g
1
lim
(x,y)→(0,0) x2 + y 2
as the function increases without bound as
(x, y) approaches (0, 0).

In some cases it may not be so obvious that


the limit does not exist.

Two path test for non-existence of a limit

If a function f (x, y) has different limits along


two different paths as (x, y) approaches (x0, y0),
then lim(x,y)→(x0,y0) f (x, y) does not exist.

Example:
Find the following limits, if they exist.

(a)
x
lim .
(x,y)→(0,1) y + x − 1
The function x/(y + x − 1) is defined ∀(x, y)
except along y = 1 − x. The point (0, 1)
lies on this line.

We consider the limit along the line x = 0.


0 0
lim = lim = 0.
(0,y)→(0,1) y − 1 y→1 y−1
Next consider the limit along y = 1:
x
lim = 1.
(x,1)→(0,1) 1 + x − 1
Hence the limit does not exist.

(b)
xy
lim
(x,y)→(0,0) x2 + y 2
The function is defined ∀(x, y) except at
(0, 0).

Take the limit as (x, y) → (0, 0) through


y = mx and y = mx2 (they all pass through
(0, 0).)
x(mx) m
lim f (x, y) = lim 2 2 2
=
(x,y)→(0,0) x→0 x +m x 1 + m2
Since the limit depends on values of m, it
is not unique.

For the path y = mx2 we have


x(mx2)
lim f (x, y) = lim 2
(x,y)→(0,0) x→0 x + m2 x4
mx
= 2 2
=0
1+m x
Therefore the limit does not exist.
(c)
x2 y
lim
(x,y)→(0,0) x2 + y 2

Taking limit along x = 0:


0
lim 2
=0
(x,y)→(0,0) 0 + y
Taking limit along y = 0:
0
lim 2
=0
(x,y)→(0,0) x + 0
Take limit along y = mx which passes through
(0, 0):
mx3 mx
lim 2 2
= lim 2
=0
(x,y)→(0,0) x (1 + m ) x→0 (1 + m )
Therefore the limit exists and it is zero.
Continuity of a function
of two variables

Definition: A function f (x, y) is said to be


continuous at the point (x0, y0) if

1. f is defined at (x0, y0)

2. lim(x,y)→(x0 ,y0) f (x, y) exists.

3. lim(x,y)→(x0 ,y0) f (x, y) = f (x0, y0)

A function is continuous if it is continuous at


every point of its domain.

Example:

(a) The function f (x, y) = x2 −y 2 is continuous


in R2. Its said to be a continuous functions.

(b)
x2 y
The function f (x, y) = 2
x + y2
is not continuous at (0, 0) since f (0, 0) is
not defined, though its limit does exist.
Thus the discontinuity is said to be remov-
able by defining the function to be the limit
i.e. f (0, 0) = 0.

(c) The function


xy
f (x, y) = 2
x + y2
does not have a limit at (0, 0). The func-
tion is not continuous at (0, 0).

(d) Determine whether f below is continuous


at (0, 0)

3x2 y


 x2+y 2
 if (x, y) 6= (0, 0)
f (x, y) =



0 if (x, y) = (0, 0)
Solution

(i) f (0, 0) = 0 is defined.

3x2 y
(ii) lim(x,y)→(0,0) 2 2 = 0.
x +y
(iii) lim(x,y)→(0,0) f (x, y) = f (0, 0)

Thus f is continuous at (0, 0).

Partial Derivatives

Here we generalize the notion of derivative to


functions of more that one variable.
Recall: For a function of one variable:
′ f (x + h) − f (x)
f (x) = lim
h→0 h
for any value of x for which the limit exists.
At any particular value of x = x0, f ′(x0) is
interpreted as the instantaneous rate of change
of f at that point.

Definition:The first partial derivative of f (x, y)


with respect to x is defined by
∂f f (x + ∆x, y) − f (x, y)
= lim ,
∂x ∆x→0 ∆x
for any values of x and y for which the limit
exists.
The first partial derivative of f (x, y) with re-
spect to y is defined by
∂f f (x, y + ∆y) − f (x, y)
= lim ,
∂y ∆y→0 ∆y
for any values of x and y for which the limit
exists.

The partial derivative ∂f


∂x (x0, y0) defined as

∂f f (x0 + ∆x, y0) − f (x0, y0)


= lim ,
∂x (x0,y0) ∆x→0 ∆x
gives the instantaneous rate of change of f
with respect to x at the point (x0, y0). Simi-
larly the partial derivative ∂f
∂y (x0, y0)

∂f f (x0, y0 + ∆y) − f (x0, y0)


= lim ,
∂y (x0 ,y0) ∆y→0 ∆y
gives the instantaneous rate of change of f
with respect to y at the point (x0, y0). Geo-
metrically these rates of change represent the
slopes of the surface z = f (x, y) at (x0, y0) in
the x or y direction.

Remark: In computing the partial derivative


partially with respect to x the value of y is held
as a constant and similarly the partial deriva-
tive with respect to y involves holding x as a
constant.

Notation: For convenience we use the nota-


tion ∂f /∂x = fx, ∂f /∂y = fy .

Examples

(i) For f (x, y) = 3x2 + x3y + y 2 compute fx,


fy , fx(1, 0) and fy (2, 1). Find the slope of
the surface at (1, 1) in the x-direction.

(ii) f (x, y) = exy + xy . Compute fx and fy .

(iii) Find ∂f /∂y if f (x, y) = y sin xy.

(iv) Find the rate of change of the function


A = ab with respect to a when a = 10 and
b = 20.

Solution
(i) fx = 6x + 3x2y, fy = x3 + 2y,
fx(1, 0) = 6, fy (2, 1) = 10.
Slope: fx(1, 1) = 9

(ii) f (x, y) = exy + x/y,


fx = yexy + 1/y, fy = xexy − x/y 2.

(iii) f (x, y) = y sin xy, fy = sin xy + yx cos xy.

(iv) A = ab, ∂A/∂a = b, Aa(10, 20) = 20.

First partial derivatives for functions of more


variables can be found in a similar manner. For
example the first partial derivations of f (x, y, z) =
xy + xz 2 + ez y are:

fx = y + z 2, fy = x + ez and fz = 2xz + ez y.

Higher order partial derivatives


The Second order partial derivatives are ob-
tained from the first order partial derivatives.
The four second order partials are denoted as
∂ ∂f ∂ 2f
 
= 2
abbreviated as fxx
∂x ∂x! ∂x
∂ ∂f ∂ 2f
= 2
= fyy
∂y ∂y ∂y
∂ ∂f ∂ 2f
 
= = fxy
∂y ∂x ∂y∂x
∂ 2f
!
∂ ∂f
= = fyx
∂x ∂y ∂x∂y

Examples: Compute all the second-order par-


tial derivatives of f (x, y) = x sin y + yex

fx = sin y + yex and fy = x cos y + ex. Hence


fxx = yex, fxy = cos y + ex,

fyx = cos y + ex, fyy = −x sin y.

Note: fyx = fxy = cos y + ex

Clairaut’s theorem: Mixed derivatives


If fxy (x, y) and fyx (x, y) are continuous on an
open set containing (a, b) then
fxy (a, b) = fyx(a, b)

Using the second order partials we can com-


pute third order partials. This can be contin-
ued to get fourth and even higher order partial
derivatives.
∂ 3f ∂ 2f
!

= = fyyx etc
∂x∂y 2 ∂x ∂y 2
Example: Given f (x, y) = cos(xy) compute:
(a) fxyy , (b) fxyyy

Solution: Show that

(a) fxyy = −2x cos(xy) + yx2 sin(xy).

(b) fxyyy = 3x2 sin(xy) + x3y cos(xy)

Note: By Clairaut’s theorem

fxyy = fyyx = fyxy


fxyyy = fyxyy = fyyxy = fyyyx .
Increments and differentials

Recall: For a function of a single variable y =


f (x) if the increment of x is ∆x, the increment
of y is
∆y = f (x + ∆x) − f (x)
and hence using the definition of a derivative:
dy f (x + ∆x) − f (x)
= lim = f ′(x)
dx ∆x→0 ∆x
the differential of y is becomes

dy = f ′(x)dx.
We extend this definition to a function of two
variables z = f (x, y).

Let ∆x and ∆y be the increments of x and y.


The increment of z is

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


Definition: If z = f (x, y) and ∆x and ∆y are
the increments of x and y, then differentials of
the independent variables x and y are
dx = ∆x and dy = ∆y and the total differen-
tial of the dependent variable z is
∂f ∂f
dz = dx + dy
∂x ∂y
This definition can be extended to functions
of more variables. For example for a function
of three variables w = f (x, y, z)
∂w ∂w ∂w
dw = dx + dy + dz
∂x ∂y ∂z

Example 1

(a) Find the total differential of z = x ln y −


3x2y

Solution: zx = ln y − 6xy, zy = x/y − x2.


Total differential: dz = zxdx + zy dy.
!
x
dz = (ln y − 6xy)dx + − 3x2 dy
y
q
(b) Find the total differential of w = 4 − x2 − y 2 − z 2 :

Solution: dw = wxdx + wy dy + wz dz where


x x
wx = − q =−
4 − x2 − y 2 − z 2 w

Similarily wy = (−y/w) and wz = (−z/w).


Thus
∂w ∂w ∂w
dw = dx + dy + dz
∂x ∂y ∂z
x y z
= − dx − dy − dz
w w w
x dx + y dy + z dz
= −
w

Exercise

A cylinder of radius r and height h has volume


V = πr2h. Find the differential of V .
∂V ∂V
dV = dr + dh
∂r ∂h
Differentiability

Definition: A function z = f (x, y) is differen-


tiable at (a, b) if ∆z can be expressed in the
form

∆z = fx(a, b)∆x + fy (a, b)∆y + ǫ1∆x + ǫ2∆y


where both ǫ1 and ǫ2 tend to zero as
(∆x, ∆y) → (0, 0). A function f is differen-
tiable in a region R if its differentiable at each
point of R.

Example 2

Show that the function z = x2 + 2xy is differ-


ential at every point in the plane.

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


= (x + ∆x)2 + 2(x + ∆x)(y + ∆y) − (x2 + 2xy)
= 2x∆x + (∆x)2 + 2x∆y + 2y∆x + 2∆x∆y
= (2x + 2y)∆x + 2x∆y + (∆x)∆x + (2∆x)∆y
= fx(x, y)∆x + fy (x, y)∆y + ǫ1∆x + ǫ2∆y
Since (ǫ1, ǫ2) = (∆x, 2∆x) → 0 as (∆x, ∆y) →
(0, 0), f is differentiable at every point in the
xy-plane.
Theorem: Sufficient condition for differ-
entiability:
If z = f (x, y) where fx and fy are continuous
in an open region R then f is differentiable on
R.

Chain rule

You are familiar with the chain rule for func-


tions of a single variable. If, in general, f =
f (g(x)) then chain rule for differentiation of f
is
d
(f (g(x)) = f ′(g(x)) g ′(x)
dx
For example the derivative of y = sin(ex) is
y ′ = ex cos(ex).

We extend the chain rule concept to functions


of several variables.

Theorem: Chain rule


If z = f (x(t), y(t)), where x(t) and y(t) are dif-
ferentiable and f (x, y) is a differentiable func-
tion. Then
!
dz d ∂f dx ∂f dy
= f (x(t), y(t)) = +
dt dt ∂x dt ∂y dt
z
zx zy
For convenience x y
we use a tree diagram
x′ y′
t t

Example:

z = f (x, y) = x2ey , x(t) = t2 − 1, y(t) = sin t.


Let g(t) = f (x(t), y(t)). Find g ′(t).

Solution
′ dz ∂f dx ∂f dy
g (t) = = +
dt ∂x dt ∂y dt
= 2xey (2t) + x2ey sin t

Substitute for x and y to get

g ′(t) = 4t(t2 − 1)esin t + (t2 − 1)2esin t

Example:
The base radius r of the right circular cone
is increasing at the rate of 2mm/s while the
perpendicular height is decreasing at 6.0mm/s.
Determine the rate at which the volume V is
changing when r = 12mm and h = 24mm.

Solution: The volume of the cylinder is


1 2
V = πr h, r = r(t), h = h(t), r′ = 2, h′ = −6
3
Chain rule:
dV ∂V ∂r ∂V ∂h
= +
dt ∂r ∂t ∂h ∂t
2πrh dr πr2 dh
= +
3 dt 3 dt
2π(12)(24) π(122)
= (2) + (−6) = 96π
3 3

Theorem: Chain rule


If z = f (x, y), where f is a differentiable func-
tion of x and y and x = x(s, t) and y = y(s, t)
both first order partial derivatives. Then we
have the chain rules:
∂z ∂z ∂x ∂z ∂y
= +
∂s ∂x ∂s ∂y ∂s
∂z ∂z ∂x ∂z ∂y
= +
∂t ∂x ∂t ∂y ∂t
The chain rule is illustrated in the tree diagram
below.

w
wx wy
x y
xs xt ys yt
s t s t

Examples:

(a) z = exy , x(u, v) = 3u sin v, y(u, v) = 4v 2u.


Find zu and zv .

(b) z = f (x, y) where x = r2 + s2, y = 2rs.


Find zr and zrr .

(c) z = f (x, y), x(r, θ) = r cos θ,


y(r, θ) = r sin θ. Show that

fr = fx cos θ + fy sin θ
frr = fxx cos2 θ + 2fxy sin θ cos θ + fyy sin2 θ
(d) Show that
1 1
fxx + fyy = frr + fr + 2 fθθ .
r r
i.e. the Laplacian in polar coordinates.

Definition: Chain rule (General case)


Suppose u is a differentiable function of n vari-
ables x1, x2, · · · , xn ad each xi is a differen-
tiable function of m variables t1, t2, · · · , tm, the
u = u(t1, t2, · · · , tm) and
∂u ∂u ∂x1 ∂u ∂x2 ∂u ∂xn
= + + ··· +
∂ti ∂x1 ∂ti ∂x2 ∂ti ∂xn ∂ti
for i = 1, 2, · · · , m.

Implicit partial differentiation

Suppose x and y are related by the equation


F (x, y) = 0, where y = y(x). Then

w(x) = F (x, y(x))


Differentiate with respect to x:
dw dx dy
= Fx(x, y) + Fy (x, y) =0
dx dx dx
where dx/dx = 1. Hence
dy
Fx(x, y) + Fy (x, y) =0
dx
dy Fx(x, y)
⇒ =− , Fy (x, y) 6= 0
dx Fy (x, y)

Theorem: If the equation F (x, y, z) defines z


implicitly as a differentiable function of x and
y, then
∂z Fx(x, y, z) ∂z Fy (x, y, z)
=− , =− , Fz 6= 0
∂x Fz (x, y, z) ∂y Fz (x, y, z)
This can be extended to differentiable func-
tions defined implicitly with any number of vari-
ables.

Examples:

(a) Find zx given the implicit equation


yz − ln z = x + y.

Here F (x, y, z) = x + y − yz + ln z = 0,
Fx = 1, Fy = 1 − z, Fz = −y + 1z = (1 − yz)/z.
∂z Fx z
= − = , yz 6= 1
∂x Fz 1 − yz
∂z Fy z(1 − z)
= − = , yz 6= 1
∂y Fz 1 − yz
(b) Three resistors of ohms R1, R2 and R3
are connected in parallel to make an R-ohm
resistor found from the equation:
1 1 1 1
= + +
R R1 R2 R3
Find ∂R/∂R2 when R1 = 30, R2 = 45 and
R3 = 90 ohms.

Solution:
1 1 1 1
F = − − − .
R R1 R2 R3
1/R = 1/30 + 1/45 + 1/90 = 1/15, then R =
15.
1 1
FR = − 2 , FR2 = 2
R R2

∂R FR2 R2 15 2 1
 
=− = 2= =
∂R2 FR R2 45 9
Taylor’s theorem for functions of
several variables
If f (x), f ′ (x), . . . f (n)(x) exist and are continu-
ous on the closed domain[a, x] and f (n+1)(x)
exists on an open domain (a, x) then there ex-
ists a number θ, with 0 < θ < 1 such that

′ (x − a)2 ′′
f (x) = f (a) + (x − a)f (a) + f (a) + · · ·
2!
(x − a)n (n) (x − a)n+1 (n+1)
+ f (a) + f (θ)
n! (n + 1)!

Taylor’s theorem in two variables is just an ex-


tension of Taylor’s theorem for a singe variable
function.

Consider the point P (a, b) and Q(a + h, b + k)


where h and k are small increments. The line
segment P Q can be parametrized as
x = a + ht, y = b + kt, 0≤t≤1
We consider the function g(t) = f (a+ht, b+kt).
Then g ′(t) can be obtained by use of chain rule:
!
∂f dx ∂f dy ∂ ∂
g′ = + = h +k f
∂x dt ∂y dt ∂x ∂y
!
′′ d ∂ ∂
g = h +k f
dt ∂x ∂y
! !
∂ ∂ ∂ ∂
= h +k h +k f
∂x ∂y ∂x ∂y
!2
∂ ∂
= h +k f
∂x ∂y
= h2fxx + 2hkfxy + k2fyy

and in general
!r
dr g ∂ ∂
g (r) = = h + k f (x, y)
dtr ∂x ∂y

By repeated use of chain rule we have


!r
∂ ∂
g (r) = h +k f (x, y)
∂x ∂y
r ∂ rf
r∂ f
r 
r−1
= h r
+ h k
∂x 1 ∂xr−1∂y
r 
r−2 2 ∂ rf
+ h k r−2 2
+ ···
2 ∂x ∂y
 r 
r−1 ∂ rf r
r∂ f
+ hk r−1
+k
r−1 ∂x∂y ∂y r
The Taylor expansion of g(t) (a function of one
variable) is

′ t2 ′′
g(t) = g(0) + tg (0) + g (0) + · · ·
2!
tn−1 (n−1) tn (n)
+ g (0) + g (tθ)
(n − 1)! n!
Putting t = 1 we have
1
g(1) = g(0) + g ′(0) + · · · + g (n−1)(0)
(n − 1)!
1 (n)
+ g (θ), 0<θ<1 (∗)
n!
where g(0) = f (a, b), g(1) = f (a + h, b + k) and

g ′(0) = hfx (a, b) + kfy (a, b)

g ′′(0) = h2fxx(a, b) + 2hkfxy (a, b) + k2fyy (a, b), etc


Substituting for g(0), g(1), g ′(0), g ′′(0) · · · in
(*) gives the Taylor’s theorem for a function
of two variables about the point (a, b) given
below:
!
∂ ∂
f (a + h, b + k) = f (a, b)+ h +k f (x, y) (a,b)
∂x ∂y
!2
1 ∂ ∂
+ h +k f (x, y) (a,b) + · · ·
2! ∂x ∂y
!(n−1)
1 ∂ ∂
+ h +k f (a,b)
(n − 1)! ∂x ∂y
!(n)
1 ∂ ∂
+ h +k f (a+θh,b+θk) ,
n! ∂x ∂y

Setting h = x − a and k = y − b we have:

f (x, y) = "
f (a, b) #
∂f ∂f
+ (x − a) (a, b) + (y − b) (a, b)
∂x ∂y
" #2
1 ∂ ∂
+ (x − a) + (y − b) f (a,b) + · · ·
2! ∂x ∂y
" #n
1 ∂ ∂
+ (x − a) +(y − b) f (a+θ(x−a),b+θ(y−b)
n! ∂x ∂y
or f (x, y) = f (a, b)+(x − a)fx (a, b) + (y − b)fy (a, b)
"
1
+ (x − a)2fxx(a, b)+2(x − a)(y − b)fxy (
2
#
(y − b)2fyy (a, b) + · · ·

0 < θ < 1 which is referred to as the Taylor’s


expansion of f (x, y) about the point (a, b).

The Maclaurin’s theorem in two variables takes


the form:
!
∂f ∂f
f (x, y) = f (0, 0) + x (0, 0) + y (0, 0)
∂x ∂y
!2
1 ∂ ∂
+ x +y f (x, y) (0,0) + · · ·
2! ∂x ∂y
!n
1 ∂ ∂
+ x +y f (θx, θy ) 0 < θ < 1
n! ∂x ∂y
!n
1 ∂ ∂
Here Rn = x +y f (θx, θy ) 0<θ<1
n! ∂x ∂y
is the remainder term.
Example:

Obtain the Taylor series of the function f (x, y) =


sin(xy) about the point (1, π3 ).

Solution

fx = y cos(xy), fy = x cos(XS),
fxx = −y 2 sin(xy), fxy = −xy sin(xy),
fyy = −x2 sin(xy), etc.
Hence

3
f (1, π/3) =
2 √
π 3
fx(1, π/3) = , fy (1, π/3) = ,
6 2
√ √
π2 3 π 3
fxx(1, π/3) = − , fxy (1, π/3) = − ,
18 6

3
fyy (1, π/3) = − , etc.
2
The Taylor series becomes:
π π π π
f (x, y) = f (1, ) + (x − 1)fx(1, ) + (y − )fy (1, )
3 3 3 3
1 π π π
+ (x − 1)2fxx(1, ) + (x − 1)(y − )fxy (1, )
2 3 3 3
1 π 2 π
+ (y − ) fyy (1, ) + · · ·
2
√ 3 3
3 π 1 π
 
sin(xy) = + (x − 1) + y− −
√2 2 6 √2 3
3π 3π π
 
(x − 1)2 + (x − 1) y −
√36 2
6 3
3 π
+ y− + ···
4 3

Definition: The linearization of a function


f (x, y) at a point (a, b) is

L(x, y) = f (a, b) + (x − a)fx(a, b) + (y − b)fy (a, b)


The approximation

f (x, y) ≈ L(x, y)
is the linear approximation of f at (a, b):

f (x, y) ≈ f (a, b) + (x − a)fx(a, b) + (y − b)fy (a, b)


which is a Taylor’s polynomial approximation
of order one.
To get a quadratic approximation, we add quadratic
terms to the Taylor formula:

f (x, y) ≈ f (a, b) + (x − a)fx(a, b) + (y − b)fy (a, b) +


(x − a)2
fxx(a, b) + (x − a)(y − b)fxy (a, b) +
2
(y − b)2
fyy (a, b).
2
Improved approximations are obtained by adding
higher power terms.

Example: Use Taylor’s theorem to find (a) a


linear approximation (b) a quadratic approxi-
mation to the function f (x, y) = ex cos y near
the origin. Use your result to approximate
f (0.1, −0.1).

fx = ex cos y, fy = −ex sin y,


fxx = ex cos y, fxy = −ex sin y, fyy = −ex cos y

f (0, 0) = 1, fx(0, 0) = 1, fy (0, 0) = 0


fxx(0, 0) = 1, fxy (0, 0) = 0, fyy = −1.
Linear approximation:

f (x, y) ≈ f (0, 0) + xfx(0, 0) + yfy (0, 0) = 1 + x


f (0.02, −0.1) ≈ 1.02.
Exact f (0.02, −0.1) = e0.02 cos(−0.1) = 1.0151.

Quadratic approximation:

f (x, y) ≈ f (0, 0) + xfx(0, 0) + yfy (0, 0) +


x2 y2
+ fxx(0, 0) + xyfxy (0, 0) + fyy (0, 0)
2 2
1 2
x − y2
 
≈ 1+x+
2
f (0.02, −0.1) ≈ 1.0152.

Example 2: Use a linear approximation to ap-


proximate ln(1.03 + 0.982). Hint: f (x, y) =
ln(x+y 2), x = 1+h, y = 1+k so that h = 0.03
and k = −0.02.

f (x, y) ≈ f (a, b) + (x − a)fx(a, b) + (y − b)fy (a, b)


with a = b = 1.
Extreme values of functions of sev-
eral variables

Revision: Let f = f (x). Then

• if f ′ (x) > 0, then f is a increasing function.

• if f ′ (x) < 0, then f is decreasing.

• if f ′(x) = 0 or does not exist, then x is a


critical point.

There are three different types of critical points:


maximum points, minimum points and points
of inflection. Let x = x0 be a stationary point
of the function f (x) so that f ′(x0) = 0. We
can classify the critical point as follows:

• if f ′′(x0) > 0 then x = x0 is a min. point.

• If f ′′ (x0) < 0 then x = x0 is a max. point.

• If f ′′(x0) = 0, then x = x0 is a point of


inflection.
Example: Investigate the critical values of y =
2x5 − 3x4 + 1.

Extreme values for function of two vari-


ables

Local maxima correspond to mountain peaks


on the surface z = f (x, y) and local minima
correspond to valley bottoms. Local extrema
are also called relative extrema.

Theorem:
Let f be a continuous function of two variables
x and y defined on a closed bounded region R
in the xy-plane.

1. There is at least one point in R where f


takes on a minimum value.

2. There is at least one point in R where f


takes on a maximum value.

Definition: Relative extrema


Let f (x, y) be defined on a region R containing
(a, b)
1. f (x, y) has a local maximum value at (a, b)
if f (a, b) ≥ f (x, y) for all (x, y) in an open
disk containing (a, b).

2. f (x, y) has a local minimum value at (a, b)


if f (a, b) ≤ f (x, y) for all (x, y) in an open
disk containing (a, b).

3. f (a, b) has a saddle point value at (a, b)


if there are points (x, y) where f (a, b) <
f (x, y) and points where f (a, b) > f (x, y).

Definition: Let f (x, y) be defined on a region


R containing (a, b). The point (a, b) is a criti-
cal point of f if one of the following is true

1. fx(a, b) = 0 and fy (a, b) = 0

2. fx(a, b) or fy (a, b) does not exist.


First derivative test for local extreme val-
ues

If f (x, y) has a local maximum or minimum


value at an interior point (a, b) of its domain
and if the first partial derivatives exist there,
then fx(a, b) = 0 and fy (a, b) = 0.

Example 1:

Find the local (or relative) extrema of f (x, y) =


2x2 + y 2 + 8x − 6y + 20.

Solution:
Note f : fx(x, y) = 4x + 8, fy (x, y) = 2y − 6 = 0
are continuous for all x and y.
Critical points are

4x+8 = 0, and 2y−6 = 0, ⇒ (−2, 3)


f (−2, 3) = 3 and writing f (x, y) = 2(x + 2)2 +
(y −3)2 +3 we see that f (x, y) > 3 at any point
(x, y) 6= (−2, 3) showing that (−2, 3) is a local
minimum point.
Theorem: Second partials test
Let f (x, y) have continuous second partial deriva-
tives on an open region containing a point
(a, b) for which

fx(a, b) = 0 and fy (a, b) = 0


To test for local extrema of f , we define the
discriminant

D(a, b) = fxx(a, b)fyy (a, b) − [fxy (a, b)]2

1. If D > 0 and fxx(a, b) > 0, then f has a


local minimum at (a, b).

2. If D > 0 and fxx(a, b) < 0, then f has a


local maximum at (a, b).

3. If D < 0 then f has a saddle point at (a, b).

4. If D = 0 the test is inconclusive.

For D > 0, both fxx(a, b) and fyy (a, b) must


have the same sign. If both are positive the
z = f (x, y) will be concave up in the plane y = b
and also x = a and hence this will correspond
to a local minimum. If both are negative, the
z = f (x, y) will be concave down at the planes
x = a and y = b and hence (a, b) will be a local
maximum point. One way to get D < 0 is
if fxx (a, b) and fyy (a, b) have opposite sign so
that their concavities at x = a and at y = b are
opposite, in which case (a, b) is a saddle point.

Remark:

A convenient way to remember the formula for


D is to use the 2 × 2 determinant
fxx (a, b) fxy (a, b)
D=
fyx (a, b) fyy (a, b)

Example 2: Determine the critical points of


the following functions. Classify these criti-
cal points as either local maxima or minima or
saddle points.

(a) f (x, y) = 2x2 − y 3 − 2xy.


(b) f (x, y) = x3 + y 3 − 3xy.

(c) f (x, y) = x3 + y 2 − 6xy + 6x + 3y − 2.

(d) f (x, y) = x2y 2

(e) f (x, y) = sin(xy)

(a) Solution:
fx = 4x − 2y = 0, fy = −3y 2 − 2x = 0.
Solving the first equation we have y = 2x.
Substitute this in the second equation to get

−3(2x)2 − 2x = 0 ⇒ x(6x + 1) = 0
so that x = 0 or x = −1/6. The correspond-
ing values of y are y = 0 and y = −1/3.
Hence we have the critical points: (0, 0) and
(−1/6, −1/3).
To classify these points, we compute the sec-
ond partial derivatives:

fxx = 4, fyy = −6y, fxy = −2


2 = −24y − 4. Thus D(0, 0) =
D = fxxfyy − fxy
−4 < 0 is a saddle point.
D(−1/6, −1/3) = 8−4 = 4 > 0, with fxx = 4 >
0 thus we have a local minimum point here.

Complete the others as exercise.

Absolute extrema

Definition: Absolute maximum and abso-


lute minimum We call f (a, b) the absolute
maximum of f on the region R is f (a, b) ≥
f (x, y) for all (x, y) ∈ R. Similarly f (a, b) the
absolute minimum of f on the region R is
f (a, b) ≤ f (x, y) for all (x, y) ∈ R. In either
case f is called the absolute extremum of f .

Theorem: Extreme value theorem: Sup-


pose f (x, y) is continuous on the closed and
bounded region R ⊂ R2 Then f has both an ab-
solute maximum and an absolute minimum on
R. Furthermore the absolute extremum may
only occur at a critical point or at a point on
the boundary of R.
Finding absolute extrema

1. Determine all the critical points of f in the


region R.

2. Find the maximum and the minimum of f


on the boundary of R.

3. Compare the values of f at the critical


points with the maximum and minimum
values of f on the boundary of R.

Example: Find the absolute extrema of


f (x, y) = 5 + 4x − 2x2 + 3y − y 2
on the region R bounded by the lines
y = 2, y = x and y = −x.

Critical values: fx = 4 − 4x, fy = 3 − 2y,


fx = fy = 0 give a single critical point (1, 3/2).
f (1, 3/2) = 5 + 4 − 2 + 9/2 − 9/4 = 9.25.

Extreme values of f on the boundaries:


Boundary y = 2:
f (x, 2) = 7 + 4x − 2x2 = g(x)

Extreme values of g(x) along −2 ≤ x ≤ 2:


Critical value: g ′(x) = 4−4x = 0, i.e x = 1 and
g ′′(x) = −4 < 0 implying that this is local max
for g(x). Hence f (1, 2) = g(1) = 7 + 4 − 2 = 9.
iAlso g(−2) = 7−8−8 = −9, g(2) = 7+8−8 =
7. Hence the minimum on this boundary is −9
at (−2, 2).

Boundary y = x: 0 ≤ x ≤ 2:
f (x, x) = 5 + 7x − 3x2 = h(x), h′(x)7 − 6x =
0, h′′(x) < 0 which means that the local max
value is h(7/6) = 5 + 49/6 − 3(49/36) ≈ 9.08;
Other extreme values are h(0) = 5, h(2) =
5 + 14 − 12 = 7.

Boundary y = −x: −2 ≤ x ≤ 0:
f (x, x) = 5 + 4x − 2x2 − 3x − x2 = 5 + x −
3x2 = k(x). Critical value: k′ (x) = 1 − 6x = 0,
x = 1/6 but the point (1/6, −1/6) is not in R.
Other extreme values: k(0) = 5 and k(−2) =
5 − 2 − 12 = −9.

Thus the absolute extreme:


Absolute maximum f (1, 3/2) = 9.25 and
Absolute minimum: f (−2, 2) = −9.

You might also like