28#ifndef _SPXSIMPLIFIER_H_
29#define _SPXSIMPLIFIER_H_
197 bool keepbounds =
false, uint32_t seed = 0) = 0;
202 bool isOptimal =
true) = 0;
270 this->_tolerances = newTolerances;
Saving LPs in a form suitable for SoPlex.
Wrapper for several output streams. A verbosity level is used to decide which stream to use and wheth...
LP simplification abstract base class.
void setOutstream(SPxOut &newOutstream)
virtual const VectorBase< R > & unsimplifiedPrimal()=0
returns a reference to the unsimplified primal solution.
virtual SPxSolverBase< R >::VarStatus getBasisColStatus(int) const =0
gets basis status for a single column.
int m_remNzos
number of removed nonzero coefficients
virtual void addObjoffset(const R val)
add objective offset.
int m_keptLRhs
number of kept left- and right-hand sides
Result
Result of the simplification.
@ INFEASIBLE
primal infeasibility was detected
@ UNBOUNDED
primal unboundedness was detected
@ OKAY
simplification could be done
@ DUAL_INFEASIBLE
dual infeasibility was detected
@ VANISHED
the problem was so much simplified that it vanished
virtual const VectorBase< R > & unsimplifiedSlacks()=0
returns a reference to the unsimplified slack values.
virtual SPxSolverBase< R >::VarStatus getBasisRowStatus(int) const =0
gets basis status for a single row.
R m_minReduction
minimal reduction (sum of removed rows/cols) to continue simplification
int m_remCols
number of removed columns
int m_remRows
number of removed rows
R m_objoffset
objective offset
const std::shared_ptr< Tolerances > tolerances() const
get the _tolerances member variable
virtual void setTolerances(std::shared_ptr< Tolerances > newTolerances)
set the _tolerances member variable
SPxSimplifier & operator=(const SPxSimplifier &rhs)
assignment operator
SPxOut * spxout
message handler
virtual Result simplify(SPxLPBase< R > &lp, Real remainingTime, bool keepbounds=false, uint32_t seed=0)=0
simplify SPxLP lp
virtual const char * getName() const
get name of simplifier.
virtual R timeUsed() const
int m_chgBnds
number of changed bounds
virtual void setMinReduction(const R minRed)
set minimal reduction threshold to continue simplification
std::shared_ptr< Tolerances > _tolerances
virtual void getBasis(typename SPxSolverBase< R >::VarStatus[], typename SPxSolverBase< R >::VarStatus[], const int rowsSize=-1, const int colsSize=-1) const =0
get optimal basis.
virtual const VectorBase< R > & unsimplifiedRedCost()=0
returns a reference to the unsimplified reduced costs.
virtual void unsimplify(const VectorBase< R > &, const VectorBase< R > &, const VectorBase< R > &, const VectorBase< R > &, const typename SPxSolverBase< R >::VarStatus[], const typename SPxSolverBase< R >::VarStatus[], bool isOptimal=true)=0
reconstructs an optimal solution for the unsimplified LP.
virtual R getObjoffset() const
get objective offset.
virtual ~SPxSimplifier()
destructor.
int m_keptBnds
number of kept bounds
virtual Result result() const =0
returns result status of the simplification
virtual const VectorBase< R > & unsimplifiedDual()=0
returns a reference to the unsimplified dual solution.
Timer * m_timeUsed
user time used for simplification
virtual bool isConsistent() const
consistency check
int m_chgLRhs
number of change right-hand sides
const char * m_name
name of the simplifier
SPxSimplifier(const char *p_name, Timer::TYPE ttype=Timer::USER_TIME)
constructor
SPxSimplifier(const SPxSimplifier &old)
copy constructor
virtual bool isUnsimplified() const
specifies whether an optimal solution has already been unsimplified.
virtual SPxSimplifier * clone() const =0
clone function for polymorphism
static Timer * createTimer(Timer::TYPE ttype)
create timers and allocate memory for them
Wrapper for the system time query methods.
virtual Real time() const =0
Everything should be within this namespace.
std::ostream & operator<<(std::ostream &s, const VectorBase< R > &vec)
Output operator.
void spx_free(T &p)
Release memory.
Debugging, floating point type and parameter definitions.
Saving LPs in a form suitable for SoPlex.