set

inline void libsemigroups::Forest::set(node_type node, node_type parent, label_type gen)

Set the parent and edge label for a node.

Complexity

Constant

Parameters
  • node – the node whose parent and label to set.

  • parent – the parent node

  • gen – the label of the edge from parent to node.

Throws

LibsemigroupsException – if node or parent exceeds nr_nodes().

Returns

(None)