0% found this document useful (0 votes)
3 views

Lecture 10

Uploaded by

kjz8wg90
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

Lecture 10

Uploaded by

kjz8wg90
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

Directional Derivatives and Gradient Vectors

Gradients and Tangents to Level Curves


• If a di↵erentiable function f (x, y) has a constant value c along a smooth curve r = g(t)i+h(t)j
(making the curve part of a level curve of f ), then f (g(t), h(t)) = c.

• Di↵erentiating both sides of this equation with respect to t leads to the equations
d d
f (g(t), h(t)) = (c)
dt dt
@f dg @f dh
+ = 0 Chain Rule
@x dt @y dt
✓ ◆ ✓ ◆
@f @f dg dh
i+ j · i + j = 0.
@x @y dt dt
| {z } | {z }
rf dr
dt

=) rf is normal to the tangent vector dr/dt


=) rf is normal to the curve

• At every point (x0 , y0 ) in the domain of a di↵erentiable


function f (x, y), the gradient of f is normal to the level curve
through (x0 , y0 ).
Directional Derivatives and Gradient Vectors

Equations for tangent lines to level curves

If N is the gradient rf |(x0 ,y0 ) = fx (x0 , y0 ) i + fy (x0 , y0 ) j, and this gradient is not the zero
vector, then this equation gives the following formula for tangent line to a level curve

fx (x0 , y0 ) (x x0 ) + fy (x0 , y0 ) (y y0 ) = 0

Example: Find an equation for the tangent to the ellipse

x2
+ y2 = 2
4
at the point ( 2, 1).

Solution:
x2
• The ellipse is a level curve of the function f (x, y) = 4
+ y2.
• The gradient of f at ( 2, 1) is rf |( 2,1) = x
2
i + 2yj ( 2,1)
= i + 2j

• Because this gradient vector is nonzero, the tangent to the ellipse at ( 2, 1) is the line

( 1)(x + 2) + (2)(y 1) = 0
x 2y = 4.
Directional Derivatives and Gradient Vectors

The derivative along a path

If r(t) = x(t)i + y(t)j + z(t)k is a smooth path C, and w = f (r(t)) is a scalar function evaluated
along C, then according to the Chain Rule
dw @w dx @w dy @w dz
= + +
dt @x dt @y dt @z dt

This implies the derivative along a smooth path C can be obtained by following formula:

d
f (r(t)) = rf (r(t)) · r0 (t).
dt
Directional Derivatives and Gradient Vectors

Tangent Planes and Normal Lines:

• If r(t) = x(t)i + y(t)j + z(t)k is a smooth curve on the level surface f (x, y, z) = c of a
di↵erentiable function f , then
d
f (r(t)) = rf (r(t)) · r0 (t) = 0 (as f is constant along the curve r(t))
dt
=) gradient rf is orthogonal to the curve’s velocity vector r0 .

Thus, an equation of Tangent Plane


to f (x, y, z) = c at P0 (x0 , y0 , z0 ) is

fx (P0 ) (x x0 ) + fy (P0 ) (y y0 ) + fz (P0 ) (z z0 ) = 0

The normal line of the surface at P0 is the line through P0 parallel to rf |P0 . And an equation
of Normal Line to f (x, y, z) = c at P0 (x0 , y0 , z0 ) is given by

x = x0 + fx (P0 ) t, y = y0 + fy (P0 ) t, z = z0 + fz (P0 ) t


Directional Derivatives and Gradient Vectors

Tangent Planes and Normal Lines:


Example Find the tangent plane and normal line of the level surface

f (x, y, z) = x2 + y 2 + z 9 = 0 at the point P0 (1, 2, 4).

Solution

• The tangent plane is the plane through P0 perpendicular to the gradient of f at P0 . The
gradient is
rf |P0 = (2xi + 2yj + k)|(1,2,4) = 2i + 4j + k.

• The tangent plane is therefore the plane

2(x 1) + 4(y 2) + (z 4) = 0, or 2x + 4y + z = 14.

• The line normal to the surface at P0 is

x = 1 + 2t, y = 2 + 4t, z = 4 + t.

Example Find the equations of the tangent plane and normal line at the point ( 2, 1, 3) to
the ellipsoid
x2 2 z2
+y + =3
4 9
Directional Derivatives and Gradient Vectors

Tangent Planes and Normal Lines:


Plane Tangent to a Surface z = f (x, y) at (x0 , y0 , f (x0 , y0 ))
• To find an equation for the plane tangent to a smooth surface z = f (x, y) at a point
P0 (x0 , y0 , z0 ) where z0 = f (x0 , y0 ), we first observe that the equation z = f (x, y) is equivalent
to f (x, y) z = 0.

• The surface z = f (x, y) is therefore the zero level surface of the function F (x, y, z) = f (x, y)
z.

• The partial derivatives of F are


@
Fx = (f (x, y) z) = fx 0 = fx
@x
@
Fy = (f (x, y) z) = fy 0 = fy
@y
@
Fz = (f (x, y) z) = 0 1= 1.
@z

