class CBNSClique : public CBNSCliqueBase

This class is derived from CBNSCliqueBase class

Inheritance:


Public Fields

static int m_nCounter
This variable is used to check for the memory leaks in the program

Public Methods

void CreatePotential ()
Creates the Potential Table for the Clique
void PrintProbability ()
Prints the functional form of the Joint Probability, for eg
void UpdatePriorProbability ()
Updates the Prior Probability or the Potential Table

Public

Constructor and Destructor
CBNSClique ()
Default Constructor
virtual ~CBNSClique ()
Destructor
Out Functions
int GetRank ()
Returns the rank of the Clique
double GetValue (vector& vStateIndex, CBNSNode* pNode)
Given the states of the nodes, this function returns the conditional probability of the node given the states of the parents
CBNSClique* GetParentClique ()
Returns the Pointer to the Parent Clique
CBNSSeparator* GetParentSeparator ()
Returns the Pointer to the Parent Separator
CBNSNode* GetNode ()
Returns the Pointer to the Node removal of which created this clique in the minimum degree algorithm
CBNSSet <CBNSNode *> GetProbNodes ()
Returns the set of probability nodes assigned to this clique
In Functions
void SetNode (CBNSNode *pNode)
Assigns m_pNode to pNode
void SetParentClique (CBNSClique *pParentClique)
Sets the Parent Clique to pParentClique
void SetParentSeparator (CBNSSeparator *pParentSeparator)
Sets the Parent Separator to pParentSeparator
void SetResidualNodes (CBNSSet<CBNSNode *> residualNodeSet)
Sets the Residual Nodes for the Clique
Update Functions
void AddProbNode (CBNSNode *pNode)
Adds a Probability Node to the Clique
void AddChild (CBNSClique *pChildClique)
Adds a Child Clique to the Clique
void AddChildSeparator (CBNSSeparator *pChildSeparator)
Adds a Child Separator to the Clique
Message Propagation
void DistributeEvidence ()
Distributes the Evidence to the Child Cliques
void CollectEvidence ()
Collects the Evidence from the Child Cliques
void GetPiMessage ()
Gets the Pi Message from the Parent Clique
void GetLambdaMessage (CBNSSeparator *pSeparator)
Gets the Lambda Message from the Child Clique
Friend Functions
friend ostream& operator << (ostream &o, CBNSClique& cClique)
Stream insertion operator
friend void PrintCliqueSet (CBNSSet<CBNSClique *> CliqueSet)
Prints the Contents in the CliqueSet
friend bool sort_clique (CBNSClique *pClique1, CBNSClique *pClique2)
This function returns true if the rank of pClique1 is is less than rank of pClique2, and is used to sort the CBNSSet of Cliques

Private

Private Member Variables
int m_nRank
Rank of the Clique
CBNSNode* m_pNode
Node used to obtain this Clique
CBNSClique* m_pParentClique
Pointer to the Parent Clique
CBNSSeparator* m_pParentSeparator
Pointer to the Parent Separator
CBNSSet <CBNSNode *> m_cProbNodes
Set of Probability Nodes assigned to this Clique
CBNSSet <CBNSClique *> m_cChildren
Set of Child Cliques to this Clique
CBNSSet <CBNSSeparator *> m_cChildSeparators
Set of Child Separators assigned to this Clique

Inherited from CBNSCliqueBase:

Public

Constructor and Destrutor

CBNSCliqueBase()
Default Constructor
virtual ~CBNSCliqueBase()
Destructor

Computation of Marginal Distributions

CBNSProbVector ComputeMarginal(CBNSSet<CBNSNode*>& cNodeSet)
Computes the Marginal Distribution
CBNSProbVector ComputeBeliefVector(CBNSNode* pNode)
Computes the Belief Vector of pNode and returns the values in a CBNSProbVector

Other Utility Functions

void UpdateClique()
Updates the Clique/Separator
void UpdatePriorProbability()
Updates the prior probability table
void PrintNodeProbabilities()
Prints the node probabilities to the console
void PrintPotentialTable()
Prints the potential table of the Clique/Separator

Protected

Protected Member Variables

CBNSProbVector m_cPotentialTable
Potential Table
CBNSProbVector m_cPriorProbability
Prior Probability
CBNSProbVector m_cUpdateRatio
Update Ratio
CBNSSet <CBNSNode*> m_cNodes
CBNSSet of Pointers to Nodes

Documentation

This class is derived from CBNSCliqueBase class. A Clique comprises of set of nodes and is formed in the process of generating the Junction Tree<\em> for the Network<\em>.
static int m_nCounter
This variable is used to check for the memory leaks in the program

