1DISPLAYBDD(3) BDD functions DISPLAYBDD(3)
2
3
4
6 displayBdd - displays a BDD
7
9 #include "logmmm.h"
10 void displayBdd(pBdd,level)
11 pNode pBdd;
12 int level;
13
15 pBdd BDD to display
16
17 level displaying level
18
20 displayBdd() displays pBDD. if level= 1, this function displays all the
21 nodes of pBdd, if level = 0 the function displays the root node of
22 pBdd.
23
25 #include "mutnnn.h" /* mbk utilities */
26 #include "logmmm.h"
27 pNode nodeA,nodeB,nodeC;
28 pNode res;
29
30 initializeBdd(SMALL_BDD);
31 nodeA = createNodeTermBdd(3);
32 nodeB = createNodeTermBdd(3);
33 nodeC = createNodeTermBdd(4);
34
35 res = applyBinBdd(OR,applyBinBdd(AND,nodeB,nodeC),nodeA);
36 /* corresponding to (OR (AND b c) a) */
37
38 displayBdd(res,1);
39
40 /* it will display
41 @res INDEX = 4 LOW = @nodeA HIGH = @inter1
42 @nodeA INDEX = 2 LOW = ZERO HIGH = ONE
43 @inter1 INDEX = 3 LOW = @nodeA HIGH = ONE
44 */
45
46 displayBdd(res,0);
47
48 /* it will display
49 @res INDEX = 4 LOW = @nodeA HIGH = @inter1
50 */
51
52 destroyBdd(1);
53
55 log(1), bdd(1), createNodeTermBdd(3), applyBinBdd(3), applyBdd(3), con‐
56 straintBdd(3), composeBdd(3), addListBdd(3), notBdd(3).
57
58
59
60
61
62ASIM/LIP6 October 1, 1997 DISPLAYBDD(3)