0

I have a pointer to the root node of a CUDD decision diagramm, say

DdNode * root

How can I retrieve the number of nodes and edges composing this decision tree?

Dan
  • 1,539
  • 12
  • 23

2 Answers2

3

You could use Cudd_DagSize() to get the number of nodes.

timrau
  • 22,578
  • 4
  • 51
  • 64
0

on cuddUtil.c read the function :

int Cudd_PrintDebug(DdManager * dd,DdNode * f,int  n,int  pr);

you can get the number of nodes :

Cudd_DagSize(root);

number of leaves :

Cudd_CountLeaves(root);

number of minterms :

Cudd_CountMinterm(dd, root, n);

and more ...

Eiko
  • 25,601
  • 15
  • 56
  • 71
Or Davidi
  • 99
  • 7