Constructor and Destructor

CBNSClique()
Default Constructor

virtual ~CBNSClique()
Destructor

Out Functions

int GetRank()
Returns the rank of the Clique. NOT IMPLEMENTED
Returns:
int

double GetValue(vector& vStateIndex, CBNSNode* pNode)
Given the states of the nodes, this function returns the conditional probability of the node given the states of the parents
Returns:
double
Parameters:
vStateIndex - is vector containing the states of the nodes in the clique
pNode - is a pointer to the node whose conditional probability for the given states of the nodes is returned

CBNSClique* GetParentClique()
Returns the Pointer to the Parent Clique
Returns:
Pointer to CBNSClique

CBNSSeparator* GetParentSeparator()
Returns the Pointer to the Parent Separator
Returns:
Pointer to CBNSSeparator

CBNSNode* GetNode()
Returns the Pointer to the Node removal of which created this clique in the minimum degree algorithm. Maybe, this function is not required.
Returns:
Pointer to CBNSNode

CBNSSet <CBNSNode *> GetProbNodes()
Returns the set of probability nodes assigned to this clique
Returns:
CBNSSet

In Functions

void SetNode(CBNSNode *pNode)
Assigns m_pNode to pNode
Parameters:
pNode - pointer to CBNSNode that was used to create the clique

void SetParentClique(CBNSClique *pParentClique)
Sets the Parent Clique to pParentClique
Parameters:
pParentClique - Pointer to the parent clique

void SetParentSeparator(CBNSSeparator *pParentSeparator)
Sets the Parent Separator to pParentSeparator
Parameters:
pParentClique - Pointer to the parent Separator

void SetResidualNodes(CBNSSet<CBNSNode *> residualNodeSet)
Sets the Residual Nodes for the Clique
Parameters:
residualNodeSet - set of residual nodes for the Clique

Update Functions

void AddProbNode(CBNSNode *pNode)
Adds a Probability Node to the Clique
Parameters:
pNode - Pointer to CBNSNode

void AddChild(CBNSClique *pChildClique)
Adds a Child Clique to the Clique
Parameters:
pChildClique - Pointer to CBNSClique

void AddChildSeparator(CBNSSeparator *pChildSeparator)
Adds a Child Separator to the Clique
Parameters:
pChildSeparator - Pointer to CBNSSeparator

Message Propagation

void DistributeEvidence()
Distributes the Evidence to the Child Cliques

void CollectEvidence()
Collects the Evidence from the Child Cliques

void GetPiMessage()
Gets the Pi Message from the Parent Clique

void GetLambdaMessage(CBNSSeparator *pSeparator)
Gets the Lambda Message from the Child Clique
Parameters:
Pointer - to the Child Separator associated with this Clique and the Child Clique

void CreatePotential()
Creates the Potential Table for the Clique

void PrintProbability()
Prints the functional form of the Joint Probability, for eg., Psi(A,B,C) = P(A|C)P(B|C)P(C)

void UpdatePriorProbability()
Updates the Prior Probability or the Potential Table

Friend Functions

friend ostream& operator << (ostream &o, CBNSClique& cClique)
Stream insertion operator
Parameters:
o - reference to ostream object
cClique - reference to CBNSClique object

friend void PrintCliqueSet(CBNSSet<CBNSClique *> CliqueSet)
Prints the Contents in the CliqueSet
Parameters:
CliqueSet - a CBNSSet of pointers to CBNSCliques

friend bool sort_clique(CBNSClique *pClique1, CBNSClique *pClique2)
This function returns true if the rank of pClique1 is is less than rank of pClique2, and is used to sort the CBNSSet of Cliques
Parameters:
pClique1 - Pointer to CBNSClique
pClique2 - Pointer to CBNSClique

Private Member Variables

int m_nRank
Rank of the Clique

CBNSNode* m_pNode
Node used to obtain this Clique

CBNSClique* m_pParentClique
Pointer to the Parent Clique

CBNSSeparator* m_pParentSeparator
Pointer to the Parent Separator

CBNSSet <CBNSNode *> m_cProbNodes
Set of Probability Nodes assigned to this Clique

CBNSSet <CBNSClique *> m_cChildren
Set of Child Cliques to this Clique

CBNSSet <CBNSSeparator *> m_cChildSeparators
Set of Child Separators assigned to this Clique


This class has no child classes.

alphabetic index hierarchy of classes


this page has been generated automatically by doc++

(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de