33 if (n2->isleaf() || n1 == n2)
36 if (n1 != n2->left &&
EqualTrees(n1, n2->left)) {
40 if (n1 != n2->right &&
EqualTrees(n1, n2->right)) {
A BinaryDrag is the GRAPHGEN implementation of a Binary Directed Rooted Acyclic Graph (DRAG in short)
node * GetRoot() const
Returns the last root of the BinaryDrag.
bool EqualTrees(const BinaryDrag< conact >::node *n1, const BinaryDrag< conact >::node *n2)
Checks whether two (sub)trees 'n1' and 'n2' are equal or nor.
void FindAndLinkIdentiesRec(BinaryDrag< conact >::node *n1, BinaryDrag< conact >::node *n2)
void Tree2DagUsingIdentities(BinaryDrag< conact > &t)
void Tree2DagUsingIdentitiesRec(BinaryDrag< conact >::node *n, BinaryDrag< conact > &t)