77 #ifdef SOPLEX_WITH_GMP 81 #ifdef SOPLEX_WITH_BOOST 82 #ifdef SOPLEX_WITH_MPFR 84 #include <boost/multiprecision/mpfr.hpp> 86 #ifdef SOPLEX_WITH_CPPMPF 87 #include <boost/multiprecision/cpp_dec_float.hpp> 94 #define SOPLEX_DEFAULT_RANDOM_SEED 0 // used to suppress output when the seed was not changed 239 bool getDualNorms(
int& nnormsRow,
int& nnormsCol, R* norms)
const;
242 bool setDualNorms(
int nnormsRow,
int nnormsCol, R* norms);
437 #ifdef SOPLEX_WITH_GMP 439 void addRowRational(
const mpq_t* lhs,
const mpq_t* rowValues,
const int* rowIndices,
440 const int rowSize,
const mpq_t* rhs);
443 void addRowsRational(
const mpq_t* lhs,
const mpq_t* rowValues,
const int* rowIndices,
444 const int* rowStarts,
const int* rowLengths,
const int numRows,
const int numValues,
454 #ifdef SOPLEX_WITH_GMP 456 void addColRational(
const mpq_t* obj,
const mpq_t* lower,
const mpq_t* colValues,
457 const int* colIndices,
const int colSize,
const mpq_t* upper);
460 void addColsRational(
const mpq_t* obj,
const mpq_t* lower,
const mpq_t* colValues,
461 const int* colIndices,
const int* colStarts,
const int* colLengths,
const int numCols,
462 const int numValues,
const mpq_t* upper);
477 #ifdef SOPLEX_WITH_GMP 485 #ifdef SOPLEX_WITH_GMP 499 #ifdef SOPLEX_WITH_GMP 513 #ifdef SOPLEX_WITH_GMP 524 #ifdef SOPLEX_WITH_GMP 535 #ifdef SOPLEX_WITH_GMP 546 #ifdef SOPLEX_WITH_GMP 554 #ifdef SOPLEX_WITH_GMP 718 #ifdef SOPLEX_WITH_GMP 801 bool unscale =
true);
810 bool unscale =
true);
818 bool multBasis(R* vec,
bool unscale =
true);
910 const DIdxSet* intvars = 0,
const bool unscale =
true)
const;
917 const DIdxSet* intvars = 0,
const bool unscale =
true)
const;
932 const bool cpxFormat =
false)
const;
937 const bool cpxFormat =
false)
const;
942 const NameSet* colNames = 0,
const bool cpxFormat =
false)
const;
1466 #ifdef SOPLEX_WITH_RATIONALPARAM 1471 RATIONALPARAM_COUNT = 0
1523 #ifdef SOPLEX_WITH_RATIONALPARAM 1524 static struct RationalParam
1550 #ifdef SOPLEX_WITH_RATIONALPARAM 1576 #ifdef SOPLEX_WITH_RATIONALPARAM 1578 Rational rationalParam(
const RationalParam param)
const;
1585 const std::shared_ptr<Tolerances>
tolerances()
const;
1596 #ifdef SOPLEX_WITH_RATIONALPARAM 1598 bool setRationalParam(
const RationalParam param,
const Rational value,
const bool init =
true);
1605 void resetSettings(
const bool quiet =
false,
const bool init =
true);
1611 bool saveSettingsFile(
const char* filename,
const bool onlyChanged =
false,
1612 int solvemode = 1)
const;
1657 bool areLPsInSync(
const bool checkVecVals =
true,
const bool checkMatVals =
false,
1658 const bool quiet =
false)
const;
1730 #ifdef SOPLEX_WITH_BOOST 1731 #ifdef SOPLEX_WITH_MPFR 1734 using BP = number<mpfr_float_backend<0>, et_off>;
1736 #ifdef SOPLEX_WITH_GMP 1737 using BP = number<gmp_float<50>, et_off>;
1739 using BP = number<cpp_dec_float<50>, et_off>;
1950 void _idxToPerm(
int* idx,
int idxSize,
int* perm,
int permSize)
const;
1953 void _rangeToPerm(
int start,
int end,
int* perm,
int permSize)
const;
2145 template <
typename T>
2162 const bool& maximizing);
2168 const bool& maximizing);
2172 bool& primalFeasible,
2178 int minIRRoundsRemaining,
2181 int numFailedRefinements);
2191 const Rational& violationImprovementFactor,
2192 int& numFailedRefinements);
2196 int& minIRRoundsRemaining,
2197 int& lastStallIterations,
2198 int& numberOfIterations,
2199 bool& factorSolNewBasis,
2201 const Rational& errorCorrectionFactor,
2205 bool& primalFeasible,
2211 bool& continueAfter);
2217 const int& maxDimRational,
2237 template <
typename T>
2241 template <
typename T>
2245 template <
typename T>
2249 template <
typename T>
2253 bool usingRefinedLP,
2263 template <
typename T>
2268 const int& maxDimRational,
2275 template <
typename T>
2279 const bool& maximizing,
2283 const int& maxDimRational);
2353 bool& primalFeasible,
2360 bool& needNewBoostedIt);
2365 bool acceptUnbounded,
2366 bool acceptInfeasible,
2367 int minIRRoundsRemaining,
2368 bool& primalFeasible,
2375 bool& needNewBoostedIt);
2380 bool acceptUnbounded,
2381 bool acceptInfeasible,
2382 int minIRRoundsRemaining,
2383 bool& primalFeasible,
2395 bool& primalFeasible,
2405 bool acceptUnbounded,
2406 bool acceptInfeasible,
2407 int minIRRoundsRemaining,
2408 bool& primalFeasible,
2418 bool& stoppedIter,
bool&
error);
2422 bool& stoppedIter,
bool&
error);
2503 const bool forceNoSimplifier =
false);
2519 bool& stoppedIter,
bool&
error,
bool& optimal);
2525 const Rational& denomBoundSquared);
2532 void _optimize(
volatile bool* interrupt = NULL);
2585 #include "soplex.hpp" 2586 #include "soplex/solverational.hpp" 2587 #include "soplex/testsoplex.hpp" 2588 #include "soplex/solvereal.hpp" 2590 #endif // _SOPLEX_H_ void getBasis(typename SPxSolverBase< R >::VarStatus rows[], typename SPxSolverBase< R >::VarStatus cols[]) const
gets current basis via arrays of statuses
SPxMainSM< R > _simplifierMainSM
SPxSteepPR< R > _pricerQuickSteep
void _computeDualViolation(SolRational &sol, Rational &dualViolation, const bool &maximizing)
computes dual violation during the refinement loop
SPxFastRT< R > _ratiotesterFast
bool _boostPrecision()
increase the multiprecision, return false if maximum precision is reached, true otherwise ...
void _updateSlacks(SolRational &sol, int &primalSize)
updates or recomputes slacks depending on which looks faster
LPRowRational::Type rowTypeRational(int i) const
returns inequality type of row i
Fast shifting ratio test.
const VectorRational & upperRational() const
returns upper bound vector
Settings & operator=(const Settings &settings)
assignment operator
const char * getRatiotesterName()
name of currently loaded ratiotester
SPxEquiliSC< BP > _boostedScalerUniequi
bool writeFile(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0, const DIdxSet *intvars=0, const bool unscale=true) const
Templated write function Real writes real LP to file; LP or MPS format is chosen from the extension i...
minimal Markowitz threshold to control sparsity/stability in LU factorization
void getNdualNorms(int &nnormsRow, int &nnormsCol) const
gets number of available dual norms
void _computeBoundsViolation(SolRational &sol, Rational &boundsViolation)
computes violation of bounds during the refinement loop
Rational _rationalNegInfty
SPxGeometSC< BP > _boostedScalerGeo1
void printSolutionStatistics(std::ostream &os)
prints solution statistics
void _changeLhsReal(const VectorBase< R > &lhs)
changes left-hand side vector for constraints to lhs and adjusts basis
void _removeRowReal(int i)
removes row i and adjusts basis
void _ensureRealLPLoaded()
ensures that the real LP and the basis are loaded in the solver; performs no sync ...
SPxDefaultRT< BP > _boostedRatiotesterTextbook
SoPlex start basis generation base class.
virtual ~SoPlexBase()
destructor
adapt tolerances to the multiprecision used
bool ignoreUnscaledViolations()
sets the status to OPTIMAL in case the LP has been solved with unscaled violations ...
void clearLPReal()
clears the LP
void _changeRangeReal(const VectorBase< R > &lhs, const VectorBase< R > &rhs)
changes left- and right-hand side vectors and adjusts basis
working tolerance for optimality in floating-point solver during iterative refinement ...
const UnitVectorRational * _unitVectorRational(const int i)
returns pointer to a constant unit vector available until destruction of the SoPlexBase class ...
Bound flipping ratio test ("long step dual") for SoPlex.Class SPxBoundFlippingRT provides an implemen...
void _storeRealSolutionAsRational(SolRational &sol, VectorBase< T > &primalReal, VectorBase< T > &dualReal, int &dualSize)
stores floating-point solution of original LP as current rational solution and ensure that solution v...
maximum number of updates without fresh factorization
std::string name[SoPlexBase< R >::BOOLPARAM_COUNT]
array of names for boolean parameters
Types of solution classes.
number< gmp_rational, et_off > Rational
void _loadRealLP(bool initBasis)
load original LP and possibly setup a slack basis
const char * getPricerName()
name of currently loaded pricer
VectorBase< R > _manualUpper
bool getExactCondition(R &condition)
computes the exact condition number for the current basis matrix using the power method; returns true...
lower threshold in lifting (nonzero matrix coefficients with smaller absolute value will be reformula...
bool getBasisInverseRowRational(const int r, SSVectorRational &vec)
computes row r of basis inverse; performs rational factorization if not available; returns true on su...
int numNonzerosRational() const
bool _readFileRational(const char *filename, NameSet *rowNames=0, NameSet *colNames=0, DIdxSet *intVars=0)
reads rational LP in LP or MPS format from file and returns true on success; gets row names...
SPxLPBase< R > _manualRealLP
Implementation of Sparse Linear Solver with Rational precision.This class implements a SLinSolverRati...
lower and upper bound finite, but different
void _untransformFeasibility(SolRational &sol, bool infeasible)
undoes transformation to feasibility problem
const VectorRational & lowerRational() const
returns lower bound vector
SPxEquiliSC< R > _scalerUniequi
bool getDualFarkasReal(R *vector, int dim)
bool getDualNorms(int &nnormsRow, int &nnormsCol, R *norms) const
gets steepest edge norms and returns false if they are not available
geometric mean scaling (max 8 rounds) followed by equilibrium scaling (rows and columns) ...
void _disableSimplifierAndScaler()
disables simplifier and scaler
void _correctPrimalSolution(SolRational &sol, Rational &primalScale, int &primalSize, const int &maxDimRational, VectorBase< T > &primalReal)
corrects primal solution and aligns with basis
SPxHarrisRT< BP > _boostedRatiotesterHarris
void _switchToBoosted()
disable initial precision solver and switch to boosted solver
void _storeBasisAsOldBasisBoosted(DataArray< typename SPxSolverBase< BP >::VarStatus > &rows, DataArray< typename SPxSolverBase< BP >::VarStatus > &cols)
void _removeColReal(int i)
removes column i
R maxAbsNonzeroReal() const
returns biggest non-zero element in absolute value
bool getBoundViolationRational(Rational &maxviol, Rational &sumviol)
Devex pricer.The Devex Pricer for SoPlex implements an approximate steepest edge pricing, that does without solving an extra linear system and computing the scalar products.
void _optimize(volatile bool *interrupt=NULL)
solves the templated LP
R upperReal(int i) const
returns upper bound of column i
R coefReal(int row, int col) const
returns (unscaled) coefficient
int dlcmSizePrimalRational(const int base=2)
get size of least common multiple of denominators in primal solution
maximum number of conjugate gradient iterations in least square scaling
void addColsRational(const mpq_t *obj, const mpq_t *lower, const mpq_t *colValues, const int *colIndices, const int *colStarts, const int *colLengths, const int numCols, const int numValues, const mpq_t *upper)
adds a set of columns (GMP only method)
Result
Result of the simplification.
void changeRhsRational(const VectorRational &rhs)
changes right-hand side vector to rhs
bool _loadBasisFromOldBasis(bool boosted)
void _performOptIRStable(SolRational &sol, bool acceptUnbounded, bool acceptInfeasible, int minIRRoundsRemaining, bool &primalFeasible, bool &dualFeasible, bool &infeasible, bool &unbounded, bool &stoppedTime, bool &stoppedIter, bool &error)
solves current problem with iterative refinement and recovery mechanism
Steepest edge pricer.Class SPxSteepExPR implements a steepest edge pricer to be used with SoPlex...
refactor threshold for fill-in in current factor update compared to fill-in in last factorization ...
SPxSolverBase< R >::Status status() const
returns the current solver status
Dense vector.Class VectorBase provides dense linear algebra vectors. Internally, VectorBase wraps std...
void _optimizeRational(volatile bool *interrupt=NULL)
temporary fix for Rational
SPxParMultPR< BP > _boostedPricerParMult
Geometric mean row/column scaling.This SPxScaler implementation performs geometric mean scaling of th...
bool _boostingLimitReached
bool getDualRational(VectorRational &vector)
bool setBoolParam(const BoolParam param, const bool value, const bool init=true)
sets boolean parameter value; returns true on success
enable precision boosting ?
const char * getSimplifierName()
name of simplifier
Abstract pricer base class.
int numNonzeros() const
returns number of nonzeros
SPxParMultPR< R > _pricerParMult
threshold on number of rows vs. number of columns for switching from column to row representations in...
SPxSumST< R > _starterSum
void removeColsReal(int perm[])
removes all columns with an index i such that perm[i] < 0; upon completion, perm[i] >= 0 indicates th...
void addRowsRational(const mpq_t *lhs, const mpq_t *rowValues, const int *rowIndices, const int *rowStarts, const int *rowLengths, const int numRows, const int numValues, const mpq_t *rhs)
adds a set of rows (GMP only method)
SPxLeastSqSC< BP > _boostedScalerLeastsq
void _completeRangeTypesRational()
completes range type arrays after adding columns and/or rows
Solution vector based start basis.
void getRowsRational(int start, int end, LPRowSetRational &lprowset) const
gets rows start, ..., end.
void addRowReal(const LPRowBase< R > &lprow)
adds a single row
void removeRowRangeReal(int start, int end, int perm[]=0)
removes rows start to end including both; an array perm of size numRows() may be passed as buffer mem...
SPxDefaultRT< R > _ratiotesterTextbook
DataArray< typename SPxSolverBase< BP >::VarStatus > _tmpBasisStatusRows
SPxScaler< BP > * _boostedScaler
void _computePrimalScalingFactor(Rational &maxScale, Rational &primalScale, Rational &boundsViolation, Rational &sideViolation, Rational &redCostViolation)
computes primal scaling factor; limit increase in scaling by tolerance used in floating point solve ...
void changeUpperRational(const VectorRational &upper)
changes vector of upper bounds to upper
VectorRational _feasLower
Sequential object-oriented SimPlex.SPxSolverBase is an LP solver class using the revised Simplex algo...
void _recomputeRangeTypesReal()
recomputes range types from scratch using real LP
working tolerance for feasibility in floating-point solver during iterative refinement ...
int dmaxSizePrimalRational(const int base=2)
get size of largest denominator in primal solution
void _storeBasisAsOldBasis(DataArray< typename SPxSolverBase< R >::VarStatus > &rows, DataArray< typename SPxSolverBase< R >::VarStatus > &cols)
bool getSlacksRational(VectorRational &vector)
gets the vector of slack values if available; returns true on success
type of algorithm, i.e., primal or dual
round scaling factors for iterative refinement to powers of two?
void _addColsReal(const LPColSetReal &lpcolset)
adds multiple columns to the real LP and adjusts basis
void _checkBasisScaling()
check correctness of (un)scaled basis matrix operations
LP geometric mean scaling.
void _applyScaledObj(SPxSolverBase< T > &solver, Rational &dualScale, SolRational &sol)
applies scaled objective function
int numRowsRational() const
only error and warning output
bool getPrimalReal(R *p_vector, int size)
bool getBasisMetric(R &metric, int type=0)
automatic choice according to number of rows and columns
bool getPrimalRational(VectorRational &vector)
geometric mean scaling on rows and columns, max 8 rounds
Abstract ratio test base class.
void _forceNonbasicToBound(SolRational &sol, int &c, const int &maxDimRational, bool toLower)
forces value of given nonbasic variable to bound
dual feasibility tolerance
SPxAutoPR< R > _pricerAuto
static struct soplex::SoPlexBase::Settings::BoolParam boolParam
Dynamic sparse vectors.Class DSVectorBase implements dynamic sparse vectors, i.e. SVectorBases with a...
const SVectorRational & colVectorRational(int i) const
returns vector of column i
Least squares scaling.This SPxScaler implementation performs least squares scaling as suggested by Cu...
SPxBoundFlippingRT< BP > _boostedRatiotesterBoundFlipping
std::string description[SoPlexBase< R >::BOOLPARAM_COUNT]
array of descriptions for boolean parameters
Safe arrays of arbitrary types.Class Array provides safe arrays of arbitrary type. Array elements are accessed just like ordinary C++ array elements by means of the index operator[](). Safety is provided by.
void setIntegralityInformation(int ncols, int *intInfo)
pass integrality information about the variables to the solver
SPxSolverBase< R > _solver
void _computeDualScalingFactor(Rational &maxScale, Rational &primalScale, Rational &dualScale, Rational &redCostViolation, Rational &dualViolation)
computes dual scaling factor; limit increase in scaling by tolerance used in floating point solve ...
VectorBase< R > _manualLower
bool writeDualFileReal(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0, const DIdxSet *intvars=0) const
writes the dual of the real LP to file; LP or MPS format is chosen from the extension in filename; if...
Implementation of Sparse Linear Solver.
bool computeBasisInverseRational()
compute rational basis inverse; returns true on success
Implementation of Sparse Linear Solver with Rational precision.
SoPlexBase< R > & operator=(const SoPlexBase< R > &rhs)
assignment operator
void _applyScaledBounds(SPxSolverBase< T > &solver, Rational &primalScale)
applies scaled bounds
only error, warning, and debug output
bool getBasisInverseTimesVecRational(const SVectorRational &rhs, SSVectorRational &sol)
computes solution of basis matrix B * sol = rhs; performs rational factorization if not available; re...
void changeColRational(int i, const LPColRational &lpcol)
replaces column i with lpcol
SoPlex start basis generation base class.SPxStarter is the virtual base class for classes generating ...
const VectorRational & lhsRational() const
returns left-hand side vector
Settings()
default constructor initializing default settings
number of boolean parameters
bool _isRefinementOver(bool &primalFeasible, bool &dualFeasible, Rational &boundsViolation, Rational &sideViolation, Rational &redCostViolation, Rational &dualViolation, int minIRRoundsRemaining, bool &stoppedTime, bool &stoppedIter, int numFailedRefinements)
checks termination criteria for refinement loop
Real _epsUpdatePrecisionRatio
void _checkRefinementProgress(Rational &boundsViolation, Rational &sideViolation, Rational &redCostViolation, Rational &dualViolation, Rational &maxViolation, Rational &bestViolation, const Rational &violationImprovementFactor, int &numFailedRefinements)
checks refinement loop progress
bool isDualFeasible() const
is stored dual solution feasible?
void _factorizeColumnRational(SolRational &sol, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusRows, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusCols, bool &stoppedTime, bool &stoppedIter, bool &error, bool &optimal)
factorizes rational basis matrix in column representation
bool getDual(VectorBase< R > &vector)
gets the dual solution vector if available; returns true on success
std::shared_ptr< Tolerances > _tolerances
void syncLPRational()
synchronizes rational LP with real LP, i.e., copies real LP to rational LP, if sync mode is manual ...
geometric mean scaling on rows and columns, max 1 round
int numIterationsBoosted() const
number of iterations in higher precision since last call to solve
void removeColRangeRational(int start, int end, int perm[]=0)
removes columns start to end including both; an array perm of size numColsRational() may be passed as...
const char * getStarterName()
name of starter
DataArray< typename SPxSolverBase< R >::VarStatus > _storedBasisStatusCols
General methods in LP preprocessing.
SLUFactorRational _rationalLUSolver
R objValueReal()
returns the objective value if a primal solution is available
VectorRational _unboundedLhs
int totalSizePrimalRational(const int base=2)
get size of primal solution
void changeLowerRational(const VectorRational &lower)
changes vector of lower bounds to lower
void _removeColsReal(int perm[])
removes all columns with an index i such that perm[i] < 0; upon completion, perm[i] >= 0 indicates th...
void _changeBoundsReal(const VectorBase< R > &lower, const VectorBase< R > &upper)
changes vectors of column bounds to lower and upper and adjusts basis
refactor threshold for nonzeros in last factorized basis matrix compared to updated basis matrix ...
SLUFactor< BP > _boostedSlufactor
row representation (lower,lhs) <= (x,Ax) <= (upper,rhs)
bool writeBasisFile(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0, const bool cpxFormat=false) const
writes basis information to filename; if rowNames and colNames are NULL, default names are used; retu...
Auto pricer.This pricer switches between Devex and Steepest edge pricer based on the difficulty of th...
void _project(SolRational &sol)
undoes lifting
SPxVectorST< R > _starterVector
bool getRowViolationRational(Rational &maxviol, Rational &sumviol)
SPxSolverBase< R >::Status optimize(volatile bool *interrupt=NULL)
optimize the given LP
bool getEstimatedCondition(R &condition)
computes an estimated condition number for the current basis matrix using the power method; returns t...
const VectorRational & maxObjRational() const
returns objective function vector after transformation to a maximization problem; since this is how i...
void changeObjRational(const VectorRational &obj)
changes objective function vector to obj
should dual infeasibility be tested in order to try to return a dual solution even if primal infeasib...
bool getDualReal(R *p_vector, int dim)
bool getPrimalRay(VectorBase< R > &vector)
gets the primal ray if available; returns true on success
void _convertDataArrayVarStatusToRPrecision(DataArray< typename SPxSolverBase< BP >::VarStatus > &base, DataArray< typename SPxSolverBase< R >::VarStatus > ©)
const SVectorRational & rowVectorRational(int i) const
returns vector of row i
void _changeUpperReal(const VectorBase< R > &upper)
changes vector of upper bounds to upper and adjusts basis
void changeElementReal(int i, int j, const R &val)
changes matrix entry in row i and column j to val
bool hasSol() const
is a solution available (not neccessarily feasible)?
void addRowsReal(const LPRowSetBase< R > &lprowset)
adds multiple rows
DataArray< typename SPxSolverBase< R >::VarStatus > _oldUnbdBasisStatusCols
void _resolveWithoutPreprocessing(typename SPxSimplifier< R >::Result simplificationStatus)
loads original problem into solver and solves again after it has been solved to optimality with prepr...
bool hasBasis() const
is an advanced starting basis available?
bool getRedCostViolation(R &maxviol, R &sumviol)
gets violation of reduced costs; returns true on success
decide according to READMODE
SPxSimplifier< BP > * _boostedSimplifier
void _syncLPRational(bool time=true)
synchronizes rational LP with real LP, i.e., copies real LP to rational LP, without looking at the sy...
greedy crash basis weighted by objective, bounds, and sides
LP simplification base class.
Saving LPs in a form suitable for SoPlex.
primal simplex algorithm, i.e., entering for column and leaving for row representation ...
SPxSteepPR< BP > _boostedPricerQuickSteep
Statistics * _statistics
statistics since last call to solveReal() or solveRational()
R maxObjReal(int i) const
returns objective value of column i after transformation to a maximization problem; since this is how...
should cycling solutions be accepted during iterative refinement?
void _correctDualSolution(SPxSolverBase< T > &solver, SolRational &sol, const bool &maximizing, VectorBase< T > &dualReal, Rational &dualScale, int &dualSize, const int &maxDimRational)
corrects dual solution and aligns with basis
mode for a posteriori feasibility checks
void changeRangeRational(const VectorRational &lhs, const VectorRational &rhs)
changes left- and right-hand side vectors
Partial multiple pricing.Class SPxParMultPr is an implementation class for SPxPricer implementing Dan...
void printStatus(std::ostream &os, typename SPxSolverBase< R >::Status status)
prints status
const VectorBase< R > & maxObjRealInternal() const
returns objective function vector after transformation to a maximization problem; since this is how i...
bool parseSettingsString(char *str)
parses one setting string and returns true on success; note that string is modified ...
RangeType
type of bounds and sides
should lifting be used to reduce range of nonzero matrix coefficients?
const VectorRational & rhsRational() const
returns right-hand side vector
Rational maxAbsNonzeroRational() const
returns biggest non-zero element in absolute value
void printShortStatistics(std::ostream &os)
prints short statistics
void getRhsReal(VectorBase< R > &rhs) const
gets right-hand side vector
void _idxToPerm(int *idx, int idxSize, int *perm, int permSize) const
creates a permutation for removing rows/columns from an array of indices
using the presolve lib papilo
void changeRowRational(int i, const LPRowRational &lprow)
replaces row i with lprow
Real solveTime() const
time spent in last call to solve
Fast shifting ratio test.Class SPxFastRT is an implementation class of SPxRatioTester providing fast ...
bool _reapplyPersistentScaling() const
check whether persistent scaling is supposed to be reapplied again after unscaling ...
void getColsRational(int start, int end, LPColSetRational &lpcolset) const
gets columns start, ..., end
should a rational factorization be performed after iterative refinement?
user sync of real and rational LP
sparse pricing threshold (#violations < dimension * SPARSITY_THRESHOLD activates sparse pricing) ...
SoPlex chooses automatically (currently always "internal")
void _addRowReal(const LPRowBase< R > &lprow)
adds a single row to the real LP and adjusts basis
bool getRedCostReal(R *vector, int dim)
DSVectorRational _primalDualDiff
maximize number of basic slack variables, i.e. more variables on bounds
R minAbsNonzeroReal() const
returns smallest non-zero element in absolute value
DataArray< RangeType > _rowTypes
apply rational reconstruction after each iterative refinement?
bool getDualViolationRational(Rational &maxviol, Rational &sumviol)
void _checkScaling(SPxLPBase< R > *origLP) const
check scaling of LP
bool getPrimalRayReal(R *vector, int dim)
void _removeRowRangeReal(int start, int end, int perm[])
removes rows start to end including both; an array perm of size numRows() may be passed as buffer mem...
bool getRedCostRational(VectorRational &vector)
VectorBase< R > _manualObj
const char * getScalerName()
name of scaling method
void removeRowRational(int i)
removes row i
SPxSolverBase< R >::Status solve(volatile bool *interrupt=NULL)
void _verifySolutionReal()
verify computed solution and resolve if necessary
standard Harris ratio test
SPxSolverBase< R >::Status _solveRealStable(bool acceptUnbounded, bool acceptInfeasible, VectorBase< R > &primal, VectorBase< R > &dual, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusRows, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusCols, const bool forceNoSimplifier=false)
solves real LP with recovery mechanism
SPxSolverBase< R >::VarStatus basisColStatus(int col) const
returns basis status for a single column
void getColVectorReal(int i, DSVectorBase< R > &col) const
gets vector of col i
SPxLeastSqSC< R > _scalerLeastsq
void _verifyObjLimitReal()
verify computed obj stop and resolve if necessary
SPxEquiliSC< BP > _boostedScalerBiequi
column representation Ax - s = 0, lower <= x <= upper, lhs <= s <= rhs
SPxSolverBase< R >::VarStatus basisRowStatus(int row) const
returns basis status for a single row
void changeBoundsRational(const VectorRational &lower, const VectorRational &upper)
changes vectors of column bounds to lower and upper
LP simplification abstract base class.Instances of classes derived from SPxSimplifier may be loaded t...
void removeRowsReal(int perm[])
removes all rows with an index i such that perm[i] < 0; upon completion, perm[i] >= 0 indicates the n...
int dlcmSizeDualRational(const int base=2)
get size of least common multiple of denominators in dual solution
bool _lowerFinite(const RangeType &rangeType) const
checks whether RangeType corresponds to finite lower bound
void _addColReal(const LPColReal &lpcol)
adds a single column to the real LP and adjusts basis
bool _isBoostedStartingFromSlack(bool initialSolve=true)
return true if slack basis has to be loaded for boosted solver
void _rangeToPerm(int start, int end, int *perm, int permSize) const
creates a permutation for removing rows/columns from a range of indices
void changeLowerReal(const VectorBase< R > &lower)
changes vector of lower bounds to lower
void getColRational(int i, LPColRational &lpcol) const
gets column i
type of timer for statistics
int totalSizeDualRational(const int base=2)
get size of dual solution
R lowerReal(int i) const
returns lower bound of column i
bool getDualFarkas(VectorBase< R > &vector)
gets the Farkas proof if available; returns true on success
SPxDevexPR< BP > _boostedPricerDevex
void _unscaleSolutionReal(SPxLPBase< R > &LP, bool persistent=true)
unscales stored solution to remove internal or external scaling of LP
bool _factorSolNewBasisPrecBoost
Wrapper for several output streams. A verbosity level is used to decide which stream to use and wheth...
iteration limit (-1 if unlimited)
bool getBoundViolation(R &maxviol, R &sumviol)
gets violation of bounds; returns true on success
type of computational form, i.e., column or row representation
void _performOptIRStableBoosted(SolRational &sol, bool acceptUnbounded, bool acceptInfeasible, int minIRRoundsRemaining, bool &primalFeasible, bool &dualFeasible, bool &infeasible, bool &unbounded, bool &stoppedTime, bool &stoppedIter, bool &error, bool &needNewBoostedIt)
solves current problem with iterative refinement and recovery mechanism using boosted solver ...
primal feasibility tolerance
bool hasDual() const
deprecated: use hasSol() instead
void _removeColRangeReal(int start, int end, int perm[])
removes columns start to end including both; an array perm of size numColsReal() may be passed as buf...
void getObjRational(VectorRational &obj) const
gets objective function vector
SPxLPRational * _rationalLP
minimize number of basic slack variables, i.e. more variables between bounds
void _untransformUnbounded(SolRational &sol, bool unbounded)
undoes transformation to unboundedness problem
void _recomputeRangeTypesRational()
recomputes range types from scratch using rational LP
void removeColsRational(int perm[])
removes all columns with an index i such that perm[i] < 0; upon completion, perm[i] >= 0 indicates th...
decide depending on tolerances whether to apply iterative refinement
bool saveSettingsFile(const char *filename, const bool onlyChanged=false, int solvemode=1) const
writes settings file; returns true on success
void _solveBoostedRealLPAndRecordStatistics(volatile bool *interrupt=NULL)
call floating-point solver and update statistics on iterations etc.
const VectorBase< R > & lowerRealInternal() const
returns lower bound vector
void removeColRangeReal(int start, int end, int perm[]=0)
removes columns start to end including both; an array perm of size numColsReal() may be passed as buf...
int numPrecisionBoosts() const
number of precision boosts since last call to solve
bool getPrimal(VectorBase< R > &vector)
gets the primal solution vector if available; returns true on success
void _computeBasisInverseRational()
computes rational inverse of basis matrix as defined by _rationalLUSolverBind
void _solveRealForRationalBoostedStable(SolRational &sol, bool &primalFeasible, bool &dualFeasible, bool &infeasible, bool &unbounded, bool &stoppedTime, bool &stoppedIter, bool &error, bool &needNewBoostedIt)
solves current problem using multiprecision floating-point solver return false if a new boosted itera...
DataArray< typename SPxSolverBase< BP >::VarStatus > _tmpBasisStatusCols
LPRowBase< R >::Type rowTypeReal(int i) const
returns inequality type of row i
bool hasPrimalRay() const
is a primal unbounded ray available?
void _solveRealLPAndRecordStatistics(volatile bool *interrupt=NULL)
call floating-point solver and update statistics on iterations etc.
void changeRhsReal(const VectorBase< R > &rhs)
changes right-hand side vector to rhs
bool readBasisFile(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0)
reads basis information from filename and returns true on success; if rowNames and colNames are NULL...
upper limit on objective value
OutputIterator copy(const RangeT &range, OutputIterator out)
should LP be transformed to equality form before a rational solve?
void _switchToStandardMode()
indicate if we are testing feasibility, unboundedness or neither
void _preprocessAndSolveReal(bool applyPreprocessing, volatile bool *interrupt=NULL)
solves real LP with/without preprocessing
textbook ratio test without stabilization
void _changeElementReal(int i, int j, const R &val)
changes matrix entry in row i and column j to val and adjusts basis
void _ratrecAndOrRatfac(int &minIRRoundsRemaining, int &lastStallIterations, int &numberOfIterations, bool &factorSolNewBasis, int &nextRatrec, const Rational &errorCorrectionFactor, Rational &errorCorrection, Rational &maxViolation, SolRational &sol, bool &primalFeasible, bool &dualFeasible, bool &stoppedTime, bool &stoppedIter, bool &error, bool &breakAfter, bool &continueAfter)
performs rational reconstruction and/or factorizationd
print condition number during the solve
void syncLPReal()
synchronizes real LP with rational LP, i.e., copies (rounded) rational LP into real LP...
Real precisionBoostTime() const
time spen in higher precision since last call to solve
bool hasPrimal() const
deprecated: use hasSol() instead
SLUFactor< R > _slufactor
void _performFeasIRStable(SolRational &sol, bool &withDualFarkas, bool &stoppedTime, bool &stoppedIter, bool &error)
performs iterative refinement on the auxiliary problem for testing feasibility
automatic sync of real and rational LP
bool multBasis(R *vec, bool unscale=true)
multiply with basis matrix; B * vec (inplace)
void _addRowsReal(const LPRowSetBase< R > &lprowset)
adds multiple rows to the real LP and adjusts basis
Solution vector based start basis.This version of SPxWeightST can be used to construct a starting bas...
SPxDevexPR< R > _pricerDevex
BoolParam
boolean parameters
bool getDualFarkasRational(VectorRational &vector)
const Settings & settings() const
returns current parameter settings
int numCols() const
Templated function that returns number of columns.
decide according to problem size
try different settings when solve fails
Dynamic index set.Class DIdxSet provides dynamic IdxSet in the sense, that no restrictions are posed ...
void setRandomSeed(unsigned int seed)
set the random seeds of the solver instance
Rational _rationalPosInfty
IntParam
integer parameters
SPxBasisBase< R >::SPxStatus basisStatus() const
returns the current basis status
unsigned int randomSeed() const
returns the current random seed of the solver instance
DataArray< RangeType > _colTypes
SPxHarrisRT< R > _ratiotesterHarris
SPxEquiliSC< R > _scalerBiequi
equilibrium scaling on rows or columns
void _invalidateSolution()
invalidates solution
bool _evaluateResult(SPxSolverBase< T > &solver, typename SPxSolverBase< T >::Status result, bool usingRefinedLP, SolRational &sol, VectorBase< T > &dualReal, bool &infeasible, bool &unbounded, bool &stoppedTime, bool &stoppedIter, bool &error)
evaluates result of solve. Return true if the algorithm must to stopped, false otherwise.
bool getBasisIndRational(DataArray< int > &bind)
gets an array of indices for the columns of the rational basis matrix; bind[i] >= 0 means that the i-...
void _transformEquality()
introduces slack variables to transform inequality constraints into equations for both rational and r...
void printStatistics(std::ostream &os)
prints complete statistics
Simple heuristic SPxStarter.
void removeRowReal(int i)
removes row i
refactor threshold for memory growth in factorization since last refactorization
Class for storing a primal-dual solution with basis information.
bool getRedCostViolationRational(Rational &maxviol, Rational &sumviol)
try to enforce that the optimal solution is a basic solution
bool _isBoostedConsistent() const
checks consistency for the boosted solver
SPxSolverBase< R >::Status _status
void _updateBoostingStatistics()
void writeStateReal(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0, const bool cpxFormat=false) const
writes internal LP, basis information, and parameter settings; if rowNames and colNames are NULL...
void removeColReal(int i)
removes column i
(In)equality for LPs.Class LPRowBase provides constraints for linear programs in the form where a is...
void _storeLastStableBasisBoosted(bool vanished)
void removeRowsRational(int perm[])
removes all rows with an index i such that perm[i] < 0; upon completion, perm[i] >= 0 indicates the n...
bool setRealParam(const RealParam param, const Real value, const bool init=true)
sets real parameter value; returns true on success
type of starter used to create crash basis
bool getSlacksReal(VectorBase< R > &vector)
gets the vector of slack values if available; returns true on success
void _solveRealForRationalBoosted(VectorBase< BP > &primal, VectorBase< BP > &dual, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusRows, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusCols, typename SPxSolverBase< BP >::Status &boostedResult, bool initialSolve)
solves real LP during iterative refinement
DataArray< typename SPxSolverBase< R >::VarStatus > _oldBasisStatusCols
void removeColRational(int i)
removes column i
SPxSimplifier< R > * _simplifier
Sparse vector .A UnitVectorBase is an SVectorBase that can take only one nonzero value with value 1 b...
Bound flipping ratio test (long step dual) for SoPlex.
VectorRational _unboundedLower
bool _isConsistent() const
checks consistency
VectorBase< R > _manualLhs
const VectorBase< R > & upperRealInternal() const
returns upper bound vector
Debugging, floating point type and parameter definitions.
void _convertDataArrayVarStatusToBoosted(DataArray< typename SPxSolverBase< R >::VarStatus > &base, DataArray< typename SPxSolverBase< BP >::VarStatus > ©)
void _ensureDSVectorRationalMemory(DSVectorRational &vec, const int newmax) const
extends sparse vector to hold newmax entries if and only if it holds no more free entries ...
bool getBasisInverseColRational(const int c, SSVectorRational &vec)
computes column c of basis inverse; performs rational factorization if not available; returns true on...
Set of strings.Class NameSet implements a symbol or name table. It allows to store or remove names (i...
mode for solution polishing
bool _parseSettingsLine(char *line, const int lineNumber)
parses one line in a settings file and returns true on success; note that the string is modified ...
mode for hyper sparse pricing
RangeType _switchRangeType(const RangeType &rangeType) const
switches RANGETYPE_LOWER to RANGETYPE_UPPER and vice versa
bool getDualViolation(R &maxviol, R &sumviol)
gets violation of dual multipliers; returns true on success
pivot zero tolerance used in factorization
SPxSolverBase< R >::Status _solveRealForRational(bool fromscratch, VectorBase< R > &primal, VectorBase< R > &dual, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusRows, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusCols)
solves real LP during iterative refinement
void _evaluateSolutionReal(typename SPxSimplifier< R >::Result simplificationStatus)
checks result of the solving process and solves again without preprocessing if necessary ...
bool _upperFinite(const RangeType &rangeType) const
checks whether RangeType corresponds to finite upper bound
const VectorBase< R > & rhsRealInternal() const
returns right-hand side vector, ignoring scaling
LP least squares scaling.
DataArray< typename SPxSolverBase< R >::VarStatus > _oldBasisStatusRows
static struct soplex::SoPlexBase::Settings::RealParam realParam
number of real parameters
upper bound is finite, lower bound is infinite
Collection of dense, sparse, and semi-sparse vectors.
RangeType _rangeTypeReal(const R &lower, const R &upper) const
determines RangeType from real bounds
RangeType _rangeTypeRational(const Rational &lower, const Rational &upper) const
determines RangeType from rational bounds
Presol< BP > _boostedSimplifierPaPILO
Implementation of Sparse Linear Solver.This class implements a SLinSolver interface by using the spar...
bool defaultValue[SoPlexBase< R >::BOOLPARAM_COUNT]
array of default values for boolean parameters
bool _reconstructSolutionRational(SolRational &sol, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusRows, DataArray< typename SPxSolverBase< R >::VarStatus > &basisStatusCols, const Rational &denomBoundSquared)
attempts rational reconstruction of primal-dual solution
SPxSteepExPR< R > _pricerSteep
void resetSettings(const bool quiet=false, const bool init=true)
resets default parameter settings
DataArray< typename SPxSolverBase< R >::VarStatus > _oldFeasBasisStatusCols
Everything should be within this namespace.
void removeRowRangeRational(int start, int end, int perm[]=0)
removes rows start to end including both; an array perm of size numRowsRational() may be passed as bu...
factor by which the precision of the floating-point solver is multiplied
lower bound is finite, upper bound is infinite
returns the current git hash of SoPlex
mode for iterative refinement strategy
maximum increase of scaling factors between refinements
Rational _rationalMaxscaleincr
Dantzig pricer.Class SPxDantzigPR is an implementation class of an SPxPricer implementing Dantzig's d...
apply standard floating-point algorithm
Harris pricing with shifting.
void _storeSolutionRealFromPresol()
stores solution from the simplifier because problem vanished in presolving step
generic solution-based crash basis
zero tolerance used in update of the factorization
bool getRowViolation(R &maxviol, R &sumviol)
gets violation of constraints; returns true on success
void changeColReal(int i, const LPColReal &lpcol)
replaces column i with lpcol
R objReal(int i) const
returns objective value of column i
void changeLhsReal(const VectorBase< R > &lhs)
changes left-hand side vector for constraints to lhs
void _storeSolutionReal(bool verify=true)
stores solution of the real LP; before calling this, the real LP must be loaded in the solver and sol...
int numRows() const
returns number of rows
void _computeSidesViolation(SolRational &sol, Rational &sideViolation)
computes violation of sides during the refinement loop
accuracy of conjugate gradient method in least squares scaling (higher value leads to more iterations...
Rational minAbsNonzeroRational() const
returns smallest non-zero element in absolute value
Saving LPs in a form suitable for SoPlex.Class SPxLPBase provides the data structures required for sa...
void _syncRealSolution()
synchronizes rational solution with real solution, i.e., copies (rounded) rational solution to real s...
void addRowRational(const LPRowRational &lprow)
adds a single row
bound flipping ratio test for long steps in the dual simplex
time limit in seconds (INFTY if unlimited)
Steepest edge pricer with exact initialization of weights.
void changeElementRational(int i, int j, const Rational &val)
changes matrix entry in row i and column j to val
SPxDantzigPR< BP > _boostedPricerDantzig
using internal presolving methods
DataArray< typename SPxSolverBase< R >::VarStatus > _basisStatusRows
Type
(In)Equality type of an LP row.
std::string statisticString() const
statistical information in form of a string
mode for reading LP files
use bound flipping also for row representation?
Real _tolPrecisionRatio
ratios for computing the tolerances for precision boosting ratio denotes the proportion of precision ...
bool setSettings(const Settings &newSettings, const bool init=true)
sets parameter settings; returns true on success
DataArray< typename SPxSolverBase< R >::VarStatus > _storedBasisStatusRows
Real _epsZeroPrecisionRatio
const SVectorBase< R > & colVectorRealInternal(int i) const
returns vector of col i, ignoring scaling
Simple heuristic SPxStarter.Testing version of an SPxVectorST using a very simplistic heuristic to bu...
Weighted start basis.Class SPxWeightST is an implementation of a SPxStarter for generating a Simplex ...
SPxBoundFlippingRT< R > _ratiotesterBoundFlipping
bool readFile(const char *filename, NameSet *rowNames=0, NameSet *colNames=0, DIdxSet *intVars=0)
reads LP file in LP or MPS format according to READMODE parameter; gets row names, column names, and integer variables if desired; returns true on success
SPxGeometSC< R > _scalerGeoequi
re-optimize the original problem to get a proof (ray) of infeasibility/unboundedness?
SPxStarter< R > * _starter
Partial multiple pricing.
minimum number of stalling refinements since last pivot to trigger rational factorization ...
void getRowRational(int i, LPRowRational &lprow) const
gets row i
void addColReal(const LPColBase< R > &lpcol)
adds a single column
SoPlexBase< Real > SoPlex
lower bound equals upper bound
Real _realParamValues[SoPlexBase< R >::REALPARAM_COUNT]
array of current real parameter values
stalling refinement limit (-1 if unlimited)
Textbook ratio test for SoPlex.Class SPxDefaultRT provides an implementation of the textbook ratio te...
void changeBoundsReal(const VectorBase< R > &lower, const VectorBase< R > &upper)
changes vectors of column bounds to lower and upper
bool _setupBoostedSolverAfterRecovery()
setup recovery mecanism using multiprecision, return false if maximum precision reached, true otherwise
void printVersion() const
prints version and compilation options
int _intParamValues[SoPlexBase< R >::INTPARAM_COUNT]
array of current integer parameter values
void _transformUnbounded()
transforms LP to unboundedness problem by moving the objective function to the constraints, changing right-hand side and bounds to zero, and adding an auxiliary variable for the decrease in the objective function
number< gmp_float< 50 >, et_off > BP
bool areLPsInSync(const bool checkVecVals=true, const bool checkMatVals=false, const bool quiet=false) const
checks if real LP and rational LP are in sync; dimensions will always be compared, vector and matrix values only if the respective parameter is set to true. If quiet is set to true the function will only display which vectors are different.
const SVectorBase< R > & rowVectorRealInternal(int i) const
returns vector of row i, ignoring scaling
LP scaler abstract base class.Instances of classes derived from SPxScaler may be loaded to SoPlex in ...
bool getPrimalRayRational(VectorRational &vector)
equilibrium scaling on rows and columns
Set of LP rows.Class LPRowSetBase implements a set of LPRowBase%s. Unless for memory limitations...
VectorRational _unboundedUpper
DataArray< typename SPxSolverBase< R >::VarStatus > _basisStatusCols
void _storeBasis()
store basis
VectorRational _feasUpper
store advanced and stable basis met before each simplex iteration, to better warm start ...
int numIterations() const
number of iterations since last call to solve
DataArray< typename SPxSolverBase< R >::VarStatus > _oldFeasBasisStatusRows
void changeRowReal(int i, const LPRowBase< R > &lprow)
replaces row i with lprow
int dmaxSizeDualRational(const int base=2)
get size of largest denominator in dual solution
void _changeLowerReal(const VectorBase< R > &lower)
changes vector of lower bounds to lower and adjusts basis
bool multBasisTranspose(R *vec, bool unscale=true)
multiply with transpose of basis matrix; vec * B^T (inplace)
void _syncLPReal(bool time=true)
synchronizes real LP with rational LP, i.e., copies (rounded) rational LP into real LP...
LPColSetRational _slackCols
minimal modification threshold to apply presolve reductions
void setTimings(const Timer::TYPE ttype)
set statistic timers to a certain type
void writeStateRational(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0, const bool cpxFormat=false) const
writes internal LP, basis information, and parameter settings; if rowNames and colNames are NULL...
void changeUpperReal(const VectorBase< R > &upper)
changes vector of upper bounds to upper
void clearBasis()
clears starting basis
steepest edge pricer with exact initialization of norms
SPxSolverBase< BP > _boostedSolver
continue iterative refinement with exact basic solution if not optimal?
void _resetBoostedPrecision()
reset the boosted precision to the default value
perturb the entire problem or only the relevant bounds of s single pivot?
void _ensureRationalLP()
ensures that the rational LP is available; performs no sync
void _restoreBasis()
restore basis
DataArray< int > _rationalLUSolverBind
void _solveRealForRationalStable(SolRational &sol, bool &primalFeasible, bool &dualFeasible, bool &infeasible, bool &unbounded, bool &stoppedTime, bool &stoppedIter, bool &error)
solves current problem using double floating-point solver
R rhsReal(int i) const
returns right-hand side of row i
bool _inStandardMode()
check if we are testing feasibility, unboundedness or neither
SPxDantzigPR< R > _pricerDantzig
minimal reduction (sum of removed rows/cols) to continue simplification
Real _epsPivotPrecisionRatio
geometric frequency at which to apply rational reconstruction
int numColsRational() const
bool isPrimalFeasible() const
is stored primal solution feasible?
SPxGeometSC< R > _scalerGeo1
SPxGeometSC< BP > _boostedScalerGeoequi
DataArray< typename SPxSolverBase< R >::VarStatus > _oldUnbdBasisStatusRows
Class for storing a primal-dual solution with basis information.
void _changeRowReal(int i, const LPRowBase< R > &lprow)
replaces row i with lprow and adjusts basis
void _computeReducedCostViolation(SolRational &sol, Rational &redCostViolation, const bool &maximizing)
computes violation of reduced costs during the refinement loop
Sparse vectors.Class SVectorBase provides packed sparse vectors. Such are a sparse vectors...
bool _readFileReal(const char *filename, NameSet *rowNames=0, NameSet *colNames=0, DIdxSet *intVars=0)
reads real LP in LP or MPS format from file and returns true on success; gets row names...
VectorRational _unboundedRhs
SPxGeometSC< R > _scalerGeo8
number of integer parameters
class of parameter settings
void _restoreLPReal()
restores objective, bounds, and sides of real LP
Forrest-Tomlin type update.
static struct soplex::SoPlexBase::Settings::IntParam intParam
void addColRational(const LPColRational &lpcol)
adds a single column
void changeLhsRational(const VectorRational &lhs)
changes left-hand side vector for constraints to lhs
void getUpperReal(VectorBase< R > &upper) const
gets upper bound vector
void _syncRationalSolution()
synchronizes real solution with rational solution, i.e., copies real solution to rational solution ...
refinement limit (-1 if unlimited)
steepest edge pricer with initialization to unit norms
void _transformFeasibility()
transforms LP to feasibility problem by removing the objective function, shifting variables...
SoPlexBase()
default constructor
void _enableSimplifierAndScaler()
enables simplifier and scaler according to current parameters
void getBasisInd(int *bind) const
gets the indices of the basic columns and rows; basic column n gives value n, basic row m gives value...
bool checkBasisDualFeasibility(VectorBase< R > feasVec)
checks the dual feasibility of the current basis
void clearLPRational()
clears the LP
Textbook ratio test for SoPlex.
bool _boolParamValues[SoPlexBase< R >::BOOLPARAM_COUNT]
array of current boolean parameter values
Array< UnitVectorRational *> _unitMatrixRational
upper threshold in lifting (nonzero matrix coefficients with larger absolute value will be reformulat...
void getLhsReal(VectorBase< R > &lhs) const
gets left-hand side vector
standard floating-point parsing
SPxFastRT< BP > _boostedRatiotesterFast
void _updateReducedCosts(SolRational &sol, int &dualSize, const int &numCorrectedPrimals)
updates or recomputes reduced cost values depending on which looks faster; adding one to the length o...
const VectorBase< R > & lhsRealInternal() const
returns left-hand side vector, ignoring scaling
bool writeFileReal(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0, const DIdxSet *intvars=0, const bool unscale=true) const
bool setIntParam(const IntParam param, const int value, const bool init=true)
sets integer parameter value; returns true on success
const std::shared_ptr< Tolerances > tolerances() const
returns current tolerances
void _performOptIRWrapper(SolRational &sol, bool acceptUnbounded, bool acceptInfeasible, int minIRRoundsRemaining, bool &primalFeasible, bool &dualFeasible, bool &infeasible, bool &unbounded, bool &stoppedTime, bool &stoppedIter, bool &error)
perform iterative refinement using the right precision
mode for synchronizing real and rational LP
lower limit on objective value
Real _epsFactorPrecisionRatio
void _setupBoostedSolver()
setup boosted solver before launching iteration
Rational objValueRational()
returns the objective value if a primal solution is available
void changeRangeReal(const VectorBase< R > &lhs, const VectorBase< R > &rhs)
changes left- and right-hand side vectors
void _computeInfeasBox(SolRational &sol, bool transformed)
void _untransformEquality(SolRational &sol)
undoes transformation to equality form
Rational _rationalFeastol
SPxWeightST< R > _starterWeight
void _storeLastStableBasis(bool vanished)
Equilibrium row/column scaling.This SPxScaler implementation performs equilibrium scaling of the LPs ...
SPxAutoPR< BP > _boostedPricerAuto
void _storeLPReal()
stores objective, bounds, and sides of real LP
crash basis from a greedy solution
void addColsReal(const LPColSetBase< R > &lpcolset)
adds multiple columns
SPxSteepExPR< BP > _boostedPricerSteep
bool getBasisInverseColReal(int c, R *coef, int *inds=NULL, int *ninds=NULL, bool unscale=true)
computes column c of basis inverse; returns true on success
VectorBase< R > _manualRhs
void changeObjReal(const VectorBase< R > &obj)
changes objective function vector to obj
bool writeFileRational(const char *filename, const NameSet *rowNames=0, const NameSet *colNames=0, const DIdxSet *intvars=0) const
void getLowerReal(VectorBase< R > &lower) const
gets lower bound vector
SPxMainSM< BP > _boostedSimplifierMainSM
void _applyScaledSides(SPxSolverBase< T > &solver, Rational &primalScale)
applies scaled sides
zero tolerance used in factorization
R lhsReal(int i) const
returns left-hand side of row i
bool getBasisInverseTimesVecReal(R *rhs, R *sol, bool unscale=true)
computes dense solution of basis matrix B * sol = rhs; returns true on success
void getObjReal(VectorBase< R > &obj) const
gets objective function vector
LP column.Class LPColBase provides a datatype for storing the column of an LP a the form similar to ...
void printSolvingStatistics(std::ostream &os)
prints statistics on solving process
partial multiple pricer based on Dantzig pricing
bool getBasisInverseRowReal(int r, R *coef, int *inds=NULL, int *ninds=NULL, bool unscale=true)
computes row r of basis inverse; returns true on success
bool hasDualFarkas() const
is Farkas proof of infeasibility available?
dual simplex algorithm, i.e., leaving for column and entering for row representation ...
bool loadSettingsFile(const char *filename)
reads settings file; returns true on success
void _changeRhsReal(const VectorBase< R > &rhs)
changes right-hand side vector to rhs and adjusts basis
boosted solver start from last basis
void _removeRowsReal(int perm[])
removes all rows with an index i such that perm[i] < 0; upon completion, perm[i] >= 0 indicates the n...
force iterative refinement
modified Harris ratio test
Steepest edge pricer.Class SPxSteepPR implements a steepest edge pricer to be used with SoPlex...
bool setDualNorms(int nnormsRow, int nnormsCol, R *norms)
sets steepest edge norms and returns false if that's not possible
SPxGeometSC< BP > _boostedScalerGeo8
void setBasis(const typename SPxSolverBase< R >::VarStatus rows[], const typename SPxSolverBase< R >::VarStatus cols[])
sets starting basis via arrays of statuses
void getRowVectorReal(int i, DSVectorBase< R > &row) const
gets vector of row i
Presol< R > _simplifierPaPILO
void _performUnboundedIRStable(SolRational &sol, bool &hasUnboundedRay, bool &stoppedTime, bool &stoppedIter, bool &error)
performs iterative refinement on the auxiliary problem for testing unboundedness
Harris pricing with shifting.Class SPxHarrisRT is a stable implementation of a SPxRatioTester class a...
Rational objRational(int i) const
returns objective value of column i
bool getRedCost(VectorBase< R > &vector)
gets the vector of reduced cost values if available; returns true on success
DSVectorRational _tauColVector
LP simplifier for removing uneccessary row/columns.This SPxSimplifier is mainly based on the paper "P...
void _lift()
reduces matrix coefficient in absolute value by the lifting procedure of Thiele et al...
void _changeColReal(int i, const LPColReal &lpcol)
replaces column i with lpcol and adjusts basis
bool _isSolveStopped(bool &stoppedTime, bool &stoppedIter) const
should solving process be stopped?
Settings * _currentSettings
void printUserSettings()
print non-default parameter values