29 #ifndef DOXYGEN_SHOULD_SKIP_THIS 48 Edge edge(first, second);
101 for (
auto iter = nei.beginSafe(); iter != nei.endSafe();
123 if (elt.second.contains(
id))
return elt.first;
125 GUM_ERROR(NotFound,
"This node belongs to no clique");
132 __separators[Edge(nei, id1)] = __cliques[id1] * __cliques[nei];
140 __cliques[id] = new_clique;
153 const NodeId node2)
const {
182 return (!
operator==(from));
bool operator!=(const CliqueGraph &from) const
checks whether two clique graphs are different
virtual void clear()
removes all the nodes and edges from the graph
virtual void addNodeWithId(const NodeId id)
try to insert a node with the given id
bool isJoinTree() const
indicates whether the graph is a join tree
virtual void eraseNode(const NodeId node)
removes a given clique from the clique graph
const NodeSet & separator(const Edge &edge) const
returns the separator included in a given edge
Set< NodeId > NodeSet
Some typdefs and define for shortcuts ...
virtual void setClique(const NodeId idClique, const NodeSet &new_clique)
changes the set of nodes included into a given clique and returns the new set
virtual void addEdge(const NodeId first, const NodeId second)
insert a new edge into the undirected graph
virtual void clear()
removes all the cliques and separators from the graph (as well as their adjacent edges) ...
bool exists(const NodeId id) const
alias for existsNode
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
virtual NodeId addNode()
insert a new node and return its id
const NodeSet & neighbours(const NodeId id) const
returns the set of edges adjacent to a given node
virtual void eraseNode(const NodeId id)
remove a node and its adjacent edges from the graph
virtual void clearEdges()
removes all the edges from the EdgeGraphPart
NodeProperty< NodeSet > __cliques
the set of nodes contained into the cliques
void __updateSeparators(const NodeId clique1)
function used to update the separators when a clique is modified
bool existsEdge(const Edge &edge) const
indicates whether a given edge exists
virtual void eraseEdge(const Edge &edge)
removes an edge (and its separator) from the clique graph
virtual void addEdge(const NodeId first, const NodeId second)
inserts a new edge between two cliques
const NodeSet & clique(const NodeId idClique) const
returns the set of nodes included into a given clique
NodeId container(const NodeId idNode) const
returns the id of a clique containing the node the id of which is in argument
EdgeProperty< NodeSet > __separators
the set of nodes contained into the separators
bool hasUndirectedCycle() const
checks whether the graph contains cycles
CliqueGraph & operator=(const CliqueGraph &from)
copy operator
virtual NodeId addNode()
adds a new clique to the graph
UndiGraph & operator=(const UndiGraph &g)
copy operator
CliqueGraph(Size nodes_size=HashTableConst::default_size, bool nodes_resize_policy=true, Size edges_size=HashTableConst::default_size, bool edges_resize_policy=true)
basic constructor: creates an empty clique graph
virtual void eraseEdge(const Edge &edge)
removes an edge from the EdgeGraphPart
virtual void clearEdges()
removes all edges and their separators
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
Size NodeId
Type for node ids.
bool hasRunningIntersection() const
indicates whether the running intersection property holds
#define GUM_ERROR(type, msg)