Main Page
Related Pages
Classes
Files
File List
File Members
opt
build
coinor-osi
coinor-osi-0.103.0
Osi
src
OsiPresolve.hpp
Go to the documentation of this file.
1
// Copyright (C) 2003, International Business Machines
2
// Corporation and others. All Rights Reserved.
3
4
#ifndef OsiPresolve_H
5
#define OsiPresolve_H
6
#include "
OsiSolverInterface.hpp
"
7
8
class
CoinPresolveAction;
9
#include "CoinPresolveMatrix.hpp"
10
11
61
class
OsiPresolve
{
62
public
:
64
OsiPresolve
();
65
67
virtual
~OsiPresolve
();
68
89
virtual
OsiSolverInterface
*
presolvedModel
(
OsiSolverInterface
& origModel,
90
double
feasibilityTolerance=0.0,
91
bool
keepIntegers=
true
,
92
int
numberPasses=5,
93
const
char
* prohibited=NULL,
94
bool
doStatus=
true
,
95
const
char
* rowProhibited=NULL);
96
114
virtual
void
postsolve
(
bool
updateStatus=
true
);
115
117
OsiSolverInterface
*
model
()
const
;
118
120
OsiSolverInterface
*
originalModel
()
const
;
121
123
void
setOriginalModel
(
OsiSolverInterface
*model);
124
126
const
int
*
originalColumns
()
const
;
127
129
const
int
*
originalRows
()
const
;
130
132
inline
int
getNumRows
()
const
133
{
return
nrows_
;}
134
136
inline
int
getNumCols
()
const
137
{
return
ncols_
;}
138
143
inline
void
setNonLinearValue
(
double
value)
144
{
nonLinearValue_
= value;}
145
inline
double
nonLinearValue
()
const
146
{
return
nonLinearValue_
;}
156
inline
void
setPresolveActions
(
int
action)
157
{
presolveActions_
= (
presolveActions_
&0xffff0000)|(action&0xffff);}
158
159
private
:
164
OsiSolverInterface
*
originalModel_
;
165
170
OsiSolverInterface
*
presolvedModel_
;
171
177
double
nonLinearValue_
;
178
180
int
*
originalColumn_
;
181
183
int
*
originalRow_
;
184
186
const
CoinPresolveAction *
paction_
;
187
194
int
ncols_
;
195
197
int
nrows_
;
198
200
CoinBigIndex
nelems_
;
201
207
int
presolveActions_
;
209
int
numberPasses_
;
210
211
protected
:
220
virtual
const
CoinPresolveAction *
presolve
(CoinPresolveMatrix *prob);
221
232
virtual
void
postsolve
(CoinPostsolveMatrix &prob);
233
240
void
gutsOfDestroy
();
241
};
242
#endif
Generated on Tue Mar 1 2016 22:33:32 by
1.8.4