39# ifndef TPL_TEST_ACYCLIQUE_H
40# define TPL_TEST_ACYCLIQUE_H
65 template <
class GT,
class SA = Dft_Show_Arc<GT>>
79 typename GT::Arc *arc = i.get_current_arc_ne();
97 <<
"is_graph_acyclique() does not work for digraphs";
105 for (
typename GT::Node_Iterator it(g); it.has_curr(); it.next_ne())
107 typename GT::Node *curr = it.get_current_node_ne();
189 template <
class GT,
class SA = Dft_Show_Arc<GT>>
Exception handling system with formatted messages for Aleph-w.
#define ah_domain_error_if(C)
Throws std::domain_error if condition holds.
void next_ne() noexcept
Advances the iterator to the next filtered element (noexcept version).
Determines whether a graph contains cycles.
Has_Cycle(SA &&__sa=SA())
bool operator()(GT &g) const
Invokes the cycle-existence test.
Determines whether a graph is acyclic (contains no cycles).
bool is_acyclique(typename GT::Node *curr)
Is_Graph_Acyclique(SA &&__sa=SA())
Is_Graph_Acyclique(SA &__sa)
bool is_acyclique(GT &g, size_t num_arcs)
bool operator()(GT &g, size_t num_arcs)
Invokes the acyclicity test.
void reset_bit_nodes(int bit) const noexcept
Reset bit to zero for all the nodes of graph.
constexpr size_t get_num_nodes() const noexcept
Return the total of nodes of graph.
bool is_digraph() const noexcept
Return true if the graph this is directed.
void reset_bit_arcs(int bit) const noexcept
Reset bit to zero for all the arcs of graph.
constexpr size_t get_num_arcs() const noexcept
#define IS_NODE_VISITED(p, bit)
Determine whether the control bit is set or not to one.
#define ARC_BITS(p)
Return the control bits of arc p.
#define IS_ARC_VISITED(p, bit)
Determine whether the bit field is or not set to one.
#define NODE_BITS(p)
Get the control bits of a node.
Main namespace for Aleph-w library functions.
DynList< T > maps(const C &c, Op op)
Classic map operation.
Arc of graph implemented with double-linked adjacency lists.
Filtered iterator of adjacent arcs of a node.
Utility algorithms and operations for graphs.