Originally posted by: SystemAdmin
You could do so by adding the following lines of code after your 'Subject to{..}' block:
tuple displaySched
{
int start;
int end;
int size; string label;
int present;
}
{displaySched
} solutionSet=
{
}; displaySched ganttCompletion[Jobs][Mchs]; execute
{
for(var j in Jobs)
{
for(var m in Mchs)
{ var name=
"J"+j+
",M"+m; var temp=solutionSet.add(Completion[j][m]-Processing[j][m],Completion[j][m],Processing[j][m],name,1); ganttCompletion[j][m]=temp;
}
} ganttCompletion;
}
Run the particular configuration, and click the 'Show data view' button for the 'ganttCompletion' variable in the 'Problem browser' window to the left. Now, click the 'Gantt Chart' tab in the opened window at the bottom (above the various OPL views) to see the gantt representation of the 'Completion' variable.
#DecisionOptimization#MathematicalProgramming-General