8/14/2019 LSyn3 Unate
1/23
1ECE 667 - Synthesis & Verification - Lecture 11
ECE 697B 667ECE 697B 667Spring 2007Spring 2007
Synthesis and Verification
of Digital Systems
Unate Recursive Paradigm
8/14/2019 LSyn3 Unate
2/23
ECE 667 - Synthesis & Verification - Lecture 11 2
Shannon ExpansionShannon Expansion
f : BnBShannon Expansion:
Theorem: F is a cover of f. Then
We say that f(F) is expanded aboutxi.
xi is called the splitting variable.
i i
ii x x f x f x f
i iii x x
F x F x F %
8/14/2019 LSyn3 Unate
3/23
ECE 667 - Synthesis & Verification - Lecture 11 3
Example
Cube bcist split into two cubes
( ) ( )a a
F ab ac bc
F aF aF a b c bc a bc
ab ac abc abc
%
c
a
bc
a
bc
ac
ab
Shannon Expansion (cont.)Shannon Expansion (cont.)
8/14/2019 LSyn3 Unate
4/23
ECE 667 - Synthesis & Verification - Lecture 11 4
List of Cubes (Cover Matrix)List of Cubes (Cover Matrix)
We often use matrix notation to represent a cover:
Example: F = ac + cd + bcd
a b c d a b c d
a c 1 2 1 2 1 - 1 - cd 2 2 0 1 or - - 0 1
bcd 2 1 1 0 - 1 1 0
Each row represents a cube
1 means that the positive literal appears in the cube
0 means that the negative literal appears in the cube
The 2 (or -) represents that the variable doesnot appearin the cube.
Finding factors from matrix representation is easy.
8/14/2019 LSyn3 Unate
5/23
ECE 667 - Synthesis & Verification - Lecture 11 5
Definition: A function f : Bn
B issymmetricwith respect tovariablesxi andxjiff
f(x1,,xi,,xj,,xn ) = f(x1,,xj,,xi,,xn)
Definition: A function f : BnB istotally symmetric iffanypermutation of the variables in f does not change the function
Some Special FunctionsSome Special Functions
i j i j x x x xf f
Symmetry can be exploited in searching the binary decision tree
because:
- That means we can skip one of four sub-cases
- used in automatic variable ordering for BDDs
8/14/2019 LSyn3 Unate
6/23
ECE 667 - Synthesis & Verification - Lecture 11 6
Definition: A function f: Bn
B ispositive unateinvariablexiiff
This is equivalent tomonotone increasinginxi:
for all minterm pairs (m-, m+) where
For example, m-3=1001, m+3=1011 (where i =3)
ii xx f f
)()( + mfmf
,
0
1
j j
i
i
m m j i
m
m
Unate FunctionsUnate Functions
8/14/2019 LSyn3 Unate
7/23
ECE 667 - Synthesis & Verification - Lecture 11 7
Similarly fornegative unate
monotone decreasing:
A function isunateinxi if it is either positive unate or negative unate inxi.
Definition: A function isunateif it is unate in each variable.
Definition: A cover F ispositive unateinxi iffxicj for all cubes cjF
i ix x f f
)()( + mfmf
Unate FunctionsUnate Functions
8/14/2019 LSyn3 Unate
8/23
ECE 667 - Synthesis & Verification - Lecture 11 8
c
ba
mc+
mc-
fis positive unate in a,b :
f(ma+) f(ma-)
f(mb+) f(mb-)
and negative unate in c:
f(mc-) = 1 f(mc+) = 0
f ab bc ac
Example - unatenessExample - unateness
off
on
Minterms associated with c
mc- = (010) = 1mc+ = (011) = 0
8/14/2019 LSyn3 Unate
9/23
ECE 667 - Synthesis & Verification - Lecture 11 9
The Unate Recursive ParadigmThe Unate Recursive Paradigm
Key pruning technique based on exploiting the properties ofunatefunctions
based on the fact that unate leaf cases can be solved efficiently
New case splitting heuristic
splitting variable is chosen so that the functions at lower nodes
of the recursion tree become unate
8/14/2019 LSyn3 Unate
10/23
ECE 667 - Synthesis & Verification - Lecture 11 10
Unate covers Fhave many extraordinary properties: If a coverFis minimal with respect to single-cube
containment, all of its cubes are essential primes.
In this case F is the unique minimum cube representation ofits logic function.
A unate cover represents the tautology iff it contains a cubewith no literals (constant 1).
Positive unate: f = x fx+ fx
Negative unate: f = fx+ xfx
This type of implicit enumeration applies to many sub-problems(prime generation, reduction, complementation, etc.).
The Unate Recursive Paradigm
8/14/2019 LSyn3 Unate
11/23
ECE 667 - Synthesis & Verification - Lecture 11 11
Unate Recursive ParadigmUnate Recursive Paradigm
Create cofactoring tree stopping atunate covers choose, at each node, the most binate variable for splitting
recurse until no binate variable left (unate leaf)
Operateon the unate cover at each leaf to obtain the result for thatleaf. Return the result
At each non-leaf node,merge(appropriately) the results of the twochildren.
Main idea: Operationon unate leaf is computationally less complex Operations: complement, simplify, tautology, generate-primes,...etc.
a
cbmerge
8/14/2019 LSyn3 Unate
12/23
ECE 667 - Synthesis & Verification - Lecture 11 12
Two Useful Theorems - TautologyTwo Useful Theorems - Tautology
Theorem:
Checking for tatutology for is simplified for unate functions
Positive unate (f = x fx+ fx) f1 fx= 1
Negative unate (f = fx+ xfx)f1 fx= 1
Theorem: LetA be a unate cover matrix.
ThenA1 if and only ifA has a row of all -s.
Proof:If. A row of all -s is the tautology cube.
Only if. Assume no row of all -s. Without loss of generality, suppose function ispositive unate. Then each row has at least one 1 in it. Consider the point
(0,0,,0). This is not contained in any row of A. HenceA1.
1 ( 1) ( 1)j j
x x F F F
8/14/2019 LSyn3 Unate
13/23
ECE 667 - Synthesis & Verification - Lecture 11 13
Recursive Tautology termination rulesRecursive Tautology termination rules
8/14/2019 LSyn3 Unate
14/23
ECE 667 - Synthesis & Verification - Lecture 11 14
Recursive Tautology - exampleRecursive Tautology - example
8/14/2019 LSyn3 Unate
15/23
ECE 667 - Synthesis & Verification - Lecture 11 15
Recursive Complement OperationRecursive Complement Operation
x x f x f x f
0
1
x x
x x
g x f x f
f x f x f
f gg f
f g
Theorem:
Proof:
8/14/2019 LSyn3 Unate
16/23
ECE 667 - Synthesis & Verification - Lecture 11 16
COMPLEMENT OperationCOMPLEMENT Operation
Algorithm COMPLEMENT(List_of_Cubes C) {
if(C contains single cube c) {
Cres = complement_cube(c) // generate one cube per
return Cres // literal l in c with ^l
}else {
xi = SELECT_VARIABLE(C)
C0= COMPLEMENT(COFACTOR(C,^xi)) ^xiC
1= COMPLEMENT(COFACTOR(C,x
i )) x
i
return OR(C0,C1)
}
}
8/14/2019 LSyn3 Unate
17/23
ECE 667 - Synthesis & Verification - Lecture 11 17
Recursive Complement termination rulesRecursive Complement termination rules
8/14/2019 LSyn3 Unate
18/23
ECE 667 - Synthesis & Verification - Lecture 11 18
Recursive Complement example (split)Recursive Complement example (split)
8/14/2019 LSyn3 Unate
19/23
ECE 667 - Synthesis & Verification - Lecture 11 19
Recursive Complement example (merge)Recursive Complement example (merge)
8/14/2019 LSyn3 Unate
20/23
ECE 667 - Synthesis & Verification - Lecture 11 20
Incompletely Specified Boolean FunctionsIncompletely Specified Boolean Functions
F = (f, d, r) : Bn {0, 1, *}where * represents a dont care.
f= onset function - f(x)=1 F(x)=1
r= offset function - r(x)=1 F(x)=0 d= dont care function - d(x)=1 F(x)=*
(f,d,r) forms a partition ofBn, i.e. f + d + r = Bn
fd =fr = dr= (pairwise disjoint)
8/14/2019 LSyn3 Unate
21/23
ECE 667 - Synthesis & Verification - Lecture 11 21
A completely specified Boolean function gis a cover forF= (f,d,r) if
f g f+dNote:
g r =
ifxd, then g(x) = 0 or 1 (dont care) ifxf, then g(x)=1
ifxr, then g(x)=0.
Also: r = fd g f
Incompletely Specified Boolean FunctionsIncompletely Specified Boolean Functions
fd
r
8/14/2019 LSyn3 Unate
22/23
ECE 667 - Synthesis & Verification - Lecture 11 22
Example: Logic Minimization (single output)Example: Logic Minimization (single output)
ConsiderF(a,b,c)=(f,d,r), where f={abc, abc, abc} and d ={abc, abc}, andthe sequence of covers illustrated below:
abcis redundanta is primeF3= a+abc
Expandabc bc
Expandabca
F2= a+abc + abc
F4= a+bc
off
on
Dont care
F1= abc + abc+ abc
8/14/2019 LSyn3 Unate
23/23
ECE 667 - Synthesis & Verification - Lecture 11 23
Two-level minimization (multiple-outputs)Two-level minimization (multiple-outputs)
Initial representation: x y z0 0
0 1
1 1
1 1
f1 f20 1
0 1
1 0
1 0
x
yz
000 100
110010
111011
010
000 100
110010
111011
010
f1f2
101 101
f1 f2
000 100
110
010
111011
010
000 100
110
010
111011
010101 101
x y z
0 0
0 1 1
1 1
f1 f2
0 1
1 1
1 0
Minimized cover: