[Cgl] cgl, cpx, mir, error

Matthew Galati Matthew.Galati at sas.com
Wed Apr 11 17:13:23 EDT 2007


Any suggestions on a workaround? I don't see any OSI functions for setRowActivity. 

And, it doesn't look like the idea of making CGL independent of OSI worked out. Although I do see Francois added CglData - which looks like what I wanted. But, most of the CGLs are still using OSI.



-----Original Message-----
From: Ted Ralphs [mailto:tkralphs at Lehigh.EDU] 
Sent: Wednesday, April 11, 2007 5:07 PM
To: cgl at list.coin-or.org
Cc: Matthew Galati
Subject: Re: [Cgl] cgl, cpx, mir, error

There is a call to getRowActivity() in CglMixedIntegerRounding2. In OsiCpx, this call is implemented through a call to CPLEX, which complains that there is no solution whenever you have not just finished solving the loaded instance (which it looks like you have not. The other cut generators seem only to use calls that require returning information cached in the interface layer, so you don't get the error.

Cheers,

Ted

Matthew Galati wrote:
> Hi.
> 
> I am creating an OsiCpx object, populating a model, setting the primal solution, and then calling the MIR cut generator.
> 
> OsiSolverInterface * siCgl = new OsiLpSolverInterface();
> 
>   siCgl->loadProblem(*m_modelCore->M,
>                        &m_modelCore->colLB[0],
>                        &m_modelCore->colUB[0],
>                        m_app->m_model.objCoeff, 
>                        &m_modelCore->rowLB[0],
>                        &m_modelCore->rowUB[0]);
> 
>    siCgl->setInteger(&m_modelRelax->integerVars[0],
>                       static_cast<int>(m_modelRelax->integerVars.size()));
>    siCgl->setColSolution(m_xhat);
> 
>    CglMixedIntegerRounding2 cglMirs;
>    cglMirs.generateCuts(*siCgl, cs);
> 
> And, I get the error from Cplex:
>   CPLEX Error  1217: No solution exists.
> 
> Note: I don't get that error with Cliques/Knap/Flow CGLs.
> 
> Any ideas?
> 
> Thanks,
> Matt
> 
> _______________________________________________
> Cgl mailing list
> Cgl at list.coin-or.org
> http://list.coin-or.org/mailman/listinfo/cgl


--
Dr. Ted Ralphs
Associate Professor
Industrial and Systems Engineering
Lehigh University
(610)758-4784
tkralphs at lehigh.edu
www.lehigh.edu/~tkr2



More information about the Cgl mailing list