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

01 Directional Derivatives and Gradient

The document discusses directional derivatives and the gradient vector. It defines the directional derivative of a function f at a point (x0, y0) in the direction of a unit vector u = (a, b) as the limit of the difference quotient (f(x0 + ha, y0 + hb) - f(x0, y0))/h as h approaches 0. It then proves that if f is differentiable, its directional derivative equals the partial derivative with respect to x times a plus the partial derivative with respect to y times b.

Uploaded by

yay
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)
137 views

01 Directional Derivatives and Gradient

The document discusses directional derivatives and the gradient vector. It defines the directional derivative of a function f at a point (x0, y0) in the direction of a unit vector u = (a, b) as the limit of the difference quotient (f(x0 + ha, y0 + hb) - f(x0, y0))/h as h approaches 0. It then proves that if f is differentiable, its directional derivative equals the partial derivative with respect to x times a plus the partial derivative with respect to y times b.

Uploaded by

yay
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/ 114

Directional Derivatives and the Gradient Vector

Lucky Galvez
Institute of Mathematics
University of the Philippines
Diliman

Math 55

Directional Derivatives & Gradient

Recall: Partial Derivatives


Let z = f (x, y).
z
x
z
y

f (x + h, y) f (x, y)
h0
h
f (x, y + h) f (x, y)
= fy (x, y) = lim
h0
h
= fx (x, y) = lim

Math 55

Directional Derivatives & Gradient

Recall: Partial Derivatives


Let z = f (x, y).
z
x
z
y

f (x + h, y) f (x, y)
h0
h
f (x, y + h) f (x, y)
= fy (x, y) = lim
h0
h
= fx (x, y) = lim

R
R

fx represents the rate of change


of f with respect to x when y is
fixed
fy represents the rate of change
of f with respect to y when x is
fixed

Math 55

Directional Derivatives & Gradient

Directional Derivative
Suppose we want to find the rate of change of f at (x0 , y0 ) in
the direction of a unit vector u = ha, bi.

Math 55

Directional Derivatives & Gradient

Directional Derivative
Suppose we want to find the rate of change of f at (x0 , y0 ) in
the direction of a unit vector u = ha, bi. That is, the slope of
the tangent line to C at P .

Math 55

Directional Derivatives & Gradient

Directional Derivative
Suppose we want to find the rate of change of f at (x0 , y0 ) in
the direction of a unit vector u = ha, bi. That is, the slope of
the tangent line to C at P .

If Q(x, y, z) is another
point on C and P 0 , Q0
are the projections of P
and Q on the xy-plane,
resp., then the vector
P ~0 Q0 is parallel to u

Math 55

Directional Derivatives & Gradient

Directional Derivative
Suppose we want to find the rate of change of f at (x0 , y0 ) in
the direction of a unit vector u = ha, bi. That is, the slope of
the tangent line to C at P .

If Q(x, y, z) is another
point on C and P 0 , Q0
are the projections of P
and Q on the xy-plane,
resp., then the vector
P ~0 Q0 is parallel to u so
for some scalar h,
P ~0 Q0 = hu = hha, hbi .

Math 55

Directional Derivatives & Gradient

Directional Derivative
Therefore,
x x0 = ha x = x0 + ha
y y0 = hb y = y0 + hb

Math 55

Directional Derivatives & Gradient

Directional Derivative
Therefore,
x x0 = ha x = x0 + ha
y y0 = hb y = y0 + hb

The rate of change of f (with respect to distance) in the


direction of u is
f
h0 h
lim

Math 55

Directional Derivatives & Gradient

Directional Derivative
Therefore,
x x0 = ha x = x0 + ha
y y0 = hb y = y0 + hb

The rate of change of f (with respect to distance) in the


direction of u is
f
h0 h
lim

f (x, y) f (x0 , y0 )
h0
h
lim

Math 55

Directional Derivatives & Gradient

Directional Derivative
Therefore,
x x0 = ha x = x0 + ha
y y0 = hb y = y0 + hb

