ve
Class FactorStoreSequential
java.lang.Object
|
+--ve.FactorStore
|
+--ve.FactorStoreSequential
- public class FactorStoreSequential
- extends FactorStore
a place to store factors during computation using a given
elimination ordering
Constructor Summary |
FactorStoreSequential(Variable[] toSumOut,
Factor[] initialFactors,
int numInitFactors)
generate a factor store containing the given initial factors and initial variables. |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
theVariables
private Variable[] theVariables
varPos
private int varPos
factorMaxSize
private int factorMaxSize
last
private Variable last
buckets
private Factor[][] buckets
bucketSize
private int[] bucketSize
varToBucketIndex
private java.util.Hashtable varToBucketIndex
finalFactors
private Factor[] finalFactors
numFinalFactors
private int numFinalFactors
FactorStoreSequential
public FactorStoreSequential(Variable[] toSumOut,
Factor[] initialFactors,
int numInitFactors)
- generate a factor store containing the given initial factors and initial variables.
hasNext
public boolean hasNext()
- Overrides:
hasNext
in class FactorStore
next
public Variable next()
- Overrides:
next
in class FactorStore
addFactor
public void addFactor(Factor newFactor)
- Overrides:
addFactor
in class FactorStore
addtoBuckets
private void addtoBuckets(Factor fac)
- adds a factor to the appropriate bucket
emunFactorsRemoved
public FactorIterator emunFactorsRemoved()
- Returns an iterator over the factors that contain the variable
var.
- Overrides:
emunFactorsRemoved
in class FactorStore
emunFactorsRemaining
public FactorIterator emunFactorsRemaining()
- Returns an iterator over the the remaining factors.
- Overrides:
emunFactorsRemaining
in class FactorStore