alpar@0: /* -*- mode: C++; indent-tabs-mode: nil; -*- alpar@0: * alpar@0: * This file is a part of LEMON, a generic C++ optimization library. alpar@0: * alpar@0: * Copyright (C) 2003-2009 alpar@0: * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport alpar@0: * (Egervary Research Group on Combinatorial Optimization, EGRES). alpar@0: * alpar@0: * Permission to use, modify and distribute this software is granted alpar@0: * provided that this copyright notice appears in all copies. For alpar@0: * precise terms see the accompanying LICENSE file. alpar@0: * alpar@0: * This software is provided "AS IS" with no warranty of any kind, alpar@0: * express or implied, and with no claim as to its suitability for any alpar@0: * purpose. alpar@0: * alpar@0: */ alpar@0: alpar@11: #include alpar@0: #include alpar@11: #include alpar@0: alpar@0: ///The main entry point alpar@11: int main(int argc, char **argv) alpar@0: { alpar@11: alpar@11: lemon::ArgParser ap(argc,argv); alpar@11: ap.run(); alpar@11: alpar@0: lemon::ListGraph g; alpar@0: g.addNode(); alpar@11: alpar@11: typedef lemon::GlpkLp Solver; alpar@11: Solver lp; alpar@11: Solver::Col x = lp.addCol(); alpar@11: Solver::Col y = lp.addCol(); alpar@11: lp.colLowerBound(x,0); alpar@11: lp.colLowerBound(y,0); alpar@11: lp.addRow(3<=x+2*y<=10); alpar@11: lp.obj(-4*x+3*y); alpar@11: lp.max(); alpar@11: lp.solve(); alpar@11: alpar@0: }