The rate of change of f (with respect to distance) in the


direction of u is
f
h0 h
lim

f (x, y) f (x0 , y0 )
h0
h
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
=

lim

Math 55

Directional Derivatives & Gradient

Directional Derivative
Definition
The directional derivative of f (x, y) at (x0 , y0 ) in the
direction of a unit vector u = ha, bi is
Du f (x0 , y0 ) = lim

h0

f (x0 + ha, y0 + hb) f (x0 , y0 )


h

provided this limit exists.

Math 55

Directional Derivatives & Gradient

Directional Derivative
Definition
The directional derivative of f (x, y) at (x0 , y0 ) in the
direction of a unit vector u = ha, bi is
Du f (x0 , y0 ) = lim

h0

f (x0 + ha, y0 + hb) f (x0 , y0 )


h

provided this limit exists.


Remarks:
1

If u = = h1, 0i, then


f (x0 + h, y0 ) f (x0 , y0 )
D f = lim
h0
h

Math 55

Directional Derivatives & Gradient

Directional Derivative
Definition
The directional derivative of f (x, y) at (x0 , y0 ) in the
direction of a unit vector u = ha, bi is
Du f (x0 , y0 ) = lim

h0

f (x0 + ha, y0 + hb) f (x0 , y0 )


h

provided this limit exists.


Remarks:
1

If u = = h1, 0i, then


f (x0 + h, y0 ) f (x0 , y0 )
= fx (x0 , y0 ).
D f = lim
h0
h

Math 55

Directional Derivatives & Gradient

Directional Derivative
Definition
The directional derivative of f (x, y) at (x0 , y0 ) in the
direction of a unit vector u = ha, bi is
Du f (x0 , y0 ) = lim

h0

f (x0 + ha, y0 + hb) f (x0 , y0 )


h

provided this limit exists.


Remarks:
1

If u = = h1, 0i, then


f (x0 + h, y0 ) f (x0 , y0 )
= fx (x0 , y0 ).
D f = lim
h0
h
If u = = h0, 1i, then
f (x0 , y0 + h) f (x0 , y0 )
Df = lim
h0
h
Math 55

Directional Derivatives & Gradient

Directional Derivative
Definition
The directional derivative of f (x, y) at (x0 , y0 ) in the
direction of a unit vector u = ha, bi is
Du f (x0 , y0 ) = lim

h0

f (x0 + ha, y0 + hb) f (x0 , y0 )


h

provided this limit exists.


Remarks:
1

If u = = h1, 0i, then


f (x0 + h, y0 ) f (x0 , y0 )
= fx (x0 , y0 ).
D f = lim
h0
h
If u = = h0, 1i, then
f (x0 , y0 + h) f (x0 , y0 )
Df = lim
= fy (x0 , y0 ).
h0
h
Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb).

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

lim

h0

g(h) g(0)
h

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

lim

h0

g(h) g(0)
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
h

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

=
=

g(h) g(0)
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
h
Du f (x0 , y0 ).
lim

h0

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

=
=

g(h) g(0)
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
h
Du f (x0 , y0 ).
lim

h0

Let g(h) = f (x, y) where x = x0 + ha, y = y0 + hb. By Chain Rule,


g 0 (h) =

f dy
f dx
+
x dh
y dh

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

=
=

g(h) g(0)
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
h
Du f (x0 , y0 ).
lim

h0

Let g(h) = f (x, y) where x = x0 + ha, y = y0 + hb. By Chain Rule,


g 0 (h) =

f dy
f dx
= fx (x, y)a + fy (x, y)b
+
x dh
y dh

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

=
=

g(h) g(0)
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
h
Du f (x0 , y0 ).
lim

h0

Let g(h) = f (x, y) where x = x0 + ha, y = y0 + hb. By Chain Rule,


g 0 (h) =

f dy
f dx
= fx (x, y)a + fy (x, y)b
+
x dh
y dh

