
Comparative Analysis Methods in Modeling: GAMS and Scenario Comparison
Explore comparative analysis techniques using GAMS through multiple submissions and the LOOP procedure. Understand the process of analyzing scenarios to determine optimal solutions efficiently.
Download Presentation

Please find below an Image/Link to download the presentation.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.
You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.
E N D
Presentation Transcript
Lecture 10 Comparative analysis Chengcheng Fei 2018 Fall Based on material written by Gillig and McCarl; Improved upon by many previous lab instructors; Special thanks to Zidong Mark Wang.
Introduction Often we would like to exam the results under different scenarios. Two ways to conduct comparative analysis Use multiple GAMS submissions or multiple solves generating report writing output and then manually comparing the analysis results Use the GAMS LOOP procedure and set up a comparative scenario analysis system that creates cross scenario comparison tables
The example Lexicography Example Min w i + t s . . w gl T 0 for all r r r r = gl g X for all r r rj j j a X b for all m mj j m j w w for all r i r r w for all r i r , 0 w X for all j and r r j gl unrestrict ed for all r r
Steps of Multiple GAMS Submission data section model structure GOAL2("PROFIT1")=yes; Set up sets and parameters WEIGHTS(GOAL2)=1 SOLVE RESALLOC USING LP MINIMIZING GOALOBJ; solve the model WEIGHTS(GOAL2)=0.00001; GOAL2("PROFIT1")=NO; Turn off the sets and reset parameters to original value GOAL2( lathetime")=yes; Change sets and parameters WEIGHTS(GOAL2)=1 SOLVE RESALLOC USING LP MINIMIZING GOALOBJ; solve the model WEIGHTS(GOAL2)=0.00001; Turn off the sets and reset parameters to original value GOAL2( lathetime")=NO;
2. Loops LOOP procedure causes GAMS to repeat execution of statement enclosed in the parentheses for each value of the defining set. Within the Loop the index is treated as If it referenced only the single set element that the Loop index takes on during each pass.For example
Loop Steps Step1: Define scenario set Step2:Define parameters that will be altered by scenario Step3:Define parameters used in the loop (i.e. output)
Set weight of looped scenario to 1 Reset weight of looped scenario to original value, after the solve statement
Alternative Way Step1: Define scenario set Step2:Define parameters that will be altered by scenario Step3:Define parameters used in the loop (i.e. output)
Loop: Structural Modification Many comparative studies involve model structure modification. One can introduce context sensitive structure by making constraints or terms conditionals.
Loop: Structural Modification Base Scenario Comparative Result Scenario1
Base: Comparative Result Scenario 1: