19 #ifndef _SLUFACTOR_RATIONAL_H_ 20 #define _SLUFACTOR_RATIONAL_H_ 34 #define MAXUPDATES 1000 133 lastThreshold = 0.01;
138 lastThreshold = 0.99;
247 return solveTime->
time();
303 #endif // _SLUFACTOR_RATIONAL_H_ void resetSolveTime()
reset SolveTime
Implementation of Sparse Linear Solver with Rational precision.This class implements a SLinSolverRati...
int firstUnused
number of first unused L vector
Implementation of sparse LU factorization with Rational precision.
void changeEta(int idx, SSVectorRational &eta)
int thedim
dimension of factorized matrix
Rational stability() const
int getFactorCount() const
number of factorizations performed
UpdateType utype() const
returns the current update type uptype.
int getSolveCount() const
number of solves performed
SLUFactorRational()
default constructor.
Real timeLimit
Time limit on factorization or solves.
Wrapper for GMP type mpq_class.We wrap mpq_class so that we can replace it by a double type if GMP is...
Sparse Linear Solver virtual base class with Rational precision.
SSVectorRational ssvec
Temporary semi-sparse vector.
UpdateType uptype
the current UpdateType.
void setMarkowitz(const Rational &m)
sets minimum Markowitz threshold.
void assign(const SLUFactorRational &old)
used to implement the assignment operator
Sparse Linear Solver virtual base class with Rational precision.Class SLinSolverRational provides a c...
Rational minStability
minimum stability to achieve by setting threshold.
SLinSolverRational::Status Status
for convenience
Rational minThreshold
minimum threshold to use.
Real getSolveTime() const
time spent in solves
virtual SLinSolverRational * clone() const
clone function for polymorphism
void setTimeLimit(const Real limit)
set time limit on factorization
void setUtype(UpdateType tp)
sets update type.
Rational lastThreshold
pivoting threshold of last factorization
void solveRight(VectorRational &x, const VectorRational &b)
Solves .
void solveRight4update(SSVectorRational &x, const SVectorRational &b)
Solves .
int solveCount
Number of solves.
SSVectorRational forest
? Update vector set up by solveRight4update() and solve2right4update()
virtual Real time() const =0
Timer * factorTime
Time spent in factorizations.
Status load(const SVectorRational *vec[], int dim)
bool isConsistent() const
consistency check.
const char * getName() const
virtual ~SLUFactorRational()
destructor.
bool usetup
TRUE iff update vector has been setup.
Debugging, floating point type and parameter definitions.
void dump() const
prints the LU factorization to stdout.
Real getFactorTime() const
time spent in factorizations
Status change(int idx, const SVectorRational &subst, const SSVectorRational *eta=0)
Implementation of sparse LU factorization with Rational precision.This class implements a sparse LU f...
Everything should be within this namespace.
Timer * solveTime
Time spent in solves.
std::string statistics() const
int * start
starting positions in val and idx
UpdateType
Specifies how to perform change method.
int factorCount
Number of factorizations.
void solve3right4update(SSVectorRational &x, VectorRational &y, VectorRational &z, const SVectorRational &b, SSVectorRational &d, SSVectorRational &e)
Solves , and .
SLUFactorRational & operator=(const SLUFactorRational &old)
assignment operator.
void resetFactorTime()
reset FactorTime
virtual void reset()=0
initialize timer, set timing accounts to zero.
Rational markowitz()
returns Markowitz threshold.
void solveLeft(VectorRational &x, const VectorRational &b)
Solves .
Status
status flags of the SLinSolverRational class.
void resetCounters()
reset timers and counters
Wrapper for the system time query methods.
int nzCnt
number of nonzeros in U
void solve2right4update(SSVectorRational &x, VectorRational &y, const SVectorRational &b, SSVectorRational &d)
Solves and .
DVectorRational vec
Temporary vector.
SLinSolverRational::Status stat
Status indicator.