Note that h = 0 x = x0 , y = y0

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

=
=

g(h) g(0)
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
h
Du f (x0 , y0 ).
lim

h0

Let g(h) = f (x, y) where x = x0 + ha, y = y0 + hb. By Chain Rule,


g 0 (h) =

f dy
f dx
= fx (x, y)a + fy (x, y)b
+
x dh
y dh

Note that h = 0 x = x0 , y = y0 so g 0 (0) = fx (x0 , y0 )a + fy (x0 , y0 )b.

Math 55

Directional Derivatives & Gradient

Directional Derivative
Theorem
If f is a differentiable function of x and y, then f has a
directional derivative at any point (x0 , y0 ) in the domain of f ,
in the direction of any unit vector u = ha, bi and
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.
Proof. Define g(h) = f (x0 + ha, y0 + hb). Then
g 0 (0)

=
=

g(h) g(0)
f (x0 + ha, y0 + hb) f (x0 , y0 )
= lim
h0
h
h
Du f (x0 , y0 ).
lim

h0

Let g(h) = f (x, y) where x = x0 + ha, y = y0 + hb. By Chain Rule,


g 0 (h) =

f dy
f dx
= fx (x, y)a + fy (x, y)b
+
x dh
y dh

Note that h = 0 x = x0 , y = y0 so g 0 (0) = fx (x0 , y0 )a + fy (x0 , y0 )b.


Hence,
Du f (x0 , y0 ) = fx (x0 , y0 )a + fy (x0 , y0 )b.

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

Math 55

E
2
2
,

2
2 .

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y)

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2)

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2
fy (x, y)

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2
fy (x, y) = 2x 2y

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2
fy (x, y) = 2x 2y fy (1, 2)

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2
fy (x, y) = 2x 2y fy (1, 2) = 6

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2
fy (x, y) = 2x 2y fy (1, 2) = 6
Hence,
Du f (1, 2) = fx (1, 2)

Math 55

!
!
2
2
+ fy (1, 2)
2
2

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2
fy (x, y) = 2x 2y fy (1, 2) = 6
Hence,
!
!
2
2
+ fy (1, 2)
Du f (1, 2) = fx (1, 2)
2
2
!
!
2
2
= 2
6
2
2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Evaluate Du f (1, 2) if f (x, y) = x2 2xy y 2 if u =

E
2
2
,

2
2 .

Solution. First, we compute the partial derivatives


fx (x, y) = 2x 2y fx (1, 2) = 2
fy (x, y) = 2x 2y fy (1, 2) = 6
Hence,
!
!
2
2
+ fy (1, 2)
Du f (1, 2) = fx (1, 2)
2
2
!
!
2
2
= 2
6
2
2

= 2 2
Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is
u=

h3, 4i
k h3, 4i k

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is
u=

h3, 4i
h3, 4i
=p
k h3, 4i k
32 + (4)2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is


h3, 4i
h3, 4i
3 4
p
u=
,
=
=
k h3, 4i k
5 5
32 + (4)2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is


h3, 4i
h3, 4i
3 4
p
u=
,
=
=
k h3, 4i k
5 5
32 + (4)2
Hence,
 
 
3
4
Du f (x, y) = fx (x, y)
+ fy (x, y)
5
5

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is


h3, 4i
h3, 4i
3 4
p
u=
,
=
=
k h3, 4i k
5 5
32 + (4)2
Hence,
 
 
3
4
Du f (x, y) = fx (x, y)
+ fy (x, y)
5
5

= y 2 + y sin(xy)

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is


h3, 4i
h3, 4i
3 4
p
u=
,
=
=
k h3, 4i k
5 5
32 + (4)2
Hence,
 
 
3
4
Du f (x, y) = fx (x, y)
+ fy (x, y)
5
5
 

3
= y 2 + y sin(xy)
5
Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is


h3, 4i
h3, 4i
3 4
p
u=
,
=
=
k h3, 4i k
5 5
32 + (4)2
Hence,
 
 
3
4
Du f (x, y) = fx (x, y)
+ fy (x, y)
5
5
 

