digplanet beta 1: Athena
Share digplanet:


Applied sciences






















In computer science, a binary decision diagram (BDD) or branching program is a data structure that is used to represent a Boolean function. On a more abstract level, BDDs can be considered as a compressed representation of sets or relations. Unlike other compressed representations, operations are performed directly on the compressed representation, i.e. without decompression. Other data structures used to represent a Boolean function include negation normal form (NNF), propositional directed acyclic graph (PDAG).


A Boolean function can be represented as a rooted, directed, acyclic graph, which consists of several decision nodes and terminal nodes. There are two types of terminal nodes called 0-terminal and 1-terminal. Each decision node N is labeled by Boolean variable V_N and has two child nodes called low child and high child. The edge from node V_N to a low (or high) child represents an assignment of V_N to 0 (resp. 1). Such a BDD is called 'ordered' if different variables appear in the same order on all paths from the root. A BDD is said to be 'reduced' if the following two rules have been applied to its graph:

In popular usage, the term BDD almost always refers to Reduced Ordered Binary Decision Diagram (ROBDD in the literature, used when the ordering and reduction aspects need to be emphasized). The advantage of an ROBDD is that it is canonical (unique) for a particular function and variable order.[1] This property makes it useful in functional equivalence checking and other operations like functional technology mapping.

A path from the root node to the 1-terminal represents a (possibly partial) variable assignment for which the represented Boolean function is true. As the path descends to a low (or high) child from a node, then that node's variable is assigned to 0 (resp. 1).


The left figure below shows a binary decision tree (the reduction rules are not applied), and a truth table, each representing the function f (x1, x2, x3). In the tree on the left, the value of the function can be determined for a given variable assignment by following a path down the graph to a terminal. In the figures below, dotted lines represent edges to a low child, while solid lines represent edges to a high child. Therefore, to find (x1=0, x2=1, x3=1), begin at x1, traverse down the dotted line to x2 (since x1 has an assignment to 0), then down two solid lines (since x2 and x3 each have an assignment to one). This leads to the terminal 1, which is the value of f (x1=0, x2=1, x3=1).

The binary decision tree of the left figure can be transformed into a binary decision diagram by maximally reducing it according to the two reduction rules. The resulting BDD is shown in the right figure.

Binary decision tree and truth table for the function f(x_1, x_2, x_3)=\bar{x}_1 \bar{x}_2 \bar{x}_3 + x_1 x_2 + x_2 x_3
BDD for the function f


The basic idea from which the data structure was created is the Shannon expansion. A switching function is split into two sub-functions (cofactors) by assigning one variable (cf. if-then-else normal form). If such a sub-function is considered as a sub-tree, it can be represented by a binary decision tree. Binary decision diagrams (BDD) were introduced by Lee,[2] and further studied and made known by Akers[3] and Boute.[4]

The full potential for efficient algorithms based on the data structure was investigated by Randal Bryant at Carnegie Mellon University: his key extensions were to use a fixed variable ordering (for canonical representation) and shared sub-graphs (for compression). Applying these two concepts results in an efficient data structure and algorithms for the representation of sets and relations.[5][6] By extending the sharing to several BDDs, i.e. one sub-graph is used by several BDDs, the data structure Shared Reduced Ordered Binary Decision Diagram is defined.[7] The notion of a BDD is now generally used to refer to that particular data structure.

In his video lecture Fun With Binary Decision Diagrams (BDDs),[8] Donald Knuth calls BDDs "one of the only really fundamental data structures that came out in the last twenty-five years" and mentions that Bryant's 1986 paper was for some time one of the most-cited papers in computer science.

Adnan Darwiche and his collaborators have shown that BDDs are one of several normal forms for Boolean functions, each induced by a different combination of requirements. Another important normal form identified by Darwiche is Decomposable Negation Normal Form or DNNF.


BDDs are extensively used in CAD software to synthesize circuits (logic synthesis) and in formal verification. There are several lesser known applications of BDD, including fault tree analysis, Bayesian reasoning, product configuration, and private information retrieval [9] [10][citation needed].

Every arbitrary BDD (even if it is not reduced or ordered) can be directly implemented in hardware by replacing each node with a 2 to 1 multiplexer; each multiplexer can be directly implemented by a 4-LUT in a FPGA. It is not so simple to convert from an arbitrary network of logic gates to a BDD[citation needed] (unlike the and-inverter graph).

Variable ordering[edit]

The size of the BDD is determined both by the function being represented and the chosen ordering of the variables. There exist Boolean functions f(x_1,\ldots, x_{n}) for which depending upon the ordering of the variables we would end up getting a graph whose number of nodes would be linear (in n) at the best and exponential at the worst case (e.g., a ripple carry adder). Let us consider the Boolean function f(x_1,\ldots, x_{2n}) = x_1x_2 + x_3x_4 + \cdots + x_{2n-1}x_{2n}. Using the variable ordering x_1 < x_3 < \cdots < x_{2n-1} < x_2 < x_4 < \cdots < x_{2n}, the BDD needs 2n+1 nodes to represent the function. Using the ordering x_1 < x_2 < x_3 < x_4 < \cdots < x_{2n-1} < x_{2n}, the BDD consists of 2n + 2 nodes.

BDD for the function ƒ(x1, ..., x8) = x1x2 + x3x4 + x5x6 + x7x8 using bad variable ordering
Good variable ordering

It is of crucial importance to care about variable ordering when applying this data structure in practice. The problem of finding the best variable ordering is NP-hard.[11] For any constant c > 1 it is even NP-hard to compute a variable ordering resulting in an OBDD with a size that is at most c times larger than an optimal one.[12] However there exist efficient heuristics to tackle the problem.[13]

There are functions for which the graph size is always exponential — independent of variable ordering. This holds e. g. for the multiplication function[1] (an indication[citation needed] as to the apparent complexity of factorization ).

Researchers have of late suggested refinements on the BDD data structure giving way to a number of related graphs, such as BMD (binary moment diagrams), ZDD (zero-suppressed decision diagram), FDD (free binary decision diagrams), PDD (parity decision diagrams), and MTBDDs (multiple terminal BDDs).

Logical operations on BDDs[edit]

Many logical operations on BDDs can be implemented by polynomial-time graph manipulation algorithms:[14]:20

However, repeating these operations several times, for example forming the conjunction or disjunction of a set of BDDs, may in the worst case result in an exponentially big BDD. This is because any of the preceding operations for two BDDs may result in a BDD with a size proportional to the product of the BDDs' sizes, and consequently for several BDDs the size may be exponential. Also, since constructing the BDD of a Boolean function solves the NP-complete Boolean satisfiability problem and the co-NP-complete tautology problem, constructing the BDD can take exponential time in the size of the Boolean formula even when the resulting BDD is small.

See also[edit]


  1. ^ a b Graph-Based Algorithms for Boolean Function Manipulation, Randal E. Bryant, 1986
  2. ^ C. Y. Lee. "Representation of Switching Circuits by Binary-Decision Programs". Bell Systems Technical Journal, 38:985–999, 1959.
  3. ^ Sheldon B. Akers. Binary Decision Diagrams, IEEE Transactions on Computers, C-27(6):509–516, June 1978.
  4. ^ Raymond T. Boute, "The Binary Decision Machine as a programmable controller". EUROMICRO Newsletter, Vol. 1(2):16–22, January 1976.
  5. ^ Randal E. Bryant. "Graph-Based Algorithms for Boolean Function Manipulation". IEEE Transactions on Computers, C-35(8):677–691, 1986.
  6. ^ R. E. Bryant, "Symbolic Boolean Manipulation with Ordered Binary Decision Diagrams", ACM Computing Surveys, Vol. 24, No. 3 (September, 1992), pp. 293–318.
  7. ^ Karl S. Brace, Richard L. Rudell and Randal E. Bryant. "Efficient Implementation of a BDD Package". In Proceedings of the 27th ACM/IEEE Design Automation Conference (DAC 1990), pages 40–45. IEEE Computer Society Press, 1990.
  8. ^ http://scpd.stanford.edu/knuth/index.jsp
  9. ^ R.M. Jensen. "CLab: A C+ + library for fast backtrack-free interactive product configuration". Proceedings of the Tenth International Conference on Principles and Practice of Constraint Programming, 2004.
  10. ^ H.L. Lipmaa. "First CPIR Protocol with Data-Dependent Computation". ICISC 2009.
  11. ^ Beate Bollig, Ingo Wegener. Improving the Variable Ordering of OBDDs Is NP-Complete, IEEE Transactions on Computers, 45(9):993–1002, September 1996.
  12. ^ Detlef Sieling. "The nonapproximability of OBDD minimization." Information and Computation 172, 103–138. 2002.
  13. ^ Rice, Michael. "A Survey of Static Variable Ordering Heuristics for Efficient BDD/MDD Construction" (PDF). 
  14. ^ Andersen, H. R. (1999). "An Introduction to Binary Decision Diagrams". Lecture Notes. IT University of Copenhagen. 
  • R. Ubar, "Test Generation for Digital Circuits Using Alternative Graphs (in Russian)", in Proc. Tallinn Technical University, 1976, No.409, Tallinn Technical University, Tallinn, Estonia, pp. 75–81.

Further reading[edit]

External links[edit]

Original courtesy of Wikipedia: http://en.wikipedia.org/wiki/Binary_decision_diagram — Please support Wikipedia.
This page uses Creative Commons Licensed content from Wikipedia. A portion of the proceeds from advertising on Digplanet goes to supporting Wikipedia.

77 news items

صدي السعودية (بيان صحفي) (مدوّنة)

صدي السعودية (بيان صحفي) (مدوّنة)
Sat, 31 Oct 2015 07:37:30 -0700

لقد تم افتتاح ستار أكاديمي 11 البرايم الاول على قوات LBC و CBC وعلى قناة ستار اكاديمي 24/24 التي تم ظهورها يوم الخميس الماضي قبل انطلاق البرايم الاول ،حيث ان ستار اكاديمي هي اكاديمية لتعليم الغناء ،حيث يعيش المشتركين في بيت واحد ويقاسمون الاكل والشرب ...

EE Journal

EE Journal
Mon, 19 Jan 2015 08:21:06 -0800

As noted, this arrangement looks suspiciously like a binary decision diagram (BDD). At each level, we're making a true/false decision and moving either to the left or to the right. BDDs will be pretty familiar to EDA types; they're less so for the rest ...

أخبار متجددة

أخبار متجددة
Wed, 09 Sep 2015 06:27:34 -0700

منذ بداية #ازمة_النفايات المفتوحة وعدم قدرة الحكومة على معالجة ملفها وحناجر اصوات المجتمع المدني والجمعيات البيئية- لا ينشط بعضها الا في الصور والاطلالات الاعلامية- لا تتوقف عن المطالبة على مدار الساعة باستقالة وزير البيئة محمد #المشنوق. علي الرغم ...
صدي السعودية (بيان صحفي) (مدوّنة)
Wed, 28 Oct 2015 11:22:30 -0700

الشوط الاول من مباراة بروسيا دورتموند اليوم , وننشر علي صدي السعودية نيوز احاث شوط المباراة الأول بين بوروسيا دورتموند بادربورن في الدور الثاني من بطولة كاس المانيا 2015 وتقام المباراة علي ملعب سيغنال ايدونا بارك , بقيادة الحكم: بيتير سيبيل وزالمعلق ...

صدي السعودية (بيان صحفي) (مدوّنة)

صدي السعودية (بيان صحفي) (مدوّنة)
Thu, 22 Oct 2015 00:11:14 -0700

اخبار المصدر 7 تحميل واتس اب بلس: تنزيل تطبيق whatsapp plus 2015 علي متجر بلاي اخر اصدار واتساب نتابع معكم كل جديد في عالم التكنولوجيا والمعلومات حيث تم اصدار نسخه جديدة من برنامج واتس اب بلس عبر متجر جوجل بلاي المعروف . ومن خلال استخدام واتس اب ...

EE Journal

EE Journal
Mon, 08 Dec 2014 08:45:24 -0800

I love surprises like this. You go into what promises to be a wonky, even dull, conference presentation – and come out agog. That's exactly what happened to me at the recent ICCAD in San Jose. It was a presentation based on a collaboration between the ...

صدي السعودية (بيان صحفي) (مدوّنة)

صدي السعودية (بيان صحفي) (مدوّنة)
Sat, 31 Oct 2015 07:51:03 -0700

ن المدير الفني لنادي الزمالك، البرتغالي فيراير عن تشكيل الزمالك الأساسي الذي سيخوض مباراة اليوم في الدوري المصري، حيث مباراة الزمالك والإنتاج الحربي، في المباراة التي يتقابل من خلالها الفريقين ضمن مباريات الأسبوع الثالث من الدوري المصري الممتاز ...

صدي السعودية (بيان صحفي) (مدوّنة)

صدي السعودية (بيان صحفي) (مدوّنة)
Sat, 31 Oct 2015 10:15:00 -0700

مشاهدة مباراة إنتر ميلان و روما بث مباشر «يلا شوت» اليوم 31-10-2015 فى الدوري الايطالي ، رابط يوتيوب بث مباشر ماتش “محمد صلاح” روما وانتر ميلان ، حيث تنقل اليوم قناة بى ان سبورت “bein sport 3 Hd” الرياضية ماتش الفرعون المصري «محمد صلاح» فى منافسات ...

Oops, we seem to be having trouble contacting Twitter

Support Wikipedia

A portion of the proceeds from advertising on Digplanet goes to supporting Wikipedia. Please add your support for Wikipedia!

Searchlight Group

Digplanet also receives support from Searchlight Group. Visit Searchlight