View
218
Download
0
Category
Preview:
Citation preview
7/29/2019 M2L4_LN
1/6
Optimization Methods: Optimization using Calculus - Equality constraints 1
Module 2 Lecture Notes 4
Optimization of Functions of Multiple Variables subject to Equality Constraints
Introduction
In the previous lecture we learnt the optimization of functions of multiple variables studied
for unconstrained optimization. This is done with the aid of the gradient vector and the
Hessian matrix. In this lecture we will learn the optimization of functions of multiple
variables subjected to equality constraints using the method of constrained variation and the
method of Lagrange multipliers.
Constrained optimization
A function of multiple variables, f(x), is to be optimized subject to one or more equality
constraints of many variables. These equality constraints, gj(x), may or may not be linear. The
problem statement is as follows:
Maximize (or minimize)f(X), subject to gj(X) = 0, j = 1, 2, , m
where
1
2
n
x
xX
x
=
M
with the condition that ; or else ifm > n then the problem becomes an over defined one
and there will be no solution. Of the many available methods, the method of constrained
variation and the method using Lagrange multipliers are discussed.
m n
Solution by method of Constrained Variation
For the optimization problem defined above, let us consider a specific case with n = 2 and
m=1 before we proceed to find the necessary and sufficient conditions for a general problem
using Lagrange multipliers. The problem statement is as follows:
Minimizef(x1,x2), subject to g(x1,x2) = 0
For f(x1,x2) to have a minimum at a point X* = [x1*,x2*], a necessary condition is that the
total derivative off(x1,x2) must be zero at [x1*,x2*].
1 2
1 2
0f f
df dx dxx x
= + =
(1)
D Nagesh Kumar, IISc, Bangalore M2L4
7/29/2019 M2L4_LN
2/6
Optimization Methods: Optimization using Calculus - Equality constraints 2
Since g(x1*,x2*) = 0 at the minimum point, variations dx1 and dx2 about the point [x1*, x2*]
must be admissible variations, i.e. the point lies on the constraint:
g(x1* + dx1, x2* + dx2) = 0 (2)
assuming dx1 and dx2 are small the Taylor series expansion of this gives us
1 1 2 2 1 2 1 2 1 1 2 2
1 2
( * , * ) ( *, *) (x *,x *) (x *,x *) 0g g
g x dx x dx g x x dx dxx x
+ + = + +
= (3)
or
1 2
1 2
0g g
dg dx dxx x
= +
=
0
at [x1*,x2*] (4)
which is the condition that must be satisfied for all admissible variations.
Assuming (4)2/g x can be rewritten as
12 1
2
/( *, *)
/
g xdx x x dx
g x2 1
=
(5)
which indicates that once variation alongx1 (d x1) is chosen arbitrarily, the variation alongx2
(d x2) is decided automatically to satisfy the condition for the admissible variation.
Substituting equation (5)in(1)we have:
1 2
11
1 2 2 (x *, x *)
/0
/
g xf fdf dx
x g x x
= =
(6)
The equation on the left hand side is called the constrained variation off. Equation (5)has to
be satisfied for all dx1, hence we have
1 21 2 2 1 (x *, x *)
0f g f g
x x x x
=
(7)
This gives us the necessary condition to have [x1*, x2*] as an extreme point (maximum or
minimum)
Solution by method of Lagrange multipliers
Continuing with the same specific case of the optimization problem with n = 2 and m = 1 we
define a quantity , called theLagrange multiplieras
1 2
2
2 (x *, x *)
/
/
f x
g x
=
(8)
Using this in (6)
D Nagesh Kumar, IISc, Bangalore M2L4
7/29/2019 M2L4_LN
3/6
Optimization Methods: Optimization using Calculus - Equality constraints 3
1 21 1 (x *, x *)
0f g
x x
+ =
(9)
And (8) written as
1 22 2 (x *, x *)
0f g
x x
+ =
(10)
Also, the constraint equation has to be satisfied at the extreme point
1 21 2 ( *, *)
( , ) 0x x
g x x = (11)
Hence equations (9)to(11) represent the necessary conditions for the point [x1*, x2*] to be
an extreme point.
Note that could be expressed in terms of 1/g x as well and 1/g x has to be non-zero.
Thus, these necessary conditions require that at least one of the partial derivatives ofg(x1, x2)
be non-zero at an extreme point.
The conditions given by equations (9) to (11) can also be generated by constructing a
functionL, known as the Lagrangian function, as
1 2 1 2 1 2( , , ) ( , ) ( , )L x x f x x g x x = + (12)
Alternatively, treating L as a function ofx1,x2 and
, the necessary conditions for itsextremum are given by
1 2 1 2 1 2
1 1 1
1 2 1 2 1 2
2 2 2
1 2 1 2
( , , ) ( , ) ( , ) 0
( , , ) ( , ) ( , ) 0
( , , ) ( , ) 0
L f gx x x x x x
x x x
L f gx x x x x x
x x x
Lx x g x x
= + =
= +
= =
= (13)
The necessary and sufficient conditions for a general problem are discussed next.Necessary conditions for a general problem
For a general problem with n variables and m equality constraints the problem is defined as
shown earlier
Maximize (or minimize)f(X), subject to gj(X) = 0, j = 1, 2, , m
where
1
2
n
x
x
x
=
XM
D Nagesh Kumar, IISc, Bangalore M2L4
7/29/2019 M2L4_LN
4/6
Optimization Methods: Optimization using Calculus - Equality constraints 4
In this case the Lagrange function,L, will have one Lagrange multiplierj for each constraint
as(X)jg
1 2 , 1 2 1 1 2 2( , ,..., , ,..., ) ( ) ( ) ( ) ... ( )n m m mL x x x f g g g = + + + +X X X X
m
(14)
L is now a function ofn + m unknowns, 1 2 , 1 2, ,..., , ,...,nx x x , and the necessary conditions
for the problem defined above are given by
1
( ) ( ) 0, 1,2,..., 1,2,...,
( ) 0, 1, 2,...,
mj
j
ji i i
j
j
gL fi n j
x x x
Lg j m
=
= + = = =
= = =
X X
X
m
(15)
which represent n + m equations in terms of the n + m unknowns,xi and j . The solution to
this set of equations gives us
1
2
*
*
*n
x
x
x
=
XM
and
1
2
*
**
*m
=
M (16)
The vector X corresponds to the relative constrained minimum off(X) (subject to the
verification of sufficient conditions).
Sufficient conditions for a general problem
A sufficient condition for f(X) to have a relative minimum at X* is that each root of the
polynomial in , defined by the following determinant equation be positive.
11 12 1 11 21 1
21 22 2 12 22 2
1 2 1 2
11 12 1
21 22 2
1 2
0
0 0
0 0
n m
n m
n n nn n n mn
n
n
m m mn
L L L g g g
L L L g g g
L L L g g g
g g g
g g g
g g g
=
L L
M O M M O M
L L
L L L
M O M
M O M M M
L L L
(17)
D Nagesh Kumar, IISc, Bangalore M2L4
7/29/2019 M2L4_LN
5/6
Optimization Methods: Optimization using Calculus - Equality constraints 5
where
2
( *, *), for 1,2,..., 1,2,...,
( *), where 1,2,..., and 1,2,...,
ij
i j
p
pq
q
LL i n j
x x
g
g p mx
= =
= =
X
X
m
q n
=
=
2
(18)
Similarly, a sufficient condition forf(X) to have a relative maximum at X* is that each root of
the polynomial in , defined by equation (17) be negative. If equation (17), on solving yields
roots, some of which are positive and others negative, then the point X* is neither a
maximum nor a minimum.
Example
Minimize
2 2
1 1 2 2 1( ) 3 6 5 7 5f x x x x x= + +X x
Subject to 1 2 5x x+ =
Solution
1 1 2( ) 5 0g x x= + =X
1 2 , 1 2 1 1 2 2( , ,..., , ,..., ) ( ) ( ) ( ) ... ( )n m m mx x x f g g g = + + + +L X X X X
)
with n = 2 and m = 1
L = 2 21 1 2 2 1 2 1 1 23 6 5 7 5 ( 5x x x x x x x x + + + +
1 2 1
1
1 2 1
1
6 6 7
1(7 )
6
15 (7 )
6
x xx
x x
0= + + =
=> + = +
=> = +
L
or 1 23 =
1 2 1
2
1 2 1
1 2 2 1
6 10 5 0
13 5 (5 )
2
13( ) 2 (5 )
2
x xx
x x
x x x
= + + =
=> + = +
=> + + = +
L
D Nagesh Kumar, IISc, Bangalore M2L4
7/29/2019 M2L4_LN
6/6
Optimization Methods: Optimization using Calculus - Equality constraints 6
2
1
2x
=
and, 111
2x =
Hence [ ]1 11
* , ; * 22 2
= =
X 3
11 12 11
21 22 21
11 12
0
0
L L g
L L g
g g
=
2
11 2
1 ( )
6Lx
= =
X*,*
L
2
12 21
1 2 ( )
6L Lx x
= = =
X*,*
L
2
22 2
2 ( )
10Lx
= =
X*,*
L
111
1 ( )
112 21
2 ( )
1
1
ggx
gg g
x
= =
= = =
X*,*
X*,*
The determinant becomes
6 6 1
6 10 1
1 1 0
0 =
or( 6 )[ 1] ( 6)[ 1] 1[ 6 10 ] 0
2
+ + + =
=>=
Since is negative, X*, correspond to a maximum.*
D Nagesh Kumar, IISc, Bangalore M2L4
Recommended