A bit more information on installation.
2 * lemon/lp_skeleton.h - Part of LEMON, a generic C++ optimization library
4 * Copyright (C) 2005 Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
5 * (Egervary Research Group on Combinatorial Optimization, EGRES).
7 * Permission to use, modify and distribute this software is granted
8 * provided that this copyright notice appears in all copies. For
9 * precise terms see the accompanying LICENSE file.
11 * This software is provided "AS IS" with no warranty of any kind,
12 * express or implied, and with no claim as to its suitability for any
17 #ifndef LEMON_LP_SKELETON
18 #define LEMON_LP_SKELETON
20 #include <lemon/lp_base.h>
23 ///\brief A skeleton file to implement LP solver interfaces
26 ///A skeleton class to implement LP solver interfaces
27 class LpSkeleton :public LpSolverBase {
32 virtual LpSolverBase &_newLp();
34 virtual LpSolverBase &_copyLp();
36 virtual int _addCol();
38 virtual int _addRow();
40 virtual void _eraseCol(int i);
42 virtual void _eraseRow(int i);
45 /// \warning Arrays are indexed from 1 (datum at index 0 is ignored)
47 virtual void _setRowCoeffs(int i,
50 Value const * values );
53 /// \warning Arrays are indexed from 1 (datum at index 0 is ignored)
55 virtual void _setColCoeffs(int i,
58 Value const * values );
60 /// Set one element of the coefficient matrix
61 virtual void _setCoeff(int row, int col, Value value);
63 /// The lower bound of a variable (column) have to be given by an
64 /// extended number of type Value, i.e. a finite number of type
65 /// Value or -\ref INF.
66 virtual void _setColLowerBound(int i, Value value);
69 /// The upper bound of a variable (column) have to be given by an
70 /// extended number of type Value, i.e. a finite number of type
71 /// Value or \ref INF.
72 virtual void _setColUpperBound(int i, Value value);
75 // /// The lower bound of a linear expression (row) have to be given by an
76 // /// extended number of type Value, i.e. a finite number of type
77 // /// Value or -\ref INF.
78 // virtual void _setRowLowerBound(int i, Value value);
81 // /// The upper bound of a linear expression (row) have to be given by an
82 // /// extended number of type Value, i.e. a finite number of type
83 // /// Value or \ref INF.
84 // virtual void _setRowUpperBound(int i, Value value);
86 /// The lower and upper bound of a linear expression (row) have to be
88 /// extended number of type Value, i.e. a finite number of type
89 /// Value or +/-\ref INF.
90 virtual void _setRowBounds(int i, Value lb, Value ub);
95 virtual void _clearObj();
97 virtual void _setObjCoeff(int i, Value obj_coef);
101 ///\bug Wrong interface
103 virtual SolveExitStatus _solve();
107 ///\bug Wrong interface
109 virtual Value _getPrimal(int i);
112 ///\bug Wrong interface
114 virtual Value _getPrimalValue();
117 ///\bug Wrong interface
119 virtual SolutionStatus _getPrimalStatus();
122 virtual SolutionStatus _getDualStatus();
126 virtual ProblemTypes _getProblemType();
129 virtual void _setMax();
131 virtual void _setMin();
135 LpSkeleton() : LpSolverBase(), col_num(0), row_num(0) {}
140 #endif // LEMON_LP_SKELETON