Chapter 4: Partial Differentiation
Section 4.3: Chain Rule
Example 4.3.6
The composition of f⁡x,y=ln⁡3⁢x2+4⁢y2 with xr,s=3 r+2 s,yr,s=5 r−7 s forms the function Fr,s=fxr,s,yr,s. Obtain the partial derivatives Fr and Fs by appropriate forms of the chain rule, and again by writing the rule for F explicitly. Show that the results agree.
Solution
Mathematical Solution
An application of the chain rule gives
Fr
=fx xr+fy yr
=18⁢x3⁢x2+4⁢y2+40⁢y3⁢x2+4⁢y2
=18⁢3⁢r+2⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2+40⁢5⁢r−7⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2
=2⁢127⁢r−122⁢s127⁢r2−244⁢r⁢s+208⁢s2
and
Fs
=fx xs+fy ys
=12⁢x3⁢x2+4⁢y2−56⁢y3⁢x2+4⁢y2
=12⁢3⁢r+2⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2−56⁢5⁢r−7⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2
=4⁢104 s−61 r127⁢r2−244⁢r⁢s+208⁢s2
Writing Fr,s=fxr,s,yr,s=ln⁡127⁢r2−244⁢r⁢s+208⁢s2 explicitly gives Fr=2⁢127⁢r−122⁢s127⁢r2−244⁢r⁢s+208⁢s2 and Fs=4⁢104 s−61 r127⁢r2−244⁢r⁢s+208⁢s2, in agreement with the chain-rule results.
Maple Solution - Interactive
Formal statement of the relevant chain rules
Context Panel: Differentiate≻With Respect To≻r
fxr,s,yr,s→differentiate w.r.t. rD1⁡f⁡x⁡r,s,y⁡r,s⁢∂∂r⁢x⁡r,s+D2⁡f⁡x⁡r,s,y⁡r,s⁢∂∂r⁢y⁡r,s
Context Panel: Differentiate≻With Respect To≻t
fxr,s,yr,s→differentiate w.r.t. sD1⁡f⁡x⁡r,s,y⁡r,s⁢∂∂s⁢x⁡r,s+D2⁡f⁡x⁡r,s,y⁡r,s⁢∂∂s⁢y⁡r,s
It is possible to obtain notational simplifications interactively, via the Typesetting Rules Assistant in the View menu. However, this is a tedious multistep process, so will not be pursued here.
Implement the chain rule
Context Panel: Assign Function
fx,y=ln⁡3⁢x2+4⁢y2→assign as functionf
Context Panel: Assign Name
X=3 r+2 s→assign
Y=5 r−7 s→assign
Calculus palette: Partial and ordinary differential operators Press the Enter key.
Context Panel: Evaluate at a Point≻x=X,y=Y
Context Panel: Simplify≻Simplify
∂∂ x fx,y ⅆⅆ r X+∂∂ y fx,y ⅆⅆ r Y
18⁢x3⁢x2+4⁢y2+40⁢y3⁢x2+4⁢y2
→evaluate at point
18⁢3⁢r+2⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2+40⁢5⁢r−7⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2
= simplify
2⁢127⁢r−122⁢s127⁢r2−244⁢r⁢s+208⁢s2
∂∂ x fx,y ⅆⅆ s X+∂∂ y fx,y ⅆⅆ s Y
12⁢x3⁢x2+4⁢y2−56⁢y3⁢x2+4⁢y2
12⁢3⁢r+2⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2−56⁢5⁢r−7⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2
−4⁢61⁢r−104⁢s127⁢r2−244⁢r⁢s+208⁢s2
Obtain Fr and Fs from the explicit representation Fr,s=fxr,s,yr,s
Calculus palette: Partial differentiation operator
Context Panel: Evaluate and Display Inline
∂∂ r fX,Y = 254⁢r−244⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2= simplify 2⁢127⁢r−122⁢s127⁢r2−244⁢r⁢s+208⁢s2
∂∂ s fX,Y = −244⁢r+416⁢s3⁢3⁢r+2⁢s2+4⁢5⁢r−7⁢s2= simplify −4⁢61⁢r−104⁢s127⁢r2−244⁢r⁢s+208⁢s2
Maple Solution - Coded
Initialize
Simplified Maple notation is available if the commands to the right are first executed.
interfacetypesetting=extended:Typesetting:-Suppressxr,s,yr,s:Typesetting:-Settingsuserep=true:
difffxr,s,yr,s,r
D1⁡f⁡x,y⁢xr+D2⁡f⁡x,y⁢yr
difffxr,s,yr,s,s
D1⁡f⁡x,y⁢xs+D2⁡f⁡x,y⁢ys
Although the chain rules for this problem could be written as Fr=fx xr+fy yr and Fs=fx xs+fy ys, Maple uses the D-operator notation to express the partial derivatives fx and fy, and cannot suppress the arguments of f once suppression of arguments has been applied to x and y.
Restore the variables x and y.
Typesetting:-Unsuppressxr,s,yr,s:
Define the function f.
f≔x,y→ln⁡3⁢x2+4⁢y2:
Assign xr,s and yr,s to the names X and Y, respectively.
X≔3 r+2 s:Y≔5 r−7 s:
Apply the simplify and diff commands.
simplifyD1fX,Y diffX,r+D2fX,Y diffY,r
simplifyD1fX,Y diffX,s+D2fX,Y diffY,s
Obtain Fr and Fs from an explicit representation of Fr,s
Using the diff and simplify commands, explicitly differentiate fxr,s,yr,s.
simplifydifffX,Y,r
simplifydifffX,Y,s
<< Previous Example Section 4.3 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