[Coin-discuss] Preserving row and column names using readLP & OsiSolverInterface

James Gibbons James.Gibbons at nottingham.ac.uk
Fri Jan 20 06:45:02 EST 2006


Dear all,

I am trying to use the Clp and Cbc solvers to solve a problem generated by XpressMP Mosel. I have been able to read and solve the problem as a .lp file but not using a .mps file. (I think Xpress mps files might have a non-standard extension to the format?).

What I can't work out how to do is too keep the row and column names from the original problem. A simple example:

    OsiClpSolverInterface solver0;
    std::string fn = "test2.lp";
    solver0.readLp(fn.c_str());
    int ncols = solver0.getNumCols();
    for(int i=0;i<ncols;i++) {
		std::cout<<solver0.getColName(i)<<"\n";}

This outputs the column names as C0000001 etc. As there is no guarantee  about what order Mosel generates the matrix in I really need access to the names. I've tried recompiling with LPIO_DEBUG defined in the CoinLPIO.cpp file and the output from this suggests that readLp is reading in the problem names correctly. So am I missing something obvious or doing something wrong?

Thanks,

James

This message has been checked for viruses but the contents of an attachment
may still contain software viruses, which could damage your computer system:
you are advised to perform your own checks. Email communications with the
University of Nottingham may be monitored as permitted by UK legislation.





More information about the Coin-discuss mailing list