[Coin-discuss] problem with OsiCpx getRowUpper
Stefan Vigerske
stefan at math.hu-berlin.de
Wed Aug 13 13:55:14 EDT 2008
Hi,
> Better description of the issue:
>
> On the first call of OsiCpxSolverInterface::getRowUpper(), OsiCpx
> creates a vector rowupper_ of rhs upper bounds and returns it.
> The problem starts when I change some of the RHS and call the
> getRowUpper() - since rowupper_ exists from before, it is just returned
> as it is, i.e. with the values valid at the time of the first call.
> Since rowupper_ is private, there is no chance to change or delete it.
Yes, that description is better.
> I think that the best (and easiest) way of dealing with the problem is
> to do it the same way as in for ex. OsiGlpk: update the rowlower_ and
> rowupper_ vectors each time RHS is changed, i.e. in setRowLower,
> setRowUpper and setRowBounds methods (if the vectors exist).
> This would be a very minor change in the code...
I think there is indeed a bug in OsiCpx::setRowType (which is used by
the setRowLower, setRowUpper,... methods), the caches do not get cleared
when the row bounds are changed, whereas OsiCpx::setRowSetType (which is
used by setRowSetBounds) seem to be fine.
Filing a ticket is a good idea, but you might need to wait ages to get
it fixed.
Can you try whether the Osi from
https://projects.coin-or.org/svn/Osi/stable/BSP
fixes your problem?
It is a copy of 0.99 with some bugfixes.
Best,
Stefan
--
Stefan Vigerske
Humboldt University Berlin, Numerical Mathematics
http://www.math.hu-berlin.de/~stefan
More information about the Coin-discuss
mailing list