Originally posted by: SystemAdmin
[frenky_ser said:]
Paul,
I will add a question of the topicstarter.
I have a trivial example
[b]Primal:[/b]
[b]min[/b] -5x1 + 5x2 + 0.1x3
[b]st[/b] x1 - x2 - x3 = 0
lb = (0 0 0) ub = (16 28 0.001)
My steps:
[b]1. Solve MILP -> change problem type on CPXPROB_FIXEDMILP -> reoptimize(lpopt)[/b]
/* I use callable library and this is my code
/
/ create problem
/
[problemPtr, env, status] = calllib(cplexLibName, 'CPXcreateprob', EnvCPLEX, 0, 'testMilpProblem');
/ send data to problem
/
status = calllib(cplexLibName, 'CPXcopylp', EnvCPLEX, problemPtr, size(A,2), size(A,1), fn_CPLEX_Consts('CPX_MIN'),...
full(f), full(b), sense, matbeg, matcnt, matind, matval, full(lb), full(ub), []);
/ change problem type
/
status = calllib(cplexLibName, 'CPXchgprobtype', EnvCPLEX, problemPtr, fn_CPLEX_Consts('CPXPROB_MILP'));
...variable types are integer (I)
/ solve
/
status = calllib(cplexLibName, 'CPXmipopt', EnvCPLEX, problemPtr)
/ change problem type on CPXPROB_FIXEDMILP
/
status = calllib(cplexLibName, 'CPXchgprobtype', EnvCPLEX, problemPtr, fn_CPLEX_Consts('CPXPROB_FIXEDMILP'));
/ re-optimize */
status = calllib(cplexLibName, 'CPXlpopt', EnvCPLEX, problemPtr);
This algorithm is described in the ILOG CPLEX 11 user's manual...
[b]Lagrange multipliers equal zeros :(([/b]
[b]2. turn off dependency checker, presolve. Sometimes (on the big examples) it helped:[/b]
status = calllib(cplexLibName, 'CPXsetintparam', EnvCPLEX, fn_CPLEX_Consts('CPX_PARAM_PREIND'), 0);
status = calllib(cplexLibName, 'CPXsetintparam', EnvCPLEX, fn_CPLEX_Consts('CPX_PARAM_DEPIND'), 0);
status = calllib(cplexLibName, 'CPXsetintparam', EnvCPLEX, fn_CPLEX_Consts('CPX_PARAM_RELAXPREIND'), 0);
[b]Lagrange multipliers equal zeros :(([/b]
[b]3. Change target function (f)[/b]
[b]min[/b] -5x1 + (5-e)x2 + 0.1x3
[b]Lagrange multipliers are correct!!! up to e < 1e-07[/b]<br />
[b]4. re-optimize in a solution point (X)[/b]
lb - lower bounds
ub - upper bounds
X - optimal solution
lb = X, ub = X
[b]Lagrange multipliers equal zeros :(([/b]
5. re-optimize in solution epsilon neighborhood
lb = max(lb, lb - E)
ub = min(ub, ub + E)
[b]Lagrange multipliers equal zeros (Does not depend on epsilon neighborhood):(([/b]
6. Search of LM by means of LP
Lagrange multipliers are correct on all interval of admissible values (without changing lb and ub) and in solution epsilon neighborhood,
is but X is incorrect (X tends to lb)...
There are two questions.
1. Why LM = 0 at the [u]equal prices[/u]?
2. Why X tends to lower bounds(lb) at the LP?
#CPLEXOptimizers#DecisionOptimization