Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Mathematics and Algorithms > Discrete Mathematics > Boolean Computation >
Mathematica > Mathematics and Algorithms > Logic & Boolean Algebra > Boolean Computation >

BooleanConvert

BooleanConvert[expr]
converts the Boolean expression expr to disjunctive normal form.
BooleanConvert[expr, form]
converts the Boolean expression expr to the specified form.
BooleanConvert[expr, form, cond]
finds an expression in the specified form that is equivalent to expr when cond is true.
  • BooleanConvert[expr, form] will produce an expression equivalent to expr.
  • Available forms are:
"DNF","SOP"disjunctive normal form, sum of products
"CNF","POS"conjunctive normal form, product of sums
"ESOP"exclusive sum of products
"ANF"algebraic normal form
"NOR"two-level Nor and Not
"NAND"two-level Nand and Not
"AND"two-level And and Not
"OR"two-level Or and Not
"IMPLIES"Implies and Not
"ITE","IF"If and constants
"BFF"BooleanFunction form
"BDT"Boolean decision tree
Convert a Boolean expression to disjunctive normal form:
Convert xXory to some common forms:
Convert xXoryXorz using the condition that xAnd(yOrz) is true:
Show that the output is equivalent to the input when xAnd(yOrz):
Convert a Boolean expression to disjunctive normal form:
In[1]:=
Click for copyable input
Out[1]=
 
Convert xXory to some common forms:
In[1]:=
Click for copyable input
Out[1]=
 
Convert xXoryXorz using the condition that xAnd(yOrz) is true:
In[1]:=
Click for copyable input
Out[1]=
Show that the output is equivalent to the input when xAnd(yOrz):
In[2]:=
Click for copyable input
Out[2]=
Convert a Boolean expression to different forms:
Disjunctive normal form:
Conjunctive normal form:
Exclusive sum of products:
Algebraic normal form:
Two-level Nand and Not:
Two-level Nor and Not:
Two-level And and Not:
Two-level Or and Not:
Implies and Not:
If and constants:
Boolean function form:
Boolean decision tree:
Show that they are all equivalent:
Convert a Boolean function using a "care set" or condition:
The resulting forms are equivalent when cond is true:
They are not equivalent without the condition:
Typically the forms are longer without conditions:
The output from BooleanConvert is equivalent to its input:
The output from BooleanConvert with condition is conditionally equivalent to its input:
The forms f and g are equivalent when cond is true:
They are not equivalent on their own:
Use BooleanMinimize to get the minimal length form:
The forms are equivalent:
New in 7
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team