solving business problems with sas analytics and optmodel
Post on 20-Oct-2021
3 Views
Preview:
TRANSCRIPT
Copyright c©2013, SAS Institute Inc. All rights reserved.
Solving Business Problemswith SAS Analyticsand OPTMODEL
Pre-Conference WorkshopINFORMS Annual MeetingMinneapolis, MN
SAS Institute Inc.
October 5, 2013
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
Background on SAS
Founded in 1976World’s largest privatelyheld software companyOver 400 offices worldwideOver 800 alliances globallyOver 65,000 customersites in 135 countriesSAS customers, affiliates:90 of top 100 companies in2012 Fortune Global 500Hundreds of local usergroups
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS Data Sets, Language, Terminology
SAS data set: tabular data file» Rows are “observations”» Columns are “variables”» Created with SAS DATA step and/or SQL» Read from / write to all major data formats
SAS programming language base: data handling andexploration, elementary statistics, wide range of functions
Software modules are procedures, abbreviated “PROC”
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS Data Sets and External Data Formats
SAS has several ways (programmatic, point and click)to convert any data in tabular form into a SAS data set
» DATA step functionality» PROC IMPORT» Enterprise Guide
Through SAS ACCESS engines, can create SAS viewsto any commonly used database
» Data appears as SAS data sets to SAS, but remains in thenative database format
» SAS can write results back to the native database format
Copyright c©2013, SAS Institute Inc. All rights reserved.
Overview of SAS Functions
Mathematical, Arithmetic, TruncationArrayCharacterDate and TimeFinancialProbability DistributionsTrigonometric, HyperbolicRandom Number GenerationSample Statistics, Quantiles
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS Products and Solutions
SAS products: breadth and depth» Data Integration: access, cleansing, metadata creation» Business Intelligence: query, reporting, visualization» Analytics: statistics, forecasting, data mining, text mining,
quality control, optimization, scheduling, simulation
SAS solutions» Cross-Industry: Customer Intelligence, Supply Chain
Intelligence, Predictive Asset Maintenance, RiskManagement, Sustainability Management, SecurityIntelligence, Visual Analytics
» Industry-Specific: Retail, Oil and Gas, Manufacturing,Energy & Utilities, Financial Services, Health Care, LifeSciences, Insurance, Communications, Media, Hotels,Casinos, Travel & Transportation, Government, Education,Defense & Aerospace
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS Products and Solutions
SAS products: breadth and depth» Data Integration: access, cleansing, metadata creation» Business Intelligence: query, reporting, visualization» Analytics: statistics, forecasting, data mining, text mining,
quality control, optimization, scheduling, simulation
SAS solutions» Cross-Industry: Customer Intelligence, Supply Chain
Intelligence, Predictive Asset Maintenance, RiskManagement, Sustainability Management, SecurityIntelligence, Visual Analytics
» Industry-Specific: Retail, Oil and Gas, Manufacturing,Energy & Utilities, Financial Services, Health Care, LifeSciences, Insurance, Communications, Media, Hotels,Casinos, Travel & Transportation, Government, Education,Defense & Aerospace
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS-Related Presentations at INFORMS
SA04 New Approaches to Mixed Integer Programming HeuristicsMenal Güzelsoy, Philipp Christophel, Imre Pólik
SB29 JMP Software from SASJian Cao
MA08 Recent Improvements in SAS/OR Optimization SolversImre Pólik, Philipp Christophel, Menal Güzelsoy, Yan Xu, Amar Narisetty
MA29 SAS Global Academic Program: High-Performance Data Mining withSAS Enterprise MinerAndré de Waal
MB34 ARD: An Automated Replication-Deletion Method for SimulationAnalysisEmily Lada, Anup Mokashi, James Wilson
MC08 New Features in OPTMODEL: Parallel Coroutines and SemanticModelingLeo Lopes
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS-Related Presentations at INFORMS(cont.)
MC23 The Value of the Price EnvelopeBahadir Aral
MC23 Revenue Management as a Strategic ToolMaarten Oosten
MD08 Dip and DipPy: A Decomposition-based Modeling System and Solverco-author Matthew Galati
MD10 Managing Successful Careers in O.R. Practice - A Panel Discussionincluding Radhika Kulkarni
MD29 Building and Solving Optimization Models with SASEd Hughes, Rob Pratt
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS-Related Presentations at INFORMS(cont.)
TA04 A Generalized Benders’ Algorithm for the Two-stage Stochastic MixedInteger Linear Problemco-author Menal Güzelsoy
TC65 Social Media Intelligence for Regional InstabilityTom Sabo, Sr.
WB06 P-median and P-dispersion Problems: A Bi-criteria AnalysisGolbarg Tutunchi, Fatemeh Sayyady
WB19 FlowBalancer Supports Strategic and Tactical Planning Problems byusing Analytical Queueing ModelsNico Vandaele, Kris Lieckens (KU Leuven)
WB30 Two-stage Stochastic View Selection for Data-analysis Queries:Properties and AlgorithmsRong Huang
WD23 Multicriteria Model for Price and Promotion OptimizationNatalia Viktorovna, Maarten Oosten
Copyright c©2013, SAS Institute Inc. All rights reserved.
The Scope of SAS/OR
1. Mathematical optimization
2. Discrete event simulation
3. Constraint programming
4. Global and local search
5. Project and resource scheduling
Copyright c©2013, SAS Institute Inc. All rights reserved.
Broad Range of Optimization SolversLinear Programming:
» Primal, Dual, Network Simplex» Interior Point» Concurrent
Mixed Integer Linear Programming:» Branch and Bound with heuristics, cuts, conflict search» Decomposition algorithm (MILP and LP)
Network Algorithms
Quadratic Programming:» Interior Point
Nonlinear Programming:» Active Set» Interior Point» Multistart, Concurrent
Copyright c©2013, SAS Institute Inc. All rights reserved.
DECOMP (Decomposition) Algorithm
New in SAS/OR 12.1Accessible in PROC OPTMODELUser conveys block structure via .block constraint suffixsolve with LP|MILP / decomp=(method=user);
Master and subproblems generated and solvedautomatically and in parallelFor block-angular problems, dramatic performanceimprovements over direct solverIn SAS/OR 13.1, automatically detects identicalsubproblems and uses Ryan-Foster branching if applicable
Copyright c©2013, SAS Institute Inc. All rights reserved.
Network Algorithms
PROC OPTNET (new in SAS/OR 12.1)PROC OPTMODEL:
» SUBMIT block (new in SAS/OR 12.1)» SOLVE WITH NETWORK (new in SAS/OR 13.1)
Connected componentsBiconnected componentsand articulation pointsMaximal cliquesCyclesTransitive closureLinear assignmentproblem
Shortest path problemMinimum-cost network flowproblemMinimum spanning treeproblemMinimum cut problemTraveling salesmanproblem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Global and Local Search Optimization
PROC OPTLSO (new in SAS/OR 12.3)For black-box objectivesContinuous and discrete variablesLinear and nonlinear constraintsParallel execution of:
» Local search methods» Global GA-type heuristics» Pattern search
Objective can be an aggregation over an externalpre-distributed data setArray-structured input data supported
Copyright c©2013, SAS Institute Inc. All rights reserved.
Other Recent and Upcoming Enhancementsin SAS/OR 12.1 through 13.1
Concurrent LP and NLP solversParallel MILP option tunerParallel NLP multistartSAS code block (SUBMIT/ENDSUBMIT) in OPTMODELParallel FOR loop (COFOR) in OPTMODELNetwork algorithms access from OPTMODELCutting plane strategy and conflict search for MILPParallel MILP algorithmCrossover enhancements for LP interior point algorithm
Copyright c©2013, SAS Institute Inc. All rights reserved.
SAS Optimization-Based Solutions
SAS MarketingOptimizationSAS Service PartsOptimizationSAS Contact CenterPlanning and OptimizationSAS Revenue OptimizationSuiteSAS Size OptimizationSAS Credit Scoring forBanking
SAS Risk Management forBanking, for InsuranceSAS Social NetworkAnalysisSAS InventoryOptimizationSAS Enterprise DecisionManagementSAS RevenueManagement and PriceOptimization Analytics
Copyright c©2013, SAS Institute Inc. All rights reserved.
OPTMODEL: Major Features
Algebraic modeling language with optimization-orientedsyntax:
» Variables, constraints, bounds, objective» Algebraic expression of functions» Parameters, variables, arrays, index sets
Tight integration with SAS programming environmentFlexible input/output: read from and create data setsInteractive environmentDirect access to LP, MILP, Network, QP, NLP solversSupport for customized algorithms
Copyright c©2013, SAS Institute Inc. All rights reserved.
OPTMODEL Programming Statements
Control and Looping:» DO, IF, etc.» DO iterative, DO UNTIL, DO WHILE, etc.» FOR, COFOR
General» CALL» SUBMIT/ENDSUBMIT
Input/Output:» READ DATA, CREATE DATA: working with SAS data sets» SAVE MPS, SAVE QPS» FILE, PRINT, PUT
Model Management:» SOLVE» PROBLEM/USE PROBLEM (named models)» DROP/RESTORE (constraints), FIX/UNFIX (variables)» EXPAND (selective or overall)
Copyright c©2013, SAS Institute Inc. All rights reserved.
OPTMODEL Expressions Overview
Aggregation operators (evaluate an expression or a setexpression over an index set):
» SUM, PROD, MAX, MIN» INTER aggregation, UNION aggregation» SETOF, AND aggregation, OR aggregation
Set operators:» IN, WITHIN» INTER, UNION, SYMDIFF, DIFF» CROSS, SLICE
Logical:» Conditional: IF-THEN-ELSE» Boolean: AND, OR
Scalar and set expressions
Copyright c©2013, SAS Institute Inc. All rights reserved.
Basics of the SAS Macro Language
Macros: parameterized blocks of SAS codeMacro variables:
» Assigning a value: %let varname=<value>;» Using: &varname
Declaring a macro:%macro macroname (param1, param2);<SAS code>
%mend macroname;
Invoking a macro:%macroname (<value1>, <value2>);Special code within macros:
» %if &varname=<value> %then %do; ...%end;» %do n=1 %to &number;...%end;
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
Multicommodity Flow Problem
Given directed network (N,A) and commodities K
Each node i ∈ N has supply bki for commodity k ∈ K
Each arc (i, j) ∈ A has:» cost cij per unit of flow» capacity uij that limits sum of flows of commodities
Satisfy all supplies and demands at minimum cost, whilerespecting arc capacitiesTwo approaches:
» Direct LP» Dantzig-Wolfe Decomposition
Copyright c©2013, SAS Institute Inc. All rights reserved.
Example Network with Two Commodities
110 2 −10
3 4
520 6 −20
(c = 1, u = 5)
(5, 30)
(1, 10)
(5, 30)
(1, 30)(1, 30)
(5, 30)
Copyright c©2013, SAS Institute Inc. All rights reserved.
Optimal Solution
110 2 −10
3 4
520 6 −20
(c = 1, u = 5)
(5, 30)
(1, 10)
(5, 30)
(1, 30)(1, 30)
(5, 30)
5
5
5 5
5
55
15
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
cijxkij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K
xkij ≥ 0 (i, j) ∈ A, k ∈ K
var Flow {ARCS, COMMODITIES} >= 0;min TotalCost =
sum {<i,j> in ARCS, k in COMMODITIES} cost[i,j] * Flow[i,j,k];con Linking {<i,j> in ARCS}:
sum {k in COMMODITIES} Flow[i,j,k] <= capacity[i,j];con Balance {i in NODES, k in COMMODITIES}:
sum {<(i),j> in ARCS} Flow[i,j,k]- sum {<j,(i)> in ARCS} Flow[j,i,k] = supply[i,k];
Copyright c©2013, SAS Institute Inc. All rights reserved.
Multicommodity Flow Problem: Direct LP
OPTMODEL codeMulticommodityFlow.sas
Copyright c©2013, SAS Institute Inc. All rights reserved.
Constraint Matrix for Example Network
1 11 1
1 11 1
1 11 1
1 11 1−1 −1
−1 −1 1−1 1 1
1 1−1 −1
1 1−1 −1
−1 −1 1−1 1 1
1 1−1 −1
Copyright c©2013, SAS Institute Inc. All rights reserved.
Block-Angular Structure
A1 A2 · · · A|K|B1
B2. . .
B|K|
Copyright c©2013, SAS Institute Inc. All rights reserved.
Linear Programming Formulation
minimize∑
(i,j)∈A
∑k∈K
ckijx
kij
subject to∑k∈K
xkij ≤ uij (i, j) ∈ A (1)∑
(i,j)∈A
xkij −
∑(j,i)∈A
xkji = bk
i i ∈ N, k ∈ K (2)
xkij ≥ 0 (i, j) ∈ A, k ∈ K (3)
Dantzig-Wolfe DecompositionMaster: (1)Subproblem: (2)-(3)
Copyright c©2013, SAS Institute Inc. All rights reserved.
DECOMP (Decomposition) Algorithm
New in SAS/OR 12.1Accessible in PROC OPTMODELUser conveys block structure via .block constraint suffixsolve with LP|MILP / decomp=(method=user);
Master and subproblems generated and solvedautomatically and in parallelFor block-angular problems, dramatic performanceimprovements over direct solverIn SAS/OR 13.1, automatically detects identicalsubproblems and uses Ryan-Foster branching if applicable
Copyright c©2013, SAS Institute Inc. All rights reserved.
DECOMP: METHOD= Option
USER: User defines the subproblems using constraint suffix.block
NETWORK: Finds an embedded network [Bixby88] and usesthe weakly connected components as subproblem blocksAUTO: Searches for disjoint blocks (no master constraints)after presolve
Copyright c©2013, SAS Institute Inc. All rights reserved.
Multicommodity Flow Problem:Decomposition Algorithm
OPTMODEL codeMulticommodityFlowDecomp.sas
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
Network Algorithms in SAS/OR
Connected componentsBiconnected components and articulation pointsMaximal cliquesCyclesTransitive closureLinear assignment problemShortest path problemMinimum-cost network flow problemMinimum spanning tree problemMinimum cut problemTraveling salesman problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Network Algorithm for Shortest Path
PROC OPTNET can be called directly:» Reads arc data set via DATA_LINKS= option» By default, SHORTPATH statement invokes all-pairs
shortest paths solver» Can specify SOURCE= and SINK= to solve s-t shortest
path problem
PROC OPTNET can also be called from within PROCOPTMODEL via SUBMIT/ENDSUBMITIn SAS/OR 13.1, network algorithms accessible usingSOLVE WITH NETWORK statement in PROC OPTMODEL
Copyright c©2013, SAS Institute Inc. All rights reserved.
Network Algorithm
OPTMODEL codeShortestPathOPTNET.sas
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
COFOR LoopUses multiple threads to execute SOLVE statements inparallel across iterations of loopSyntax for serial FOR loop:
for {i in ISET} do;...solve ...;...
end;
Syntax for parallel COFOR loop:cofor {i in ISET} do;
...solve ...;...
end;
Copyright c©2013, SAS Institute Inc. All rights reserved.
Milk Collection: Periodic VRPH.P. Williams, Model Building in MathematicalProgramming (2013)SAS/OR R© 12.3 User’s Guide: Mathematical ProgrammingExamples (2013)Scheduling and routing milk collection trucks
» Truck collects milk from dairy farms» Each farm’s collection frequency is daily or every other day
1
2
3
4
5
6
7
8
9
10
11
1213
14
15
16
17
18
19
2021
-6 -4 -2 0 2 4 6
-5
0
5
10
12frequency
day = 1
1
2
3
4
5
6
7
8
9
10
11
1213
14
15
16
17
18
19
2021
-6 -4 -2 0 2 4 6
-5
0
5
10
12frequency
day = 2
Copyright c©2013, SAS Institute Inc. All rights reserved.
Benders Decomposition
Combinatorial Benders Decomposition with a TSPsubproblem oracleMaster problem decides which nodes (farms) to visit eachday and enforces:
» capacity, frequency, and symmetry breaking» optimality cuts (generated by subproblem)
Subproblem is a TSP for each day» generates optimality cuts for the master» uses specialized TSP solver» subset of nodes changes at each iteration
Copyright c©2013, SAS Institute Inc. All rights reserved.
Milk Collection Problem: BendersDecomposition using SOLVE WITHNETWORK and COFOR loop (both new inSAS/OR 13.1)
OPTMODEL codeMilkCollectionBendersNetworkCofor.sas
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
SUBMIT Block
Access the full SAS system without exiting OPTMODELBuild novel dynamic algorithms using statistics, matrixmanipulation, visualization, interaction, etc.Syntax:
proc optmodel;...submit [arguments] [/ options];
[arbitrary SAS code]endsubmit;...
quit;
Copyright c©2013, SAS Institute Inc. All rights reserved.
Cardinality Constrained Regression: WhichRegressors Produce the Best Fit?
Multivariate linear regression
Y = Xβ + β0e + ε,
whereY ∈ Rm, X ∈ Rm×n are datae ∈ Rm is vector of onesβ ∈ Rn, β0 ∈ R, ε ∈ Rm are decision variables
Letz ∈ {0, 1}n: indicator variables for βk: user input number of regressors to allow
Minimize the SSE over all models with k or fewer regressors.
Copyright c©2013, SAS Institute Inc. All rights reserved.
Cardinality Constrained Regression: WhichRegressors Produce the Best Fit?
Multivariate linear regression
Y = Xβ + β0e + ε,
whereY ∈ Rm, X ∈ Rm×n are datae ∈ Rm is vector of onesβ ∈ Rn, β0 ∈ R, ε ∈ Rm are decision variables
Letz ∈ {0, 1}n: indicator variables for βk: user input number of regressors to allow
Minimize the SSE over all models with k or fewer regressors.
Copyright c©2013, SAS Institute Inc. All rights reserved.
Cardinality Constrained Regression: WhichRegressors Produce the Best Fit?
Multivariate linear regression
Y = Xβ + β0e + ε,
whereY ∈ Rm, X ∈ Rm×n are datae ∈ Rm is vector of onesβ ∈ Rn, β0 ∈ R, ε ∈ Rm are decision variables
Letz ∈ {0, 1}n: indicator variables for βk: user input number of regressors to allow
Minimize the SSE over all models with k or fewer regressors.
Copyright c©2013, SAS Institute Inc. All rights reserved.
Benders Decomposition
Master is selection problem (over z)Can include any rule expressible as a MILP (e.g., subsetcardinality, clique constraints)Optimality cut for each regressor subset and all its subsetsSubproblem is just linear regression (β, ε), so can usePROC REG
Copyright c©2013, SAS Institute Inc. All rights reserved.
Cardinality Constrained Regression:Benders Decomposition using SUBMIT tocall PROC REG
OPTMODEL codeRegressionBendersSubmit.sas
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
Problem Statement
Given undirected graph, node weights, positive integer k,target t ∈ [`, u]
Partition node set into k subsets, each with total weightwithin [`, u]
Usual objective: minimize sum of edge weights betweenparts of partitionOur objective: find most “balanced” partition
» Minimize total absolute deviation of subset weight fromtarget (L1 norm)
» Minimize maximum absolute deviation of subset weightfrom target (L∞ norm)
Connectivity constraints: each of the k resulting inducedsubgraphs must be connected
Copyright c©2013, SAS Institute Inc. All rights reserved.
Motivation
Dennis E. Shasha, Doctor Ecco’s Cyberpuzzles (2002)» Political districting
AAOS consulting engagement» Assigning service workers to customer regions
INFORMS OR Exchange posting (Jan. 2013)http://www.or-exchange.com/questions/7248/
graph-partitioning-with-connectivity-constraints
» Forestry
Copyright c©2013, SAS Institute Inc. All rights reserved.
Solution for k = 14, t = 12000, [`, u] = t ± 100
Copyright c©2013, SAS Institute Inc. All rights reserved.
Solution Approaches
Compact MILP formulation with IsCapital[i] binaryvariables and nonnegative flow variablesRow generation, dynamically excluding disconnectedsubsetsColumn generation, dynamically generating connectedsubsetsColumn generation, statically generating all possibleconnected subsets
Copyright c©2013, SAS Institute Inc. All rights reserved.
Solution Approaches
Compact MILP formulation with IsCapital[i] binaryvariables and nonnegative flow variablesRow generation, dynamically excluding disconnectedsubsetsColumn generation, dynamically generating connectedsubsetsColumn generation, statically generating all possibleconnected subsets
Copyright c©2013, SAS Institute Inc. All rights reserved.
Solution Approaches
Compact MILP formulation with IsCapital[i] binaryvariables and nonnegative flow variablesRow generation, dynamically excluding disconnectedsubsetsColumn generation, dynamically generating connectedsubsetsColumn generation, statically generating all possibleconnected subsets
Copyright c©2013, SAS Institute Inc. All rights reserved.
Solution Approaches
Compact MILP formulation with IsCapital[i] binaryvariables and nonnegative flow variablesRow generation, dynamically excluding disconnectedsubsetsColumn generation, dynamically generating connectedsubsetsColumn generation, statically generating all possibleconnected subsets
Copyright c©2013, SAS Institute Inc. All rights reserved.
Solution Approaches
Compact MILP formulation with IsCapital[i] binaryvariables and nonnegative flow variablesRow generation, dynamically excluding disconnectedsubsetsColumn generation, dynamically generating connectedsubsetsColumn generation, statically generating all possibleconnected subsets
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Main Steps
1. Generate all possible connected subsets with weightsclose enough to target1.1 Relax connectivity and find all possible subsets1.2 Postprocess to filter out disconnected subsets
2. Solve cardinality constrained set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Main Steps
1. Generate all possible connected subsets with weightsclose enough to target1.1 Relax connectivity and find all possible subsets1.2 Postprocess to filter out disconnected subsets
2. Solve cardinality constrained set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Main Steps
1. Generate all possible connected subsets with weightsclose enough to target1.1 Relax connectivity and find all possible subsets1.2 Postprocess to filter out disconnected subsets
2. Solve cardinality constrained set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Features Used inPROC OPTMODEL
MILP solver to compute maximum subset size for eachnode (COFOR loop)SOLVE WITH NETWORK (all-pairs shortest path) togenerate valid cuts that encourage connectivityFILE and PUT statements to generate PROC CLP codeSUBMIT block to call PROC CLP (later, SOLVE WITHCLP)SOLVE WITH NETWORK (connected components) tocheck connectivity (COFOR loop)MILP solver to solve set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Features Used inPROC OPTMODEL
MILP solver to compute maximum subset size for eachnode (COFOR loop)SOLVE WITH NETWORK (all-pairs shortest path) togenerate valid cuts that encourage connectivityFILE and PUT statements to generate PROC CLP codeSUBMIT block to call PROC CLP (later, SOLVE WITHCLP)SOLVE WITH NETWORK (connected components) tocheck connectivity (COFOR loop)MILP solver to solve set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Features Used inPROC OPTMODEL
MILP solver to compute maximum subset size for eachnode (COFOR loop)SOLVE WITH NETWORK (all-pairs shortest path) togenerate valid cuts that encourage connectivityFILE and PUT statements to generate PROC CLP codeSUBMIT block to call PROC CLP (later, SOLVE WITHCLP)SOLVE WITH NETWORK (connected components) tocheck connectivity (COFOR loop)MILP solver to solve set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Features Used inPROC OPTMODEL
MILP solver to compute maximum subset size for eachnode (COFOR loop)SOLVE WITH NETWORK (all-pairs shortest path) togenerate valid cuts that encourage connectivityFILE and PUT statements to generate PROC CLP codeSUBMIT block to call PROC CLP (later, SOLVE WITHCLP)SOLVE WITH NETWORK (connected components) tocheck connectivity (COFOR loop)MILP solver to solve set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Features Used inPROC OPTMODEL
MILP solver to compute maximum subset size for eachnode (COFOR loop)SOLVE WITH NETWORK (all-pairs shortest path) togenerate valid cuts that encourage connectivityFILE and PUT statements to generate PROC CLP codeSUBMIT block to call PROC CLP (later, SOLVE WITHCLP)SOLVE WITH NETWORK (connected components) tocheck connectivity (COFOR loop)MILP solver to solve set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Static Column Generation: Features Used inPROC OPTMODEL
MILP solver to compute maximum subset size for eachnode (COFOR loop)SOLVE WITH NETWORK (all-pairs shortest path) togenerate valid cuts that encourage connectivityFILE and PUT statements to generate PROC CLP codeSUBMIT block to call PROC CLP (later, SOLVE WITHCLP)SOLVE WITH NETWORK (connected components) tocheck connectivity (COFOR loop)MILP solver to solve set partitioning problem
Copyright c©2013, SAS Institute Inc. All rights reserved.
Column Generation Subproblem
Given node populations pi and target population range [`, u]
Find all connected node subsets close to target populationBinary variable xi to indicate whether node i appears insubset` ≤
∑i∈N
pixi ≤ u
Connectivity hard to impose directly, so relax (but do notignore)
Copyright c©2013, SAS Institute Inc. All rights reserved.
Valid Subproblem Cuts to EncourageConnectivity: Nodes Too Far Apart
mi: max # nodes among feasible subsets containing node iIf shortest path distance dij ≥ min(mi,mj) then xi + xj ≤ 1
Copyright c©2013, SAS Institute Inc. All rights reserved.
Valid Subproblem Cuts to EncourageConnectivity: Isolated Nodes
If xi = 1 and pi < ` then xj = 1 for some neighbor j of ixi ≤
∑j∈Ni
xj
Copyright c©2013, SAS Institute Inc. All rights reserved.
Valid Subproblem Cuts to EncourageConnectivity: Isolated Edges
If xi = xj = 1 and pi + pj < ` then xk = 1 for some neighbor kxi + xj − 1 ≤
∑k∈(Ni∪Nj)\{i,j} xk
Copyright c©2013, SAS Institute Inc. All rights reserved.
Valid Subproblem Cuts to EncourageConnectivity: Isolated Edges (Stronger Cuts)
If (xi = 1 or xj = 1) and pi + pj < ` then xk = 1 for someneighbor k in moat around {i, j}xi ≤
∑k∈(Ni∪Nj)\{i,j}
xk
xj ≤∑
k∈(Ni∪Nj)\{i,j}xk
Copyright c©2013, SAS Institute Inc. All rights reserved.
Valid Subproblem Cuts to EncourageConnectivity: Sets with Small Population
More generally, if xi = 1 for some i ∈ S ⊂ N such that∑j∈S
pj < ` then xk = 1 for some neighbor k in moat around S
xi ≤∑
k∈(∪j∈SNj)\Sxk
Known as “ring inequalities” in the literature
Copyright c©2013, SAS Institute Inc. All rights reserved.
Graph Partitioning with ConnectivityConstraints
OPTMODEL codeGraphPartitioningConnectivity.sas
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
Business Problem
Given daily insurance claims and availability of adjustersObjective:
» Increase efficiency of claim processing» Provide user capability to visualize current state of workload
Optimization problem: Distribute claims evenly amongadjusters while considering eligibility and capacityconstraints
Copyright c©2013, SAS Institute Inc. All rights reserved.
Mathematical Model
Objective» Minimize workload deviation among adjusters
Decision» Which claims assigned to which adjuster
Assignment eligibility» Skill level (hard constraints)» Location (soft constraints)
Capacity requirements based on skill level of adjuster» Limit on total weighted load» Limit on number of newly assigned claims
Copyright c©2013, SAS Institute Inc. All rights reserved.
Insurance Claim Assignment Optimization
Planning horizon: 5 monthsClaims
» Average number of claims per day: 80» Type: auto, home
Adjusters» Number of adjusters: 20» Job grade: 1,2,3
Skills: Construction, auto body, paralegal, software, . . .Geographical regions in Florida: North, Central, South
Copyright c©2013, SAS Institute Inc. All rights reserved.
Insurance Claim Assignment Optimization
Interface written in Adobe Flash/FlexCalls PROC OPTMODEL code as stored processCommunication via SAS data sets and SAS macrolanguage
Launch Insurance Claim Assignment Optimization Demo
Copyright c©2013, SAS Institute Inc. All rights reserved.
Outline
1 SAS/OR Introduction
2 Multicommodity Flow Problem
3 Network Algorithms
4 COFOR Loop
5 SUBMIT Block
6 Graph Partitioning with Connectivity Constraints
7 Customer Case Study: Insurance Claim Assignment
8 Sample Consulting Engagements
Copyright c©2013, SAS Institute Inc. All rights reserved.
Sample Consulting Engagements
Advanced Analytics and Optimization Services» Part of Advanced Analytics Division in R&D» Ph.D.-level developers/consultants
Areas of Focus» Generic Optimization Details
» Simulation Details
» Revenue Management Details
» Inventory Optimization Details
Copyright c©2013, SAS Institute Inc. All rights reserved.
Sample Consulting Engagements:Generic Optimization
Investment portfolio optimization Details
Optimal ATM replenishment Details
Optimal loan assignment Details
Chemical mixture optimization Details
Water management Details
Casino floor mix optimization Details
Copyright c©2013, SAS Institute Inc. All rights reserved.
Sample Consulting Engagements:Simulation
Simulation for discovery oncology Details
Prison population simulation Details
Copyright c©2013, SAS Institute Inc. All rights reserved.
Sample Consulting Engagements:Revenue Management (RM) and Pricing
RM framework for car rental Details
RM framework for cruise line Details
Show ticket RM Details
Pricing and inventory optimization Details
Copyright c©2013, SAS Institute Inc. All rights reserved.
Sample Consulting Engagements:Inventory Optimization (IO)
Retail inventory replenishment Details
IO for spare parts Details
IO for automotive Details
IO for construction equipment Details
Copyright c©2013, SAS Institute Inc. All rights reserved.
Investment Portfolio Optimization
Customer: Large US Government AgencyInvestment portfolio optimization
» Portfolio mix: T-Bills, T-Notes, CDs» Suggested investment strategy for 5 years» Discrete: minimum investment requirements
MILPSAS tools:
» SAS Forecast Studio» SAS/OR: OPTMODEL, MILP solver
Generalized network flow formulation
Copyright c©2013, SAS Institute Inc. All rights reserved.
Simulation for Discovery Oncology
Customer: Large Global PharmaceuticalDiscrete Event Simulation for Oncology Drug Discovery
» Synthesizing and testing drug compounds is very expensive» Goal is to find a candidate compound for clinical trials:
» Faster—reduce time to market» Cheaper—reduce cost of assay testing» More reliably—increase chance of success in trials
» Major strategies to evaluate via simulation:» Which compound to synthesize next?» Which compounds to send to which assays?» When to stop testing a compound?» How to identify a good clinical candidate?
SAS Simulation Studio
Copyright c©2013, SAS Institute Inc. All rights reserved.
ATM Cash Optimization Overview
Customer: Large South-East Asian BankATM cash replenishment optimization
» Large number of ATMs» Side constraints (capacity, etc)
MILPSAS tools:
» SAS Forecast Studio: demand forecasting» SAS/OR: OPTMODEL, MILP solver
Reformulated for tractability
Copyright c©2013, SAS Institute Inc. All rights reserved.
Retail Inventory Replenishment
Customer: Large Retail CompanyRetail Inventory Replenishment
» Large number of SKUs, locations, and vendors» Demand forecast» Reorder point to satisfy service level» Order decisions
Stochastic optimization at storesMILP optimization at depotsSAS tools:
» SAS/OR: OPTMODEL, MILP solver» SAS Forecast Studio: demand forecasting
Copyright c©2013, SAS Institute Inc. All rights reserved.
Optimal Loan Assignment
Customer: Large US BankLoan Assignment Optimization
» Goal: assign new loans (foreclosures, short sales, etc)» Minimize standard deviation between teams» Resource pool: CRMs (Customer Relationship Managers)
teams and PS (Process Support) resources» Constraints: maximum case loads, limits on case types, etc.» Eligibility rules: case type match, geographical (time zone),
language, etc.Difficult problem (MINLP):
» Nonlinear objective (standard deviation)» Binary variables (assignment)
SAS tools:» SAS/OR: OPTMODEL, MILP solver» SAS/DI and SAS/BI for data integration and reporting
Copyright c©2013, SAS Institute Inc. All rights reserved.
Mixture Optimization
Customer: Large US CPG CompanyOptimization of raw material portfolio for manufacturing
» Minimum cost portfolio problem» Nonlinear performance constraints» Discrete: assignment constraints
MINLPSAS tools:
» SAS/OR: OPTMODEL, MILP solver, NLP solver» JMP» (Future) SAS/Grid Manager: parallel computations
Completely custom algorithm
Copyright c©2013, SAS Institute Inc. All rights reserved.
Revenue Management for Car Rental
Customer: Large US Car Rental CompanyBusiness Analytics Framework developmentOptimizing for growth (market share)Automate RM processPricing and reservation system
» Data integration» Segmentation» Forecasting: unconstrained demand by segment and length
of rent» Optimization: automatic generation of step
recommendations
RMPO with extensions
Copyright c©2013, SAS Institute Inc. All rights reserved.
Show Ticket Revenue Management
Customer: Large US ResortAttendance forecastShow ticket availability optimizationDemand channel managementSAS tools:
» RMPO with extensions» SAS/OR: OPTMODEL, QP solver
Copyright c©2013, SAS Institute Inc. All rights reserved.
Revenue Management for Cruise Line
Customer: Large US Entertainment CompanyBusiness Analytics Framework developmentAutomate pricing and availability management processAccount for multiple constraintsPricing and revenue management system
» Data integration» Segmentation» Forecasting: unconstrained demand by segment» Estimation: demand response to changes in pricing
strategy» Optimization: automatic generation of pricing and
availability recommendations
RMPO with extensions
Copyright c©2013, SAS Institute Inc. All rights reserved.
Pricing and Inventory Optimization
Customer: Large US RetailerProduct promotion optimization
» Retail pricing and inventory network» Non-convex NLP» Discrete side constraints
Multi-objective NLPSAS tools:
» SAS/OR: OPTMODEL, NLP and MILP solvers
Customized heuristics
Copyright c©2013, SAS Institute Inc. All rights reserved.
Spare Parts Inventory Optimization
Customer: Injection Molding SystemsInventory Replenishment
» Large number of SKUs» Three warehouses in America, Europe, and Asia» Demand forecast» Reorder point to satisfy service level» Order decisions
Stochastic optimization at warehousesInventory balancing across warehousesSAS tools:
» SAS Forecast Studio: demand forecasting» PROC MIRP
Decomposed for tractability
Copyright c©2013, SAS Institute Inc. All rights reserved.
Manufacturing Inventory Planning
Customer: Large AutomakerManufacturing Inventory Planning
» Large supply chain networks with plants, warehouses, anddealers
» Close to one thousand packages (cars with options)» More than ten thousand service parts» A few hundred outsourcing parts for manufacturing» Inventory decisions for finished goods, service parts, and
manufacturing partsSAS tools:
» SAS Inventory Replenishment Planning» SAS/OR: OPTMODEL, MILP solver» SAS Forecast Server: demand forecasting
Copyright c©2013, SAS Institute Inc. All rights reserved.
Manufacturing Inventory Planning
Customer: Large Construction Equipment ManufacturerManufacturing Inventory Planning
» Supply chain networks with plants, and warehouses» Dozens of product lines» Hundreds of critical components» Long order-to-delivery (OTD) time» Inventory decisions for components to meet OTD
constraintsSAS tools:
» SAS Inventory Replenishment Planning
Copyright c©2013, SAS Institute Inc. All rights reserved.
Prison Population Simulation
Customer: State Legislative AgencyPrison Planning and Scenario Analysis
» Mandated projections to plan for prison capacity» Numbers highly dependent on legislative policy» Must consider current population and future entries» Need to account for revocations
SAS tools:» SAS/OR: Simulation Studio
Copyright c©2013, SAS Institute Inc. All rights reserved.
Water Management
Customer: National Utilities AgencyWater flow scheduling and routing
» Demand forecast for public water» Network of reservoirs and pumping stations» Business rules for reserve capacity and flow» Multi-objective problem
SAS tools:» SAS/OR: OPTMODEL, MILP solver» SAS Forecast Server
Copyright c©2013, SAS Institute Inc. All rights reserved.
Casino Floor Mix Optimization
Customer: Canadian CasinoSlot Machine Floor Mix Optimization
» Machine categorization» Forecasting Revenue and Utilization» Optimizing Revenue to determine slot machine mix on the
floor (hard and soft constraints)
MILPSAS tools:
» SAS/OR: OPTMODEL, MILP solver» SAS Forecast Studio» SAS Enterprise Miner
Copyright c©2013, SAS Institute Inc. All rights reserved.
top related