432 virtual void _setColLowerBound(int i, Value value) = 0; |
432 virtual void _setColLowerBound(int i, Value value) = 0; |
433 virtual void _setColUpperBound(int i, Value value) = 0; |
433 virtual void _setColUpperBound(int i, Value value) = 0; |
434 virtual void _setRowLowerBound(int i, Value value) = 0; |
434 virtual void _setRowLowerBound(int i, Value value) = 0; |
435 virtual void _setRowUpperBound(int i, Value value) = 0; |
435 virtual void _setRowUpperBound(int i, Value value) = 0; |
436 virtual void _setObjCoeff(int i, Value obj_coef) = 0; |
436 virtual void _setObjCoeff(int i, Value obj_coef) = 0; |
437 virtual void _setObj(int length, |
437 virtual void _clearObj()=0; |
438 int const * indices, |
438 // virtual void _setObj(int length, |
439 Value const * values ) = 0; |
439 // int const * indices, |
|
440 // Value const * values ) = 0; |
440 virtual SolveExitStatus _solve() = 0; |
441 virtual SolveExitStatus _solve() = 0; |
441 virtual Value _getPrimal(int i) = 0; |
442 virtual Value _getPrimal(int i) = 0; |
442 virtual Value _getPrimalValue() = 0; |
443 virtual Value _getPrimalValue() = 0; |
443 virtual SolutionStatus _getPrimalStatus() = 0; |
444 virtual SolutionStatus _getPrimalStatus() = 0; |
444 virtual void _setMax() = 0; |
445 virtual void _setMax() = 0; |
665 ///Set the objective function |
664 ///Set the objective function |
666 |
665 |
667 ///\param e is a linear expression of type \ref Expr. |
666 ///\param e is a linear expression of type \ref Expr. |
668 ///\bug The previous objective function is not cleared! |
667 ///\bug The previous objective function is not cleared! |
669 void setObj(Expr e) { |
668 void setObj(Expr e) { |
670 clearObj(); |
669 _clearObj(); |
671 for (Expr::iterator i=e.begin(); i!=e.end(); ++i) |
670 for (Expr::iterator i=e.begin(); i!=e.end(); ++i) |
672 objCoeff((*i).first,(*i).second); |
671 objCoeff((*i).first,(*i).second); |
673 obj_const_comp=e.constComp(); |
672 obj_const_comp=e.constComp(); |
674 } |
673 } |
675 |
674 |