3
= y 2 + y sin(xy)
+ (2xy + x sin(xy))
5
Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
Determine the directional derivative of f (x, y) = xy 2 cos(xy)
at any point, in the direction of the vector 3 4
.
Solution. The unit vector in the same direction as the given
vector is


h3, 4i
h3, 4i
3 4
p
u=
,
=
=
k h3, 4i k
5 5
32 + (4)2
Hence,
 
 
3
4
Du f (x, y) = fx (x, y)
+ fy (x, y)
5
5
 
 

3
4
2
= y + y sin(xy)
+ (2xy + x sin(xy))
5
5
Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then

Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then
cos

Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then
a
cos =
kuk

Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then
a
cos =
=a
kuk

Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then
a
cos =
= a and sin
kuk

Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then
a
b
cos =
= a and sin =
kuk
kuk

Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then
a
b
cos =
= a and sin =
=b
kuk
kuk

Math 55

Directional Derivatives & Gradient

Directional Derivative

u
(x0 , y0 )

If the unit vector u = ha, bi, makes an angle with the x-axis,
then
a
b
cos =
= a and sin =
=b
kuk
kuk
and the formula in the previous theorem becomes
Du f (x, y) = fx (x, y) cos + fy (x, y) sin .
Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin


2
=
2xyex y 2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin



2
=
2xyex y 2 cos
3

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin




2
2
=
2xyex y 2 cos + x2 ex y + 1
3

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin





2
2
=
2xyex y 2 cos + x2 ex y + 1 sin
3
3

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin





2
2
=
2xyex y 2 cos + x2 ex y + 1 sin
3
3
Hence,
Du f (1, 0)

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin





2
2
=
2xyex y 2 cos + x2 ex y + 1 sin
3
3
Hence,
Du f (1, 0) = 2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin





2
2
=
2xyex y 2 cos + x2 ex y + 1 sin
3
3
Hence,
 
1
Du f (1, 0) = 2
2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin





2
2
=
2xyex y 2 cos + x2 ex y + 1 sin
3
3
Hence,
 
1
Du f (1, 0) = 2
+2
2

Math 55

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin





2
2
=
2xyex y 2 cos + x2 ex y + 1 sin
3
3
Hence,
 
1
Du f (1, 0) = 2
+2
2

Math 55

!
3
2

Directional Derivatives & Gradient

Directional Derivative
Example
2

Find the directional derivative of f (x, y) = ex y 2x + y at the


point (1, 0) in the direction of the unit vector given by = 3 .
Solution: From the previous formula,
Du f (x, y) = fx (x, y) cos + fy (x, y) sin





2
2
=
2xyex y 2 cos + x2 ex y + 1 sin
3
3
Hence,
 
1
Du f (1, 0) = 2
+2
2

= 1 + 3

Math 55

!
3
2

Directional Derivatives & Gradient

The Gradient Vector

From the previous theorem,


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

Math 55

Directional Derivatives & Gradient

The Gradient Vector

From the previous theorem,


Du f (x, y) = fx (x, y)a + fy (x, y)b
= hfx (x, y), fy (x, y)i ha, bi

Math 55

Directional Derivatives & Gradient

The Gradient Vector

From the previous theorem,


Du f (x, y) = fx (x, y)a + fy (x, y)b
= hfx (x, y), fy (x, y)i ha, bi
= hfx (x, y), fy (x, y)i u

Math 55

Directional Derivatives & Gradient

The Gradient Vector

From the previous theorem,


Du f (x, y) = fx (x, y)a + fy (x, y)b
= hfx (x, y), fy (x, y)i ha, bi
= hfx (x, y), fy (x, y)i u

Math 55

Directional Derivatives & Gradient

The Gradient Vector

From the previous theorem,


Du f (x, y) = fx (x, y)a + fy (x, y)b
= hfx (x, y), fy (x, y)i ha, bi
= hfx (x, y), fy (x, y)i u
The vector hfx (x, y), fy (x, y)i appears not only in the formula
for directional derivative but in many applications as well.

