Chapter 4: Partial Differentiation
Section 4.4: Directional Derivative
Example 4.4.2
At the point P:1,1,0, and in the direction of the point Q:2,−3,6, obtain the directional derivative of fx,y,z=x3−x y2−z.
Solution
Mathematical Solution
Let v=Q−P = 2−36−110 = 1−46 be the vector from point P to point Q.
Let u=v/v = v/53 be the unit vector from point P in the direction of point Q,
Let R=P+t u be the line through P in the direction defined by u. The parametric equations of this line are
x=1+t53,y=1−4 t53,z=6 t53
Along this line the function values of f are given by
wt=fxt,yt,zt=4 t53−553⁢t2−152809⁢t3⁢53
The requisite directional derivative is then w′0=4/53.
Alternatively, obtain the vector ∇fx=a|f(x)P = fx i+fy j+fz kx=a|f(x)P = 2−2−1 and compute its dot product with u so that
DufP=2−2−1·1531−46=453
Maple Solution - Interactive
Initialize
Tools≻Load Package: Student Multivariate Calculus
Loading Student:-MultivariateCalculus
Context Panel: Assign Name
f=x3−x y2−z→assign
v=1,−4,6→assign
u=v/v2→assign
Instant answer via the Context Panel
Type the name f. Context Panel: Evaluate and Display Inline
Context Panel: Student Multivariate Calculus≻Differentiate≻Directional Derivative Fill in the "Variables, Point, and Vector" dialog as shown in Figure 4.4.2(a) Click the OK button.
Figure 4.4.2(a) Variables, Point, and Vector dialog
f = x3−x⁢y2−z→directional derivative453⁢53
Obtain ∇fx=a|f(x)P
Context Panel: Student Multivariate Calculus≻Differentiate≻Gradient (See Figure 4.4.2(b).)
Context Panel: Select Element≻1
Context Panel: Assign to a Name≻Gf
Figure 4.4.2(b) Gradient dialog
x3−x y2−z→gradient2−2−1→select entry 12−2−1→assign to a nameGf
Obtain DufP=(∇fx=a|f(x)P)·u
Common Symbols palette: Dot product operator
Context Panel: Evaluate and Display Inline
Gf·u = 453⁢53
Solution from first principles:
Obtain R=P+t u, the line through P with direction u
Write a sequence of point P and unit vector u.
Context Panel: Student Multivariate Calculus≻ Lines & Planes≻Line
Context Panel: Student Multivariate Calculus≻ Lines & Planes≻Representation≻parametric (See Figure 4.4.2(c).)
Context Panel: Assign to a Name≻L
Figure 4.4.2(c) Line representation dialog
1,1,0,u→make line<< Line 1 >>→representationx=1+t⁢5353,y=1−4⁢t⁢5353,z=6⁢t⁢5353→assign to a nameL
Obtain wt=fxt,yt,zt and DufP=w′0
Expression palette: Evaluation template Press the Enter key.
Context Panel: Simplify≻Simplify
Context Panel: Differentiate≻With Respect To≻t
Context Panel: Evaluate at a Point≻t=0
fx=a|f(x)L
1+153⁢t⁢533−1+153⁢t⁢53⁢1−453⁢t⁢532−653⁢t⁢53
= simplify
453⁢t⁢53−553⁢t2−152809⁢t3⁢53
→differentiate w.r.t. t
453⁢53−1053⁢t−452809⁢t2⁢53
→evaluate at point
453⁢53
Maple Solution - Coded
Install the Student MultivariateCalculus package.
withStudent:-MultivariateCalculus:
Define f.
f≔x3−x y2−z:
Define v as a list.
v≔1,−4,6:
Obtain the directional derivative
Apply the DirectionalDerivative command.
DirectionalDerivativef,x,y,z=1,1,0,v
There is a DirectionalDerivative command in the Student VectorCalculus package, and a DirectionalDiff command in the Physics:-Vectors package. These alternatives will not be explored further; instead, the following two computations are provided.
Compute DufP=(∇fx=a|f(x)P)·u
Apply the Gradient command, evaluating the resulting vector at point P.
Gf≔Gradientf,x,y,z=1,1,0
Apply to the list v the convert/Vector command, then apply the Normalize command to normalize the resulting vector, thereby obtaining the unit vector u.
V≔convertv,Vector:u≔NormalizeV
Invoke the Dotproduct command.
DotProductGf,u = 453⁢53
Obtain the directional derivative from first principles
Use the Line and GetRepresentation commands to obtain the parametric form of the line through P in the direction of u.
L≔GetRepresentationLine1,1,0,u,form=parametric
x=1+153⁢t⁢53,y=1−453⁢t⁢53,z=653⁢t⁢53
Use the eval command to obtain the value of f along line L, then apply the simplify command.
w≔simplifyevalf,L
Apply the diff command to wt, then the eval command to obtain w′0.
evaldiffw,t,t=0
<< Previous Example Section 4.4 Next Example >>
© Maplesoft, a division of Waterloo Maple Inc., 2024. All rights reserved. This product is protected by copyright and distributed under licenses restricting its use, copying, distribution, and decompilation.
For more information on Maplesoft products and services, visit www.maplesoft.com
Download Help Document