• The formula
Fx (P0 ) (x x0 ) + Fy (P0 ) (y y0 ) + Fz (P0 ) (z z0 ) = 0
for the plane tangent to the level surface at P0 therefore reduces to

fx (x0 , y0 ) (x x0 ) + fy (x0 , y0 ) (y y0 ) (z z0 ) = 0

as long as the gradient is not the zero vector at the point P0 .


Directional Derivatives and Gradient Vectors

Tangent Planes and Normal Lines:


Plane Tangent to a Surface z = f (x, y) at (x0 , y0 , f (x0 , y0 ))
The plane tangent to the surface z = f (x, y) of a di↵erentiable function f at the point
P0 (x0 , y0 , z0 ) = (x0 , y0 , f (x0 , y0 )) is

fx (x0 , y0 ) (x x0 ) + fy (x0 , y0 ) (y y0 ) (z z0 ) = 0.

Example: Find the plane tangent to the surface z = x cos y yex at (0, 0, 0).

Solution:

• Calculate the partial derivatives of f (x, y) = x cos y yex :

fx (0, 0) = (cos y yex )|(0,0) = 1 0·1=1


fy (0, 0) = ( x sin y ex )|(0,0) = 0 1= 1.

• The tangent plane is therefore

1 · (x 0) 1 · (y 0) (z 0) = 0,

or
x y z=0
Directional Derivatives and Gradient Vectors

Example: The surfaces

f (x, y, z) = x2 + y 2 2=0 (A cylinder )

and
g(x, y, z) = x + z 4=0 (A plane )
meet in an ellipse E. Find parametric equations for the line tangent to E at the point P0 (1, 1, 3).
Solution:

• The tangent line is orthogonal to both rf


and rg at P0 , and therefore parallel to v = rf ⇥ rg.

• The components of v and the coordinates


of P0 give us equations for the line.
• We have
rf |(1,1,3) = (2xi + 2yj)|(1,1,3) = 2i + 2j
rg|(1,1,3) = (i + k)|(1,1,3) = i + k
i j k
v = (2i + 2j) ⇥ (i + k) = 2 2 0 = 2i 2j 2k.
1 0 1
• The tangent line to the ellipse of intersection is

x = 1 + 2t, y=1 2t, z=3 2t


Function of Several Variables

Linearization: (Recall one dimensional concept)

• It is often useful to approximate complicated functions with simpler ones


that give the accuracy we want for specific applications and at the same
time are easier to work with than the original functions.

• The approximating functions discussed in this section are called


linearizations, and they are based on tangent lines.

• There are other approximating functions, such as polynomials, trigonometric


functions…but beyond the scope of this course .
Function of Several Variables

Linearization: (Recall one dimensional concept)

Every differentiable curve behaves locally like its tangent line, therefore
tangent line locally provide a linear approximation of the differentiable
curves.
• Let y = f (x) be a di↵erentiable function, then the equation of the tangent line passing
through (a, f (a)) is
y = f (a) + f 0 (a)(x a)

• This tangent line is the graph of the linear function

L(x) = f (a) + f 0 (a)(x a)

As long as this line remains


close to the graph of f as we
move o↵ the point of tangency, L(x)
gives a good approximation to f (x).

The tangent to the curve y = f (x) at x = a


is the line L(x) = f (a) + f 0 (a)(x a).
Function of Several Variables

Linearization: (Recall one dimensional concept)


Function of Several Variables

Linearization: (Recall one dimensional concept)

Definition. If f is di↵erentiable at x = a, then the approximating function

L(x) = f (a) + f 0 (a)(x a)

is the linearization of f at a. The approximation

f (x) ⇡ L(x)

of f by L is the standard linear approximation of f at a. The point x = a is the center of


the approximation.

The tangent to the curve y = f (x) at x = a


is the line L(x) = f (a) + f 0 (a)(x a).
Function of Several Variables

Linearization: (Recall one dimensional concept)


p
Example: Find the linearization of f (x) = 1 + x at x = 0.

Solution: Since
1
f 0 (x) = (1 + x) 1/2
2
we have f (0) = 1 and f 0 (0) = 1/2, giving the linearization
1 x
L(x) = f (a) + f 0 (a)(x a) = 1 + (x 0) = 1 +
2 2

p
The data shows how accurate the approximation 1 + x ⇡ 1 + (x/2) is for some values of x
near 0. As we move away from zero,
p we lose accuracy. For example, for x = 2, the linearization
gives 2 as the approximation for 3, which is not even accurate to one decimal place.
Function of Several Variables

Linearization: (Recall one dimensional concept)

Example:

Find the linearization of


p
1. f (x) = 1 + x at x = 3.

2. f (x) = cos x at x = ⇡/2

3. f (x) = (1 + x)k at x = 0 for any number k


Function of Several Variables

Linearization: (How to Linearize a Function of Two Variables)


The linearization of a function of two variables is a tangent- plane approximation
in the same way that the linearization of a function of a single variable is a
tangent-line approximation.

Definition. The linearization of a function f (x, y) at a point (x0 , y0 ) where f is di↵erentiable