Math 55

Directional Derivatives & Gradient

The Gradient Vector

From the previous theorem,


Du f (x, y) = fx (x, y)a + fy (x, y)b
= hfx (x, y), fy (x, y)i ha, bi
= hfx (x, y), fy (x, y)i u
The vector hfx (x, y), fy (x, y)i appears not only in the formula
for directional derivative but in many applications as well.
This vector is called the gradient of f , denoted grad f or f .

Math 55

Directional Derivatives & Gradient

The Gradient Vector

Definition
If f is a function of x and y, then the gradient of f is the vector
function f defined as
f (x, y) = hfx (x, y), fy (x, y)i

Math 55

Directional Derivatives & Gradient

The Gradient Vector

Definition
If f is a function of x and y, then the gradient of f is the vector
function f defined as
f (x, y) = hfx (x, y), fy (x, y)i
Thus, the directional derivetive of f in the direction of a unit
vector u = ha, bi can be written as
Du f (x, y) = f (x, y) u

Math 55

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .

Math 55

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

Math 55

1
2
,
5
5

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient


f (x, y)

Math 55

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient


f (x, y) =

hfx (x, y), fy (x, y)i

Math 55

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient



f (x, y) =

hfx (x, y), fy (x, y)i =

Math 55

2x ln y,

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient



f (x, y) =

hfx (x, y), fy (x, y)i =

Math 55

x2
2x ln y,
y

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient



f (x, y) =
f (2, 1) =

hfx (x, y), fy (x, y)i =

x2
2x ln y,
y

h0,

Math 55

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient



f (x, y) =
f (2, 1) =

hfx (x, y), fy (x, y)i =

x2
2x ln y,
y

h0, 4i

Math 55

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient



f (x, y) =
f (2, 1) =

hfx (x, y), fy (x, y)i =

x2
2x ln y,
y

h0, 4i

Hence,
Du f (2, 1) = f (2, 1) u
Math 55

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient



f (x, y) =
f (2, 1) =

hfx (x, y), fy (x, y)i =

x2
2x ln y,
y

h0, 4i

Hence,

Du f (2, 1) = f (2, 1) u = h0, 4i
Math 55

2
1
,
5
5

Directional Derivatives & Gradient

Example
Example
Find the directional derivative of f (x, y) = x2 ln y at the point
(2, 1) in the direction of 2 + .
Solution: We normalize the given vector
u=

h2, 1i
=
22 + 1 2

1
2
,
5
5

Next, compute the gradient



f (x, y) =
f (2, 1) =

hfx (x, y), fy (x, y)i =

x2
2x ln y,
y

h0, 4i

Hence,

Du f (2, 1) = f (2, 1) u = h0, 4i
Math 55

2
1
,
5
5

4
=
5

Directional Derivatives & Gradient

Functions of Three Variables


Definition
The directional derivative of f (x, y, z) at (x0 , y0 , z0 ) in the
direction of the unit vector u = ha, b, ci is
f (x0 + ha, y0 + hb, z0 + hc) f (x0 , y0 , z0 )
h0
h
lim

provided this limit exists.

Math 55

Directional Derivatives & Gradient

Functions of Three Variables


Definition
The directional derivative of f (x, y, z) at (x0 , y0 , z0 ) in the
direction of the unit vector u = ha, b, ci is
f (x0 + ha, y0 + hb, z0 + hc) f (x0 , y0 , z0 )
h0
h
lim

provided this limit exists.


Definition
The gradient vector of f (x, y, z) is
f (x, y, z) = hfx (x, y, z), fy (x, y, z), fz (x, y, z)i

Math 55

Directional Derivatives & Gradient

Functions of Three Variables


Definition
The directional derivative of f (x, y, z) at (x0 , y0 , z0 ) in the
direction of the unit vector u = ha, b, ci is
f (x0 + ha, y0 + hb, z0 + hc) f (x0 , y0 , z0 )
h0
h
lim

