Originally posted by: behi
Dear Alex
I coded the classic max-flow problem, I added the dual constraints and complementary constraints. (please find the attached files)
Max sum y(i,des)
s.t.
for all j !=(org || des) sum i y(i,j)= sum i y (j,i)
I already checked the dual constraints with CPLEX and they are almost correct.
Since I added the dual constraints and the complementary constraints, I expect that if I change the objective function the optimal solution remains unchanged.
it almost works! but when I reverse the objective function by using the "minimize" rather than the "maximize", the optimal solution changes! but according to the duality theory the "primary constraints + dual constraints + complementary constraints" all collectively guarantees the optimal solution, regardless the objective function.
would you please check why the optimal solution changes wen the objective function reversed?
#DecisionOptimization#OPLusingCPLEXOptimizer