180 likes | 275 Views
Solving MINLP problems with AIMMS. Pittsburgh June 4, 2014 Marcel Hunting AIMMS Software Developer. Overview. Introducing AIMMS Generated Math Program (GMP) Outer Approximation AIMMS Presolver Implement Branch-and-Bound. AIMMS Modeling Structure.
E N D
Solving MINLP problems with AIMMS Pittsburgh June 4, 2014 Marcel HuntingAIMMS Software Developer
Overview Introducing AIMMS Generated Math Program (GMP) Outer Approximation AIMMS Presolver Implement Branch-and-Bound
AIMMS Modeling Structure • AIMMS, integrated & interactive modeling system • Modeling language, integrated GUI, direct access to solvers,advanced deployment options,and extensive development tools
AIMMS Modeling Structure • AIMMS, integrated & interactive modeling system • Modeling language, integrated GUI, direct access to solvers,advanced deployment options,and extensive development tools
Model generation Columns: • c0 … c48 • c49 … c118 • c119 • Rows: • r0 … r6 • r7 … r13 • r14 … r76 • r77 … r136 Variables: JobSchedule(j,s) StartTime(s,m) TimeSpan Constraints: OneJobPerSchedule(s) OneSchedulePerJob(j) MachineStartTime(s,m) ScheduleStartTime(s,m) Solve
Symbolic MP Generated MP Matrix • symbolic variables • symbolic constraints • generated columns • generated rows • generated matrix coefficients • mappings from/to variables and constraints Solution Repository • 1 • solution status • level values • [basis information] • 2 • solution status • level values • [basis information] . . . Pool of Solver Sessions • 1 • solver • option settings • 2 • solver • option settings . . . Generated Math Program (GMP)
Basic GMP Normally: solve MathProgram; GMP: myGMP:= GMP::Instance::Generate(MathProgram); GMP::Instance::Solve(myGMP); Modify: GMP::Column::SetUpperBound(myGMP,StartTime(s1,m1),5);
Selection of GMP functions GMP::Instance:: Generate, Solve, Copy, FixColumns,CreateFeasibilityProblem, CreatePresolved GMP::Column:: Add, Delete, Freeze, SetLowerBound GMP::Row:: Add, Delete, SetRightHandSide GMP::Coefficient:: Set, Get, SetQuadratic, GetQuadratic GMP::Solution:: Copy, SendToModel, GetColumnValue GMP::Linearization:: Add, Delete GMP::SolverSession:: Execute, AsynchronousExecute
Outer Approximation module • Module: GMPOuterApproximation • Call: myGMP:= GMP::Instance::Generate( myMathProgram) ; GMPOuterApprox::DoOuterApproximation( myGMP); • Uses AIMMS presolver by default • Can be combined with Multi-start module • Quesada & Grossmann(1992) versionfor convex MINLP • Uses lazy constraints callback • Uses nested solve
AIMMS Presolver • Delete redundant constraints & fixed variables • Bound Tightening - Feasibility based • Variable x: range [0,inf)-►range [10,55] • Linear & nonlinear constraints • Improve coefficients (possibly using probing) • Linearize quadratic constraints
Linearize quadratic constraints Constraint (binary, and continuous or integer) Linearization:
Branch-and-Bound MINLP problem with binary variables x(i) and y(i,j). Implement branching; choose most fractional column. gmpBB: Generated Math Program for a node in B&B tree
Branching for (i) do xLev(i) := GMP::Column::GetColumnValue( gmpBB, 1, x(i) ); xHalfGap(i) := abs( xLev(i) - 0.5 ); endfor; xMostFractionalColumn := ArgMin( i, xHalfGap(i) ); for(i,j) do yLev(i,j) := GMP::Column::GetColumnValue( gmpBB, 1, y(i,j) ); yHalfGap(i,j) := abs( yLev(i,j) - 0.5 ); endfor; yMostFractionalColumn:= ArgMin( (i,j), yHalfGap(i,j) ); MostFractionalColumn := …
Branching - Improved Vars := { ‘x’, ‘y’ }; ColNrs:= GMP::Instance::GetColumnNumbers( gmpBB, Vars ); For example: ColNrs = {3,4,…,10,20,21,…,43} index: c for(c) do Lev(c) := GMP::Column::GetColumnValue( gmpBB, 1, c ); HalfGap(c) := abs( Lev(c) - 0.5 ); endfor; MostFractionalColumn:= ArgMin( c, HalfGap(c) );
Branching - Improved Vars := AllIntegerVariables; ColNrs:= GMP::Instance::GetColumnNumbers( gmpBB, Vars ); For example: ColNrs = {3,4,…,10,20,21,…,43} index: c for(c) do Lev(c) := GMP::Column::GetColumnValue( gmpBB, 1, c ); HalfGap(c) := abs( Lev(c) - 0.5 ); endfor; MostFractionalColumn:= ArgMin( c, HalfGap(c) );