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

NAME

6       applybddnodeite - computes the IF-THEN-ELSE logical operation.
7
8

SYNOPSIS

10       #include "bdd101.h"
11       bddnode ∗applybddnodeite( BddSystem, BddIf, BddThen, BddElse )
12         bddnode   ∗BddSystem;
13         bddnode   ∗BddIf;
14         bddnode   ∗BddThen;
15         bddnode   ∗BddElse;
16

PARAMETERS

18       BddSystem           The bdd system.
19
20       BddIf               The IF bdd node.
21
22       BddThen             The THEN bdd node.
23
24       BddElse             The ELSE bdd node.
25

DESCRIPTION

27       applybddnodeite  computes  the  following  logical  function (BddIf AND
28       BddThen) OR ((NOT BddIf) AND BddElse) in the bdd system BddSystem.   If
29       a null pointer is given, the default bdd system is used.
30

RETURN VALUE

32       applybddnodeite  returns  a  pointer to the resulting bdd node with its
33       number of external reference incremented.
34

EXAMPLE

36       #include "bdd101.h"
37          bddsystem  ∗BddSystem;
38          bddcircuit ∗BddCircuit;
39          bddnode    ∗BddNode;
40          chain_list ∗Expr;
41          BddSystem  = createbddsystem( 100, 1000, 100, 50000 );
42          BddCircuit = createbddcircuit( "hello_world", 10, 10, BddSystem );
43          addbddcircuitin( (bddcircuit ∗)0, "i0", 0, BDD_IN_MODE_FIRST );
44          addbddcircuitin( (bddcircuit ∗)0, "i1", 0, BDD_IN_MODE_FIRST );
45          addbddcircuitin( (bddcircuit ∗)0, "i2", 0, BDD_IN_MODE_FIRST );
46          BddNode = applybddnodeite( (bddsystem ∗)0,
47                                     searchbddcircuitin( (bddcircuit ∗)0, "i0" ),
48                                     searchbddcircuitin( (bddcircuit ∗)0, "i1" ),
49                                     searchbddcircuitin( (bddcircuit ∗)0, "i2" ) );
50          Expr = convertbddcircuitabl( (bddcircuit ∗)0, BddNode );
51          /* displays ((i0 and i1) or ((not i0) and i2) */
52          viewablexpr( Expr, ABL_VIEW_VHDL );
53          freeablexpr( Expr );
54          destroybddsystem( (bddsystem ∗)0 );
55          destroybddcircuit( (bddcircuit ∗)0 );
56

SEE ALSO

58       bdd(1)
59
60
61
62
63
64
65ASIM/LIP6                       October 1, 1997             APPLYBDDNODEITE(3)
Impressum