provided this limit exists.


Definition
The gradient vector of f (x, y, z) is
f (x, y, z) = hfx (x, y, z), fy (x, y, z), fz (x, y, z)i

Du f (x, y, z) = fx (x, y, z)a + fy (x, y, z)b + fz (x, y, z)c

Math 55

Directional Derivatives & Gradient

Functions of Three Variables


Definition
The directional derivative of f (x, y, z) at (x0 , y0 , z0 ) in the
direction of the unit vector u = ha, b, ci is
f (x0 + ha, y0 + hb, z0 + hc) f (x0 , y0 , z0 )
h0
h
lim

provided this limit exists.


Definition
The gradient vector of f (x, y, z) is
f (x, y, z) = hfx (x, y, z), fy (x, y, z), fz (x, y, z)i

Du f (x, y, z) = fx (x, y, z)a + fy (x, y, z)b + fz (x, y, z)c


= f (x, y, z) u
Math 55

Directional Derivatives & Gradient

The Gradient Vector


Theorem
Suppose f is a differentiable function of x and y. The
maximum value of Du f is kf k and it occurs when u is in the
same direction as f .

Math 55

Directional Derivatives & Gradient

The Gradient Vector


Theorem
Suppose f is a differentiable function of x and y. The
maximum value of Du f is kf k and it occurs when u is in the
same direction as f .
Proof. Let be the angle between f and u.

Math 55

Directional Derivatives & Gradient

The Gradient Vector


Theorem
Suppose f is a differentiable function of x and y. The
maximum value of Du f is kf k and it occurs when u is in the
same direction as f .
Proof. Let be the angle between f and u.
Du f (x, y) = f u

Math 55

Directional Derivatives & Gradient

The Gradient Vector


Theorem
Suppose f is a differentiable function of x and y. The
maximum value of Du f is kf k and it occurs when u is in the
same direction as f .
Proof. Let be the angle between f and u.
Du f (x, y) = f u
= kf kkuk cos

Math 55

Directional Derivatives & Gradient

The Gradient Vector


Theorem
Suppose f is a differentiable function of x and y. The
maximum value of Du f is kf k and it occurs when u is in the
same direction as f .
Proof. Let be the angle between f and u.
Du f (x, y) = f u
= kf kkuk cos
= kf k cos

Math 55

Directional Derivatives & Gradient

The Gradient Vector


Theorem
Suppose f is a differentiable function of x and y. The
maximum value of Du f is kf k and it occurs when u is in the
same direction as f .
Proof. Let be the angle between f and u.
Du f (x, y) = f u
= kf kkuk cos
= kf k cos
and the result follows since the maximum value of cos is 1 and
is attained when = 0, i.e., f and u are in the same direction.

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y)

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y) = h0.04x,

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y) = h0.04x, 0.02yi

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y) = h0.04x, 0.02yi
h(50, 80) = h0.04(50), 0.02(80)i

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y) = h0.04x, 0.02yi
h(50, 80) = h0.04(50), 0.02(80)i = h2, 1.6i

Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y) = h0.04x, 0.02yi
h(50, 80) = h0.04(50), 0.02(80)i = h2, 1.6i
and the maximum rate of change of h (Du h) is
kh(50, 80)k
Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y) = h0.04x, 0.02yi
h(50, 80) = h0.04(50), 0.02(80)i = h2, 1.6i
and the maximum rate of change of h (Du h) is
p
kh(50, 80)k = (2)2 + (1.6)2
Math 55

Directional Derivatives & Gradient

Example
Example
Suppose that the height of a hill above sea level is modelled by
h(x, y) = 1000 0.02x2 0.01y 2 . Standing at the point (50, 80),
in which direction is the elevation changing fastest? What is
the maximum rate of change of the elevation?
Solution: The maximum rate of change occurs in the
direction of h(50, 80).
h(x, y) = h0.04x, 0.02yi
h(50, 80) = h0.04(50), 0.02(80)i = h2, 1.6i
and the maximum rate of change of h (Du h) is
p
kh(50, 80)k = (2)2 + (1.6)2 = 2.5612.
Math 55

