{VERSION 4 0 "IBM INTEL NT" "4.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 1 }{CSTYLE "2D Math" -1 2 "Times" 0 1 0 0 0 0 0 0 2 0 0 0 0 0 0 1 }{CSTYLE "2D Comment" 2 18 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 256 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 257 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 258 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 259 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 260 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 261 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 262 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 263 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 264 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 265 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 266 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 267 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 268 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 269 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 270 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 271 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 272 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 273 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 274 "" 0 1 0 0 0 0 1 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 275 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 276 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 277 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 278 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 279 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 280 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 281 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 282 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 283 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 284 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 285 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 286 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 287 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 288 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 289 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 290 "BCSYMA" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 291 "BCSYMA" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }{CSTYLE " " -1 292 "BCSYMA" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 293 " " 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 294 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 295 "BCSYMA" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 296 "Verdana" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 297 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 298 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{PSTYLE "Normal" -1 0 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "Heading 1" 0 3 1 {CSTYLE "" -1 -1 "" 1 18 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }1 0 0 0 6 6 0 0 0 0 0 0 -1 0 }{PSTYLE "Head ing 2" 3 4 1 {CSTYLE "" -1 -1 "" 1 14 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }0 0 0 -1 4 4 0 0 0 0 0 0 -1 0 }{PSTYLE "R3 Font 0" -1 256 1 {CSTYLE "" -1 -1 "Times" 0 14 0 0 0 1 2 1 2 0 0 0 0 0 0 1 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "R3 Font 2" -1 257 1 {CSTYLE "" -1 -1 "Courier" 0 11 0 0 0 1 2 1 2 0 0 0 0 0 0 1 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 } {PSTYLE "" 0 258 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 259 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 260 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 261 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 262 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 263 1 {CSTYLE " " -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 264 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 265 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 266 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 267 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 268 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 269 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 270 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE " " 0 271 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 272 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 273 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 274 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 275 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 276 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 277 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 278 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 279 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 280 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 281 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 282 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 283 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }} {SECT 0 {EXCHG {PARA 0 "" 0 "" {TEXT -1 23 "Unit 4: Vector Calculus" } }{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 31 "Chapter \+ 18: The Gradient Vector" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 35 "Section 18.4: Lagrange multipliers" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 9 "Copyright" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 48 "Co pyright * 2001 by Addison Wesley Longman, Inc." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 302 "All rights reserved. No part of this publication may be reproduced, stored in a retrieval sys tem, or transmitted, in any form or by any means, electronic, mechanic al, photocopying, recording, or otherwise, without the prior written p ermission of the publisher. Printed in the United States of America." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {SECT 1 {PARA 3 "" 0 "" {TEXT -1 15 "Initializations" }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart;" } }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 76 "with(plots):\nwith(plottoo ls):\nwith(linalg):\nwith(student):\nread(`pvac.txt`):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 24 "Constrained Optimization" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {EXCHG {PARA 0 "" 0 "" {TEXT -1 75 "Elementary calculus considers cons trained optimization problems of the form" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 258 "" 0 "" {TEXT 256 74 "Find the rectangular box of max imum area if the perimeter is fixed at 100." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 123 "Initially, these problems sre \+ solved by eliminating one of the variables. For example, with the are a of the box written as" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 9 "A := x*y;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 31 "and the pe rimeter constraint as" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "P := 2*x + 2*y = 100;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 34 "the constraint can be solved, for " }{XPPEDIT 18 0 "y=50-x" "6# /%\"yG,&\"#]\"\"\"%\"xG!\"\"" }{TEXT -1 14 ", that is, for" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 16 "Y : = solve(P,y);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 8 "so that " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 18 "Ax := subs(y=Y,A) ;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 91 "The ordinary techniques of differentiation (or plott ing) now lead to the maximum of 625 at " }{XPPEDIT 18 0 "x=y " "6#/%\" xG%\"yG" }{TEXT -1 31 " = 25, as we see from the graph" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 17 "plot(A x,x=0..50);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 30 "or by the analytical device of" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 32 "X [max] := solve(diff(Ax,x)=0,x);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 18 "The corresponding " } {TEXT 257 1 "y" }{TEXT -1 14 "-coordinate is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 27 "Y[max] := subs(x= X[max],Y);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 47 "The rectangle is a square of side 25, and area " }{XPPEDIT 18 0 "25^2=625" "6#/*$\"#D\"\"#\"$D'" }{TEXT -1 1 ". " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 30 "The Lagrang e Multiplier Method" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 330 "The Lagrange multiplier technique is an alternat e method for solving constrained optimization problems. By making an \+ elegant application of the gradient vector, it avoids the algebra of u sing the constraint to eliminate one of the variables. The method of \+ Lagrange multipliers is illustrated through the following five example s." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 12 "Example 18. 7" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 133 "In this first example, we show how the Lagrange-multiplier method selects points at which the level curves of the objective function " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 85 " are tang ent to the constraint curve. To do this, we will find the extreme val ue of " }{XPPEDIT 18 0 "f(x,y)=x*y" "6#/-%\"fG6$%\"xG%\"yG*&F'\"\"\"F( F*" }{TEXT -1 32 " along the constraining ellipse " }{XPPEDIT 18 0 "g( x,y)=x^2+4*y^2-8" "6#/-%\"gG6$%\"xG%\"yG,(*$F'\"\"#\"\"\"*&\"\"%F,*$F( F+F,F,\"\")!\"\"" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 68 "The objective function (what is maximized or minimized) is therefore" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 9 "f := x*y;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 51 "and the constraint curve is defined by the function" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "g := x^2 + \+ 4*y^2 - 8;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 41 "with the actual constraint equation being " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 29 "constraint_equation := g = 0;" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 48 "Figure 8.11 shows the constraint ellipse in the " }{XPPEDIT 18 0 "xy" "6#%#x yG" }{TEXT -1 31 "-plane, along with the surface " }{XPPEDIT 18 0 "z=f (x,y)" "6#/%\"zG-%\"fG6$%\"xG%\"yG" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 442 "a := sqrt( 8):\nb := sqrt(2):\nxt := a*cos(t):\nyt := b*sin(t):\nft := subs(\{x=x t, y=yt\},f):\np1 := spacecurve([xt,yt,.01], t=0..2*Pi, color = black, thickness = 3):\np2 := plot3d(f,x=-2..2,y=-2..2,style=hidden,color=bl ack):\np3 := plot3d(0, x = -a..a, y = -2..2, color = cyan, style=wiref rame):\ndisplay([p||(1..3)],scaling=constrained, tickmarks=[3,3,3], la bels=[`x `,` y`,`z `], labelfont=[TIMES,ITALIC,12],axes=frame, o rientation =[-25,70]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 85 "By way of interpretation, imagi ne being restricted to walking on this ellipse in the " }{TEXT 283 2 " xy" }{TEXT -1 32 "-plane. Overhead, the function " }{XPPEDIT 18 0 "f( x,y)" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 158 " determines the shape of t he ceiling. You want to know where, on the elliptic path being walked , you will find the highest and lowest points of the ceiling. " }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 33 "The inter section of the cylinder " }{XPPEDIT 18 0 "g(x,y)=0" "6#/-%\"gG6$%\"xG% \"yG\"\"!" }{TEXT -1 17 " and the surface " }{XPPEDIT 18 0 "z=f(x,y)" "6#/%\"zG-%\"fG6$%\"xG%\"yG" }{TEXT -1 124 " is the space curve (thin \+ black) shown in Figure 18.12, below. Included is a rendition of the e llipse (thick black) in the " }{XPPEDIT 18 0 "xy" "6#%#xyG" }{TEXT -1 54 "-plane. Clearly, there are two maxima and two minima." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 477 "p1 := spacecurve([xt,yt,ft], t=0..2*Pi, color = black, thickness = 3):\n p2 := spacecurve([xt,yt,0], t=0..2*Pi, color = black, thickness = 6): \np3 := plot3d(0, x = -a..a, y = -2..2, color = cyan, style=wireframe) :\ndots:=spacecurve(\{[[-3,-2,-2],[-3,2,-2],[3,2,-2]]\}, color=black, \+ linestyle=2):\ndisplay([p||(1..3),dots], axes = frame, orientation = [ 45,70], scaling = constrained, labels=[` x`,`y `,`z `], labelfon t=[TIMES,ITALIC,12], tickmarks=[5,5,5], orientation=[-40,75]);" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{SECT 1 {PARA 4 "" 0 "" {TEXT -1 39 "Maple Graphics - Generating Figure 8.12" }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 87 "Write the constr aint ellipse in standard form by dividing through by 8 so that the for m" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 266 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "x^2/(a^2)+y^2/(b^2) = 1;" "6#/,&*&%\"xG\"\"#*$%\"aGF'! \"\"\"\"\"*&%\"yGF'*$%\"bGF'F*F+F+" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 12 "is obtained." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "constraint_equation/8;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 29 "In this form, we realize that" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 27 "a := sqrt(8);\nb := sqrt( 2);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 " " 0 "" {TEXT -1 56 "and a convenient parametric form of the ellipse i s then" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 31 "xt := a*cos(t);\nyt := b*sin(t);" }}}{EXCHG {PARA 0 " > " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 13 "The \+ function " }{XPPEDIT 18 0 "f(x,y);" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 39 ", evaluated along this ellipse, is then" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 27 "ft := subs(\{x=xt , y=yt\},f);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 20 "Plot the heights of " }{XPPEDIT 18 0 "f(x ,y);" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 79 " above the ellipse as a spa ce curve. Include the ellipse itself in the figure." }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 291 "p1 := sp acecurve([xt,yt,ft], t=0..2*Pi, color = black, thickness = 3):\np2 := \+ spacecurve([xt,yt,0], t=0..2*Pi, color = green, thickness = 6):\np3 := plot3d(0, x = -a..a, y = -2..2, color = red, style=wireframe):\ndispl ay([p||(1..3)], axes = boxed, orientation = [45,75], scaling = constra ined);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 149 "The green path is the constraint ellipse along which we walk. The black curve is the contour of the ceiling directl y above the constraint ellipse. " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 99 "The contour map in Figure 8.13 is yet another way of look ing at this problem. The level curves of " }{XPPEDIT 18 0 "f(x,y)" "6 #-%\"fG6$%\"xG%\"yG" }{TEXT -1 63 " (black) and the constraint ellipse (red) are all drawn in the " }{XPPEDIT 18 0 "xy" "6#%#xyG" }{TEXT -1 7 "-plane." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 " " {MPLTEXT 1 0 458 "gx := implicitplot(g = 0, x = -3..3, y = -2..2, co lor=red):\np1 := contourplot(f, x =-3..3, y = -3..3, contours = [1,2,3 ,-1,-2,-3], color = black):\np2 := textplot(\{[-2.1,2.5,`f(x,y) < 0`], [2.2,2.5,`f(x,y) > 0`], \n[-2.1,-2.5,`f(x,y) > 0`], [2.2,-2.5,`f(x,y) \+ < 0`], [0,1,`g(x,y) = 0`]\}, font=[TIMES,ROMAN,12]):\np3 := display([p 1,p2,gx], axes = boxed, scaling = constrained, xtickmarks=7, ytickmark s=[-1,0,1], labels=[x,`y `], labelfont=[TIMES,ITALIC,12]):\np3;" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 23 "Where a level curve of " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"f G6$%\"xG%\"yG" }{TEXT -1 68 " cuts through the graph of g = 0, there c an't be a stationary value." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 25 "Where the level curve of " }{XPPEDIT 18 0 "f(x, y)" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 48 " is tangent to the graph of g = 0, the value of " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\"yG" } {TEXT -1 52 " becomes stationary because it \"pauses\" momentarily." } }{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 14 "The meth od of " }{TEXT 284 8 "Lagrange" }{TEXT -1 1 " " }{TEXT 285 11 "multipl iers" }{TEXT -1 39 " seeks points were the level curves of " } {XPPEDIT 18 0 "f" "6#%\"fG" }{TEXT -1 37 " are tangent to the constrai nt curve " }{XPPEDIT 18 0 "g=0" "6#/%\"gG\"\"!" }{TEXT -1 1 "." }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 65 "It does t his by looking for points where the gradient vectors of " }{XPPEDIT 18 0 "f" "6#%\"fG" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "g" "6#%\"gG" } {TEXT -1 34 " are colinear. This happens where" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 267 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "grad( f)=MATRIX([[y],[x]])" "6#/-%%gradG6#%\"fG-%'MATRIXG6#7$7#%\"yG7#%\"xG " }{TEXT -1 2 " " }}{PARA 0 "" 0 "" {TEXT -1 17 "is a multiple of " } }{PARA 268 "" 0 "" {XPPEDIT 18 0 "grad(g)=MATRIX([[2*x],[8*y]])" "6#/- %%gradG6#%\"gG-%'MATRIXG6#7$7#*&\"\"#\"\"\"%\"xGF/7#*&\"\")F/%\"yGF/" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 41 "where we obtain the gradients in Maple as" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 43 "gf := \+ grad(f, [x,y]);\ngg := grad(g, [x,y]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 91 "Figure 18.14 \+ (below) shows the gradient vectors at the four points where they are c olinear." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 450 "gft := subs(\{x=xt,y=yt\},op(gf)):\nggt := subs(\{x= xt,y=yt\},op(gg)):\nf1 := z -> arrow(subs(t=z,[xt,yt]), subs(t=z,op(gf t)),.2,.4,.3, color=black):\nf2 := z -> arrow(subs(t=z,[xt,yt]), subs( t=z,op(ggt)),.2,.4,.3, color=cyan):\nf3 := z -> display([f1(z),f2(z)]) :\np4 := display([f3(Pi/4),f3(3*Pi/4),f3(5*Pi/4),f3(7*Pi/4)]):\ndispla y([p4,gx,p1], scaling=constrained, axes=box, xtickmarks=7, ytickmarks= [-1,0,1], labels=[x,`y `], labelfont=[TIMES,ITALIC,12]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 183 "We can do better with the live medium of a computer screen. W e can simulate a trip around the ellipse, showing the two gradient vec tors encountered at each point. Thus, we evaluate " }{XPPEDIT 18 0 "g rad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "grad(g )" "6#-%%gradG6#%\"gG" }{TEXT -1 19 " on the ellipse via" }}{PARA 0 " " 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 65 "gft \+ := subs(\{x=xt,y=yt\},op(gf));\nggt := subs(\{x=xt,y=yt\},op(gg));" }} }{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 89 "then generate the following animation. The constraint el lipse is drawn in red, but grad(" }{TEXT 270 1 "g" }{TEXT -1 41 ") is \+ drawn in cyan. The level curves of " }{TEXT 271 1 "f" }{TEXT -1 32 " \+ are drawn in black, as is grad(" }{TEXT 272 1 "f" }{TEXT -1 2 ")." }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 291 "f1 := z -> arrow(subs(t=z,[xt,yt]), subs(t=z,op(gft)),.2,.4,.3, color=black):\nf2 := z -> arrow(subs(t=z,[xt,yt]), subs(t=z,op(ggt)), .2,.4,.3, color=cyan):\nf3 := z -> display([f1(z),f2(z)]):\np3 := disp lay([seq(f3(.05*Pi*k),k=0..39)],insequence=true):\ndisplay([gx,p1,p3], scaling=constrained);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 39 "This example shows two things. \+ First, " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 22 " \+ (black) never equals " }{XPPEDIT 18 0 "grad(g)" "6#-%%gradG6#%\"gG" } {TEXT -1 42 " (cyan) which is considerably longer than " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 39 ". Second, at two point s of tangency, " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 33 " points in the same direction as " }{XPPEDIT 18 0 "grad(g)" "6# -%%gradG6#%\"gG" }{TEXT -1 98 ", but at the other two points of tangen cy, the two gradients point in exactly opposite directions." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 74 "The analytic co ndition which expresses the colinearity of the gradients is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 259 "" 0 "" {XPPEDIT 18 0 "grad(f) = l ambda*grad(g);" "6#/-%%gradG6#%\"fG*&%'lambdaG\"\"\"-F%6#%\"gGF*" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 48 "which sta nds for the pair of component equations" }}{PARA 260 "" 0 "" {XPPEDIT 18 0 "f[x] = lambda*g[x];" "6#/&%\"fG6#%\"xG*&%'lambdaG\"\"\"&%\"gG6#F 'F*" }}{PARA 261 "" 0 "" {XPPEDIT 18 0 "f[y] = lambda*g[y];" "6#/&%\"f G6#%\"yG*&%'lambdaG\"\"\"&%\"gG6#F'F*" }}{PARA 0 "" 0 "" {TEXT -1 0 " " }}{PARA 0 "" 0 "" {TEXT -1 31 "The factor of proportionality, " } {XPPEDIT 18 0 "lambda;" "6#%'lambdaG" }{TEXT -1 16 ", is called the " }{TEXT 274 19 "Lagrange multiplier" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 50 "There are three unknowns, namely, the coordinates " }{XPPEDIT 18 0 "x" "6#%\"xG" }{TEXT -1 5 " \+ and " }{XPPEDIT 18 0 "y" "6#%\"yG" }{TEXT -1 30 ", and the Lagrange mu ltiplier " }{XPPEDIT 18 0 "lambda" "6#%'lambdaG" }{TEXT -1 47 ". Thes e are determined by the two equations in" }}{PARA 269 "" 0 "" {XPPEDIT 18 0 "grad(f) = lambda*grad(g);" "6#/-%%gradG6#%\"fG*&%'lambd aG\"\"\"-F%6#%\"gGF*" }}{PARA 0 "" 0 "" {TEXT -1 28 "and the constrain t equation " }}{PARA 270 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "g(x,y) =0" "6#/-%\"gG6$%\"xG%\"yG\"\"!" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 64 "Table 18.1 lists the equa tions, the solutions, and the value of " }{XPPEDIT 18 0 "f(x,y)" "6#-% \"fG6$%\"xG%\"yG" }{TEXT -1 23 " at each extreme point." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 33 " Equations \+ " }{XPPEDIT 18 0 "lambda" "6#%'lambdaG" }{TEXT -1 19 " \+ " }{XPPEDIT 18 0 "``(x,y)" "6#-%!G6$%\"xG%\"yG" } {TEXT -1 12 " " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\" yG" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 60 "=========== \+ === ====== =====" }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "x=8*lambda*y" "6#/%\"xG*(\"\")\"\"\"%'lambdaGF'% \"yGF'" }{TEXT -1 23 " " }{XPPEDIT 18 0 "1/4" "6 #*&\"\"\"F$\"\"%!\"\"" }{TEXT -1 19 " " }{XPPEDIT 18 0 "``(2,1)" "6#-%!G6$\"\"#\"\"\"" }{TEXT -1 16 " 2" } }{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "y=2*lambda*x" "6#/%\"y G*(\"\"#\"\"\"%'lambdaGF'%\"xGF'" }{TEXT -1 23 " \+ " }{XPPEDIT 18 0 "1/4" "6#*&\"\"\"F$\"\"%!\"\"" }{TEXT -1 17 " \+ " }{XPPEDIT 18 0 "``(-2,-1)" "6#-%!G6$,$\"\"#!\"\",$\"\"\"F( " }{TEXT -1 14 " 2" }}{PARA 0 "" 0 "" {TEXT -1 1 " " } {XPPEDIT 18 0 "x^2+4*y^2=8" "6#/,&*$%\"xG\"\"#\"\"\"*&\"\"%F(*$%\"yGF' F(F(\"\")" }{TEXT -1 12 " " }{XPPEDIT 18 0 "-1/4" "6#,$*&\" \"\"F%\"\"%!\"\"F'" }{TEXT -1 18 " " }{XPPEDIT 18 0 " ``(2,-1)" "6#-%!G6$\"\"#,$\"\"\"!\"\"" }{TEXT -1 12 " " } {XPPEDIT 18 0 "-2" "6#,$\"\"#!\"\"" }}{PARA 0 "" 0 "" {TEXT -1 35 " \+ " }{XPPEDIT 18 0 "-1/4" "6#,$*&\"\"\"F %\"\"%!\"\"F'" }{TEXT -1 18 " " }{XPPEDIT 18 0 "``(-2 ,1)" "6#-%!G6$,$\"\"#!\"\"\"\"\"" }{TEXT -1 12 " " } {XPPEDIT 18 0 "-2" "6#,$\"\"#!\"\"" }}{PARA 0 "" 0 "" {TEXT -1 50 "___ _______________________________________________" }}{PARA 0 "" 0 "" {TEXT -1 49 " Table 18.1" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 61 "The solut ions in Table 18.1 are obtained in Maple as follows." }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 80 "The simplest way to equ ate coefficients of the two gradient vectors is with the " }{TEXT 258 6 "equate" }{TEXT -1 18 " command from the " }{TEXT 259 7 "student" } {TEXT -1 72 " package. Note how we use the notationally simpler Lagra nge multiplier " }{TEXT 273 1 "m" }{TEXT -1 12 " instead of " } {XPPEDIT 18 0 "lambda;" "6#%'lambdaG" }{TEXT -1 1 "." }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "q := equa te(gf, m*gg);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 52 "So far, we have two equations in t he three unknowns " }{TEXT 260 1 "x" }{TEXT -1 2 ", " }{TEXT 261 1 "y " }{TEXT -1 30 ", and the Lagrange multiplier " }{TEXT 262 1 "m" } {TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 176 "The third equation is the constraint equation g = 0. Co nsequently, we solve three equations in three unknowns. (Note that th e first two equations are already in a set called " }{XPPEDIT 18 0 "q " "6#%\"qG" }{TEXT -1 138 ", so to insert the remaining equation into \+ that set, use the operator for the union of sets, thereby generating a set of three equations.)" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 40 "q1 := solve(q union \{g = 0\}, \{x, y, m\});" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 110 "There are 4 possible extreme values corr esponding to the critical points (2, 1), (-2, -1), -2, 1), and (2, -1) " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 51 "for k from 1 to 4 do\nP||k := subs(q1[k],[x,y]);\nod; " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 14 "The values of " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$% \"xG%\"yG" }{TEXT -1 27 " at the critical points are" }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 47 "for k fro m 1 to 4 do\nsubs(q1[k],[[x,y],f]);\nod;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 52 "Hence, there \+ are two places on the constraint curve " }{XPPEDIT 18 0 "g(x,y)=0" "6# /-%\"gG6$%\"xG%\"yG\"\"!" }{TEXT -1 7 " where " }{XPPEDIT 18 0 "f(x,y) " "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 64 " attains a maximum and two plac es on the constraint curve where " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$ %\"xG%\"yG" }{TEXT -1 19 " attains a minimum." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 10 "f(2,1) = 2" }}{PARA 0 "" 0 "" {TEXT -1 12 "f(-2,-1) = 2" }}{PARA 0 "" 0 "" {TEXT -1 12 "f(-2,1) = -2" }}{PARA 0 "" 0 "" {TEXT -1 13 "f(2, -1) = -2" }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}} {SECT 1 {PARA 3 "" 0 "" {TEXT -1 12 "Example 18.8" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 301 "In this second ex ample, we will find the Lagrange multiplier is zero, so an extreme poi nt occurs where the constraint is not operative. The extreme point is on the constraint, but it is also a critical point for the unconstrai ned objective function. To illustrate this, we find the extreme value s of" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 11 "f := x^2*y;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 26 "subject to the constrain t " }{XPPEDIT 18 0 "g(x,y)=0" "6#/-%\"gG6$%\"xG%\"yG\"\"!" }{TEXT -1 8 ", where " }{XPPEDIT 18 0 "g(x,y)" "6#-%\"gG6$%\"xG%\"yG" }{TEXT -1 12 " is given by" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 14 "g := x + y -3;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 39 "Figure 18.15 \+ (below) shows the surface " }{XPPEDIT 18 0 "z=f(x,y)" "6#/%\"zG-%\"fG6 $%\"xG%\"yG" }{TEXT -1 6 ", the " }{XPPEDIT 18 0 "xy" "6#%#xyG" } {TEXT -1 26 "-plane, constraint (line) " }{XPPEDIT 18 0 "g(x,y)=0" "6# /-%\"gG6$%\"xG%\"yG\"\"!" }{TEXT -1 36 ", and the intersection of the \+ plane " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 271 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "x+y=3" "6#/,&%\"xG\"\"\"%\"yGF&\"\"$" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 17 "with the surface " }{XPPEDIT 18 0 "z=f(x,y)" "6#/%\"zG-%\"fG6$%\"xG%\"yG" }{TEXT -1 3 ". " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 436 "F \+ := subs(y = 3-x,f):\np4 := spacecurve([x,3-x,F, x = -2..4], color = bl ack, thickness=3):\np5 := spacecurve([x,3-x,0,x=-2..4], color = red, t hickness=3):\np6 := plot3d(0,x=-2..4,y=-1..5,color=cyan):\np7 := plot3 d(f,x = -2..4,y=-1..5,color=black,style=wireframe):\ndisplay([p||(4..7 )],axes=frame, labels=[x,y,z], view=[-2..4,-1..5,-2..20], orientation= [-60,60], tickmarks=[7,7,5], labels=[`x `,` y`,`z `], labelfont= [TIMES,ITALIC,12]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 35 "The space curve in which the plane " }{XPPEDIT 18 0 "x+y=3" "6#/,&%\"xG\"\"\"%\"yGF&\"\"$" }{TEXT -1 32 " intersects the surface, namely," }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "Z := subs(y = 3-x,f);" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 26 " is shown in Figure 18.16." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 108 "plot(Z, x = -2..4, co lor=black, xtickmarks=7, ytickmarks=8, labels=[x,`z `], labelfont=[T IMES,ITALIC,12]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 12 "It suggests " }{XPPEDIT 18 0 "f(x, y)" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 23 " has extreme values at " } {XPPEDIT 18 0 "x=0" "6#/%\"xG\"\"!" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "x=2" "6#/%\"xG\"\"#" }{TEXT -1 27 " along the constraint line." }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 49 "Figure 18 .17 shows a contour plot of the surface " }{XPPEDIT 18 0 "z=f(x,y)" "6 #/%\"zG-%\"fG6$%\"xG%\"yG" }{TEXT -1 44 " and in red, a graph of the c onstraint line " }{XPPEDIT 18 0 "g(x,y)=0" "6#/-%\"gG6$%\"xG%\"yG\"\"! " }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 268 "p8 := contourplot(f, x = -2..4, y = -1..5, c ontours = [0,.1,1,2,3,4,5,6,7,8], color = black):\np9 := implicitplot( g,x=-2..4,y=-1..5,color=red):\ndisplay([p8,p9], axes=boxed, xtickmarks =7, ytickmarks=7, labels=[x,`y `], labelfont=[TIMES,ITALIC,12],scali ng=constrained);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 50 "This view suggests we will find ex treme values of " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\"yG" } {TEXT -1 4 " at " }{TEXT 267 1 "x" }{TEXT -1 9 " = 0 and " }{TEXT 268 1 "x" }{TEXT -1 5 " = 2." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 " " 0 "" {TEXT -1 86 "This view is significant since it shows but a sing le point of tangency at about (2,1)." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 31 "Table 18.2 lists the equations " } {XPPEDIT 18 0 "grad(f)=lambda*grad(g),g(x,y)=0" "6$/-%%gradG6#%\"fG*&% 'lambdaG\"\"\"-F%6#%\"gGF*/-F-6$%\"xG%\"yG\"\"!" }{TEXT -1 24 ", and t he solutions for " }{XPPEDIT 18 0 "lambda,x" "6$%'lambdaG%\"xG" } {TEXT -1 6 ", and " }{XPPEDIT 18 0 "y" "6#%\"yG" }{TEXT -1 20 ", and t he values of " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 23 " at the extreme points." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 24 " Equations " }{XPPEDIT 18 0 "lambda" "6#%'lambdaG" }{TEXT -1 13 " " }{XPPEDIT 18 0 "`` (x,y)" "6#-%!G6$%\"xG%\"yG" }{TEXT -1 12 " " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 51 "======== === ===== ======" }} {PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*x*y=lambda" "6#/*(\" \"#\"\"\"%\"xGF&%\"yGF&%'lambdaG" }{TEXT -1 28 " 4 \+ " }{XPPEDIT 18 0 "``(2,1)" "6#-%!G6$\"\"#\"\"\"" }{TEXT -1 18 " \+ 4" }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "x^ 2=lambda" "6#/*$%\"xG\"\"#%'lambdaG" }{TEXT -1 31 " 0 \+ " }{XPPEDIT 18 0 "``(0,3)" "6#-%!G6$\"\"!\"\"$" }{TEXT -1 19 " 0" }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "x+y=3" "6#/,&%\"xG\"\"\"%\"yGF&\"\"$" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 45 "_____________________________________________" }} {PARA 0 "" 0 "" {TEXT -1 44 " Table 18 .2 " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 5 "Whe n " }{XPPEDIT 18 0 "lambda=0" "6#/%'lambdaG\"\"!" }{TEXT -1 313 ", the constraint does not apply. The corresponding extreme point is a crit ical point for the unconstrained optimization problem, and would have \+ been found without the constraint. That is why Figure 18.17 shows but one point of tangency between the constraint line and the level curve s of the objective function " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG %\"yG" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 77 "Carrying out the computations in Maple, we have the gr adient vectors of both " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\"yG " }{TEXT -1 5 " and " }{XPPEDIT 18 0 "g(x,y)" "6#-%\"gG6$%\"xG%\"yG" } {TEXT -1 9 " given by" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 43 "gf := grad(f, [x,y]);\ngg := grad(g , [x,y]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 37 "I f we then equate the components of " } {XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 20 " with a mult iple of " }{XPPEDIT 18 0 "grad(g)" "6#-%%gradG6#%\"gG" }{TEXT -1 11 ", we obtain" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 " " {MPLTEXT 1 0 22 "q := equate(gf, m*gg);" }}}{EXCHG {PARA 0 "> " 0 " " {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 52 "Solving thr ee equations in three unknowns, we obtain" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 40 "q1 := solve(q union \+ \{g = 0\}, \{x, y, m\});" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 " " }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 30 "There are two critical points :" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 12 "(2, \+ 1) with " }{XPPEDIT 18 0 "m=4" "6#/%\"mG\"\"%" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 12 "(0, 3) with " }{XPPEDIT 18 0 "m=0" "6#/%\"mG\"\"!" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 " " 0 "" {TEXT -1 35 "with corresponding function values " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 45 "subs(q 1[1],[[x,y],f]);\nsubs(q1[2],[[x,y],f]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 12 "Example 18.9" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {EXCHG {PARA 0 "" 0 "" {TEXT -1 212 "In this third example, the object ive function must be constructed from a verbal description provided by the problem statement, namely, the requirement to find the (shortest) distance from the origin to the plane " }{XPPEDIT 18 0 "2*x+y-z=5" "6 #/,(*&\"\"#\"\"\"%\"xGF'F'%\"yGF'%\"zG!\"\"\"\"&" }{TEXT -1 1 "." }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 79 "Thus, the quantity to be minimized is the distance from the origin to a point ( " }{XPPEDIT 18 0 "x,y,z" "6%%\"xG%\"yG%\"zG" }{TEXT -1 65 ") on the pl ane. It's generally easier, however, to miminize the " }{TEXT 263 6 " square" }{TEXT -1 17 " of the distance." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 15 "The constraint " }{XPPEDIT 18 0 "g(x ,y,z)=0" "6#/-%\"gG6%%\"xG%\"yG%\"zG\"\"!" }{TEXT -1 48 " is the equat ion of the plane. We herefore have" }}{PARA 0 "" 0 "" {TEXT -1 0 "" } }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "f := x^2 + y^2 + z^2;" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 4 "and " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "g := 2*x + y - z - 5;" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 17 "The gr adients of " }{XPPEDIT 18 0 "f(x,y,z)" "6#-%\"fG6%%\"xG%\"yG%\"zG" } {TEXT -1 8 " and of " }{XPPEDIT 18 0 "g(x,y,z)" "6#-%\"gG6%%\"xG%\"yG% \"zG" }{TEXT -1 19 " are, respectively," }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 47 "gf := grad(f, [x,y,z]) ;\ngg := grad(g, [x,y,z]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 29 "There are three equations \+ in " }{XPPEDIT 18 0 "grad(f)=lambda*grad(g)" "6#/-%%gradG6#%\"fG*&%'la mbdaG\"\"\"-F%6#%\"gGF*" }{TEXT -1 29 ", and four unknowns, namely, " }{XPPEDIT 18 0 "x,y,z" "6%%\"xG%\"yG%\"zG" }{TEXT -1 6 ", and " } {XPPEDIT 18 0 "lambda" "6#%'lambdaG" }{TEXT -1 65 ". Table 18.3 lists the four equations and their single solution." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 33 " Equations \+ " }{XPPEDIT 18 0 "lambda" "6#%'lambdaG" }{TEXT -1 16 " \+ " }{XPPEDIT 18 0 "``(x,y,z)" "6#-%!G6%%\"xG%\"yG%\"zG" }{TEXT -1 14 " " }{XPPEDIT 18 0 "sqrt(f(x,y,z))" "6#-%%sqrtG6#-% \"fG6%%\"xG%\"yG%\"zG" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 61 " ============ === ========== ===========" }} {PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*x=2*lambda" "6#/*&\" \"#\"\"\"%\"xGF&*&F%F&%'lambdaGF&" }{TEXT -1 22 " \+ " }{XPPEDIT 18 0 "5/3" "6#*&\"\"&\"\"\"\"\"$!\"\"" }{TEXT -1 12 " \+ " }{XPPEDIT 18 0 "``(5/3,5/6,-5/6)" "6#-%!G6%*&\"\"&\"\"\"\"\" $!\"\"*&F'F(\"\"'F*,$*&F'F(F,F*F*" }{TEXT -1 17 " " } {XPPEDIT 18 0 "5/sqrt(6)" "6#*&\"\"&\"\"\"-%%sqrtG6#\"\"'!\"\"" } {TEXT -1 2 " " }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*y=l ambda" "6#/*&\"\"#\"\"\"%\"yGF&%'lambdaG" }{TEXT -1 1 " " }}{PARA 0 " " 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*z=-lambda" "6#/*&\"\"#\"\"\"% \"zGF&,$%'lambdaG!\"\"" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*x+y-z=5" "6#/,(*&\"\"#\"\"\"%\"xGF'F'%\"yGF'%\"zG !\"\"\"\"&" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 56 "___________ _____________________________________________" }}{PARA 0 "" 0 "" {TEXT -1 57 " Table 18.3 \+ " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 24 "To ob tain the equations " }{XPPEDIT 18 0 "grad(f)=lambda*grad(g)" "6#/-%%gr adG6#%\"fG*&%'lambdaG\"\"\"-F%6#%\"gGF*" }{TEXT -1 36 " in Maple, equa te the components of " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" } {TEXT -1 20 " with a multiple of " }{XPPEDIT 18 0 "grad(g)" "6#-%%grad G6#%\"gG" }{TEXT -1 35 ", using the more convenient letter " } {XPPEDIT 18 0 "m" "6#%\"mG" }{TEXT -1 12 " instead of " }{XPPEDIT 18 0 "lambda" "6#%'lambdaG" }{TEXT -1 12 ". We obtain" }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "q := equa te(gf, m*gg);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 42 "Solve four equations in the four u nknowns " }{XPPEDIT 18 0 "x,y,z,m" "6&%\"xG%\"yG%\"zG%\"mG" }{TEXT -1 18 ", again using the " }{TEXT 286 5 "union" }{TEXT -1 116 " command t o add the constraint equation to the set of three equations obtained f rom the gradient condition. We find" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 40 "q1 := solve(q union \{g = 0\}, \{x,y,z,m\});" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 22 "Evaluate the distance " }{XPPEDIT 18 0 "sqrt(f(x,y,z))" "6#-%%sqrtG6#-%\"fG6%%\"xG%\"yG%\"zG" }{TEXT -1 33 " at the critical point, obtaining" }}{PARA 0 "" 0 "" {TEXT -1 0 " " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 37 "simplify(subs(q1,[[x,y, z],sqrt(f)]));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}} {SECT 1 {PARA 3 "" 0 "" {TEXT -1 13 "Example 18.10" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 160 "A pentagon is for med from a rectangle surmounted by an isosceles triangle. What dimens ions give the pentagon least perimeter if the area is fixed at the val ue " }{TEXT 264 1 "a" }{TEXT -1 44 "? (See the following figure, Figu re 18.18.)" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 " " {MPLTEXT 1 0 341 "a:='a':\np10 := plot([[0,0],[6,0],[6,3],[3,5],[0,3 ],[0,0]], color=black):\np11 := plot(\{[[0,3],[6,3]],[[3,5],[3,3]]\}, \+ linestyle = 3, color=black):\np12 := textplot(\{[1.5,2.7,`x`], [4.5,2. 7,`x`], [3.2,4,`z`], [5.4,4.5,`sqrt(z^2 + x^2)`], [6.2,1.5,`y`], [3,-. 5,`2x`]\}, font=[TIMES,ROMAN,12]):\ndisplay([p||(10..12)],axes=none,sc aling=constrained);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 213 "In this fourth example, the const raint contains a symbolic parameter, and the algebra becomes significa ntly more complicated. The point of the example is to show how to nav igate through such seemingly complexity." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 " " 0 "" {TEXT -1 117 "From Figure 18.18 the area of the triangle, the a rea of the rectangle, the total area, and the perimeter are given by" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 29 "Area of Triangle: 2 [" }{XPPEDIT 18 0 "1/2" "6#*&\"\"\"F$\"\"#!\"\"" }{TEXT -1 1 " " }{TEXT 287 1 "x" }{TEXT -1 1 " " }{TEXT 288 1 "z" } {TEXT -1 1 "]" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 25 "Area of Rectangle: " }{XPPEDIT 18 0 "``(2*x)*y" "6# *&-%!G6#*&\"\"#\"\"\"%\"xGF)F)%\"yGF)" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 31 "Total Area: \+ " }{XPPEDIT 18 0 "g(x,y,z)=2*x*y+x*z" "6#/-%\"gG6%%\"xG%\"yG% \"zG,&*(\"\"#\"\"\"F'F-F(F-F-*&F'F-F)F-F-" }{TEXT -1 3 " = " }{TEXT 269 1 "a" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 30 "Perimeter: " }{XPPEDIT 18 0 "f(x,y,z)=2*sqrt(x^ 2+z^2)+2*x+y+y" "6#/-%\"fG6%%\"xG%\"yG%\"zG,**&\"\"#\"\"\"-%%sqrtG6#,& *$F'F,F-*$F)F,F-F-F-*&F,F-F'F-F-F(F-F(F-" }{TEXT -1 1 " " }}{PARA 0 " " 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 53 "The objective func tion is the perimeter, so we define" }}{PARA 0 "" 0 "" {TEXT -1 0 "" } }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 35 "f := 2*sqrt(z^2 + x^2) + 2 *x + 2*y;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 46 "The constraint is the fixed area, so we d efine" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "g := 2*x*y + x*z - a;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 26 "The gradient \+ vectors grad(" }{TEXT 275 1 "f" }{TEXT -1 11 ") and grad(" }{TEXT 276 1 "g" }{TEXT -1 10 ") are then" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 47 "gf := grad(f, [x,y,z]);\ngg \+ := grad(g, [x,y,z]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }} }{EXCHG {PARA 0 "" 0 "" {TEXT -1 49 "Table 18.4 lists the four equatio ns arising from " }{XPPEDIT 18 0 "grad(f)=lambda*grad(g)" "6#/-%%gradG 6#%\"fG*&%'lambdaG\"\"\"-F%6#%\"gGF*" }{TEXT -1 20 " and the constrain t " }{XPPEDIT 18 0 "g(x,y,z)=a" "6#/-%\"gG6%%\"xG%\"yG%\"zG%\"aG" } {TEXT -1 41 ". There are four possible solutions for " }{XPPEDIT 18 0 "x,y,z" "6%%\"xG%\"yG%\"zG" }{TEXT -1 6 ", and " }{XPPEDIT 18 0 "lam bda" "6#%'lambdaG" }{TEXT -1 149 "; computed exactly in Maple (below), they are listed in floating-point form in table 18.4. Only one solut ion gives all three dimensions as positive." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 56 " Equations \+ " }{XPPEDIT 18 0 "lambda" "6#%'lambdaG" } {TEXT -1 27 " " }{XPPEDIT 18 0 "``(x,y,z)" " 6#-%!G6%%\"xG%\"yG%\"zG" }{TEXT -1 33 " \+ " }{XPPEDIT 18 0 "f(x,y,z)" "6#-%\"fG6%%\"xG%\"yG%\"zG" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 84 "====================== === ====================== ========" }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*x/sqrt(x^2+z^2)+2=lambda*(2*y+z)" "6# /,&*(\"\"#\"\"\"%\"xGF'-%%sqrtG6#,&*$F(F&F'*$%\"zGF&F'!\"\"F'F&F'*&%'l ambdaGF',&*&F&F'%\"yGF'F'F/F'F'" }{TEXT -1 14 " " } {XPPEDIT 18 0 ".52/sqrt(a)" "6#*&$\"#_!\"#\"\"\"-%%sqrtG6#%\"aG!\"\"" }{TEXT -1 9 " " }{XPPEDIT 18 0 "``(1.9*sqrt(a),.82*sqrt(a),-1. 1*sqrt(a)) " "6#-%!G6%*&$\"#>!\"\"\"\"\"-%%sqrtG6#%\"aGF**&$\"##)!\"#F *-F,6#F.F*,$*&$\"#6F)F*-F,6#F.F*F)" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2=2*lam bda*x" "6#/\"\"#*(F$\"\"\"%'lambdaGF&%\"xGF&" }{TEXT -1 42 " \+ " }{XPPEDIT 18 0 "-.52/sqrt(a)" "6#,$* &$\"#_!\"#\"\"\"-%%sqrtG6#%\"aG!\"\"F-" }{TEXT -1 9 " " } {XPPEDIT 18 0 "``(-1.9*sqrt(a),-.82*sqrt(a),1.1*sqrt(a)) " "6#-%!G6%,$ *&$\"#>!\"\"\"\"\"-%%sqrtG6#%\"aGF+F*,$*&$\"##)!\"#F+-F-6#F/F+F**&$\"# 6F*F+-F-6#F/F+" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*z/sqrt(x^2+z^2)=lambd a*x" "6#/*(\"\"#\"\"\"%\"zGF&-%%sqrtG6#,&*$%\"xGF%F&*$F'F%F&!\"\"*&%'l ambdaGF&F-F&" }{TEXT -1 32 " " } {XPPEDIT 18 0 "1.9/sqrt(a)" "6#*&$\"#>!\"\"\"\"\"-%%sqrtG6#%\"aGF&" } {TEXT -1 10 " " }{XPPEDIT 18 0 "``(.52*sqrt(a),.82*sqrt(a),.3 0*sqrt(a))" "6#-%!G6%*&$\"#_!\"#\"\"\"-%%sqrtG6#%\"aGF**&$\"##)F)F*-F, 6#F.F**&$\"#IF)F*-F,6#F.F*" }{TEXT -1 17 " " } {XPPEDIT 18 0 "3.86*sqrt(a)" "6#*&$\"$'Q!\"#\"\"\"-%%sqrtG6#%\"aGF'" } {TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*x*y+x*z=a" "6#/,&*(\"\"#\"\"\"%\"xGF' %\"yGF'F'*&F(F'%\"zGF'F'%\"aG" }{TEXT -1 33 " \+ " }{XPPEDIT 18 0 "-1.9/sqrt(a)" "6#,$*&$\"#>!\"\"\"\"\"-%%sqrt G6#%\"aGF'F'" }{TEXT -1 11 " " }{XPPEDIT 18 0 "``(-.52*sqrt( a),-.82*sqrt(a),-.30*sqrt(a))" "6#-%!G6%,$*&$\"#_!\"#\"\"\"-%%sqrtG6#% \"aGF+!\"\",$*&$\"##)F*F+-F-6#F/F+F0,$*&$\"#IF*F+-F-6#F/F+F0" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 78 "______________________________ ________________________________________________" }}{PARA 0 "" 0 "" {TEXT -1 73 " \+ Table 18.4 " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 80 "The third solution is the physically meaningful one, and \+ can be given exactly as" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 272 " " 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "``(beta,(1+1/sqrt(3))*beta,beta/ sqrt(3))" "6#-%!G6%%%betaG*&,&\"\"\"F)*&F)F)-%%sqrtG6#\"\"$!\"\"F)F)F& F)*&F&F)-F,6#F.F/" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 6 "where " }}{PARA 273 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "beta=sqrt(a*(2-s qrt(3)))" "6#/%%betaG-%%sqrtG6#*&%\"aG\"\"\",&\"\"#F*-F&6#\"\"$!\"\"F* " }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 63 "The minimum value of the perimeter can also be given exac tly as" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 274 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "(1+sqrt(3))*sqrt(2*a)" "6#*&,&\"\"\"F%-%%sqrtG6# \"\"$F%F%-F'6#*&\"\"#F%%\"aGF%F%" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 65 "It is surprising how much the presence of the symbolic parameter " }{XPPEDIT 18 0 "a" "6#%\"aG " }{TEXT -1 179 " complicates the algebra. But the reader should not \+ let the additional complexity in the algebra obscure the underlying si mplicity of the basic technique of Lagrange multipliers." }}{PARA 0 " " 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 67 "To execute these c alculations in Maple, equate the coefficients of " }{XPPEDIT 18 0 "gra d(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 20 " with a multiple of " } {XPPEDIT 18 0 "grad(g)" "6#-%%gradG6#%\"gG" }{TEXT -1 35 ", obtaining \+ (after again replacing " }{XPPEDIT 18 0 "lambda" "6#%'lambdaG" }{TEXT -1 33 " with the more convenient letter " }{XPPEDIT 18 0 "m" "6#%\"mG " }{TEXT -1 2 ")," }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "> " 0 " " {MPLTEXT 1 0 22 "q := equate(gf, m*gg);" }}}{EXCHG {PARA 0 "> " 0 " " {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 42 "Solve four \+ equations in the four unknowns " }{XPPEDIT 18 0 "x,y,z,m" "6&%\"xG%\"y G%\"zG%\"mG" }{TEXT -1 11 ", obtaining" }}{PARA 0 "" 0 "" {TEXT -1 0 " " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 40 "q1 := solve(q union \{g = 0\}, \{x,y,z,m\});" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" } }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 17 "where again, the " }{TEXT 289 5 "union" }{TEXT -1 105 " command adds the constraint equation to the se t of three equations obtained from the gradient condition." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 17 "The cure for the \+ " }{TEXT 277 6 "RootOf" }{TEXT -1 14 " structure is " }{TEXT 265 9 "al lvalues" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 20 "q2 := allvalues(q1);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 160 "There are 4 possible critical points and we will have to inves tigate each one. Execute the following Maple instruction to isolate a nd name each critical point." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 39 "for k from 1 to 4 do\ns||k : = q2[k];\nod;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 133 "A useful view of the critical poi nts is afforded by a conversion to floating-point form. Thus, for the first critical point, we have" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 10 "evalf(s1);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 27 "R eject this solution since " }{TEXT 266 1 "z" }{TEXT -1 24 " (a length) is negative." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 37 "The next critical point to examine is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 10 "evalf(s2); " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 79 "Again, reject this solution since at least one varia ble (a length) is negative." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 69 "The situation is the same for the last critical point, as we see from" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 10 "evalf(s4);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 11 "where bo th " }{XPPEDIT 18 0 "x" "6#%\"xG" }{TEXT -1 5 " and " }{XPPEDIT 18 0 " y" "6#%\"yG" }{TEXT -1 34 " (which are lengths) are negative." }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 41 "The remai ning critical point evaluates to" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 10 "evalf(s3);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 116 " and we see this is viable since all three variables (lengths) are posi tive. The function value at this candidate is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 36 "f3 := simpl ify(subs(s3,f),symbolic);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 63 "Thus, there is just the one \+ solution, s3, for which the point (" }{XPPEDIT 18 0 "x,y,z;" "6%%\"xG% \"yG%\"zG" }{TEXT -1 4 ") is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "P := subs(s3,[x,y,z]);" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 35 "The function value at this point is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 3 "f3;" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 43 "An alternate view of this value is given by" }}{PARA 0 " " 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 10 "eval f(f3);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 56 "Maple can be coerced into simplifying the optim al value." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 " " {MPLTEXT 1 0 32 "factor(expand(rationalize(f3)));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 94 "M aple can also be coerced into simplifying (slightly) the representatio n of the extreme point." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 37 "P1 := factor(expand(rationalize(P)) );" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 " " 0 "" {TEXT -1 51 "Maple resists compressing this solution to the for m" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 275 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "``(beta,(1+1/sqrt(3))*beta,beta/sqrt(3))" "6#-%!G6%%%b etaG*&,&\"\"\"F)*&F)F)-%%sqrtG6#\"\"$!\"\"F)F)F&F)*&F&F)-F,6#F.F/" } {TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 6 "where " }}{PARA 276 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "beta=sqrt(a*(2-sqrt(3)))" "6#/%%beta G-%%sqrtG6#*&%\"aG\"\"\",&\"\"#F*-F&6#\"\"$!\"\"F*" }{TEXT -1 1 " " }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 119 "However, Maple does help with enough of the algebra so that with just a bit of intervention, this form can be achieved." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 37 "Let us begin by defining the quant ity" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 19 "u := a*(2-sqrt(3));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 21 "whose square \+ root is " }{XPPEDIT 18 0 "beta" "6#%%betaG" }{TEXT -1 10 ". (Thus, " }{XPPEDIT 18 0 "beta=sqrt(u)" "6#/%%betaG-%%sqrtG6#%\"uG" }{TEXT -1 4 ".) " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 46 " In as many places as Maple will allow, insert " }{XPPEDIT 18 0 "U" "6# %\"UG" }{TEXT -1 74 " where this quantity appears. (Since we have jus t assigned to the letter " }{XPPEDIT 18 0 "u" "6#%\"uG" }{TEXT -1 94 " , we can't substitute this letter into the expression, so we substitut e the alternate letter, " }{XPPEDIT 18 0 "U" "6#%\"UG" }{TEXT -1 2 ".) " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 9 "We obt ain" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 23 "PP1 := algsubs(u=U,P1);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 14 "Next, replace " }{XPPEDIT 18 0 "sqrt(U)" "6#-%%sqrtG6#%\"UG" }{TEXT -1 6 " with " } {XPPEDIT 18 0 "beta" "6#%%betaG" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "PP2 := subs (sqrt(U)=beta,PP1);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 4 "But " }{XPPEDIT 18 0 "U^`3/2`=U*sqr t(U)" "6#/)%\"UG%$3/2G*&F%\"\"\"-%%sqrtG6#F%F(" }{TEXT -1 3 " = " } {XPPEDIT 18 0 "u*beta" "6#*&%\"uG\"\"\"%%betaGF%" }{TEXT -1 24 " which we can inject via" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 36 "radnormal(subs(U^(3/2)=u*beta,PP2));" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 43 "Except for Maple's tendency to rationalize " }{XPPEDIT 18 0 "1/sqrt(3)" "6#*&\"\"\"F$-%%sqrtG6#\"\"$!\"\"" }{TEXT -1 4 " to \+ " }{XPPEDIT 18 0 "sqrt(3)/3" "6#*&-%%sqrtG6#\"\"$\"\"\"F'!\"\"" } {TEXT -1 36 ", we have achieved the desired form." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 13 "Example 18.11" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 160 "In this fifth example w e extend the method to the case of two constraints by finding the shor test distance from the origin to the intersection of the two planes" } }{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 262 "" 0 "" {XPPEDIT 18 0 "g[1] =``" "6#/&%\"gG6#\"\"\"%!G" }{TEXT -1 1 " " }{XPPEDIT 18 0 "2*x-3*y+5* z=9" "6#/,(*&\"\"#\"\"\"%\"xGF'F'*&\"\"$F'%\"yGF'!\"\"*&\"\"&F'%\"zGF' F'\"\"*" }{TEXT -1 1 " " }}{PARA 263 "" 0 "" {XPPEDIT 18 0 "g[2]=``" " 6#/&%\"gG6#\"\"#%!G" }{TEXT -1 1 " " }{XPPEDIT 18 0 "6*x+y-7*z=12" "6# /,(*&\"\"'\"\"\"%\"xGF'F'%\"yGF'*&\"\"(F'%\"zGF'!\"\"\"#7" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 8 "that is," }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 52 "g1 := 2*x - 3*y + 5*z - 9;\ng2 := 6*x + y - 7*z - 12;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 143 "We give two \+ solutions, the first with the use of Lagrange multipliers, and the sec ond, without. For both solutions, the objective function is " }} {PARA 277 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "f(x,y,z)=x^2+y^2+z^2 " "6#/-%\"fG6%%\"xG%\"yG%\"zG,(*$F'\"\"#\"\"\"*$F(F,F-*$F)F,F-" } {TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 8 "that is," }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 23 "f := x^ 2 + y^2 + z^2;\n" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 56 "the square of the distance from th e origin to the point " }{XPPEDIT 18 0 "``(x,y,z)" "6#-%!G6%%\"xG%\"yG %\"zG" }{TEXT -1 3 ". " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 65 "As explained below, the Lagrange-multiplier method g eneralizes to" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 278 "" 0 "" {TEXT -1 1 " " }{TEXT 290 1 "f" }{TEXT -1 1 " " }{TEXT 293 1 "f" } {TEXT -1 3 " = " }{XPPEDIT 18 0 "lambda[1]" "6#&%'lambdaG6#\"\"\"" } {TEXT -1 1 " " }{TEXT 291 1 "f" }{TEXT -1 1 " " }{XPPEDIT 18 0 "g[1]" "6#&%\"gG6#\"\"\"" }{TEXT -1 3 " + " }{XPPEDIT 18 0 "lambda[2]" "6#&%' lambdaG6#\"\"#" }{TEXT -1 1 " " }{TEXT 292 1 "f" }{TEXT -1 1 " " } {XPPEDIT 18 0 "g[2]" "6#&%\"gG6#\"\"#" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 11 "that is, to" }}{PARA 279 "" 0 "" {TEXT -1 1 " " } {XPPEDIT 18 0 "grad(f)=lambda[1]*grad(g[1])+lambda[2]*grad(g[2])" "6#/ -%%gradG6#%\"fG,&*&&%'lambdaG6#\"\"\"F--F%6#&%\"gG6#F-F-F-*&&F+6#\"\"# F--F%6#&F16#F6F-F-" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 53 "so now, there are five equations in the f ive unknowns" }}{PARA 280 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "x,y,z ,lambda[1],lambda[2]" "6'%\"xG%\"yG%\"zG&%'lambdaG6#\"\"\"&F'6#\"\"#" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 27 "Alternatively, the func tion" }}{PARA 281 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "F(x,y,z)=f(x, y,z)-``" "6#/-%\"FG6%%\"xG%\"yG%\"zG,&-%\"fG6%F'F(F)\"\"\"%!G!\"\"" } {XPPEDIT 18 0 "sum(lambda[k]*g[k](x,y,z),k=1..2)" "6#-%$sumG6$*&&%'lam bdaG6#%\"kG\"\"\"-&%\"gG6#F*6%%\"xG%\"yG%\"zGF+/F*;F+\"\"#" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 62 "c ould be defined, and the same set of equations obtained from " }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 282 "" 0 "" {TEXT -1 1 " " } {TEXT 295 1 "f" }{TEXT -1 1 " " }{XPPEDIT 18 0 "F" "6#%\"FG" }{TEXT -1 3 " = " }{XPPEDIT 18 0 "MATRIX([[F[x]],[F[y]],[F[z]]])=MATRIX([[0], [0],[0]])" "6#/-%'MATRIXG6#7%7#&%\"FG6#%\"xG7#&F*6#%\"yG7#&F*6#%\"zG-F %6#7%7#\"\"!7#F97#F9" }{TEXT -1 3 " = " }{TEXT 294 1 "0" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 118 "The equations, and their single solution, are listed in Table 18.5. The \+ point closest to the origin is designated by " }{XPPEDIT 18 0 "P" "6#% \"PG" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 " " {TEXT -1 38 " Equations " }{XPPEDIT 18 0 "``(lambda[1],lambda[2])" "6#-%!G6$&%'lambdaG6#\"\"\"&F'6#\"\"#" } {TEXT -1 25 " " }{XPPEDIT 18 0 "``(x,y,z)" "6# -%!G6%%\"xG%\"yG%\"zG" }{TEXT -1 19 " " }{XPPEDIT 18 0 "sqrt(f(x,y,z))" "6#-%%sqrtG6#-%\"fG6%%\"xG%\"yG%\"zG" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 74 "============== ========== \+ =============== =========" }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*x=2*lambda[1]+6*lambda[2]" "6#/*&\"\"#\"\"\"% \"xGF&,&*&F%F&&%'lambdaG6#F&F&F&*&\"\"'F&&F+6#F%F&F&" }{TEXT -1 11 " \+ " }{XPPEDIT 18 0 "``(181/216,115/216)" "6#-%!G6$*&\"$\"=\"\" \"\"$;#!\"\"*&\"$:\"F(F)F*" }{TEXT -1 12 " " }{XPPEDIT 18 0 "``(263/108,-197/108,25/108)" "6#-%!G6%*&\"$j#\"\"\"\"$3\"!\"\",$*& \"$(>F(F)F*F**&\"#DF(F)F*" }{TEXT -1 13 " " }{XPPEDIT 18 0 "sqrt(1003)/12" "6#*&-%%sqrtG6#\"%.5\"\"\"\"#7!\"\"" }{TEXT -1 1 " \+ " }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*y=-3*lambda[1]+la mbda[2]" "6#/*&\"\"#\"\"\"%\"yGF&,&*&\"\"$F&&%'lambdaG6#F&F&!\"\"&F,6# F%F&" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "2*z=5*lambda[1]-7*lambda[2]" "6#/*&\"\"#\"\"\"%\"zGF&,&*&\"\"&F&&%'la mbdaG6#F&F&F&*&\"\"(F&&F,6#F%F&!\"\"" }{TEXT -1 1 " " }}{PARA 0 "" 0 " " {TEXT -1 1 " " }{XPPEDIT 18 0 "2*x-3*y+5*z=9" "6#/,(*&\"\"#\"\"\"%\" xGF'F'*&\"\"$F'%\"yGF'!\"\"*&\"\"&F'%\"zGF'F'\"\"*" }{TEXT -1 1 " " }} {PARA 0 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "6*x+y-7*z=12" "6#/,(*& \"\"'\"\"\"%\"xGF'F'%\"yGF'*&\"\"(F'%\"zGF'!\"\"\"#7" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 69 "_______________________________________ ______________________________" }}{PARA 0 "" 0 "" {TEXT -1 66 " \+ Table 18.5 " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 155 "Implementing t his first solution in Maple begins with the computation of the gradien ts of the objective function and the constraints, which we designate a s" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 85 "grad_f := grad(f,[x,y,z]);\ngrad_g1 := grad(g1,[x,y, z]);\ngrad_g2 := grad(g2,[x,y,z]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 72 "The generaliz ation of the Lagrange-multiplier technique relevant here is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 264 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 3 " = " }{XPPEDIT 18 0 "S um(lambda[k]*grad(g[k]),k=1..2)=lambda[1]*grad(g[1])+lambda[2]*grad(g[ 2])" "6#/-%$SumG6$*&&%'lambdaG6#%\"kG\"\"\"-%%gradG6#&%\"gG6#F+F,/F+;F ,\"\"#,&*&&F)6#F,F,-F.6#&F16#F,F,F,*&&F)6#F5F,-F.6#&F16#F5F,F," } {TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 112 "This form of the Lagrange-multiplier method conforms wel l to the available Maple syntax, and is implemented with" }}{PARA 0 " " 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 44 "q := equate(grad_f,m1*grad_g1 + m2*grad_g2);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 49 "which forms t hree equations in the five unknowns " }{XPPEDIT 18 0 "x,y,z,m[1],m[2] " "6'%\"xG%\"yG%\"zG&%\"mG6#\"\"\"&F'6#\"\"#" }{TEXT -1 169 ". The ad ditional two equations needed to make a determinate system are the con straints themselves. The five relevant equations are then solved in M aple with the syntax" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 44 "q1 := solve(q union \{g1,g2\}, \{x,y,z,m1 ,m2\});" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 86 "The point on the intersection of the two \+ planes which is closest to the origin is then" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 20 "P:=subs(q1, [x,y,z]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 49 "and the distance of this point from the o rigin is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 33 "f1 := simplify(subs(q1,sqrt(f)));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 2 "or" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 10 "evalf(f1);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 27 "as a floating-point number." }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 13 "At the po int " }{XPPEDIT 18 0 "P=``(263/108, -107/108, 25/108)" "6#/%\"PG-%!G6% *&\"$j#\"\"\"\"$3\"!\"\",$*&\"$2\"F*F+F,F,*&\"#DF*F+F," }{TEXT -1 10 " , we find " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 17 " to be the vector" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 25 "F := subs(q1,op(grad_f));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 14 "O f course, at " }{XPPEDIT 18 0 "P" "6#%\"PG" }{TEXT -1 30 ", this vecto r will agree with " }{XPPEDIT 18 0 "lambda[1]*grad(g[1])+lambda[2]*gra d(g[2])" "6#,&*&&%'lambdaG6#\"\"\"F(-%%gradG6#&%\"gG6#F(F(F(*&&F&6#\" \"#F(-F*6#&F-6#F2F(F(" }{TEXT -1 41 ", as we see by the following calc ulation." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 40 "subs(q1,evalm(m1*grad_g1 + m2*grad_g2));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 278 "A second solution to this problem can be framed within the con fines of simple multivariable calculus operations. First, a vector al ong the line of intersection of the two constraint planes is given by \+ the cross product of normals to the two planes. Thus, we compute the \+ vector" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 283 "" 0 "" {TEXT -1 1 " " }{TEXT 298 1 "V" }{TEXT -1 3 " = " }{XPPEDIT 18 0 " grad(g[1])" "6#-%%gradG6#&%\"gG6#\"\"\"" }{TEXT -1 1 " " }{TEXT 296 1 "x" }{TEXT -1 1 " " }{XPPEDIT 18 0 "grad(g[2])" "6#-%%gradG6#&%\"gG6#\"\"#" } {TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 8 "that is," }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 32 "V := cro ssprod(grad_g1,grad_g2);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 " " }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 101 "which lies along the line of intersection of the constraint planes. This vector is perpendicular \+ to " }{TEXT 297 1 "F" }{TEXT -1 3 " = " }{XPPEDIT 18 0 "grad(f)" "6#-% %gradG6#%\"fG" }{TEXT -1 14 " at the point " }{XPPEDIT 18 0 "P" "6#%\" PG" }{TEXT -1 21 ", as we can see from " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 13 "dotprod(F,V);" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 127 "Hence, the line of intersection of the constraint planes is tangent to the level surface determined by the objective function, " }{XPPEDIT 18 0 "f(x,y,z)" "6#-%\"fG6%%\"xG%\"yG%\"zG" }{TEXT -1 90 ". This is the analog of the geometry which applies in the case of th e objective function " }{XPPEDIT 18 0 "f(x,y)" "6#-%\"fG6$%\"xG%\"yG" }{TEXT -1 42 " constrained by a single constraint curve " }{XPPEDIT 18 0 "g(x,y)=0" "6#/-%\"gG6$%\"xG%\"yG\"\"!" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 78 "To find a point on the line of intersection of the two constraint planes, set " } {XPPEDIT 18 0 "z=0" "6#/%\"zG\"\"!" }{TEXT -1 58 " in both planes to f ind where the line passes through the " }{XPPEDIT 18 0 "xy" "6#%#xyG" }{TEXT -1 38 "-plane. The solution of the equations" }}{PARA 0 "" 0 " " {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 41 "eq1 := su bs(z=0,g1);\neq2 := subs(z=0,g2);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 14 "is found to b e" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 29 "q2 := solve(\{eq1,eq2\},\{x,y\});" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 69 "so \+ the line of intersection can be given parametrically by the vector" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 35 "R := evalm(subs(q2,[x,y,0]) + t*V);" }}}{EXCHG {PARA 0 "> " 0 " " {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 15 "If we evalu ate " }{XPPEDIT 18 0 "f(x,y,z) " "6#-%\"fG6%%\"xG%\"yG%\"zG" }{TEXT -1 28 " along this line, we obtain " }{XPPEDIT 18 0 "f(t)=f(x(t),y(t), z(t))" "6#/-%\"fG6#%\"tG-F%6%-%\"xG6#F'-%\"yG6#F'-%\"zG6#F'" }{TEXT -1 52 ", a function of a single variable. This function is" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 45 "f t := simplify(subs(x=R[1],y=R[2],z=R[3],f));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 128 "and the techniques of elementary differential calculus, setting the derivativ e to zero and solving, gives the critical value of " }{XPPEDIT 18 0 "t " "6#%\"tG" }{TEXT -1 3 " as" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 25 "T := solve(diff(ft,t),t);" } }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 " " {TEXT -1 11 "Evaluating " }{TEXT 278 1 "R" }{XPPEDIT 18 0 "``(t)" "6 #-%!G6#%\"tG" }{TEXT -1 18 " at this value of " }{XPPEDIT 18 0 "t" "6# %\"tG" }{TEXT -1 6 " gives" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 16 "subs(t=T,op(R));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 38 "w hich is the vector form of the point " }{XPPEDIT 18 0 "P" "6#%\"PG" } {TEXT -1 41 " found by the Lagrange-multiplier method." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 59 "Finally, we construc t Figure 18.19, a sketch of the sphere " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 9 "f = f1^2;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 33 "along with a segment of the line " }{TEXT 279 1 "R" }{XPPEDIT 18 0 "``(t)" "6#-%!G6#%\"tG" }{TEXT -1 18 ", and the vectors " } {XPPEDIT 18 0 "grad(f),grad(g[1])" "6$-%%gradG6#%\"fG-F$6#&%\"gG6#\"\" \"" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "grad(g[2])" "6#-%%gradG6#&%\"g G6#\"\"#" }{TEXT -1 21 ", all drawn at point " }{XPPEDIT 18 0 "P" "6#% \"PG" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 529 "p13 := sphereplot(f1,theta=0..2*Pi,phi=0 ..Pi,color=black, style=hidden):\np14 := spacecurve(R,t=-1/20..1/10,co lor=cyan,thickness=3):\np15 := arrow(P,F,[1,1,0],.3,.6,.2,color=blue): \np16 := arrow(P,grad_g1,[1,-1,0],.3,.6,.2,color=red):\np17 := arrow(P ,grad_g2,[1,-1,0],.1,.4,.1,color=green):\ndots:=spacecurve(\{[[-2.1,-4 ,-6.5],[-2.1,2,-6.5],[8,2,-6.5]]\}, color=black, linestyle=2):\ndispla y([p||(13..17),dots],axes=frame,scaling=constrained, labels=[x,`y `,` z `], labelfont=[TIMES,ITALIC,12], tickmarks=[3,3,3], orientation=[-5 5,70]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 11 "The vector " }{TEXT 280 1 "F" }{TEXT -1 3 " = " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 42 " is drawn in blue, while the gradients to " }{XPPEDIT 18 0 "g[1]" "6#&%\" gG6#\"\"\"" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "g[2]" "6#&%\"gG6#\"\"# " }{TEXT -1 68 " are drawn in red and green, respectively. The segmen t of the line " }{TEXT 281 1 "R" }{XPPEDIT 18 0 "``(t)" "6#-%!G6#%\"tG " }{TEXT -1 20 " is drawn in cyan. " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 125 "The line of intersection of the two co nstraining planes is tangent to the level surface determined by the ob jective function " }{XPPEDIT 18 0 "f(x,y,z)" "6#-%\"fG6%%\"xG%\"yG%\"z G" }{TEXT -1 3 ". " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 " " {TEXT -1 35 "The plane spanned by the gradients " }{XPPEDIT 18 0 "gr ad(g[1]" "6#-%%gradG6#&%\"gG6#\"\"\"" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "grad(g[2])" "6#-%%gradG6#&%\"gG6#\"\"#" }{TEXT -1 30 " is orthog onal to this line. " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 " " {TEXT -1 11 "The vector " }{TEXT 282 1 "F" }{TEXT -1 3 " = " } {XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 44 " lies in the plane spanned by the gradients " }{XPPEDIT 18 0 "grad(g[1]" "6#-%%gra dG6#&%\"gG6#\"\"\"" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "grad(g[2])" "6 #-%%gradG6#&%\"gG6#\"\"#" }{TEXT -1 36 ". The Lagrange-multiplier con dition" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 265 "" 0 "" {TEXT -1 1 " " }{XPPEDIT 18 0 "grad(f)" "6#-%%gradG6#%\"fG" }{TEXT -1 3 " = " } {XPPEDIT 18 0 "Sum(lambda[k]*grad(g[k]),k=1..2)=lambda[1]*grad(g[1])+l ambda[2]*grad(g[2])" "6#/-%$SumG6$*&&%'lambdaG6#%\"kG\"\"\"-%%gradG6#& %\"gG6#F+F,/F+;F,\"\"#,&*&&F)6#F,F,-F.6#&F16#F,F,F,*&&F)6#F5F,-F.6#&F1 6#F5F,F," }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 " " 0 "" {TEXT -1 38 "finds points at which the gradient of " }{XPPEDIT 18 0 "f" "6#%\"fG" }{TEXT -1 47 " lies in the plane spanned by the gra dients of " }{XPPEDIT 18 0 "g[1]" "6#&%\"gG6#\"\"\"" }{TEXT -1 5 " and " }{XPPEDIT 18 0 "g[2]" "6#&%\"gG6#\"\"#" }{TEXT -1 120 ". At such p oints, the curve of intersection of the constraints is tangent to a le vel surface of the objective function " }{XPPEDIT 18 0 "f" "6#%\"fG" } {TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}}{MARK "1" 0 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }