In order to test algorithms and programs it is convenient to have a benchmark of problems of various sizes and origins at one disposal. I collected a number of Boolean formulae that are available hereafter. These formulae come from different sources. Generators for scalable families of formulae are also available as Perl scripts. Translators from other formats to mine are also provided. Contributions to extend this benchmark are welcome.
Here follows several fault trees coming from various areas (avionic systems, nuclear industry, ...). These formula are at the Aralia format
The whole benchmark of fault trees as a zip archive: FT.zip.
Here follows several sums of products. These formula are at the DNF format
The following sums of products are the sums of the minimal cutsets of fault trees.
| baobab1 | baobab2 | baobab3 | chinese | das9201 |
| das9202 | das9205 | das9208 | edf9205 | edfpa15r |
| ftr10 | isp9603 | isp9605 | isp9606 | jbd9601 |
The following sums of products encode the s,t-paths of reliability networks.
The whole benchmark of sums of products as a zip archive: DNF.zip.
Fn = (x1.y1) + ... + (xn.yn) at the Aralia format. This formula
has been given by Bryant in order to show the influence of variable
ordering on BDD sizes. The Aralia command to set the worst order
(x1 < ... < xn < y1 < ... < yn) is generated as well.
Usage: bryant86.pl n
n, the number of products m, the size of
the products k and the seed of the random number generator
s. Each product is generated independently by first picking
k variables out of the n's and then deciding
the polarity of each literal (positive and negative polarity have the
same probability).
Usage: fl-dnf.pl n m k s
n, the number of products m, the size of
the products k and the seed of the random number generator
s. Each product is generated independently by picking
k variables out of the n's.
Usage: fl-mdnf.pl n m k s
p pigeons into h holes in such way that
there is at most one pigeon per hole.
Usage: pigeonhole.pl p h
n-queens problem:
how to put n queens onto a nxn chessboard in such way that
there is no two queens attacking each other.
Usage: queens.pl n
S(k,n,m)
over the variables x1,...,xm such that S(k,n,m)
is satisfied if and only if there is a window of n consecutive
indices in which at least k variables are true.
Usage: sliding-kn.pl k n m
dnf2dag.pl dnf-file
[a-zA-Z][a-zA-Z0-9_]*
_, - or
. starting with a letter.
0 et 1
x, x1,..., xp are variables and
F, F1,...,Fn are formulae, then the following
constructs are formulae as well.
Syntax
Semantics
-F1
Negation (not F1)
(F1 | ... | Fn)
Disjunction (F1 or ... or Fn)
(F1 & ... & Fn)
Conjunction (F1 and ... and Fn)
(F1 = ... = Fn)
Equivalence (F1 iff ... iff Fn)
(F1 # ... # Fn)
Exclusif or (F1 xor ... xor Fn)
(F1 => F2)
Implication (F1 implies F2)
(F1 <= F2)
Co-implication (F2 implies F1)
(F1 ? F2 : f3)
If F1 Then F2 Else f3
@(k,[F1,...,Fn])
k out of F1,...,Fn
#(i,j,[F1,...,Fn])
At least i and at most j out of
F1,...,Fn
exists x1,...,xp F1
Existential quantification
forall x1,...,xp F1
Universal Quantification
cofactor l1,...,lp F1
Cofactor, where li=xi or li=-xi (i=1,..,p)
x := F;
variable definition (equation)
Example
TOP := (G1 | g2);
G1 := (E1 & E2);
G2 := (E2 & E3);
The DNF Format
The DNF format for sums of products is a very simple format
in which everything is declared in advance (in order to
allocate data structures before filling them). Here follows
an introducing example.
DNF 4 3
VAR 1 a
VAR 2 b
VAR 3 c
VAR 4 d
LAW 1 0.01
PRD 3 1 -2 3
PRD 2 -4 1
PRD 2 -4 2
A description is a sequence of instructions (one per line).
A description starts with a header of the form:
DNF #variables #products
Variables are numbered from 1 to #variables.
Negative literals are just denoted with negative numbers.
It is possible to name to variables through the instruction:
VAR number name
It is possible to associate probabilities to variables through the instruction
LAW number probability
The syntax for products is as follows.
PRD size literal1 ... literalsize
The description ends with the last product declaration (otherwise
the various instructions can be given in any order).
The above description encode the sum of products
a.-b.c + -d.a + -d.b . The probability 0.01
is associated with a.