Non Linear Optimization - Additional Exercises - Solution
Non Linear Optimization - Additional Exercises - Solution
Solution:
We define the Lagrangian associated to this problem:
L(x, y, z, l) = 𝑙𝑛 (𝑥) + 2 ln(𝑦) + 3 ln(𝑧) − l(𝑥 + 𝑦 + 𝑧 − 60)
We then derive taking the gradient to 0. We got X=10, y=20 and z=30.
2- The highway department is planning to build a picnic area for motorists along a major
highway. It is to be rectangular with an area of 1000 square meters and is to be fenced off
on the three sides not adjacent to the highway. The objective to identify the least amount of
fencing that will be needed to complete the job
1 2 −3 2
𝑓 = 𝑓B𝑥!, 𝑥# C = − 𝑥 $ E F 𝑥 + 𝑥$ E F − 7
2 −1 1 −1
Solution:
XT=(x1, x2) so replacing in f we got
1
𝑓 = 𝑓B𝑥!, 𝑥# C = −𝑥!# + 2𝑥! 𝑥# − 𝑥## + 2𝑥! − 𝑥# − 7
2
æ -2 x1 + 2 x2 + 2 ö æ -2 2 ö
Ñf ( x1 , x2 ) = ç ÷ H ( x1 , x2 ) = ç ÷
è 2 x1 - x2 - 1 ø è 2 -1ø
x1 = x 0 - H ( x 0 ) -1 Ñf ( x 0 )
æ1 ö
-1 -1 æ -1 -2 ö ç 1÷
The inverse of H is H ( x1 , x2 ) = ç ÷=ç2 ÷
2 è -2 -2 ø ç ÷
è 1 1ø
æ1 ö
æ -1ö ç 1 æ 12 ö æ -1ö æ -1ö æ 0 ö
x = ç ÷ - 2 ÷ç ÷ = ç ÷ - ç ÷ = ç ÷
1
è 4 ø çç 1 1÷÷ è -7 ø è 4 ø è 5 ø è -1ø
è ø
Note that we this solution the gradient is 0 and we got to the optimal solution in one
iteration.