Dear professor,
I’ve used the same way.
After I calculate
[MODEL,RECOVERYMODEL,DIAGNOSTIC,INTERNAL] = export(Constraints,Obj,ops);
I found in my problem the size of recoverymodel.used_variables, which is 1*6819, is less than the variables in model, which is 1*7629.
Then I used the code:
[x,fval,exitflag,output]=cplexmilp(MODEL.f,MODEL.Aineq,MODEL.bineq,MODEL.Aeq,MODEL.beq,[],[],[],MODEL.lb,MODEL.ub,MODEL.ctype',MODEL.x0,MODEL.options);
assign(recover(recoverymodel.used_variables,x);
and it occurred that the variables cannot be recovered. it’s necessary that Both arguments must have same size when using assign function.
Could you give me some suggestions in solving such a problem? How to recover the variable when the size of recoverymodel.used_variables is less than the variables in model?