SSJ
V. labo.

umontreal.iro.lecuyer.markovchain
Class MarkovChainComparable

java.lang.Object
  extended by umontreal.iro.lecuyer.markovchain.MarkovChain
      extended by umontreal.iro.lecuyer.markovchain.MarkovChainComparable
All Implemented Interfaces:
Cloneable, MultiDimComparable<MarkovChainComparable>
Direct Known Subclasses:
MarkovChainComparableStop, MarkovChainDouble

public abstract class MarkovChainComparable
extends MarkovChain
implements MultiDimComparable<MarkovChainComparable>

A subclass of Markov chain for which there is a total ordering between the states in each dimension induced by the implementation of the MultiDimComparable interface in package umontreal.iro.lecuyer.util. A list or array of Markov chains can then be sorted according to their states at a given step, using a MultiDimComparator and an external sorting method.

The method compareTo(MarkovChainComparable m, int i) must return a negative integer, zero, or a positive integer as the implicit Markov chain is considered smaller than, equal to, or greater than m in dimension i. The meaning of smaller, equal or larger is very flexible as well as the meaning of dimension.

Concrete subclasses must implement compareTo and must initialize variable stateDim in the constructor to the value of the state dimension. It can be understood as the largest integer j for which the method compareTo(m,j) can be called. They must also implement abstract methods of MarkovChain.


Constructor Summary
MarkovChainComparable()
           
 
Method Summary
 int dimension()
          Returns the dimension of the state.
 
Methods inherited from class umontreal.iro.lecuyer.markovchain.MarkovChain
clone, formatResults, formatResultsRQMC, getPerformance, hasStopped, initialState, nextStep, simulRQMC, simulRQMC, simulRQMCFormat, simulRuns, simulRunsFormat, simulRunsWithSubstreams, simulRunsWithSubstreamsFormat, simulSteps, simulSteps, testImprovementRQMC
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface umontreal.iro.lecuyer.util.MultiDimComparable
compareTo
 

Constructor Detail

MarkovChainComparable

public MarkovChainComparable()
Method Detail

dimension

public int dimension()
Returns the dimension of the state.

Specified by:
dimension in interface MultiDimComparable<MarkovChainComparable>

SSJ
V. labo.

To submit a bug or ask questions, send an e-mail to Pierre L'Ecuyer.