MODUAR DECOMPOSITION OF THE NOR-TSUM MUTIPE-AUED PA T. KAGANOA, N. IPNITSKAYA, G. HOOWINSKI k Belarusian State University f Infrmatics and Radielectrnics, abratry f Image Prcessing and Pattern Recgnitin. Brvky St., 6, 6, Minsk, Republic f Belarus, Phne: (37517) 49-19-81, Fax: (37517) 495-16, E-mail: jack@expert.belpak.minsk.by r pttsina@risq.belcaf.minsk.by k Institute f Cmputer Science & Infrmatin Systems, Technical University, ul. Zlnierska 49, Szczecin, Pland, Fax. (+4891) 48-76439, E-mail: hlwins@dedal.man.szczecin.pl ABSTRACT. A methd fr designing PA-based cmbinatinal circuits by mdular decmpsitin is presented. Main subjects are 1) Specific prperties f TSUM peratr, ) MIN-TSUM and NOR-TSUM expansins with respect t the bund set, X 1 f variables, 3) Realizatin f functins by multiple-valued PA-based cmbinatinal circuits, 4) Cmparisn with ther methds. Experimental investigatins shw that the size f suggested cmbinatinal circuit is the same as the size f multiple-valued PA implementing a multiple-valued lgic functin with large number f variables. KEY WORDS. Multiple-valued lgic, mdular decmpsitins, lgic design, multiple-valued prgrammable lgic array (M PA) 1. Intrductin Multiple-valued lgic is ne f the active area f research. It is knwn that multiple-valued lgic allws intercnnectins t be reduced int a chip, as well as a reductin in the numbers f inputs and utputs. Different M PA structures t implement the multiple-valued lgic (M) functins have been prpsed 1,, 3, 4]. These M PA's realize the lgic functins using the MIN (r-valued minimum), MAX (r-valued maximum), MODSUM (mdular sum), linear SUM and TSUM (truncated sum) arrays. The number f inputs, utputs and prduct terms f suggested M PA's have physical restrictins. These structures d nt permits the M functins with the large number f variables t be implemented because f the number f inputs is smaller than the number f input variables. The slutin f this prblem is t use the functinal decmpsitin technique. The decmpsitin f a lgic functin can lead t a systematic design which incrprates readily designed simpler functins. Ideally, a systematic design wuld psses such desirable prperties as regularity and testability. One apprach t decmpsitin f multiple-valued lgic functins (M functins) is t extend disjunctive decmpsitin fr the binary case 5]. The main drawback f this apprach is fllws. Since nly a very small number f functins will have a specific decmpsitin prperty 5], if the functin des nt have the desired prperty, the analysis des nt yield a design. In ther hand, the specific prperty f M functins is that an arbitrary lgic functin can be given by different set f multiple-valued peratrs. These determines the basic multiple-valued gates frm which a cmplex digital circuit implemented given M functin is synthesized. In this paper a NOR-TSUM M PA, prpsed by Pelay and etc., is assumed t be the cmpnent used t implement the functin. A decmpsitin apprach fr the mdular design f cmbinatinal multiple-valued circuits based n the NOR-TSUM PA is described. The primary bjective f this apprach is t develp prcedures which are applicable t the design f PA-based cmbinatinal circuits and t extent the class f decmpsable functins. The rest f the paper is structured as fllws. Sectin prvides definitins and ntatins, the distinctive features f TSUM peratr are investigated in Sectin 3, Sectin 4 is devted t MIN-TSUM and NOR-TSUM decmpsitins f the M functin; the M PA - based technique is explained in Sectin 5, experimental results are disscussed in Sectin 6, the Sectin 7 draws a cnclusin.. Definitin and ntatins et us examine sme r-valued peratrs by which we can represent any r-valued lgic functin. et x and y be tw r-valued variables. Then, (a) (b) x Λ y=x y=min(x, y); x y=tsum(x+y, );, if x = s,
(c) x s =, therwise, s {,1,...,}. A prduct f the literals x σ 1 1 x σ... x σ n n, is reffered t as a prduct term (als called term r prduct fr shrt). In a prduct term, all the peratins are AND peratins. A prduct term that includes literals fr all variables x 1, x,..., x n is called a full term. An r-valued minimum f term and r-valued cnstant, f(σ) x 1 σ 1 x σ... x n σ n is dented as an r-valued minimum term (als called r-valued term). An r-valued term that cntains literals fr all variables x 1, x,..., x n is called a full r-valued term. A truncated sum f r-valued terms is called a truncated sum-f-minimums (TSOM) expressin: ( 1) f(x) = l f(σ) x σ 1 1 x σ... x σ n n where the symbl l stands fr TSUM peratr, f(σ) is the value f functin evaluated with X=σ, σ=(σ 1 σ...σ n ) r, f(σ) E r ={, 1,..., }, x i E r, σ i E r. In ther hand, this expressin may be written as fllws 1]: n ( ) f(x) = l f(σ)λ( x i σ i ). i=1 where the symbl stands fr binary NOR peratr. Expressin ( ) states that any r-valued functin may be expanded as a truncated sum f binary NOR terms weighted by the r-valued cnstants f(σ). Definitin 1. et X is the set f r-valued variables. {X 1, X } is a partitin f X when X 1 X = and X 1 X =X. T represent r-valued functins with minimal expressins, the fllwing ntatins are adpted: E r : the set f cnstants is an r-valued Rsser algebra, E r ={, 1,..., } X : the set f n r-valued variables {x 1,x,...,x n }, where n is the number f elements f X. X 1 : the bund set f variables; X : the free set f variables; d(x): the number f elements f the set X. σ : (σ 1 σ σ n ), where σ i E r, i=1,,..., n. τ : (τ 1 τ τ n1 ) σ, where τ i E r, i=1,,...,n 1, d(x 1 )=n 1. η : (η 1 η η n ) σ, where η i E r, i=1,,...,n, d(x )=n. Definitin. et f(x) be an r-valued functin and {X 1, X } is a partitin f X. Then the prjectin f f(x) ver X 1 =τ, f(τ, X ) is the value f f(x) evaluated with X 1 =τ. Definitin 3. An r-valued functin f(x) is said t have a generalized decmpsitin with a bund set X 1 and a free set X if there exist r-valued functins h 1,h,...,h k and g such that ( 3) f(x)=g(h 1 (X 1 ), h (X 1 ),..., h k (X 1 ), X ) where {X 1, X } is a partitin f X. n 1 n X 1 H k h 1 h k n G g(h 1 (X 1 ),..., h k (X 1 ), X ) X H k f(τ, X ) f(τ, X ) n 1 G g(h 1 (X 1 ),..., h k (X 1 ), X ) X X 1 (a) Fig. 1 Circuit diagram f f(x)=g(h 1 (X 1 ), h (X 1 ),..., h k (X 1 ), X ). (a) h i is cded as r-valued variables, (b) h i =f(τ, X ) is examined as the prjectins f f(x) ver X 1 =τ. There are tw ways t realize generalized decmpsitin f M functins. The first way is applied in classical decmpsitin methds. Here, r-valued functins h i are cded as r-valued variables f g (Fig. 1(a)). By secnd way, r-valued functins h 1 (X 1 ), h (X 1 ),..., h k (X 1 ) can be examined as the prjectin f f(x) ver X 1 =τ, f(τ,x ) (Fig. 1(b)). In this paper the circuit diagram f f(x)=g(h 1 (X 1 ), h (X 1 ),..., h k (X 1 ), X ), shwn in Fig. 1 (a), will be cnsider mre detail. (b)
3. The specific prperties f TSUM peratr In this sectin we derive the specific prperties f TSUM peratr. Based n these features the MIN- TSUM and NOR-TSUM expansins with respect t a grup f variables (Therem 1 and Therem ) are btained which will be used in the next sectin fr designing the PA-based cmbinatinal circuits. et x, y and z be r-valued lgic variables. The fllwing peratins hld fr multiple-valued algebra: 1. Assciative laws: y) x= (y z). Cmmutative laws: y = y 3. Identities: 3A. () x= 3B. = 3C. 1... = 3D. 1 Λ 1 Λ... () Λ =x 4. Distributive laws: 4A. Λy) z=( z)(y z) 4B. y)λz (Λz) (yλz) 4C. y)λz i =(Λz i ) (yλz i ). All specific prperties f TSUM peratr are prved in Appendix 1. 4. Decmpsitin f NOR-TSUM and MIN-TSUM expansins In this sectin we will describe the new representatins f NOR-TSUM and MIN-TSUM expansins ver the bund set, X 1 f variables. The Q σ (X) term is a binary functin defined by the Blean prduct f literals and taking values in the {, } set: Q σ (X) = x σ 1 1 x σ... x σ n n Therem A. et f(x) be an r-valued lgic functin and {X 1, X } be a partitin f X. et n 1 =d(x 1 ) and n =d(x ). Then the MIN-TSUM expansin f f(x) ver X 1 is given by r n1-1 ( 4) f(x) = l Q τ (X 1 ) l f(τ,η)λq η (X ) τ= η= where f(σ) =f(τ,η) is the value f f(x) evaluated with X 1 =τ and X =η, i.e. simple the value f f(x) fr σ, σ=(σ 1 σ...σ n ) r be the input cmbinatin f X, σ={τ, η}, Q σ (X) = Q τ (X 1 )ΛQ η (X ). (Prf) Transfrm expressin ( 1) using cnjunctin and truncated sum prperties. By definitin f Q σ (X) term, expressin ( 1) can be represented as: f(x) = l f(σ)λq σ (X) Because {X 1, X } is a partitin f X, the functin Q σ (X) can be expressed as Q σ (X)=Q τ (X 1 )ΛQ η (X ), where σ={τ, η} is the input cmbinatin f X and τ and η are the input cmbinatins f X 1 and X, respectively. Therefre, f(x) = l f(σ) Λ Q τ (X 1 ) Λ Q η (X ) Bth cnjunctin and truncated sum are cmmutative f(x) = l Q τ (X 1 )Λ f(σ) Λ Q η (X ) ( 9), then Nte, that Q τ (X 1 ) and Q η (X ) are the binary functins and f(σ) takes the value f, 1,..., (). Because σ={τ, η} and bth cnjunctin and truncated sum are submitted t all distributive laws ( 14, ( 16), s r n1-1 f(x) = l Q τ (X 1 ) l f(τ,η)λq η (X ) τ= η=
Hence, the therem is prved. Q.E.D. Nte that the prjectin f f(x) ver X 1 fr MIN-TSUM expansin is determined as fllws: f(τ, X ) = l f(τ,η)λq η (X ) η= Example A. Cnsider a 3-valued 3 variable lgic functin f(x 1,x,x 3 ) (r=3, n=3), shwn in Table 1. Than the MIN-TSUM expansin with respect t x 1, x variables fr this functin is given as x 1 x 3 x f(x)= x 1 x ( x 3 x 1 3 1 x 3 ) x 1 1 x (1 x 3 1 x 1 3 1 x 3 ) x 1 x ( x 3 x 1 3 x 3 ) x 1 x 1 ( x 3 1 x 1 3 x 3 ) x 1 1 x 1 ( x 3 x 1 3 x 3 ) x 1 x 1 (1 x 3 x 1 3 1 x 3 ) x 1 x (1 x 3 x 1 3 1 x 3 ) x 1 1 x (1 x 3 x 1 3 x 3 ) x 1 x ( x 3 x 1 3 x 3 ). (End f example) Therem B. et f(x) be an r-valued lgic functin and {X 1, X } be a partitin f X. et n 1 =d(x 1 ) and n =d(x ). Then the expansin f f(x) ver X 1 fr NOR-TSUM expressin is given by r n1-1 n 1 n ( 5) f(x) = l ( x j τ j ) l f(τ,η)λ( x i η i ) τ= j=1 η= i=1 where the symbl stands fr binary NOR peratr. (Prf) By therem a any r-valued functin can be represented as fllws: r n1-1 ( 6) f(x) = l Q τ (X 1 ) l f(τ,η)λq η (X ) τ= η= Each term in previus expressin may be cnverted as fllws 1] ( 7) Q τ (X 1 ) = x 1 τ 1 Λx τ Λ... Λx n1 τ n1 = x 1 τ 1 x τ... x n1 τ n1 = x i τ i i=1 Taking int accunt the expressin ( 7) we can make the substitutin in ( 6). Hence we have a therem. Q.E.D. Nte that the prjectin f f(x) ver X 1 fr NOR-TSUM expansin is determined as fllws: n ZebpZ 1 Decmpsitin table fr f(x 1, x, x 3 ) 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 f(τ,x ) = l f(τ,η)λ( x i η i ) η= i=1 Example B. The NOR-TSUM expansin with respect t x 1, x variables fr functin described in example a is ffered as f(x)= x 1 x Λ( Λx 3 Λx 3 1 Λx 3 ) x 11 x Λ(1 Λx 3 Λx 3 1 Λ x 3 ) x 1 x Λ(1Λ x 3 Λ x 3 1 1Λ x 3 ) x 1 x 1 Λ(1 Λx 3 Λ x 3 1 1 Λx 3 ) x 11 x 1 Λ( Λx 3 Λ x 3 1 Λ x 3 ) x 1 x 1 Λ(Λ x 3 1Λ x 3 1 Λ x 3 ) x 1 x Λ( Λx 3 Λx 3 1 Λ x 3 ) x 11 x Λ(1Λ x 3 1Λ x 3 1 1 Λx 3 ) x 1 x Λ( Λx 3 Λx 3 1 1 Λx 3 ). (End f example) 5. Design methd fr M PA-based cmbinatinal circuits In this sectin we present a design methd fr M PA based cmbinatinal circuits using decmpsitin f NOR-TSUM and MIN-TSUM expansins. This nvel methd incrprates the cncept f systematically reexpressing the given M functin. In ur apprach, we d nt attempt t rewrite the functin in terms f functins which are then used as new variables in the lgic equatin. Rather, we identify the minimum number f prjectins f f(x) ver X 1 and reexpressed the given functin by btained partitin f X. Each f fucntin prjectin is then utilized as r- valued cnstant in the lgic equatin. The functin is reespressed recursively until it is represented entirely by the functin prjectins. In this case the partitin f X cmpses p subsets f variables {X 1, X,..., X p }, where p is the number f functin reexpressins. In this paper we cnsider nly partitin f X cntaining tw subsets. Therefre, functin f(x) is reexpressed nly nce (Therem 1 and Therem ). n 1
The r-valued cmbinatinal circuit cmpses f tw level. On the first level the prjectins f f(x) ver X 1 are implemented by M PA. et us cnsider the M PA prpsed in 1], and called NOR-TSUM PA. In this case the number f inputs crrespnds t the number f variables in the free set, X. The number f utputs is determined by the number f different prjectins in the NOR-TSUM expansin. On the secnd level f cmbinatinal circuit the functin prjectins ver X 1 are identified as r-valued cnstants. The number f inputs in the secnd NOR-TSUM PA is determined by the number f variables in bund set X 1. Fig. (a) illustrates the structure f tw-level PA-based cmbinatinal circuit. Nte that instead f M PA we can use any kind f universal lgic mdule such as T-gate (multiplexer), prgrammable lgic array (PA), lk-up table type FPGA (field prgrammable gate array) and etc.. Example 3. ZebpZ shws a 3-valued 5 variable functin, f(x 1, x, x 3, x 4, x 5 ). A 3 variable M PA is assumed t be the cmpnent used t implement the functin. Since the M PA uses nt mre than 3 variables, nly 3 variables are used t partitin functin f(x). N attempt is made t try 4 variables in an attempt t decmpse the functin. Selecting x 1 and x as the variables f the free set, X, the functin f(x) is rewritten as a 3 variable functin and its functinal values becme the prjectins f f(x) ver X 1. Then, there are 5 different prjectins f f(x) ver X 1 =τ, f(τ, X ), that is the number f prduct terms in the secnd M PA. The r- valued cmbinatinal circuit implementing f(x) functin is shwn in Fig. (b). ZebpZ Decmpsitin table f f(x 1, x, x 3, x 4, x 5 ) x x 1 1 1 11 1 1 x 5 x 4 x 3 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 a b b b b a c a b d d d d e d a b b b b a c a b 3 «3 3 3 15 5 3 «3 3 3 15 «15 5 3 3 3 4 4 4 5 5 5 15 768 Iτ ; 768 Iτ ; 768 I; 768 I; E Fig. The structure f PA-based cmbinatinal circuit (a) cmmn case, (b) fr functin f(x 1, x, x 3, x 4, x 5 ). E ZebpZ 3 PA by methd 1] Cmbinatinal circuit by the prpsed methd Functin The first PA The secnd PA In Out W * S * In Out W 1 S 1 In Out W S S 1 +S X+Y
S 4 1 13 153 1 8 136 1 1 17 153 S 1 4 1 35 459 4 15 3 1 16 7 57 S 4 1 11 187 3 4 76 1 1 17 46 X*Y M 4 1 7 13 4 3 6 1 9 153 13 M 1 4 1 156 3 16 64 48 1 16 7 3 M 4 1 138 549 15 74 94 1 15 55 549 M 3 4 1 57 99 1 9 754 1 14 38 99 3 digit shift register R 4 1 5 18 3 3 6 1 4 68 18 R 1 4 1 5 51 3 34 1 1 17 51 R 4 1 5 51 3 34 1 1 17 51 R 3 4 1 5 18 3 3 6 1 4 68 51 6. Experimental results ZebpZ 3 cmpares the size f synthesized circuits with the size f M PA implemented the initial functin. This table shws that the present methd prduces the cmpetitive results with ther methds. Because the prpsed decmpsitin apprach permits nly ne r-valued functin t be decmpsed the functins frm the standardized benchmarks are separately implemented. Here such benchmarks as -figure quaternary adder, -figure quaternary multiplier, 3 digit shift register are used fr experimental investigatins. 7. Cnclusin A new technique fr realizing PA-based cmbinatinal circuits has been prpsed. This technique yields multiple-valued circuit f reduced size. This has been illustrated by cnsidering the realizatin f functins frm standardized benchmarks. Within suggested apprach the nvel MIN-TSUM and NOR- TSUM expansins with respect t X 1 are derived. The specific prperties f TSUM peratr are investigated t. It is shwn that truncated sum f r-valued variables des nt submit ne f the distributive laws. It needs t take int accunt the cnsideratin at examining the MIN-TSUM and NOR-TSUM expansins. Future wrk is carried ut in frame f generalizatin the prpsed apprach fr system f M functins. It leads t investigate the perfrmance f new apprach n ther standardized benchmark prblem. 8. Acknwledgment The authrs sincerely thank Dr.. Shmerk frn Technical University (Szczecin, Pland) fr his helpful cmments and suggestins n this paper. Appendix 1 1. Assciative laws: ( 8) y) x= (y z) (Prf) 1 ) 3=MIN (x 1 +x, ) x 3 =MIN (x 1 +x +x 3, +x 3, ) = MIN(x 1 +x +x 3, ), (a) because r- 1+z fr all values f z. In ther hand, 1 ( 3)=1 MIN(x +x 3, )=MIN (x 1 +x +x 3, +x 1, ) = MIN(x 1 +x +x 3, ), (b) because +x fr all values f. Since expressins (a) and (b) are equivalent, then TSUM peratr is assciative. Q.E.D.. Cmmutative laws: ( 9) y = y (Prf) This expressin is prved using the definitin f TSUM peratr. 3. Identities: ( 1) () x= (Prf) () x=min(+x, ) =, because +x fr all values f. Q.E.D. ( 11) = (Prf) x=min(+x, ) =MIN(x, ) =. Q.E.D. ( 1) 1... = (Prf) This expressin describes all input cmbinatin f x, therefre by definitin f literal functin Eq. ( 1) takes value (). Q.E.D. ( 13) 1 Λ 1 Λ... () Λ =x, where the symbl Λ stands fr r-valued minimum.
(Prf) x= Λ 1 Λ1 Λ... () Λ =1 Λ 1 Λ... () Λ, because Λ =. Q.E.D. 4. Distributive laws. ( 14) Λy) z=( z)(y z), where x, y, z {, 1,..., } (Prf) a) x Λ y z = MIN (MIN (x, y) + z, ) = MIN (x+z, y+z, ) b) ( z)(y z)=min (x+z,) Λ MIN (y+z,)=min(min(x+z,),min (y+z,))=min (x+z, y+z, r- 1). Since expressins (a) and (b) are equivalent, then TSUM peratr submit t the distributive law. Q.E.D. ( 15) y)λz (Λz) (yλz). (Prf) a) (x y) Λ z = MIN (x+y, ) Λ z = MIN( MIN(x+y, ), z))= MIN (x+y, z, ). b) (Λz) (yλz)=min (x, z) MIN(y, z) =MIN(MIN(x, z)+min(y, z), ) = MIN(x+y, z+x, z, y+z, ) Because, the expressins (a) and (b) are nt equivalent, TSUM peratr des nt submit t the distributive laws. Q.E.D. ( 16) y)λz i =(Λz i ) (yλz i ). (Prf) a) (x y) Λ z i = MIN (x+y, ) Λ z i = MIN(MIN(x+y, ), z i )) = MIN (x+y, z i, ). b) (Λz i ) (yλz i )= MIN(x, z i ) MIN(y, z i ) =MIN(MIN(x, z i )+MIN(y, z i ), ) = MIN(x+y, z i +x, z i, y+z i, ) Because z i {,}, then x _keb z=, x+z i =MAX(x, y) = x+, therwise. But +, Eq. (b) takes int accunt variable z i, therefre x+z i and z i d nt examine. The expressin y+z i is analyzed by analgy with previus expressin. (c) MIN (x+y, z i +x, z i, y+z i, )=MIN(x+y, z, ). Since expressins (a) and (c) are equivalent, then TSUM peratr submits t the distributive law. Q.E.D. References 1 Pelay F.J. and thers, CMOS Current - Mde Multiple-alued PA s. IEEE Trans. Circut and Syst., 1991, l. 38, pp. 434-441.. Asari K., C. Eswaran, An Optimisatin Technique fr the Design f Multiple-alued PA s. IEEE Trans. Cmput., vl.43, N. 1, 1994, pp.118-1. 3. Abd-El-Barr M. and H. Chy, Use f Simulated Annealing t Reduce -bit Decder PAs. Int. J. Electrnics, 1993, l. 74, NO. 3, pp.441-45. 4. Deng X., T.Hanyu and M.Kameyama, Design And Evaluatin Of A Current-Mde Multiple-alued PA Based On A Resnant Tunnelling transistr Mdel. IEE Prc.- Circuits Devices Syst., l. 141, N.6, 1994, pp.445-45. 5. Abugharieh S.B., S.C. ee, A Fast Algrithm Fr The Disjunctive Decmpsitin Of M-alued Functins. Part 1. The Decmpsitin Algrithm. IEEE Trans. n Cmputers. 1995, pp. 118-15.