TsutomuSasao Jon T.Butler
DepartmentofComputerScience DepartmentofElectricaland
andElectronics ComputerEngineering
KyushuInstitute ofTechnology NavalPostgraduateScho ol
Iizuka820,Japan Monterey,CA93943-5121,U.S.A.
Abstract
A logic function f has a disjoint bi-decomposition i
f can b e represented as f = h(g 1 (X 1 );g 2 (X 2 )), where X 1 andX 2
aredisjointsetofvariables,andhisan
arbi-trarytwo-variablelogic fuction. f has a non-disjoint
bi-decompositionif canberepresentedasf(X
1 ;X 2 ;x)= h(g 1 (X 1 ;x);g 2 (X 2
;x)), where x is the common
vari-able. In this paper, we show a fast method to nd
bi-decompositions. Also,weenumeratethenumb erof
func-tionshavingbi-decomp ositions.
I Intro duction
Functionaldecompositionisabasictechniquetorealize
economical networks. If thefunction f is representedas
f(X 1 ;X 2 )=h(g(X 1 );X 2
),thenf canb e realizedbythe
networkshowninFig.1.1. Tondsuchadecomp osition,
1
X
2
X
g
h
f
Figure 1.1: A simple disjoint decomp osition.1
X
2
X
g
h
g
1
2
f
Figure 1.2: A disjoint bi-decom-p osition.1
X
2
X
g
h
g
1
2
x
f
Figure 1.3: A non-disjoint bi-decomp osition.adecomp ositionchartwith2 n1 columnsand2 n2 rowsare used,wheren i
isthenumb erofvariablesinX
i
(i=1;2).
When n is large, the decomposition chart is to o large
to build. Recently, a method using BDDs has been
de-velop ed[13]. This greatly reduces memory requirements
andcomputation time. However,it isstill time
consum-ing, since we haveto check all the 0 n 1 +n 2 n1 1 partitions of n=n 1 +n 2
. Inthispaper,weconsiderbi-decompositions
oflogicfunctions,arestrictedclassoffunctional
decompo-sitionsthathavetheformf(X
1 ;X 2 )=h(g 1 (X 1 );g 2 (X 2 )).
Fig.1.2showstherealizationofthisdecomposition.
Thereasons weconsider bi-decomp ositions are as
fol-lows:
1) If f hasnobi-decomp osition, then thecomputation
timeisquitesmall.
2) Some programmable logic devices have two-input
logicelementsintheoutputs.
3) Iff hasabi-decomposition,thentheoptimizationof
theexpressionis relativelyeasy.
Arestictedclassofbi-decomp ositionshasb eenconsidered
by[8]. Thegoalsofthispap erare
1) Presentafastmetho dforndingbi-decomp ositions.
2) Enumerate the functions that have
bi-decom-positions.
Most of the proofs are omitted. They can be available
fromauthors. II Disjoint Bi-Decomposition Denition2.1 Let X = (X 1 ;X 2 ) be a partition of
the variables. A logic function f has a disjoint
bi-decomposition i f can be represented as f(X
1 ;X 2 ) = h(g 1 (X 1 );g 2 (X 2
)),wherehisanytwo-variablelogic
func-tion.
Iff hasadisjointbi-decomposition,thenf canb erealized
bythenetworkshownin Fig.1.2.
Denition2.2 Let X = (X 1 ;X 2 ) be a partition of the variables. Letn 1 andn 2
bethe numberofvariablesinX
1
andX
2
, respectively. A decompositionchart ofthe
func-tion f for a partition (X
1 ;X 2 ) consists of 2 n1 columns and2 n2
rowsof 0sand1s. The2 n1
distinctbinary
num-bers forX
1
are listedacrossthetop, andthe 2 n
2
distinct
binarynumbersforX
2
arelisteddowntheside. Theentry
forthechart correspondstothe valueof f(X
1 ;X
2 ).
Example 2.1 Twodecompositionchartsforthefunction
f(x 1 ;x 2 ;x 3 ;x 4 )=x 1 x 2 8x 3 x 4
areshown inFig. 2.1(a)
and(b). 2
Notethat thedecomposition chartis similarto the
Kar-naughmapwithadierentorderingforthecelllocations.
Denition2.3 Thenumberofdistinctcolumn(row)
pat-terns in the decomposition chart is called column (row)
1
X
0
0
0
1
0
0
0
1
0
0
0
1
1
1
1
0
00
01
10
11
00
01
10
11
x
1
=(
,
x
2
)
X
1
0
0
0
0
0
1
0
1
0
0
1
1
0
1
1
0
00
01
10
11
00
01
10
11
x
1
=(
,
x
3
)
(a)
(b)
2
X
=(
x
2
,
x
4
)
2
X
=(
x
3
,
x
4
)
Figure2.1: Decomp osition chart.
x
y
x
y
z
z
V
Figure 3.1: A real-ization of f(x;y;z) = xyz_xyz.x
y
z
Figure 3.2: Non-disjointbi-decomp osition for
f(x;y;z)=xyz_xyz.
Example 2.2 In Fig.2.1 (a), the row andcolumn
mul-tiplicities are two. In Fig. 2.1 (b), the row and column
multiplicitiesarefour. 2
Denition2.4 Let (f : X
1 ;X
2
) be the column
mul-tiplicities for f with respect to X
1 and X 2 . Let (f : X 2 ;X 1
)bethe rowmultiplicitiesforf with respecttoX
1
andX
2 .
Theorem 2.1 f has a disjointbi-decompositionof form
f(X 1 ;X 2 )=h(g 1 (X 1 );g 2 (X 2 )) i(f :X 1 ;X 2 )2 and (f:X 2 ;X 1 )2. I II Non-Disjoint Bi-Decomposition Denition3.1 Let X 1 and X 2
be disjoint sets of
vari-ables, and let x be disjoint from X
1
and X
2
. A logic
function f has anon-disjoint bi-decomposition i f can
be represented as f(X 1 ;X 2 ;x) = h(g 1 (X 1 ;x);g 2 (X 2 ;x)),
wherehisatwo-variablelogicfunction. Inthiscase,xis
calledthecommonvariable.
Afunctionf withanon-disjointbi-decompositioncanb e
realizedbythenetworkshowninFig.1.3.
Lemma3.1 Let X = (X
1 ;X
2
;x) be a partition of the
inputvariables. Leth(g
1 ;g
2
)beanarbitrarylogicfunction
oftwovariables. Then,
h(g 1 (X 1 ;x);g 2 (X 2 ;x))= xh(g 1 (X 1 ;0);g 2 (X 2 ;0))_xh(g 1 (X 1 ;1);g 2 (X 2 ;1)):
Denition3.2 Let x be the common variable of the
non-disjointbi-decomposition. Letf(X
1 ;X
2
;a)bea
sub-function,wherexissettoa0or 1.
1
X
1
0
0
0
1
0
0
0
1
0
0
0
0
1
1
1
00
01
10
11
00
01
10
11
x
1
=(
,
x
2
)
X
1
0
0
0
1
1
1
1
0
1
1
1
0
1
1
1
0
00
01
10
11
00
01
10
11
x
1
=(
,
x
2
)
(b)
f
1
=
x
1
x
2
(
x
3
v
x
4
)
(a)
f
0
=
x
1
x
2
x
3
x
4
2
X
=(
x
3
,
x
4
)
2
X
=(
x
3
,
x
4
)
Figure3.3: FunctionsinExample3.2
Theorem 3.1 f(X
1 ;X
2
;x)hasa non-disjoint
bi-decom-position of the form h(g
1 (X 1 ;x);g 2 (X 2 ;x)) i f(X 1 ;X 2 ;0) and f(X 1 ;X 2
;1) have disjoint
bi-decom-positions h(g 01 (X 1 );g 02 (X 2 )) and h(g 11 (X 1 );g 12 (X 2 )), respectively.
Example 3.1 Consider the three-variable function:
f(x;y;z) = xyz _ xyz. Suppose modules that
real-izes any function of two variables can be used. The
straightforwardrealizationshown inFig.3.1 requires ve
modules. The Shannon expansion with respect to x is
f(x;y;z) = xf(0; y;z) _xf(1;y;z); wheref(0;y;z) =
yz; andf(1;y;z) = yz: Note that both f(0;y;z) and
f(1;y;z)havebi-decompositionswithh(x;y)=xy. Since,
g 1 (x;y)=xg 01 (X 1 )_xg 11 (X 1 )=xy_xy; andg 2 (x;y )= xg 02 (X 2 )_xg 12 (X 2 ) = xz _xz: We have f(x;y;z) = g 1 (x;y)g 2
(x;z) = (xy_xy)(xz_xz): From this
expres-sion, we have the network in Fig. 3.2. This network
re-quiresonly threemodules. 2
Example 3.2 Consider the ve-variable function f =
x 5 f 0 _x 5 f 1 ,wheref 0 andf 1
areshowninFig.3.3. Since
bothf
0 andf
1
havedisjointbi-decompositionsoftheform
h(g 1 (X 1 );g 2 (X 2 )),f =x 5 f 0 _x 5 f 1
has anon-disjoint
bi-decompositionasfollows: f=x 5 fx 1 x 2 8x 3 x 4 g_x 5 fx 1 x 2 8(x 3 _x 4 )g =fx 5 (x 1 x 2 )_x 5 (x 1 x 2 )g8fx 5 (x 3 x 4 )_x 5 (x 3 _x 4 )g:
Theconverseistruealso. 2
Up to now, we only considered the case where there is
a singlecommon variable. However,the theoremcan b e
extenedtok commonvariables,where k2.
Denition3.3 Let X 1 , X 2 , and X 3 be disjoint sets of variables. Let f(X 1 ;X 2
;a) be the sub-functions, where
X
3
is set to a 2 f0;1g k
, and k denotes the number of
variablesinX 3 . Theorem 3.2 Let X 1 , X 2 , and X 3 be disjoint sets of
variables. Then, f has a non-disjoint bi-decomposition
of form f(X 1 ;X 2 ;X 3 ) = h(g 1 (X 1 ;X 3 );g 2 (X 2 ;X 3 )) i f(X 1 ;X 2
;a) has a decomposition of the form
h(g 1a (X 1 );g 2a (X 2 )) for all possible a 2 f0;1g k , where
kdenotes the numberof variablesinX
3 .
Inthissection,weshownecessaryandsucient
condi-tionsfor a functionto havea disjointbi-decomposition.
Then, we show ecient algorithms to nd disjoint
bi-decompositions. In the previoussections, h(g
1 ;g
2 ) is an
arbitrarytwo-variable logic function. To nd a disjoint
bi-decomposition,weneedto consideronlythreetyp es:
1) ORtype: f =g 1 (X 1 )_g 2 (X 2 ), 2) ANDtype: f =g 1 (X 1 )g 2 (X 2 ),and 3) EXORtyp e: f =g 1 (X 1 )8g 2 (X 2 ).
Sincef hasan AND typ e disjointbi-decomposition i
f
hasORtypedisjointbi-decomp osition,weonlyconsider
theORtypeandEXORtypebi-decomp ositions.
Denition4.1 x and x are literals of a variable x. A
logicalproductwhichcontainsatmostoneliteralforeach
variable is called a product term or a product.
Prod-uct terms combined with OR operators form a
sum-of-productsexpression(SOP).
Denition4.2 Aprimeimplicant(PI)pofafunctionf
isaproductterm which impliesf,such that the deletion
of anyliteral fromp results in anew productwhich does
notimplyf.
Denition4.3 An irredundant sum-of-products
expres-sion(ISOP)is anSOP, whereeachproduct is aPI, and
no product can be deleted without changing the function
representedby the expression.
Denition4.4 Letf(X)beafunctionandpbeaproduct
of l iteral (s) in X. The restriction of f to p, denotedby
f(Xjp)isobtainedasfollows: If x
i
appearsinp, thenset
x
i
in1inf,andif x
i
appearsinp, thensetx
i in0inf. Example 4.1 Let f(x 1 ;x 2 ;x 3 ) = x 1 x 2 _x 2 x 3 and p = x 1 x 3
. f(Xjp) is obtained asfollows: Set x
1 =x 3 =1 in f,andwehavef(Xjx 1 x 3 )=f(1;x 2 ;1)=x 2 _x 2 =1. 2 Lemma4.1 pisanimplicantof f(X), if(Xjp)=1. Example 4.2 By Lemma 4.1, x 1 x 3 is an implicant of x 1 x 2 _x 2 x 3 ,showninExample 4.1. 2
Theorem 4.1 (ORtypedisjointbi-decomposition)f has
adisjointbi-decompositionof formf(X
1 ;X 2 )=g 1 (X 1 )_ g 2 (X 2
)i everyproductin anISOPforf consistsof
lit-eralsfromX 1 onlyorX 2 only. Denition4.5 x 0 =x. x 1 =x. Corollary4.1 If f(x 1 ;x 2 ;:::;x n
) has aPI of the form
x a1 1 x a2 2 111x a n n , wherea i
2f0;1g,then f has no OR type
disjointbi-decomposition. i 1 p 2 _111_p t
beanirredundantsum-of-productsexpression
forf,wherep
i
(i=1;2;:::;t)arePIsoff. Let5
0 bethe
trivialpartitionof f1;2;:::;ng,5
0
=[f1g;f2g;:::;fng].
Algorithm 4.1 (OR type disjoint bi-decomposition:
f(X 1 ;X 2 )=g 1 (X 1 )_g 2 (X 2 )). 1. For i = 1 to t, form 5 i from 5 i01 by merging two blocks 1 and 2 of 5 i01
if atleastone literal inp
i occursin both 1 and 2 . 2. If 5 t
has at least two blocks, then f(X
1 ;X
2 ) has a
disjoint bi-decomposition of the form f(X
1 ;X 2 ) = g 1 (X 1 )_g 2 (X 2 ), with X 1
the union of one or more
blocksof5
t andX
2
theunionoftheremainingblocks.
Example 4.3 Consider the ISOP: f(x
1 ;x 2 ;:::;x 6 ) = x 1 x 2 _x 2 x 3 _x 4 x 5 _x 5 x 6 . The productsx 1 x 2 andx 2 x 3 show that x 1 , x 2 , and x 3
are in the same block. Also,
the products x
4 x 5 and x 5 x 6 show that x 4 , x 5 , and x 6
are in the same block. Thus, we have the partition
[f1;2;3g;f4;5;6g]. The corresponding OR type disjoint
bi-decomposition is f(X 1 ;X 2 )=g 1 (X 1 )_g 2 (X 2 ), where X 1 =(x 1 ;x 2 ;x 3 )andX 2 =(x 4 ;x 5 ;x 6 ). 2
Example 4.4 Consider the function f with an ISOP:
f(x 1 ;x 2 ;x 3 ;x 4 ;x 5 )=x 1 x 2 x 3 _x 3 x 4 x 5 . 1) Theproductx 1 x 2 x 3 showsthatx 1 ,x 2 ,andx 3 belong
tothesame block.
2) Theproductx 3 x 4 x 5 showsthatx 3 ,x 4 ,andx 5 belong
tothesame block.
Thus, all the variables belong to the same block. From
this,itfollows thatf has no ORtypedecomposition. 2
Theorem 4.2 (AND type disjoint bi-decomposition) f
has a disjoint bi-decomposition of form f(X
1 ;X 2 ) = g 1 (X 1 )g 2 (X 2
)ieveryproduct inanISOPfor f consists ofliteralsfromX 1 onlyor X 2 only.
Lemma 4.2 [15]Anarbitraryn-variablefunctioncanbe
uniquelyrepresentedas f(x 1 ;x 2 ;:::;x n )=a 0 8(a 1 x 1 8a 2 x 2 81118a n x n ) 8(a 12 x 1 x 2 8a 13 x 1 x 3 81118a n01n x n01 x n ) 81118a 12111n x 1 x 2 111x n ; (4.1) wherea i
2f0;1g. The aboveexpression iscalleda
posi-tivepolarityReed-Mullerexpression(PPRM).
Foragivenfunctionf,theco ecientsa
0 ,a 1 ,a 2 ,:::,a 12111n
areuniquelydetermined. Thus,thePPRMisacanonical
representation. Thenumb erofpro ductsin(4.1)isatmost
2 n
has a disjointbi-decomposition of the form f(X 1 ;X 2 )= g 1 (X 1 )8g 2 (X 2
)ieveryproductinthePPRMforf
con-sistsofliteralsfromX
1
onlyorX
2 only.
Corollary4.2 If the PPRM of an n-variable function
has the product x
1 x
2 111x
n
, then f has no EXOR type
disjointbi-decomposition.
Theorem 4.4 When f has an EXOR type disjoint
bi-decomposition, the number of true minterms of f is an
evennumber.
Corollary4.3 When the number of true minterms off
is an odd number, then f does not have an EXOR type
disjointbi-decomposition.
The signicance of this observation is that at least one
halfofthefunctionscanb equicklyrejectedascandidates
forEXORtyp edisjointbi-decomposition.
Let x
i
(i = 1;2;:::;n) b e the input variables of f.
Let p 1 8p 2 81118p t b e PPRM for f, where p i (i =
1;2;:::;t) are products. Let, 5
0
be thetrivial partition
off1;2;:::;ng,5
0
=[f1g;f2g;:::;fng].
Algorithm 4.2 (EXOR type disjoint bi-decomposition:
f(X 1 ;X 2 )=g 1 (X 1 )8g 2 (X 2 )). 1. For i =1 to t, form 5 i from 5 i01 by merging two blocks 1 and 2 of 5 i01
ifat leastone literalin p
i occursinboth 1 and 2 . 2. If5 t
hasatleasttwoblocks,thenf(X
1 ;X
2
)hasa
dis-jointbi-decompositionofformf(X
1 ;X 2 )=g 1 (X 1 )8 g 2 (X 2 ), with X 1
the union of one or more blocksof
5
t andX
2
the unionofthe remainingblocks.
Example 4.5 Consider the PPRM: f(x
1 ;x 2 ;:::;x 6 ) = x 1 x 2 8x 2 x 3 8x 4 x 5 8 x 5 x 6 . The products x 1 x 2 and x 2 x 3 show that x 1 , x 2 , and x 3
are in the same block.
Also, the productsx
4 x 5 and x 5 x 6 show that x 4 , x 5 , and x 6
are in the same block. Thus, we have the partition
[f1;2;3g;f4;5;6g]. The corresponding EXOR type
dis-joint bi-decomposition is f(X 1 ;X 2 ) = g 1 (X 1 )8g 2 (X 2 ), whereX 1 =(x 1 ;x 2 ;x 3 ) andX 2 =(x 4 ;x 5 ;x 6 ). 2
Algorithm 4.3 (Non-disjointbi-decomposition).
f(X 1 ;X 2 ;x i )=g 1 (X 1 ;x i )g 2 (X 2 ;x i ), wheredenotes
eitherOR,AND,orEXOR.Let(X
1 ;X 2 ;x i )beapartition ofthe variablesx 1 ,x 2 ,:::,andx n . Fori=1 ton,do i) Let f 0i = f(X 1 ;X 2 ;0). (Set x i to 0). Let f 1i = f(X 1 ;X 2 ;1). (Set x i to1). ii) If bothf 0i andf 1i
have the sametypeof disjoint
bi-decompositionswiththe samepartition,thenf has a
non-disjointbi-decomposition.
5.1 ORtype disjoint bi-decomposition
Weassumethat thefunctionis givenasanISOP with
t pro ducts. Note that t 2 n01
. The time to form the
partitionofvariablesisO(n1t).
5.2 EXORtyp edisjointbi-decomposition
APPRMcanb erepresentedbyafunctionaldecision
di-agram(FDD[5,15]). Eachpathfromtherootno detothe
constant1 node corresp ondsto aproduct in thePPRM.
Thus,thepartitionofthe inputvariablesisdirectly
gen-erated from the FDD. Thenumber of paths in an FDD
is O(2 n
), where n is the numb er of the input variables.
However,wecanavoidexhaustivegenerationofpaths as
follows: Letp
1 andp
2
b e productsina PPRM.Ifallthe
literalsinp
1
alsoapp earinp
2
,thenp
2
neednotb e
gener-atedintheAlgorithm,sincethepro ductp
1
thatcontains
more literals than p
2
is more important. By searching
thepathswithmoreliteralsrst,wecanecientlydetect
functionswithnodisjointbi-decomp osition.
Example 5.1 Consider the function f(X) given as a
PPRM:f(X)=x 1 8x 1 x 2 8x 3 x 4 8x 1 x 2 x 5 x 6 . In
construct-ingthe partitionof X,weneednotconsiderthe products
x 1 orx 1 x 2 ,sincex 1 x 2 x 5 x 6
hastheliteralsofx
1 andx 1 x 2 .
Inthis case,the product x
1 x 2 x 5 x 6 shows that x 1 ,x 2 ,x 5 , andx 6
belongto the samegroup. Also, the productx
3 x 4 showsthatx 3 andx 4
belongtothesamegroup. Thus,Xis
partitionedas X =(X 1 ;X 2 ), where X 1 =(x 1 ;x 2 ;x 5 ;x 6 ) andX 2 =(x 3 ;x 4 ). 2
Denition5.1 Let pbea product. The set of variables
inpisdenotedby V(p)=fx i jx i orx i appears inpg:For example,V(x 1 x 2 x 4 )=fx 1 ;x 2 ;x 4 g
Denition5.2 LetF beaPPRM.Aproductpissaidto
havemaximalvariablesetV(p)ifthereisnootherproduct
p 0
suchthatV(p)V(p 0
).
Example 5.2 For the PPRM, F = x
1 x 2 8 x 1 x 3 8 x 1 x 2 x 3 8 x 4 , V(x 1 x 2 ) = fx 1 ;x 2 g, V(x 1 x 3 ) = fx 1 ;x 3 g;V(x 1 x 2 x 3 ) = fx 1 ;x 2 ;x 3 g, and V(x 4 ) = fx 4 g. Thus,x 1 x 2 x 3 andx 4
havemaximal variablesets. 2
Theorem 5.1 A function f has an EXOR typedisjoint
bi-decompositionif afunction f 0
fromthe PPRMof f by
eliminating implicants not having maximal variable sets
hasan EXORtypedisjointbi-decomposition.
The following theorem says that if a function has an
EXOR type disjoint bi-decomp osition, then the number
ofproductsinthePPRMisrelativelysmall.
Theorem 5.2 If f has adisjointbi-decompositionofthe
form f(X 1 ;X 2 )= g 1 (X 1 )8g 2 (X 2
), then the number of
productsinthe PPRMisatmost2 n 1 +2 n 2 01,wheren i
isthe numberof variablesinX
i
Bi-Decompositions
6.1 Functions with a small numb er ofvariables
In the previous sections, we showed that disjoint
bi-decompositions areeasy to nd. Inthis section, wewill
enumeratethefunctionswithdisjointbi-decomp ositions.
Denition6.1 Afunction f issaidtobenondegenerate
ifforallx i f(jx i )6=f(jx i ):
Denition6.2 Two functions f and g are
NP-equivalent,denoted by f NP
g,i g isderived fromf by
thefollowing operations:
1) Permutationof the inputvariables.
2) Negationsof the inputvariables.
Thefollowingiseasytoprove.
Lemma6.1 If f has a disjoint bi-decomposition and if
f NP
g, then g has also the same type of disjoint
bi-decomposition.
Lemma6.2 All the two-variable functionshave disjoint
bi-decompositions.
Example 6.1 There are 2 2
3
= 256 three-variable logic
functions of which 218 are nondegenerate. These
non-degenerate functionsare grouped into16 NP-equivalence
classes as shown in Table 6.1 [9]. In this table,
the column headed by N denotes the number of
func-tions in that equivalence class. Eight classes have
disjoint bi-decompositions, and three have non-disjoint
bi-decompositions. Note that 194 functions have
bi-decompositions. 2
The numb er of functions with AND type disjoint
bi-decompositions isequal to the numb er offunctions with
ORtyp edisjointbi-decompositions.
In the case of disjoint bi-decompositions, a function
has exactly one typ e of decomp osition (Lemma 6.4).
On the other hand, in the case of non-disjoint
bi-decompositions,afunctionmayhavemorethanonetype
ofbi-decompositions.
Example 6.2 Consider the three-variable function f =
x 1 x 3 _x 1 x 2
. Thisfunctionhasthreetypesofnon-disjoint
bi-decompositions: f=x 1 x 3 _x 1 x 2
(ORtypebi-decomp osition)
=x 1 x 3 8x 1 x 2
(EXORtyp ebi-decomp osition)
=(x 1 _x 3 )(x 1 _x 2
)(ANDtype bi-decomp osition) 2
Table6.1: NP-representativefunctionsofthreevariables.
Representativefunctions N Type Property
1x18x28x3 2EXOR 2x 1 x 2 x 3 8AND Disjoint 3x 1 _x 2 _x 3 8OR Bi-Decomposition 4x 1 (x 2 _x 3 ) 24AND 5x 1 _x 2 x 3 24OR 6x 1 (x 2 8x 3 ) 12AND 7x 1 _(x 2 8x 3 ) 12OR 8x 1 8x 2 x 3 24EXOR 9x1x2x3_x1 x2 x3 4 10(x1_x2_x3)(x1_x2 _x3) 4 Non-Disjoint 11x1x3 _x1x2 24 Bi-Decomposition 12x 1 x 2 x 3 _x 2 x 3 24 13(x 1 _x 2 _x 3 )(x 2 _x 3 ) 24 14x1x2_x2x3_x3x1 8 No 15x1x2_x2x3_x1x3_x1 x2 x3 8 Bi-Decomposition 16x1x2x3 _x1x2x3 _x1x2x3 8
N: Numberofthefunctionsintheclass.
Table6.2: Numberoffunctions.
n=2 n=3 n=4
Allthefunctions 16 256 65536
Nondegeneratefunctions 10 218 64594
Disjoint AND 4 44 1660
Functionswith OR 4 44 1660
bi-decomp osition EXOR 2 26 914
Non-disjont 0 80 3860
Total 10 194 8094
6.2 The numb erof functions with
bi-decomp ositions
Lemma 6.3 [4]: Let(n) bethe numberof
nondegener-ate functionsonnvariables. Then,
(n)= n X k =0 n k (01) n0k 2 2 k 2 2 n ;
wherea(n)b(n)means lim
n!1 a(n)
b(n) =1:
Lemma 6.4 Anondegeneratefunctionf hasatmostone
typeof disjointbi-decomposition:
1. f(X 1 ;X 2 )=g 1 (X 1 )1g 2 (X 2 ), 2. f(X 1 ;X 2 )=g 1 (X 1 )_g 2 (X 2 ), or 3. f(X 1 ;X 2 )=g 1 (X 1 )8g 2 (X 2 ), where g 1 and g 2
are nondegenerate functions on one or
morevariables.
Theorem 6.1 ThenumberoffunctionsN
disjoint (n)with disjoint bi-decompositions is N disjoint (n) = A dis (n)+ O dis (n)+E dis (n),where A dis (n)=n! X k 1 ;k 2 ;:::;k n 0 1k 1 +2k 2 +111+nkn=n n Y i=1 (i)0A dis (i) i! k i 1 ki!
Table7.1: Numb eroffunctions withbi-decompositions.
Decomp ositionType Numb erofFunctions
AND 853 Disjoint OR 264 EXOR 73 AND 162 Non-disjoint OR 91 EXOR 42 O dis (n)=n! X k 1 ;k 2 ;:::;k n 0 1k 1 +2k 2 +111+nk n =n n Y i=1 (i)0O dis (i) i! k i 1 k i ! E dis (n)=2n! X k 1 ;k 2 ;:::;kn0 1k 1 +2k 2 +111+nk n =n n Y i=1 (i)0E dis (i) i! ki 1 2 k i k i !
where the sums are over all partitions of n except the
trivialpartitionn=011+012+111+01(n01)+11n(i.e.
the sum is over all partitions where k
n =0), and where A dis (1)=O dis (1)=E dis (1)=0.
Table6.2showsthenumberoffunctionswithdisjoint
bi-decompositionsupto n=4.
VI I Experimental Results
Weanalyzedthebi-decomposabilityof136 b enchmark
functions. Over these multiple-output functions,the
to-talnumberofoutputs(functions)is1908. Foreach
func-tion, we determined whether there exists a disjoint
bi-decomposition. If none existed, we determined if there
existsanon-disjointbi-decomposition(withasingle
com-mon variable). Table 7.1 summarizes our results. It is
interesting that 1190 out of 1908 functions, or 62 p
er-cent, have disjoint bi-decompositions. Of the
remain-ing718 functions, 295 havenon-disjointdecompositions.
It should be noted that more than 295 functions have
non-disjointdecomp ositions, sincea functionwith a
dis-joint bi-decomposition may also have a non-disjoint
bi-decomposition.
VI II Conclusions and Comments
In this paper, we presented the bi-decomp osition, a
special case of functional decomp osition. Disjoint
bi-decompositionshavethefollowingfeatures:
1) They are easy to detect; we use ISOPs or PPRMs
ratherthandecomposition charts.
2) Programmable logic devices exist that realize
bi-decomp ositions.
3) If the function has an OR (AND) typ e
bi-decom-p osition, then we can optimize the expression
sep-arately.
Weenumeratedfunctionswithbi-decompositions. Among
218 nondegeneratefunctions of 4 variables, 194 have
bi-ofdisjointbi-decomp ositions.
Sincethefractionoffunctionswithdecomp ositions
ap-proaches to zero as n increase [4], the fraction of
func-tions with bi-decomp ositions also approaches to zero as
n increases. However, for 1908 functions we analyzed
ab out78%ofthemhadeither disjointornon-disjoint
bi-decomp ositions.
References
[1] R.L.Ashenhurst,\Thedecomp ositionofswitching
func-tions,"InProceedingsofanInternationalSymposiumon
the Theoryof Switching,pp.74-116,April1957.
[2] J.T.Butler,\Onthenumb eroffunctionsrealizedby
cas-cades anddisjunctivenetworks,"IEEETrans.Comput.,
Vol.C-24,pp.681-690,July1975.
[3] H.A.Curtis,ANewApproachtotheDesignofSwitching
Circuits,Princeton, N.J.: VanNostrand,1962.
[4] M.A.Harrison,IntroductiontoSwitchingandAutomata
Theory,McGraw-Hill,1965.
[5] U.Kebschull,E.Schub ertandW.Rosenstiel,\Multilevel
logic synthesis based on functional decision diagrams,"
EDAC92,1992,pp.43-47.
[6] Y-T.Lai,M.Pedram,S.B.K.Vrudhula,\EVBDD-based
algorithmforintegerlinearprogramming,spectral
trans-formation, andfunctional decomposition,"IEEE Trans.
CAD,Vol.13,No.8.Aug.1994,pp.959-975.
[7] A. A. Malik, D. Harrison, and R. K. Brayton,
\Three-level decomp osition with applicatiointo PLDs,"
ICCD-1991,pp.628-633,Oct.1991.
[8] Y.Matsunaga,\Anattempttofactorlogicfunctions
us-ingexclusive-ordecomp osition,"SASIMI'96,pp.78-83.
[9] S.Muroga,LogicDesignandSwitchingTheory,John
Wi-ley&Sons,1979.
[10] T.Sasaoand K. Kinoshita, \On thenumber of
fanout-freefunctionsandunatecascadefunctions,"IEEETrans.
onComput.,Vol.C-28,No.1,pp.866-72,Jan.1979.
[11] T.Sasao,\Input variableassignment and outputphase
optimization of PLA's," IEEE Trans.Comput., Vol.
C-33,No.10,pp.879-894,Oct.1984.
[12] T.Sasao,\Applicationofmultiple-valuedlogictoaserial
decomposition of PLA's," International Symposium on
Multiple-Valued Logic, Guangzhou, China, pp. 264-271,
May1989.
[13] T.Sasao(ed.),LogicSynthesisandOptimization,Kluwer
AcademicPublishers,1993.
[14] T. Sasao, \A design method for AND-OR-EXOR
three-level networks," ACM/IEEE International
Work-shoponLogicSynthesis,Taho eCity,California,May
23-26,1995,pp.8:11-8:20.
[15] T.SasaoandM.Fujita(ed.),RepresentationsofDiscrete
Functions,KluwerAcademicPublishers,1996.
[16] T. Sasao and J. T. Butler, \Comparison of the worst
andbestsum-of-pro ductsexpressionsformultiple-valued
functions,"(preprint).
[17] M. Sauerho, I. Wegener, and R. Werchner, \Optimal
ordered binary decisiondiagrams for tree-likecircuits,"
SASIMI'96(tobepublished).
[18] S.Yang, \Logic synthesis and optimization benchmark