COIN-OR::LEMON - Graph Library

Changeset 1256:3bb4ed285c39 in lemon-0.x for src/work/athos/lp/lp_test.cc


Ignore:
Timestamp:
03/25/05 09:18:27 (15 years ago)
Author:
Alpar Juttner
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@1683
Message:
  • src/lemon/utility.h: dummy<> template added
  • LpSolverBase::INF is now really defined
  • AddColSet?() to add several column at once
    • using enable_if
    • with some doxygen hack
  • More doc improvements
  • Better Makefile
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/work/athos/lp/lp_test.cc

    r1254 r1256  
    55int main()
    66{
    7   LpSolverSkeleton lp;
     7  typedef LpSolverSkeleton LP;
     8  LP lp;
     9
     10  std::vector<LP::Col> x;
     11  for(int i=0;i<10;i++) x.push_back(lp.addCol());
     12
     13  std::vector<LP::Col> y(10);
     14  lp.addColSet(y);
     15
     16  std::map<int,LP::Col> z;
     17 
     18  z.insert(std::make_pair(12,INVALID));
     19  z.insert(std::make_pair(2,INVALID));
     20  z.insert(std::make_pair(7,INVALID));
     21  z.insert(std::make_pair(5,INVALID));
     22 
     23  lp.addColSet(z);
     24
     25
     26  LP::Expr e;
     27  e[x[3]]=2;
     28  e[x[3]]=4;
     29  e[x[3]]=1;
     30  e.constComp()=12;
     31  lp.addRow(LP::INF,e,23);
     32
    833}
Note: See TracChangeset for help on using the changeset viewer.