<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">
>> When using writeMps with OsiCpx, the integer information is lost. Using writeLp works, but not writeMps. How do I fix this?<br>
><br>
> You remember, whether you solve the LP relaxation or the MIP before<br>
> calling writeMps?<br>
> Does it work better if you add "switchToMIP();" in the beginning of<br>
> OsiCpx::writeMps?<br>
><br>
> writeMps calls the CPLEX MPS writing function, while writeLp uses an Osi<br>
> function. That may make a difference.<br>
<br>
</div>Yes, OsiCpx has some strangeness coming from the fact that switching<br>
the problem type from LP to MIP erases cached solution information.<br>
I'm pretty sure that the problem is that CPLEX is storing the problem<br>
as an LP instead of a MIP most of the time to avoid this difficulty.<br>
There have been several discussions of this on the list in the past.<br>
It should be easy to see what's going on by looking at the source.<br>
Another solution would be to switch to using the MPS writer in<br>
CoinUtils instead.<br></blockquote><div><br><br><br>Using writeMpsNative (CoinUtils) does work fine. I was just asking about
OsiCpx's version (writeMps). It seems it should work (or be disabled so users don't try to use it).<br>
<br>
Stefan - I build the model, then use Osi's setInteger, then writeMps. I
have not tried "switchToMIP".<br><br> <br></div></div>