public class MtjSolver extends SteadyStateSolver
Modifier and Type | Class and Description |
---|---|
static class |
MtjSolver.EnumPrecond
This is the list of preconditioner offered in MTJ.
|
static class |
MtjSolver.EnumSolver
This is the list of solvers provided by MTJ.
|
Constructor and Description |
---|
MtjSolver(MarkovProcess mp)
Default constructor.
|
MtjSolver(MarkovProcess mp,
MtjSolver.EnumSolver solver)
Construct a solver for the given SimpleMarkovProcess.
|
MtjSolver(MarkovProcess mp,
MtjSolver.EnumSolver solver,
boolean tryOthers)
Construct a solver for the given SimpleMarkovProcess.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
description()
This method return a complete verbal describtion of this element.
|
MtjSolver.EnumSolver |
getCurrentIterSolver() |
MtjSolver.EnumPrecond |
getCurrentPreConditioner() |
no.uib.cipr.matrix.Matrix |
getGenerator()
Returns the Generator matrix.
|
no.uib.cipr.matrix.Matrix |
getGenMatrix() |
no.uib.cipr.matrix.sparse.IterativeSolver |
getIteartiveSolver(no.uib.cipr.matrix.Vector pi) |
no.uib.cipr.matrix.sparse.IterativeSolver |
getIterativeSolver(no.uib.cipr.matrix.Vector pi0,
MtjSolver.EnumSolver solver) |
long |
getProcessTime() |
double[] |
getSteadyState()
This process should be extended in order to compute the steady State
probabilities of the MarkovChain.
|
boolean |
isTryOthers() |
java.lang.String |
label()
The name of this solver.
|
void |
setCurrentIterSolver(MtjSolver.EnumSolver iterSolver)
Sets the solver to use.
|
void |
setCurrentPreConditioner(MtjSolver.EnumPrecond preConditioner) |
void |
setIterSolver(MtjSolver.EnumSolver iterSolver,
boolean tryOthers)
Sets the solver to use.
|
void |
setTryOthers(boolean tryOthers)
Sets whether the solver shall try other solvers when it fails.
|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
equals
public MtjSolver(MarkovProcess mp)
mp
- public MtjSolver(MarkovProcess mp, MtjSolver.EnumSolver solver)
mp
- Tha Markov process solvedsolver
- The solver to use.public MtjSolver(MarkovProcess mp, MtjSolver.EnumSolver solver, boolean tryOthers)
mp
- the Markov Process to solve.solver
- the iterative solver form the enumeration IterSolver.tryOthers
- whether a different solver should be tried if the first one
fails.public no.uib.cipr.matrix.Matrix getGenerator()
public double[] getSteadyState() throws NotUnichainException
SteadyStateSolver
getRates(), getGenerator, and getRate(State,State)
getSteadyState
in class SteadyStateSolver
NotUnichainException
MarkovProcess.getGenerator()
,
MarkovProcess.getRates()
,
MarkovProcess.getRate(State, State)
public java.lang.String label()
Solver
label
in interface JMarkovElement
label
in class Solver
Solver.label()
public MtjSolver.EnumSolver getCurrentIterSolver()
public void setIterSolver(MtjSolver.EnumSolver iterSolver, boolean tryOthers)
iterSolver
- The currentIterSolver to set.tryOthers
- whether other solvers should be tryed if this fails.public void setCurrentIterSolver(MtjSolver.EnumSolver iterSolver)
iterSolver
- public MtjSolver.EnumPrecond getCurrentPreConditioner()
public void setCurrentPreConditioner(MtjSolver.EnumPrecond preConditioner)
preConditioner
- The currentPreConditioner to set.public final boolean isTryOthers()
public final void setTryOthers(boolean tryOthers)
tryOthers
- true if the solver shall try other solvers when it fails.public final no.uib.cipr.matrix.Matrix getGenMatrix()
public final long getProcessTime()
public no.uib.cipr.matrix.sparse.IterativeSolver getIteartiveSolver(no.uib.cipr.matrix.Vector pi)
pi
- The probability vector.public no.uib.cipr.matrix.sparse.IterativeSolver getIterativeSolver(no.uib.cipr.matrix.Vector pi0, MtjSolver.EnumSolver solver)
pi0
- Initial guess value.solver
- The solver used.public java.lang.String description()
JMarkovElement
JMarkovElement.label()