lemon/lp_base.h
changeset 1437 2a3f3448ced1
parent 1435 8e85e6bbefdf
child 1439 2c43106bef85
equal deleted inserted replaced
0:8463901155cf 1:eeb1468cfbad
   415     _FixId rows;
   415     _FixId rows;
   416     _FixId cols;
   416     _FixId cols;
   417 
   417 
   418     //Abstract virtual functions
   418     //Abstract virtual functions
   419     virtual LpSolverBase &_newLp() = 0;
   419     virtual LpSolverBase &_newLp() = 0;
   420     virtual LpSolverBase &_copyLp() = 0;
   420     virtual LpSolverBase &_copyLp(){
       
   421       ///\todo This should be implemented here, too,  when we have problem retrieving routines. It can be overriden.
       
   422 
       
   423       //Starting:
       
   424       LpSolverBase & newlp(_newLp());
       
   425       return newlp;
       
   426       //return *(LpSolverBase*)0;
       
   427     };
   421 
   428 
   422     virtual int _addCol() = 0;
   429     virtual int _addCol() = 0;
   423     virtual int _addRow() = 0;
   430     virtual int _addRow() = 0;
   424     virtual void _setRowCoeffs(int i, 
   431     virtual void _setRowCoeffs(int i, 
   425 			       int length,
   432 			       int length,
   606       Row r=addRow();
   613       Row r=addRow();
   607       setRow(r,c);
   614       setRow(r,c);
   608       return r;
   615       return r;
   609     }
   616     }
   610 
   617 
       
   618     ///Set an element of the coefficient matrix of the LP
       
   619 
       
   620     ///\param r is the row of the element to be modified
       
   621     ///\param c is the coloumn of the element to be modified
       
   622     ///\param val is the new value of the coefficient
       
   623     void setCoeff(Row r, Col c, Value val){
       
   624       _setCoeff(rows.floatingId(r.id),cols.floatingId(c.id), val);
       
   625     }
       
   626 
   611     /// Set the lower bound of a column (i.e a variable)
   627     /// Set the lower bound of a column (i.e a variable)
   612 
   628 
   613     /// The upper bound of a variable (column) has to be given by an 
   629     /// The upper bound of a variable (column) has to be given by an 
   614     /// extended number of type Value, i.e. a finite number of type 
   630     /// extended number of type Value, i.e. a finite number of type 
   615     /// Value or -\ref INF.
   631     /// Value or -\ref INF.