[Coin-lpsolver] Packed Matrix to CbcModel
Kyle Ellrott
kellrott at csbl.bmb.uga.edu
Tue May 23 15:00:22 EDT 2006
That lead to a weirder error message.
Both
cbc_model->assignSolver( (OsiSolverInterface*) si );
and
cbc_model->assignSolver( dynamic_cast<OsiSolverInterface*>(si) );
get
../../../open_prospect/src/intpro_threading/intpro_threading.cc:379:
error: no matching function for call to 'CbcModel::assignSolver
(OsiSolverInterface*)'
/Users/kye/CvsWork/COIN//include/CbcModel.hpp:1316: note: candidates
are: void CbcModel::assignSolver(OsiSolverInterface*&, bool)
I forget the details of using '&' in the function declaration. I
know it causes the actual variable to be copied into the function,
but assignSolver is already getting a pointer, so why would that be
needed? Could this be part of my problem?
Kyle
> Kyle,
>
> I can speak to the assignSolver question; I'll let John tackle the
> assignProblem issue (the answer may well be specific to clp).
>
> You need to up cast your OsiClpSolverInterface to OsiSolverInterface.
> This should be pretty straightforward --- either use a
> dynamic_cast, or assign
> your OsiClpSolverInterface* to a variable of type OsiSolverInterface*.
>
> Lou
>
> _______________________________________________
> Coin-lpsolver mailing list
> Coin-lpsolver at list.coin-or.org
> http://list.coin-or.org/mailman/listinfo/coin-lpsolver
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.coin-or.org/pipermail/clp/attachments/20060523/5a4518a9/attachment.html>
More information about the Clp
mailing list