Directional Derivatives & Gradient

The Gradient Vector

Math 55

Directional Derivatives & Gradient

Exercises
1

Find the directional derivative of the given function at the given


point in the direction of the vector v.

a. f (r, ) = er sin , 0, 3 , v = 3 2

Math 55

Directional Derivatives & Gradient

Exercises
1

Find the directional derivative of the given function at the given


point in the direction of the vector v.

a. f (r, ) = er sin , 0, 3 , v = 3 2

x
b. g(x, y, z) = y+z
, (4, 1, 1), v = h1, 2, 3i

Math 55

Directional Derivatives & Gradient

Exercises
1

Find the directional derivative of the given function at the given


point in the direction of the vector v.

a. f (r, ) = er sin , 0, 3 , v = 3 2

x
b. g(x, y, z) = y+z
, (4, 1, 1), v = h1, 2, 3i

If f (x, y) = xey , find the rate


 of change of f at P (2, 0) in the
direction from P to Q 12 , 2 . In what direction is f changing
fastest? What is the maximum rate of change of f ?

Math 55

Directional Derivatives & Gradient

Exercises
1

Find the directional derivative of the given function at the given


point in the direction of the vector v.

a. f (r, ) = er sin , 0, 3 , v = 3 2

x
b. g(x, y, z) = y+z
, (4, 1, 1), v = h1, 2, 3i

If f (x, y) = xey , find the rate


 of change of f at P (2, 0) in the
direction from P to Q 12 , 2 . In what direction is f changing
fastest? What is the maximum rate of change of f ?

Find all points for which the direction of fastest change of


f (x, y) = x2 + y 2 2x 4y is + .

Math 55

Directional Derivatives & Gradient

Exercises
1

Find the directional derivative of the given function at the given


point in the direction of the vector v.

a. f (r, ) = er sin , 0, 3 , v = 3 2

x
b. g(x, y, z) = y+z
, (4, 1, 1), v = h1, 2, 3i

If f (x, y) = xey , find the rate


 of change of f at P (2, 0) in the
direction from P to Q 12 , 2 . In what direction is f changing
fastest? What is the maximum rate of change of f ?

Find all points for which the direction of fastest change of


f (x, y) = x2 + y 2 2x 4y is + .

If f and g are diffentiable functions


  of x and y, show that
f
gf f g
=
.
(f g) = f g + gf and
g
g2

Math 55

Directional Derivatives & Gradient

Exercises
1

Find the directional derivative of the given function at the given


point in the direction of the vector v.

a. f (r, ) = er sin , 0, 3 , v = 3 2

x
b. g(x, y, z) = y+z
, (4, 1, 1), v = h1, 2, 3i

If f (x, y) = xey , find the rate


 of change of f at P (2, 0) in the
direction from P to Q 12 , 2 . In what direction is f changing
fastest? What is the maximum rate of change of f ?

Find all points for which the direction of fastest change of


f (x, y) = x2 + y 2 2x 4y is + .

If f and g are diffentiable functions


  of x and y, show that
f
gf f g
=
.
(f g) = f g + gf and
g
g2

Let f be a function of x and y and consider the points A(1, 3),


B(3, 3), C(1, 7) and D(6, 15). Given that DAB
~ f (1, 3) = 3 and
DAC
~ f (1, 3) = 6, find the directional derivative of f at A in the
~
direction of the vector AD.
Math 55

Directional Derivatives & Gradient

References

Stewart, J., Calculus, Early Transcendentals, 6 ed., Thomson


Brooks/Cole, 2008

Dawkins, P., Calculus 3, online notes available at


http://tutorial.math.lamar.edu/

Math 55

Directional Derivatives & Gradient

You might also like