Chapter 4: Partial Differentiation
Section 4.10: Optimization on Closed Domains
Example 4.10.5
Find the extreme values of the function fx,y=5 +x2 y−3 x+5 y2/20 on the domain R consisting of the region bounded by the parabola y=x2 and the line y=4.
Solution
Mathematical Solution
The unconstrained extrema are found by solving the equations fx=fy=0. Thus, the equations
110⁢x⁢y−320=0,120⁢x2+12⁢y=0
are solved for the one real solution −151/3,−152/3/10 ≐ −2.5,−0.61, which is outside R.
Along the constraint y=x2, find the extrema of fx,x2=6 x4−3 x+5/20 by solving the equation
ddxfx,x2=65⁢x3−320=0
for its one real solution x=1/2. Hence, find f1/2,1/4=31/160 ≐ 0.19375.
Along the constraint y=4, find the extrema of fx,4=4 x2−3 x+85/20 by solving the equation
ddxfx,4=25⁢x−320=0
for x=3/8. Hence, find f3/8,4 = 1351/320 ≐ 4.2219.
To take the constraints two at a time, obtain the values of f at −2,4 and 2,4, the intersections of the constraints y=x2 and y=4. Hence, find f−2,4 = 107/20 ≐ 5.35 and f2,4 = 19/4 ≐ 4.75.
Figures 4.10.5(a - c) show, respectively, that portion of the surface z=fx,y residing over the domain R, the graph of fx,x2, and the graph of fx,4.
use plots in module() local p1,p2,p3,f; f:=(x^2*y-3*x+5*y^2+5)/20; p1:=plot3d(f,x=-2..2,y=x^2..4,style=surfacecontour,lightmodel=none); p2:=plot3d(0,x=-2..2,y=x^2..4,shading=xy); p3:=display(p1,p2,lightmodel=none,axes=frame,tickmarks=[5,5,6],orientation=[-35,70,0],scaling=constrained); print(p3); end module: end use:
Figure 4.10.5(a) Surface on R
module() local p1,F; F:=(6*x^4-3*x+5)/20; p1:=plot(F,x=-2..2,0..6,labels=[x,typeset(Eval(` f`,y=x^2))]); print(p1); end module:
Figure 4.10.5(b) fx,x2
module() local p1,G; G:=(4*x^2-3*x+85)/20; p1:=plot(G,x=-2..2,0..6,labels=[x,typeset(Eval(` f`,y=4))]); print(p1); end module:
Figure 4.10.5(c) fx,4
Table 4.10.5(a) lists the local and global extrema found.
f−151/3,−152/3/10=9 153/80+1/4≐0.52745
Critical point not in R
f1/2,1/4=31/160≐0.19375
Local and global minimum
f3/8,4=1351/320≐4.2219
Local minimum
f−2,4=107/20≐5.3500
Local and global maximum
f2,4=19/4≐4.7500
Local maximum
Table 4.10.5(a) Local and global extrema of fx,y on R
Maple Solution - Interactive
Initialize
Context Panel: Assign Function
fx,y=5 +x2 y−3 x+5 y2/20→assign as functionf
Obtain any unconstrained extrema
Calculus palette: Partial-differentiation operator Press the Enter key.
Context Panel: Solve≻Solve (explicit)
∂∂ x fx,y=0,∂∂ y fx,y=0
x⁢y10−320=0,x220+y2=0
→solve
x=−1513,y=−152310,x=15132−I⁢3⁢15132,y=−15132−I⁢3⁢15132210,x=15132+I⁢3⁢15132,y=−15132+I⁢3⁢15132210
Extrema along the constraint y=x2
Context Panel: Differentiate≻With Respect To≻x
Context Panel: Solve≻Solve There is just one real solution to the equation ddxfx,x2=0, namely, x=1/2.
fx,x2
310⁢x4−320⁢x+14
→differentiate w.r.t. x
6⁢x35−320
x=12,x=−14−I⁢34,x=−14+I⁢34
Context Panel: Evaluate and Display Inline
Context Panel: Approximate≻5 (digits)
f1/2,1/4 = 31160→at 5 digits0.19375
Extrema along the constraint y=4
Context Panel: Solve≻Solve
fx,4
15⁢x2−320⁢x+174
2⁢x5−320
x=38
f3/8,4 = 1351320→at 5 digits4.2219
Take the constraints two at a time
Obtain the values of f at −2,4 and 2,4, the intersections of the constraints y=x2 and y=4. Context Panel: Evaluate and Display Inline Context Panel: Approximate≻5 (digits)
f−2,4 = 10720→at 5 digits5.3500
f2,4 = 194→at 5 digits4.7500
Numeric solution via the
The Optimization Assistant is no longer listed in Tools≻Assistants. It is now found in Tools≻Tutors≻Optimization
Type fx,y and press the Enter key. Context Panel: Optimization≻Optimization Assistant
Add the constraints shown in Figure 4.10.5(d). In the Add Constraint box, write y≥x2 and press Add write y≤4 and press Add In the Add Bound box: x=−2..2 and press Add.
Figure 4.10.5(e) shows the Optimization Assistant finding the global minimum.
Figure 4.10.5(f) shows the Optimization Assistant finding the global maximum.
Figure 4.10.5(d) Dialog for adding constraints
Figure 4.10.5(e) Finding the minimum
Figure 4.10.5(f) Finding the maximum
Maple Solution - Coded
Define the function f.
f≔x,y→5 +x2 y−3 x+5 y2/20:
Use the diff command to obtain the equations fx=fy=0, and the solve command to obtain their solution. Note the use of the explicit option.
The real solution −151/3,−152/3/10≐−2.5,−0.61 is outside R.
solvedifffx,y,x=0,difffx,y,y=0,explicit
Take the constraints one at a time
Use the diff and solve commands to obtain critical numbers for f evaluated along the single constraints.
solvedifffx,4,x
38
f3/8,4 = 1351320
solvedifffx,x2,x
12,−14−I⁢34,−14+I⁢34
f1/2,1/4 = 31160
Obtain the values of f at −2,4 and 2,4, the intersections of the constraints y=x2 and y=4.
f−2,4 = 10720
f2,4 = 194
Obtain the extrema numerically with the Maximize and Minimize commands in the Optimization package. These command find local, not global, extrema. Inclusion of the initialpoint option helps in the location of global extrema. Note how the region R is described in these commands.
Optimization:-Maximizefx,y,y≥x2,y≤4, x≥−2,x≤2,initialpoint=x=−1
5.34999999999999964,x=−2.,y=4.
Optimization:-Minimizefx,y,y≥x2,y≤4, x≥−2,x≤2
0.193750000000000006,x=0.499999999993870,y=0.249999999993870
<< Previous Example Section 4.10 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