1ADDBDDASSOC(3)                   BDD FUNCTIONS                  ADDBDDASSOC(3)
2
3
4

NAME

6       addbddassoc - creates a new association variables.
7

SYNOPSIS

9       #include "bdd101.h"
10       bddassoc ∗addbddassoc( BddSystem )
11         bddsystem  ∗BddSystem;
12

PARAMETERS

14       BddSystem           The bdd system.
15

DESCRIPTION

17       addbddassoc  creates  a  new  association  variables  in the bdd system
18       BddSystem.  If a null pointer is given, the default bdd system is used.
19

RETURN VALUE

21       addbddassoc returns a pointer to the new variable association.
22

ERRORS

24       "no more variable association, error !"
25              There is no variable association number left.
26

EXAMPLE

28       #include "bdd101.h"
29          bddsystem  ∗BddSystem;
30          bddcircuit ∗BddCircuit;
31          bddnode    ∗BddNode;
32          bddnode    ∗BddSubst;
33          bddnode    ∗BddVariable;
34          bddassoc   ∗Assoc;
35          chain_list ∗Expr;
36          bddvar         Variable;
37          BddSystem  = createbddsystem( 100, 1000, 100, 50000 );
38          BddCircuit = createbddcircuit( "hello_world", 10, 10, BddSystem );
39          Expr = createablbinexpr( ABL_AND,
40                                   createablatom( "i0" ),
41                                   createablatom( "i1" ) );
42          BddNode = addbddcircuitabl( BddCircuit, Expr );
43          freeablexpr( Expr );
44          Expr = createablbinexpr( ABL_OR,
45                                   createablatom( "i2" ),
46                                   createablatom( "i3" ) );
47          BddSubst = addbddcircuitabl( BddCircuit, Expr );
48          freeablexpr( Expr );
49          BddVariable = searchbddcircuitin( (bddcircuit ∗)0, "i0" );
50          Variable = getbddvarbyindex( (bddsystem ∗)0, BddVariable->INDEX );
51          Assoc = addbddassoc( (bddsystem ∗)0 );
52          addbddnodeassoc( (bddsystem ∗)0, Assoc, Variable, BddSubst );
53          BddNode = substbddnodeassoc( (bddsystem ∗)0, BddSubst, Assoc );
54          delbddassoc( (bddsystem ∗)0, Assoc );
55          Expr = convertbddcircuitabl( BddCircuit, BddNode );
56          /* displays ((i3 or i2) and i1) */
57          viewablexpr( Expr, ABL_VIEW_VHDL );
58          freeablexpr( Expr );
59          destroybddassoc( (bddsystem ∗)0 );
60          destroybddsystem( (bddsystem ∗)0 );
61          destroybddcircuit( (bddcircuit ∗)0 );
62

SEE ALSO

64       bdd(1)
65
66
67
68
69
70
71ASIM/LIP6                       October 1, 1997                 ADDBDDASSOC(3)
Impressum