COIN-OR::LEMON - Graph Library

source: lemon/lemon/lp.h @ 1300:62dba6c90f35

Last change on this file since 1300:62dba6c90f35 was 1300:62dba6c90f35, checked in by Alpar Juttner <alpar@…>, 6 years ago

Fix default LP/MIP setting (#479)

File size: 2.2 KB
Line 
1/* -*- mode: C++; indent-tabs-mode: nil; -*-
2 *
3 * This file is a part of LEMON, a generic C++ optimization library.
4 *
5 * Copyright (C) 2003-2013
6 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
7 * (Egervary Research Group on Combinatorial Optimization, EGRES).
8 *
9 * Permission to use, modify and distribute this software is granted
10 * provided that this copyright notice appears in all copies. For
11 * precise terms see the accompanying LICENSE file.
12 *
13 * This software is provided "AS IS" with no warranty of any kind,
14 * express or implied, and with no claim as to its suitability for any
15 * purpose.
16 *
17 */
18
19#ifndef LEMON_LP_H
20#define LEMON_LP_H
21
22#include<lemon/config.h>
23
24
25#ifdef LEMON_HAVE_GLPK
26#include <lemon/glpk.h>
27#elif LEMON_HAVE_CPLEX
28#include <lemon/cplex.h>
29#elif LEMON_HAVE_SOPLEX
30#include <lemon/soplex.h>
31#elif LEMON_HAVE_CLP
32#include <lemon/clp.h>
33#elif LEMON_HAVE_CBC
34#include <lemon/cbc.h>
35#endif
36
37///\file
38///\brief Defines a default LP solver
39///\ingroup lp_group
40namespace lemon {
41
42#ifdef DOXYGEN
43  ///The default LP solver identifier
44
45  ///The default LP solver identifier.
46  ///\ingroup lp_group
47  ///
48  ///Currently, the possible values are \c GLPK, \c CPLEX,
49  ///\c SOPLEX or \c CLP
50#define LEMON_DEFAULT_LP SOLVER
51  ///The default LP solver
52
53  ///The default LP solver.
54  ///\ingroup lp_group
55  ///
56  ///Currently, it is either \c GlpkLp, \c CplexLp, \c SoplexLp or \c ClpLp
57  typedef GlpkLp Lp;
58
59  ///The default MIP solver identifier
60
61  ///The default MIP solver identifier.
62  ///\ingroup lp_group
63  ///
64  ///Currently, the possible values are \c GLPK, \c CPLEX or \c CBC
65#define LEMON_DEFAULT_MIP SOLVER
66  ///The default MIP solver.
67
68  ///The default MIP solver.
69  ///\ingroup lp_group
70  ///
71  ///Currently, it is either \c GlpkMip, \c CplexMip , \c CbcMip
72  typedef GlpkMip Mip;
73#else
74#if LEMON_DEFAULT_LP == GLPK
75  typedef GlpkLp Lp;
76#elif LEMON_DEFAULT_LP == CPLEX
77  typedef CplexLp Lp;
78#elif LEMON_DEFAULT_LP == SOPLEX
79  typedef SoplexLp Lp;
80#elif LEMON_DEFAULT_LP == CLP
81  typedef ClpLp Lp;
82#endif
83#if LEMON_DEFAULT_MIP == GLPK
84  typedef GlpkMip Mip;
85#elif LEMON_DEFAULT_MIP == CPLEX
86  typedef CplexMip Mip;
87#elif LEMON_DEFAULT_MIP == CBC
88  typedef CbcMip Mip;
89#endif
90#endif
91
92} //namespace lemon
93
94#endif //LEMON_LP_H
Note: See TracBrowser for help on using the repository browser.