LP scaler abstract base class.Instances of classes derived from SPxScaler may be loaded to SoPlex in order to scale LPs before solving them. SoPlex will load() itself to the SPxScaler and then call scale(). Generally any SPxLP can be loaded to a SPxScaler for scale()ing it. The scaling can be undone by calling unscale(). More...
#include <spxscaler.h>
Public Member Functions | |
virtual int | computeScaleExp (const SVector &vec, const DataArray< int > &oldScaleExp) const |
compute a single scaling vector , e.g. of a newly added row More... | |
virtual int | computeScaleExp (const SVectorBase< Rational > &vec, const DataArray< int > &oldScaleExp) const |
virtual void | applyScaling (SPxLPBase< Real > &lp) |
applies m_colscale and m_rowscale to the lp . More... | |
Construction / destruction | |
SPxScaler (const char *name, bool colFirst=false, bool doBoth=true, SPxOut *spxout=NULL) | |
constructor More... | |
SPxScaler (const SPxScaler &) | |
copy constructor More... | |
SPxScaler & | operator= (const SPxScaler &) |
assignment operator More... | |
virtual | ~SPxScaler () |
destructor. More... | |
virtual SPxScaler * | clone () const =0 |
clone function for polymorphism More... | |
Access / modification | |
virtual const char * | getName () const |
get name of scaler More... | |
virtual void | setOrder (bool colFirst) |
set scaling order More... | |
virtual void | setBoth (bool both) |
set wether column and row scaling should be performed More... | |
virtual void | setOutstream (SPxOut &newOutstream) |
set message handler More... | |
virtual void | setRealParam (Real param, const char *name="realparam") |
set real parameter More... | |
virtual void | setIntParam (int param, const char *name="intparam") |
set int parameter More... | |
Scaling | |
virtual void | scale (SPxLPBase< Real > &lp, bool persistent=true)=0 |
scale SPxLP. More... | |
virtual void | unscale (SPxLPBase< Real > &lp) |
unscale SPxLP More... | |
virtual int | getColScaleExp (int i) const |
returns scaling factor for column i More... | |
virtual int | getRowScaleExp (int i) const |
returns scaling factor for row i More... | |
virtual void | getColUnscaled (const SPxLPBase< Real > &lp, int i, DSVector &vec) const |
gets unscaled column i More... | |
virtual Real | getColMaxAbsUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns maximum absolute value of unscaled column i More... | |
virtual Real | getColMinAbsUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns minumum absolute value of unscaled column i More... | |
virtual Real | upperUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns unscaled upper bound i More... | |
virtual void | getUpperUnscaled (const SPxLPBase< Real > &lp, Vector &vec) const |
returns unscaled upper bound vector of lp More... | |
virtual Real | lowerUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns unscaled lower bound i More... | |
virtual void | getLowerUnscaled (const SPxLPBase< Real > &lp, Vector &vec) const |
gets unscaled lower bound vector More... | |
virtual Real | maxObjUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns unscaled objective function coefficient of i More... | |
virtual void | getMaxObjUnscaled (const SPxLPBase< Real > &lp, Vector &vec) const |
gets unscaled objective function More... | |
virtual void | getRowUnscaled (const SPxLPBase< Real > &lp, int i, DSVector &vec) const |
returns unscaled row i More... | |
virtual Real | getRowMaxAbsUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns maximum absolute value of unscaled row i More... | |
virtual Real | getRowMinAbsUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns minimum absolute value of unscaled row i More... | |
virtual Real | rhsUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns unscaled right hand side i More... | |
virtual void | getRhsUnscaled (const SPxLPBase< Real > &lp, Vector &vec) const |
gets unscaled right hand side vector More... | |
virtual Real | lhsUnscaled (const SPxLPBase< Real > &lp, int i) const |
returns unscaled left hand side i of lp More... | |
virtual void | getLhsUnscaled (const SPxLPBase< Real > &lp, Vector &vec) const |
returns unscaled left hand side vector of lp More... | |
virtual Real | getCoefUnscaled (const SPxLPBase< Real > &lp, int row, int col) const |
returns unscaled coefficient of lp More... | |
virtual void | unscalePrimal (const SPxLPBase< Real > &lp, Vector &x) const |
unscale dense primal solution vector given in x . More... | |
virtual void | unscaleSlacks (const SPxLPBase< Real > &lp, Vector &s) const |
unscale dense slack vector given in s . More... | |
virtual void | unscaleDual (const SPxLPBase< Real > &lp, Vector &pi) const |
unscale dense dual solution vector given in pi . More... | |
virtual void | unscaleRedCost (const SPxLPBase< Real > &lp, Vector &r) const |
unscale dense reduced cost vector given in r . More... | |
virtual void | unscalePrimalray (const SPxLPBase< Real > &lp, Vector &ray) const |
unscale primal ray given in ray . More... | |
virtual void | unscaleDualray (const SPxLPBase< Real > &lp, Vector &ray) const |
unscale dual ray given in ray . More... | |
virtual void | scaleObj (const SPxLPBase< Real > &lp, VectorReal &origObj) const |
apply scaling to objective function vector origObj . More... | |
virtual Real | scaleObj (const SPxLPBase< Real > &lp, int i, Real origObj) const |
returns scaled objective function coefficient origObj . More... | |
virtual Real | scaleElement (const SPxLPBase< Real > &lp, int row, int col, Real val) const |
returns scaled LP element in row and col . More... | |
virtual Real | scaleLower (const SPxLPBase< Real > &lp, int col, Real lower) const |
returns scaled lower bound of column col . More... | |
virtual Real | scaleUpper (const SPxLPBase< Real > &lp, int col, Real upper) const |
returns scaled upper bound of column col . More... | |
virtual Real | scaleLhs (const SPxLPBase< Real > &lp, int row, Real lhs) const |
returns scaled left hand side of row row . More... | |
virtual Real | scaleRhs (const SPxLPBase< Real > &lp, int row, Real rhs) const |
returns scaled right hand side of row row . More... | |
virtual Real | minAbsColscale () const |
absolute smallest column scaling factor More... | |
virtual Real | maxAbsColscale () const |
absolute biggest column scaling factor More... | |
virtual Real | minAbsRowscale () const |
absolute smallest row scaling factor More... | |
virtual Real | maxAbsRowscale () const |
absolute biggest row scaling factor More... | |
virtual Real | maxColRatio (const SPxLPBase< Real > &lp) const |
maximum ratio between absolute biggest and smallest element in any column. More... | |
virtual Real | maxRowRatio (const SPxLPBase< Real > &lp) const |
maximum ratio between absolute biggest and smallest element in any row. More... | |
void | computeExpVec (const std::vector< Real > &vec, DataArray< int > &vecExp) |
round vector entries to power of 2 More... | |
Debugging | |
virtual bool | isConsistent () const |
consistency check More... | |
Protected Member Functions | |
Protected helpers | |
virtual void | setup (SPxLPBase< Real > &lp) |
clear and setup scaling arrays in the LP More... | |
Protected Attributes | |
Data | |
const char * | m_name |
Name of the scaler. More... | |
DataArray< int > * | m_activeColscaleExp |
pointer to currently active column scaling factors More... | |
DataArray< int > * | m_activeRowscaleExp |
pointer to currently active row scaling factors More... | |
bool | m_colFirst |
do column scaling first More... | |
bool | m_doBoth |
do columns and rows More... | |
SPxOut * | spxout |
message handler More... | |
Friends | |
std::ostream & | operator<< (std::ostream &s, const SPxScaler &sc) |
LP scaler abstract base class.
Instances of classes derived from SPxScaler may be loaded to SoPlex in order to scale LPs before solving them. SoPlex will load() itself to the SPxScaler and then call scale(). Generally any SPxLP can be loaded to a SPxScaler for scale()ing it. The scaling can be undone by calling unscale().
Mathematically, the scaling of a constraint matrix A can be written as \( A' = R A C \), with \( R \) and \( C \), being diagonal matrices corresponding to the row and column scale factors, respectively. Besides the constraints matrix, also the upper and lower bounds of both columns and rows need to be scaled.
Note that by default scaling is performed both before and after presolving and the former scaling factors are retained during branch-and-bound (persistent scaling). However, while within SoPlex the scaled problem is used, data accessed through the soplex.cpp interface is provided w.r.t. the original problem (i.e., in unscaled form). For instance, consider a scaled constraints matrix A' that is extended by artificial slack variables to the matrix (A',I). A basis \( B' = [(A',I)P]_{[1:m][1:m] }\) (with P being a permutation matrix) for the scaled problem corresponds to the basis \( B = R^{-1} [(A',I)P]_{[1:m][1:m]} [P^{T} \tilde{C}^{-1} P]_{[1:m][1:m] } \). In this equation, \( \tilde{C} \) is of the form
\[ \begin{array}{cc} C & 0 \\ O & R^{-1} \end{array} \]
Note that in SoPlex only scaling factors \( 2^k, k \in \mathbb{Z} \) are used.
Definition at line 76 of file spxscaler.h.
|
virtual |
applies m_colscale and m_rowscale to the lp
.
Definition at line 177 of file spxscaler.cpp.
References SPxLPBase< R >::colVector_w(), SVectorBase< R >::index(), soplex::infinity, SPxLPBase< R >::isConsistent(), SPxLPBase< R >::lhs(), SPxLPBase< R >::lhs_w(), SPxLPBase< R >::lower(), SPxLPBase< R >::lower_w(), LPColSetBase< R >::LPColSetBase(), LPRowSetBase< R >::LPRowSetBase(), SPxScaler::m_activeColscaleExp, SPxScaler::m_activeRowscaleExp, SPxLPBase< R >::maxObj_w(), SPxLPBase< R >::maxRowObj(), SPxLPBase< R >::maxRowObj_w(), MSG_DEBUG, SPxLPBase< R >::nCols(), SPxLPBase< R >::nRows(), SPxLPBase< R >::rhs(), SPxLPBase< R >::rhs_w(), SPxLPBase< R >::rowVector_w(), SPxLPBase< R >::setScalingInfo(), SVectorBase< R >::size(), DataArray< T >::size(), soplex::spxLdexp(), SPxLPBase< R >::upper(), SPxLPBase< R >::upper_w(), and SVectorBase< R >::value().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), and SPxGeometSC::scale().
|
pure virtual |
clone function for polymorphism
Implemented in SPxGeometSC, SPxEquiliSC, and SPxLeastSqSC.
round vector entries to power of 2
Definition at line 903 of file spxscaler.cpp.
References DataArray< T >::size().
Referenced by SPxGeometSC::scale(), and SPxScaler::setOutstream().
compute a single scaling vector , e.g. of a newly added row
Definition at line 146 of file spxscaler.cpp.
References soplex::GT(), SVectorBase< R >::index(), SVectorBase< R >::size(), soplex::spxAbs(), soplex::spxFrexp(), soplex::spxLdexp(), and SVectorBase< R >::value().
Referenced by SPxLPBase< Real >::doAddCol(), SPxLPBase< Real >::doAddCols(), SPxLPBase< Real >::doAddRow(), and SPxLPBase< Real >::doAddRows().
|
virtual |
Definition at line 171 of file spxscaler.cpp.
returns unscaled coefficient of lp
Definition at line 602 of file spxscaler.cpp.
References SPxLPBase< R >::colVector(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nCols(), SPxLPBase< R >::nRows(), and soplex::spxLdexp().
Referenced by SoPlex::coefReal(), and SPxScaler::setOutstream().
returns maximum absolute value of unscaled column i
Definition at line 331 of file spxscaler.cpp.
References SVectorBase< R >::index(), SPxScaler::m_activeColscaleExp, SPxScaler::m_activeRowscaleExp, SPxLPBase< R >::nCols(), SVectorBase< R >::size(), soplex::spxAbs(), soplex::spxLdexp(), and SVectorBase< R >::value().
Referenced by SPxScaler::setOutstream().
returns minumum absolute value of unscaled column i
returns minimum absolute value of unscaled column i
Definition at line 357 of file spxscaler.cpp.
References SVectorBase< R >::index(), soplex::infinity, SPxScaler::m_activeColscaleExp, SPxScaler::m_activeRowscaleExp, SPxLPBase< R >::nCols(), SVectorBase< R >::size(), soplex::spxAbs(), soplex::spxLdexp(), and SVectorBase< R >::value().
Referenced by SPxScaler::setOutstream().
|
virtual |
returns scaling factor for column i
returns scaling factor for column i
todo pass the LP?!
Definition at line 293 of file spxscaler.cpp.
References SPxScaler::m_activeColscaleExp.
Referenced by SoPlex::getBasisInverseColReal(), SoPlex::getBasisInverseRowReal(), SoPlex::getBasisInverseTimesVecReal(), SoPlex::multBasis(), SoPlex::multBasisTranspose(), and SPxScaler::setOutstream().
gets unscaled column i
Definition at line 306 of file spxscaler.cpp.
References DSVectorBase< R >::add(), SVectorBase< R >::clear(), SPxLPBase< R >::colVector(), SVectorBase< R >::index(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nCols(), DSVectorBase< R >::setMax(), SVectorBase< R >::size(), soplex::spxLdexp(), and SVectorBase< R >::value().
Referenced by SPxScaler::setOutstream().
returns unscaled left hand side vector of lp
Definition at line 590 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
gets unscaled lower bound vector
returns unscaled lower bound vector of lp
Definition at line 431 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
gets unscaled objective function
gets unscaled objective function coefficient of i
Definition at line 456 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
|
virtual |
get name of scaler
Definition at line 105 of file spxscaler.cpp.
References SPxScaler::m_name.
Referenced by SoPlex::getScalerName(), and soplex::operator<<().
gets unscaled right hand side vector
Definition at line 560 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
returns maximum absolute value of unscaled row i
Definition at line 491 of file spxscaler.cpp.
References soplex::GT(), SVectorBase< R >::index(), SPxScaler::m_activeColscaleExp, SPxScaler::m_activeRowscaleExp, SPxLPBase< R >::nRows(), SVectorBase< R >::size(), soplex::spxAbs(), soplex::spxLdexp(), and SVectorBase< R >::value().
Referenced by SPxScaler::setOutstream().
returns minimum absolute value of unscaled row i
Definition at line 517 of file spxscaler.cpp.
References SVectorBase< R >::index(), soplex::infinity, soplex::LT(), SPxScaler::m_activeColscaleExp, SPxScaler::m_activeRowscaleExp, SPxLPBase< R >::nRows(), SVectorBase< R >::size(), soplex::spxAbs(), soplex::spxLdexp(), and SVectorBase< R >::value().
Referenced by SPxScaler::setOutstream().
|
virtual |
returns scaling factor for row i
returns scaling factor for row i
todo pass the LP?!
Definition at line 300 of file spxscaler.cpp.
References SPxScaler::m_activeRowscaleExp.
Referenced by SoPlex::getBasisInverseColReal(), SoPlex::getBasisInverseRowReal(), SoPlex::getBasisInverseTimesVecReal(), SoPlex::multBasis(), SoPlex::multBasisTranspose(), and SPxScaler::setOutstream().
returns unscaled row i
gets unscaled row i
Definition at line 468 of file spxscaler.cpp.
References DSVectorBase< R >::add(), SVectorBase< R >::clear(), SVectorBase< R >::index(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nRows(), SPxLPBase< R >::rowVector(), DSVectorBase< R >::setMax(), SVectorBase< R >::size(), soplex::spxLdexp(), and SVectorBase< R >::value().
Referenced by SoPlex::getRowVectorReal(), and SPxScaler::setOutstream().
returns unscaled upper bound vector of lp
gets unscaled upper bound vector
Definition at line 401 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
|
virtual |
consistency check
Definition at line 914 of file spxscaler.cpp.
References DataArray< T >::isConsistent(), SPxScaler::m_activeColscaleExp, and SPxScaler::m_activeRowscaleExp.
Referenced by SPxScaler::operator=(), SPxScaler::setOutstream(), and SPxScaler::SPxScaler().
returns unscaled left hand side i
of lp
Definition at line 574 of file spxscaler.cpp.
References soplex::infinity, SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nRows(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
returns unscaled lower bound i
returns unscaled upper bound vector of lp
Definition at line 414 of file spxscaler.cpp.
References soplex::infinity, SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), SPxLPBase< R >::nCols(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
|
virtual |
absolute biggest column scaling factor
Definition at line 781 of file spxscaler.cpp.
References SPxScaler::m_activeColscaleExp, DataArray< T >::size(), soplex::spxAbs(), and soplex::spxLdexp().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setOutstream().
|
virtual |
absolute biggest row scaling factor
Definition at line 808 of file spxscaler.cpp.
References SPxScaler::m_activeRowscaleExp, DataArray< T >::size(), and soplex::spxLdexp().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setOutstream().
maximum ratio between absolute biggest and smallest element in any column.
\(\max_{j\in\mbox{ cols}} \left(\frac{\max_{i\in\mbox{ rows}}|a_ij|} {\min_{i\in\mbox{ rows}}|a_ij|}\right)\)
Definition at line 825 of file spxscaler.cpp.
References SPxLPBase< R >::colVector(), soplex::infinity, soplex::isZero(), SPxLPBase< R >::nCols(), SVectorBase< R >::size(), soplex::spxAbs(), and SVectorBase< R >::value().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setOutstream().
returns unscaled objective function coefficient of i
Definition at line 443 of file spxscaler.cpp.
References SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), SPxLPBase< R >::nCols(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
maximum ratio between absolute biggest and smallest element in any row.
\(\max_{i\in\mbox{ rows}} \left(\frac{\max_{j\in\mbox{ cols}}|a_ij|} {\min_{j\in\mbox{ cols}}|a_ij|}\right)\)
Definition at line 866 of file spxscaler.cpp.
References soplex::infinity, soplex::isZero(), SPxLPBase< R >::nRows(), SPxLPBase< R >::rowVector(), SVectorBase< R >::size(), soplex::spxAbs(), and SVectorBase< R >::value().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setOutstream().
|
virtual |
absolute smallest column scaling factor
Definition at line 768 of file spxscaler.cpp.
References soplex::infinity, SPxScaler::m_activeColscaleExp, DataArray< T >::size(), soplex::spxAbs(), and soplex::spxLdexp().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setOutstream().
|
virtual |
absolute smallest row scaling factor
Definition at line 795 of file spxscaler.cpp.
References SPxScaler::m_activeRowscaleExp, DataArray< T >::size(), and soplex::spxLdexp().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setOutstream().
assignment operator
Definition at line 88 of file spxscaler.cpp.
References SPxScaler::isConsistent(), SPxScaler::m_activeColscaleExp, SPxScaler::m_activeRowscaleExp, SPxScaler::m_colFirst, SPxScaler::m_doBoth, SPxScaler::m_name, and SPxScaler::spxout.
Referenced by SPxLeastSqSC::operator=(), SPxEquiliSC::operator=(), and SPxGeometSC::operator=().
returns unscaled right hand side i
Definition at line 543 of file spxscaler.cpp.
References soplex::infinity, SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nRows(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
scale SPxLP.
Implemented in SPxGeometSC, and SPxEquiliSC.
Referenced by SoPlex::_decompSimplifyAndSolve(), SoPlex::_optimizeReal(), SoPlex::_preprocessAndSolveReal(), SoPlex::_solveRealForRational(), and SPxScaler::setOutstream().
returns scaled LP element in row
and col
.
Definition at line 710 of file spxscaler.cpp.
References SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nCols(), SPxLPBase< R >::nRows(), and soplex::spxLdexp().
Referenced by SPxLPBase< Real >::changeElement(), and SPxScaler::setOutstream().
returns scaled left hand side of row row
.
Definition at line 746 of file spxscaler.cpp.
References SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nRows(), and soplex::spxLdexp().
Referenced by SPxLPBase< Real >::changeLhs(), and SPxScaler::setOutstream().
returns scaled lower bound of column col
.
Definition at line 724 of file spxscaler.cpp.
References SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), SPxLPBase< R >::nCols(), and soplex::spxLdexp().
Referenced by SPxLPBase< Real >::changeLower(), and SPxScaler::setOutstream().
|
virtual |
apply scaling to objective function vector origObj
.
Definition at line 686 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), and soplex::spxLdexp().
Referenced by SPxLPBase< Real >::changeMaxObj(), and SPxScaler::setOutstream().
returns scaled objective function coefficient origObj
.
Definition at line 698 of file spxscaler.cpp.
References SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), SPxLPBase< R >::nCols(), and soplex::spxLdexp().
returns scaled right hand side of row row
.
Definition at line 757 of file spxscaler.cpp.
References SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::nRows(), and soplex::spxLdexp().
Referenced by SPxLPBase< Real >::changeRhs(), and SPxScaler::setOutstream().
returns scaled upper bound of column col
.
Definition at line 735 of file spxscaler.cpp.
References SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), SPxLPBase< R >::nCols(), and soplex::spxLdexp().
Referenced by SPxLPBase< Real >::changeUpper(), and SPxScaler::setOutstream().
|
virtual |
set wether column and row scaling should be performed
Definition at line 117 of file spxscaler.cpp.
References SPxScaler::m_doBoth.
|
virtual |
set int parameter
Reimplemented in SPxLeastSqSC.
Definition at line 126 of file spxscaler.cpp.
Referenced by SoPlex::setIntParam(), and SPxScaler::setOutstream().
|
virtual |
|
virtual |
set message handler
Definition at line 138 of file spxscaler.h.
References SPxScaler::computeExpVec(), SPxScaler::getCoefUnscaled(), SPxScaler::getColMaxAbsUnscaled(), SPxScaler::getColMinAbsUnscaled(), SPxScaler::getColScaleExp(), SPxScaler::getColUnscaled(), SPxScaler::getLhsUnscaled(), SPxScaler::getLowerUnscaled(), SPxScaler::getMaxObjUnscaled(), SPxScaler::getRhsUnscaled(), SPxScaler::getRowMaxAbsUnscaled(), SPxScaler::getRowMinAbsUnscaled(), SPxScaler::getRowScaleExp(), SPxScaler::getRowUnscaled(), SPxScaler::getUpperUnscaled(), SPxScaler::isConsistent(), SPxScaler::lhsUnscaled(), SPxScaler::lowerUnscaled(), SPxScaler::maxAbsColscale(), SPxScaler::maxAbsRowscale(), SPxScaler::maxColRatio(), SPxScaler::maxObjUnscaled(), SPxScaler::maxRowRatio(), SPxScaler::minAbsColscale(), SPxScaler::minAbsRowscale(), SPxScaler::rhsUnscaled(), SPxScaler::scale(), SPxScaler::scaleElement(), SPxScaler::scaleLhs(), SPxScaler::scaleLower(), SPxScaler::scaleObj(), SPxScaler::scaleRhs(), SPxScaler::scaleUpper(), SPxScaler::setIntParam(), SPxScaler::setRealParam(), SPxScaler::unscale(), SPxScaler::unscaleDual(), SPxScaler::unscaleDualray(), SPxScaler::unscalePrimal(), SPxScaler::unscalePrimalray(), SPxScaler::unscaleRedCost(), SPxScaler::unscaleSlacks(), and SPxScaler::upperUnscaled().
Referenced by SoPlex::operator=(), and SoPlex::SoPlex().
|
virtual |
set real parameter
Reimplemented in SPxLeastSqSC.
Definition at line 123 of file spxscaler.cpp.
Referenced by SPxScaler::setOutstream(), and SoPlex::setRealParam().
clear and setup scaling arrays in the LP
Definition at line 129 of file spxscaler.cpp.
References SPxLPBase< R >::isConsistent(), SPxLPBase< R >::lp_scaler, LPColSetBase< R >::LPColSetBase(), LPRowSetBase< R >::LPRowSetBase(), SPxScaler::m_activeColscaleExp, SPxScaler::m_activeRowscaleExp, SPxLPBase< R >::nCols(), SPxLPBase< R >::nRows(), and DataArray< T >::reSize().
Referenced by SPxLeastSqSC::scale(), SPxEquiliSC::scale(), and SPxGeometSC::scale().
unscale SPxLP
Definition at line 236 of file spxscaler.cpp.
References SPxLPBase< R >::_isScaled, SPxLPBase< R >::colVector_w(), SVectorBase< R >::index(), soplex::infinity, SPxLPBase< R >::isConsistent(), SPxLPBase< R >::isScaled(), SPxLPBase< R >::lhs(), SPxLPBase< R >::lhs_w(), SPxLPBase< R >::lower(), SPxLPBase< R >::lower_w(), LPColSetBase< R >::LPColSetBase(), LPRowSetBase< R >::LPRowSetBase(), SPxLPBase< R >::maxObj_w(), SPxLPBase< R >::maxRowObj(), SPxLPBase< R >::maxRowObj_w(), SPxLPBase< R >::nCols(), SPxLPBase< R >::nRows(), SPxLPBase< R >::rhs(), SPxLPBase< R >::rhs_w(), SPxLPBase< R >::rowVector_w(), SVectorBase< R >::size(), soplex::spxLdexp(), SPxLPBase< R >::upper(), SPxLPBase< R >::upper_w(), and SVectorBase< R >::value().
Referenced by SPxScaler::setOutstream().
unscale dense dual solution vector given in pi
.
Definition at line 638 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), and soplex::spxLdexp().
Referenced by SoPlex::_decompResolveWithoutPreprocessing(), SoPlex::_resolveWithoutPreprocessing(), SoPlex::_solveRealForRational(), SoPlex::_unscaleSolutionReal(), and SPxScaler::setOutstream().
unscale dual ray given in ray
.
Definition at line 674 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), and soplex::spxLdexp().
Referenced by SoPlex::_unscaleSolutionReal(), and SPxScaler::setOutstream().
unscale dense primal solution vector given in x
.
Definition at line 614 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), and soplex::spxLdexp().
Referenced by SoPlex::_decompResolveWithoutPreprocessing(), SoPlex::_resolveWithoutPreprocessing(), SoPlex::_solveRealForRational(), SoPlex::_unscaleSolutionReal(), and SPxScaler::setOutstream().
unscale primal ray given in ray
.
Definition at line 662 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), and soplex::spxLdexp().
Referenced by SoPlex::_unscaleSolutionReal(), and SPxScaler::setOutstream().
unscale dense reduced cost vector given in r
.
Definition at line 650 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), and soplex::spxLdexp().
Referenced by SoPlex::_decompResolveWithoutPreprocessing(), SoPlex::_resolveWithoutPreprocessing(), SoPlex::_solveRealForRational(), SoPlex::_unscaleSolutionReal(), and SPxScaler::setOutstream().
unscale dense slack vector given in s
.
Definition at line 626 of file spxscaler.cpp.
References VectorBase< R >::dim(), SPxLPBase< R >::isScaled(), LPRowSetBase< R >::LPRowSetBase(), and soplex::spxLdexp().
Referenced by SoPlex::_decompResolveWithoutPreprocessing(), SoPlex::_resolveWithoutPreprocessing(), SoPlex::_solveRealForRational(), SoPlex::_unscaleSolutionReal(), and SPxScaler::setOutstream().
returns unscaled upper bound i
Definition at line 384 of file spxscaler.cpp.
References soplex::infinity, SPxLPBase< R >::isScaled(), LPColSetBase< R >::LPColSetBase(), SPxLPBase< R >::nCols(), and soplex::spxLdexp().
Referenced by SPxScaler::setOutstream().
|
friend |
Definition at line 33 of file spxscaler.cpp.
|
protected |
pointer to currently active column scaling factors
Definition at line 84 of file spxscaler.h.
Referenced by SPxScaler::applyScaling(), SPxScaler::getColMaxAbsUnscaled(), SPxScaler::getColMinAbsUnscaled(), SPxScaler::getColScaleExp(), SPxScaler::getRowMaxAbsUnscaled(), SPxScaler::getRowMinAbsUnscaled(), SPxScaler::isConsistent(), SPxScaler::maxAbsColscale(), SPxScaler::minAbsColscale(), soplex::operator<<(), SPxScaler::operator=(), SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setup().
|
protected |
pointer to currently active row scaling factors
Definition at line 85 of file spxscaler.h.
Referenced by SPxScaler::applyScaling(), SPxScaler::getColMaxAbsUnscaled(), SPxScaler::getColMinAbsUnscaled(), SPxScaler::getRowMaxAbsUnscaled(), SPxScaler::getRowMinAbsUnscaled(), SPxScaler::getRowScaleExp(), SPxScaler::isConsistent(), SPxScaler::maxAbsRowscale(), SPxScaler::minAbsRowscale(), soplex::operator<<(), SPxScaler::operator=(), SPxLeastSqSC::scale(), SPxEquiliSC::scale(), SPxGeometSC::scale(), and SPxScaler::setup().
|
protected |
do column scaling first
Definition at line 86 of file spxscaler.h.
Referenced by SPxScaler::operator=(), and SPxScaler::setOrder().
|
protected |
do columns and rows
Definition at line 87 of file spxscaler.h.
Referenced by SPxScaler::operator=(), SPxEquiliSC::scale(), and SPxScaler::setBoth().
|
protected |
Name of the scaler.
Definition at line 83 of file spxscaler.h.
Referenced by SPxScaler::getName(), SPxScaler::operator=(), and SPxScaler::~SPxScaler().
|
protected |
message handler
Definition at line 88 of file spxscaler.h.
Referenced by SPxScaler::operator=(), SPxLeastSqSC::scale(), SPxEquiliSC::scale(), and SPxGeometSC::scale().