39# ifndef TPL_TEST_CYCLE_H
40# define TPL_TEST_CYCLE_H
106template <
class GT,
class SA = Dft_Show_Arc<GT>>
129 typename GT::Arc * arc = it.get_current_arc_ne();
151 <<
"Test_For_Cycle: source node cannot be null";
162 typename GT::Arc * arc = it.get_current_arc_ne();
Exception handling system with formatted messages for Aleph-w.
#define ah_invalid_argument_if(C)
Throws std::invalid_argument if condition holds.
void next_ne() noexcept
Advances the iterator to the next filtered element (noexcept version).
Test whether a cycle is reachable from a given node.
bool test_cycle(typename GT::Node *curr) const
bool test_cycle(const GT &g, typename GT::Node *s) const
Test_For_Cycle(SA arc_filter=SA())
Construct a cycle tester with optional arc filter.
bool operator()(const GT &g, typename GT::Node *src_node) const
Test whether a cycle is reachable from the given source node.
void reset_bit_nodes(int bit) const noexcept
Reset bit to zero for all the nodes of graph.
void reset_bit_arcs(int bit) const noexcept
Reset bit to zero for all the arcs of graph.
#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.
Generic graph and digraph implementations.