edu.ucla.belief
Class TableShell

Object
  extended by TableShell
All Implemented Interfaces:
CPTShell, Potential, Cloneable

public class TableShell
extends Object
implements CPTShell

Since:
100702
Author:
Keith Cascio

Field Summary
static boolean FLAG_DEBUG_INSERT_STATE
           
 
Constructor Summary
TableShell(Table t)
           
 
Method Summary
 Object clone()
           
 void ensureNonsingular()
           
 void expand(FiniteVariable var)
           
 void forget(Variable from)
           
 double getCP(int index)
           
 double getCP(int[] indices)
           
 double getCP(Map instantiations)
           
 double getCP(Object[] instantiations)
           
 double getCP(Object[] parentInstantiations, Object childInstatiation)
           
 double getCPScaled(int ind)
           
 double getCPScaled(int[] indices)
           
 Table getCPT()
           
 CPTParameter getCPTParameter(int index)
           
 CPTParameter getCPTParameter(int[] mindex)
           
 CPTParameter[] getCPTParameters()
           
 Set getRelevant(int[] indices)
           
 Set getRelevant(Map instantiations)
           
 Set getRelevant(Object[] instantiations)
           
 Set getRelevant(Object[] parentInstantiations, Object childInstatiation)
           
 FiniteVariable getVariable()
           
 TableIndex index()
           
 void insertState(int index)
           
 void multiplyInto(Table t2)
           
 void normalize()
           
 void parentStateInserted(FiniteVariable parent, int indexNewInstance)
           
 void parentStateRemoved(FiniteVariable parent, int indexRemovedInstance)
           
 int randomJointValueIndex(Map mapInstantions)
           
 void removeState(int index)
           
 void replaceVariables(Map old2new, boolean partial)
           
 double scalar()
           
 void setValues(double[] valuesToSet)
           
 ArrayList valueElimination()
           
 List variables()
           
 
Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FLAG_DEBUG_INSERT_STATE

public static boolean FLAG_DEBUG_INSERT_STATE
Constructor Detail

TableShell

public TableShell(Table t)
Method Detail

setValues

public void setValues(double[] valuesToSet)
Since:
050904

clone

public Object clone()
Specified by:
clone in interface Potential
Overrides:
clone in class Object

randomJointValueIndex

public int randomJointValueIndex(Map mapInstantions)
Specified by:
randomJointValueIndex in interface CPTShell
Since:
021704

getVariable

public FiniteVariable getVariable()
Specified by:
getVariable in interface CPTShell

variables

public List variables()
Specified by:
variables in interface CPTShell
Specified by:
variables in interface Potential

replaceVariables

public void replaceVariables(Map old2new,
                             boolean partial)
Specified by:
replaceVariables in interface CPTShell
partial - If true, then skip warnings about incomplete mapping.
Since:
20080220

forget

public void forget(Variable from)
Specified by:
forget in interface CPTShell

expand

public void expand(FiniteVariable var)
Specified by:
expand in interface CPTShell

multiplyInto

public void multiplyInto(Table t2)
Specified by:
multiplyInto in interface CPTShell

ensureNonsingular

public void ensureNonsingular()
Specified by:
ensureNonsingular in interface CPTShell

normalize

public void normalize()
               throws Exception
Specified by:
normalize in interface CPTShell
Throws:
Exception

insertState

public void insertState(int index)
Specified by:
insertState in interface CPTShell
Since:
101502

removeState

public void removeState(int index)
Specified by:
removeState in interface CPTShell
Since:
101502

parentStateInserted

public void parentStateInserted(FiniteVariable parent,
                                int indexNewInstance)
Specified by:
parentStateInserted in interface CPTShell
Since:
101502

parentStateRemoved

public void parentStateRemoved(FiniteVariable parent,
                               int indexRemovedInstance)
Specified by:
parentStateRemoved in interface CPTShell
Since:
101502

index

public TableIndex index()
Specified by:
index in interface CPTShell

getCPT

public Table getCPT()
Specified by:
getCPT in interface CPTShell

scalar

public double scalar()
Specified by:
scalar in interface CPTShell
Since:
041403

getCPScaled

public double getCPScaled(int ind)
Specified by:
getCPScaled in interface CPTShell

getCPScaled

public double getCPScaled(int[] indices)
Specified by:
getCPScaled in interface CPTShell

getCP

public double getCP(int index)
Specified by:
getCP in interface CPTShell

getCP

public double getCP(int[] indices)
Specified by:
getCP in interface CPTShell

getCP

public double getCP(Object[] instantiations)
Specified by:
getCP in interface CPTShell

getCP

public double getCP(Map instantiations)
Specified by:
getCP in interface CPTShell

getCP

public double getCP(Object[] parentInstantiations,
                    Object childInstatiation)
Specified by:
getCP in interface CPTShell

getRelevant

public Set getRelevant(int[] indices)
Specified by:
getRelevant in interface CPTShell

getRelevant

public Set getRelevant(Object[] instantiations)
Specified by:
getRelevant in interface CPTShell

getRelevant

public Set getRelevant(Map instantiations)
Specified by:
getRelevant in interface CPTShell

getRelevant

public Set getRelevant(Object[] parentInstantiations,
                       Object childInstatiation)
Specified by:
getRelevant in interface CPTShell

valueElimination

public ArrayList valueElimination()

getCPTParameters

public CPTParameter[] getCPTParameters()
Specified by:
getCPTParameters in interface CPTShell

getCPTParameter

public CPTParameter getCPTParameter(int index)
Specified by:
getCPTParameter in interface CPTShell

getCPTParameter

public CPTParameter getCPTParameter(int[] mindex)
Specified by:
getCPTParameter in interface CPTShell


Copyright 2010 UCLA Automated Reasoning Group