L13 Optimization using Excel

Post on 14-Jan-2016

39 views 2 download

Tags:

description

L13 Optimization using Excel. See revised schedule read 8(1-4) + Excel “help” for Mar 12 Test Answers Review: Convex Prog. Prob. Worksheet modifications Excel optimization Summary. Trendline in Excel. Excel help “trendline” for Wed. Theorem 4.9. Given:. S is convex if: - PowerPoint PPT Presentation

transcript

L13 Optimization using Excel

• See revised scheduleread 8(1-4) + Excel “help” for Mar 12

• Test Answers• Review: Convex Prog. Prob.• Worksheet modifications• Excel optimization• Summary

1

Trendline in Excel

2

Excel help

“trendline”

for Wed

Theorem 4.9

3

}to1,0)(g; to1for,0)(|{

SetConstraint

j mjpihS i

xxx

Given:

S is convex if:1. hi are linear2. gj are convex i.e. Hg PD or PSD

When f(x) and S are convex= “convex programming problem”

“Sufficient” Theorem 4.10, pg 165

4

The first-order KKT conditions are Necessary and Sufficient for a GLOBAL minimum….if:

1. f(x) is convexHf(x) Positive definite

2. x is defined as a convex feasible set SEquality constraints must be linearInequality constraints must be convex

HINT: linear functions are convex!

Worksheet Modifications

• Naming cells• Inserting shapes• Inserting MS Equation “object”• Recording macros• Attaching a macro to a shape• Creating a SOLVER hot button• Visual basic, tools/references/solver

5

6

Figure 6.1 Excel worksheet for finding roots of 2x/3 – sin x : (a) worksheet; (b) worksheet with formulas showing.

Excel Applications

Solver parameters

7

Figure 6.2 A Solver Parameters dialog box to define the problem.

8

Figure 6.3 A Solver Results dialog box and the final worksheet.

9

Figure 6.4 A Solver Answer Report for roots of 2x/3 – sin x = 0.

10

Figure 6.5 Worksheet and Solver Parameters dialog box for KKT conditions for Example 4.31.

11

Figure 6.6 Solver Results for KKT conditions for Example 4.31.

KKT system of NL EQNs

Prob 4.59 and 4.122

12

13

Figure 6.7 Excel worksheet and Solver Parameters dialog box for unconstrained problem.

Constrained Optimization

Prob. 4.69 and 4.122

14

4

13subject to

)3()3(),(

21

21

22

2121

xxg

xxh

xxxxfMin

Graphical Solution

15

21

125.500

075.025.175.025.3

2

1

fsu

xx

16

Figure 6.8 Excel worksheet for the linear programming problem.

17

Figure 6.9 Solver Parameters dialog box for the linear programming problem.

18

Figure 6.10 Solver Results dialog box for the linear programming problem.

19

Figure 6.11 Answer Report from Solver for linear programming problem.

20

Figure 6.12 Sensitivity Report from Solver for the linear programming problem.

21

Figure 6.13 Excel worksheet for the spring design problem.

Summary• KKT pt from a Convex Prog. Prob. Is a

global min!• Use modifications for “ease of use”• Pay attention to layout

– Design variables– Parameters– Analysis/Performance “Variables”– Objective function– Constraints

• May need multiple starting points22