is the function

L(x, y) = f (x0 , y0 ) + fx (x0 , y0 ) (x x0 ) + fy (x0 , y0 ) (y y0 ) .

The approximation
f (x, y) ⇡ L(x, y)
is the standard linear approximation of f at (x0 , y0 ).
Function of Several Variables

Linearization: (How to Linearize a Function of Two Variables)

Example: Find the linearization of f (x, y) = x2 xy + 12 y 2 + 3 at the point (3, 2).

Solution:

• We first evaluate f, fx , and fy at the point (x0 , y0 ) = (3, 2) :


✓ ◆
1
f (3, 2) = x2 xy + y 2 + 3 =8
2 (3,2)
✓ ◆
@ 1
fx (3, 2) = x2 xy + y 2 + 3 = (2x y)|(3,2) = 4
@x 2 (3,2)
✓ ◆
@ 1
fy (3, 2) = x2 xy + y 2 + 3 = ( x + y)|(3,2) = 1,
@y 2 (3,2)

• Giving
L(x, y) = f (x0 , y0 ) + fx (x0 , y0 ) (x x0 ) + fy (x0 , y0 ) (y y0 )
= 8 + (4)(x 3) + ( 1)(y 2) = 4x y 2.

• The linearization of f at (3, 2) is L(x, y) = 4x y 2.


Function of Several Variables

Linearization: (How to Linearize a Function of Two Variables)


The linearization of a function of two variables is a tangent- plane approximation
in the same way that the linearization of a function of a single variable is a
tangent-line approximation.

Definition. The linearization of a function f (x, y) at a point (x0 , y0 ) where f is di↵erentiable


is the function

L(x, y) = f (x0 , y0 ) + fx (x0 , y0 ) (x x0 ) + fy (x0 , y0 ) (y y0 ) .

The approximation
f (x, y) ⇡ L(x, y)
is the standard linear approximation of f at (x0 , y0 ).

• When approximating a di↵erentiable function f (x, y) by its linearization L(x, y) at (x0 , y0 ),


an important question is how accurate the approximation might be.

We answer this question in next slide


Function of Several Variables

Linearization: (How to Linearize a Function of Two Variables)


• When approximating a di↵erentiable function f (x, y) by its linearization L(x, y) at (x0 , y0 ),
an important question is how accurate the approximation might be.

The Error in the Standard Linear Approximation:


If f has continuous first and second partial derivatives throughout an open set containing a
rectangle R centered at (x0 , y0 ) and if M is any upper bound for the values of |fxx | , |fyy |, and |fxy |
on R, then the error E(x, y) incurred in replacing f (x, y) on R by its linearization

L(x, y) = f (x0 , y0 ) + fx (x0 , y0 ) (x x0 ) + fy (x0 , y0 ) (y y0 )

satisfies the inequality


1
|E(x, y)| = |f (x, y) L(x, y)|  M (|x x0 | + |y y0 |)2 .
2

• To make |E(x, y)| small for a given M ,


we just make |x x0 | and |y y0 | small.

The rectangular region


R : |x x0 |  h, |y y0 |  k
in the xy-plane.
Function of Several Variables

Linearization:

Linearization in the 3-dimensions

The linearization of f (x, y, z) at a point P0 (x0 , y0 , z0 ) is

L(x, y, z) = f (P0 ) + fx (P0 ) (x x0 ) + fy (P0 ) (y y0 ) + fz (P0 ) (z z0 )

Error In the Linearization:


Suppose that R is a closed rectangular solid centered at P0 and lying in an open region on which
the second partial derivatives of f are continuous. Suppose also that |fxx | , |fyy | , |fzz | , |fxy | , |fxz |,
and |fyz | are all less than or equal to M throughout R. Then the error E(x, y, z) = f (x, y, z)
L(x, y, z) in the approximation of f by L is bounded throughout R by the inequality
1
|E| = |f (x, y, z) L(x, y, z)|  M (|x x0 | + |y y0 | + |z z0 |)2
2
Function of Several Variables

Example: Find the linearization L(x, y, z) of

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

at the point (x0 , y0 , z0 ) = (2, 1, 0). Find an upper bound for the error incurred in replacing f by L
on the rectangular region

R : |x 2|  0.01, |y 1|  0.02, |z|  0.01

Solution:

• Routine calculations give

f (2, 1, 0) = 2, fx (2, 1, 0) = 3, fy (2, 1, 0) = 2, fz (2, 1, 0) = 3.

• Thus,
L(x, y, z) = 2 + 3(x 2) + ( 2)(y 1) + 3(z 0) = 3x 2y + 3z 2

• Since
fxx = 2, fyy = 0, fzz = 3 sin z, fxy = 1, fxz = 0, fyz = 0,
and | 3 sin z|  3 sin 0.01 ⇡ 0.03, we may take M = 2 as a bound on the second partials.

• Hence, the error incurred by replacing f by L on R satisfies


1
|E|  (2)(0.01 + 0.02 + 0.01)2 = 0.0016
2

You might also like