Presentation is loading. Please wait.

Presentation is loading. Please wait.

A New Approach to Structural Analysis and Transformation of Networks Alan Mishchenko November 29, 1999.

Similar presentations


Presentation on theme: "A New Approach to Structural Analysis and Transformation of Networks Alan Mishchenko November 29, 1999."— Presentation transcript:

1 A New Approach to Structural Analysis and Transformation of Networks Alan Mishchenko November 29, 1999

2 Problem1: Locating Elements n Find all occurrences of the combination of AND-OR gate in the network of logic gates Network Element

3 Problem2: Replacing Elements Replace a given element with another one in all the places where is occurs. For example: c = a + b; d = ( a + b )&b = ab + b = b a b d c a b d c

4 November 11, 1999Logic, Design, and Learning Group Seminar4 Presentation Overview n Introduction n BDD basics ä Product and quantification ä Image computation ä Labels n Location of structural elements n Replacement of structural elements n Conclusions

5 Truth Table and Decision Tree x1x1 x3x3 x2x2 x3x3 x3x3 x3x3 10 x2x2 1 10000 x1x1 00001111 x2x2 00110011 x3x3 01010101 F00010101 0 1 1 0 10 0 1 0 1 010 1

6 Reduction of Decision Tree Rule 1: Nodes must be unique Rule 2: Redundant tests should not be present aa bb a bb a b b

7 Decision Tree Reduction: Example x1x1 x3x3 x2x2 x3x3 x3x3 x3x3 x2x2 10 x1x1 x3x3 x2x2 x3x3 x2x2 10 x1x1 x3x3 x2x2 10 BDD Decision tree Reduced Tree Rule 1 Rule 2

8 Introduction to BDDs n Canonicity n Compactness (with some exceptions) n BDDs represent various discrete objects ä Boolean functions ä Compositional sets ä Encodings and labels n BDDs facilitate symbolic methods ä Two-level minimization, state minimization, decomposition, ATPG, etc.

9 BDD Representation n Boolean functions n Characteristic functions ä Combinatorial sets n Relations ä FSM transition relations ä Covering tables, matrices, graphs

10 Characteristic Functions: Example n Problem: Given the set {p 1, p 2, p 3, p 4, p 5, p 6 }, create the characteristic function of the subset {p 1, p 3, p 4 } and represent it using BDDs n Step 1: Introduce an encoding of the set p 1 – p 2 – p 3 – p 4 – p 5 – p 6 – n Step 2: Define a function over the encoding variables (x 1, x 2, x 3 ) such that it will be equal to 1 for minterms encoding the subset {p 1, p 3, p 4 }.

11 Characteristic Functions: Example (continued)  {p1, p3, p4} ( x 0, x 1, x 2 ) = = + + n Step 3: Represent this function as a BDD x2 x0 x1 10

12 Labeling n To generate m unique labels ä Define k =  log 2 m  binary labeling variables ä Create m minterms, corresponding to the binary encoding of integers {0, 1, 2,… m-1} ä Represent the minterms as BDDs over the labeling variables n For any assignment of labeling variables, only one label can be equal to 1

13 Boolean Relations n A boolean relation is a boolean function over two domains of binary variables (x 1,x 2,x 3,…) and (y 1,y 2,y 3,…). The function is true for an assignment of variables (x 1,x 2,x 3,…,y 1,y 2,y 3,…) iff assignments (x 1,x 2,x 3,…) and (y 1,y 2,y 3,…) are in a certain relation. n Example: Assignments (x 1,x 2,x 3,…) and (y 1,y 2,y 3,…) may be the codes of a present state and a next state of a Finite State Machine

14 Relations for FSMs 1 3 2 00 / 1 Transition Relation T(x 0,x 1,y 0,y 1,i 0,i 1 ) = 1- / 1 00 / 1 11 / 1 01 / 000 01 10

15 Relations for Graphs n a and n are in relation AND2-direct n n and a are in relation AND2-reverse n a and b are in relation AND2-adjacent, etc.

16 Relations for Graphs n Assign each signal (“cut point”), each type of gate and relation a unique binary code (label) a - b - n -, etc AND2 - OR2 - EXOR2 - Direct - Reverse - Adjacent – n Create products for each couple of objects (like nodes in the graph) and multiply these objects by labels, defining their relationship n Compute a bdd equal to the sum of these products

17 Relations for Graphs n Create a structural BDD of the network n R(x 2,x 1,x 0,y 2,y 1.y 0,g 1,g 0,a 1,a 0 ) =

18 Structural BDD Representation n Encodes all information about structure (complementary w.r.t. the sensitivity function) n Lead to a new “calculus” for structural analysis and transformations of encoded graphs (logic networks) based on the following operations efficiently implemented in the BDD package ä product/sum, ä quantification (existential, universal, unique) ä image/pre-image computation

19 Quantification n Given boolean function F(x 1, x 2, x 3 ) n Existential quantification of F w.r.t. x 1 is  x1 F(x 1, x 2, x 3 ) = F(0, x 2, x 3 ) + F(1, x 2, x 3 ) n Universal quantification of F w.r.t. x 1 is  x1 F(x 1, x 2, x 3 ) = F(0, x 2, x 3 ) & F(1, x 2, x 3 ) n Unique quantification of F w.r.t. x 1 is ! x1 F(x 1, x 2, x 3 ) = F(0, x 2, x 3 )  F(1, x 2, x 3 )

20 Image Computation n Given relation R(X, Y) and the set of assignments A(X), it is possible to compute the set of assignments B(Y) such that X and Y satisfy the relation R(X, Y). B(Y) =  x [ R(X, Y) & A(X) ] n B(Y) is called the forward image of the set A(X) in the relation R(X, Y). n Similarly, it is possible to compute the backward image A(X) of the set B(Y).

21 Problem1: Locating Elements n Find all occurrences of the combination of AND-OR gate in the network of logic gates Network Element

22 Problem2: Replacing Elements c = a + b; d = ( a + b )&b = ab + b = b a b d c a b d c

23 Solution of Problem 1: Idea n Given the structural representation of the network R( X, Y, A ), it is possible to find relations between any types of “cutpoints” a b d c

24 Solution of Problem 1 (cont.) n Cut-points b and c are in relations OR2-direct and AND2-adjacent n Relation between all possible occurrences of b and c throughout the network is R bc (X,Y) = R(X,Y,A OR2D ) & R(X,Y,A AND2A ) n The characteristic function of all occurrences of the structural element (located using b-type cut- points as references) is L b (X) =  y R bc (X,Y)

25 Solution of Problem 2: Ideas n Find the char. function L d of the d-type cut-points n Extract relations with d from R(X,Y,A) n Remove relations b-d-AND2D and d-c-AND2D from the extracted relation n Remove relations b-c-AND2A from R(X,Y,A) n Replace d-encoded cut-points for b-encoded cut- points in the remaining extracted relations n Add them to the structural bdd R(X,Y,A) a b d c a b d c

26 Solution of Problem 2 (cont.) n Characteristic function L d of d-type cut-points is L d (X) =  y [ R(X,Y,A AND2D ) & L b (Y) ] n Extract relations with d extracted from R(X,Y,A) R d (X,Y,A) = R(X,Y,A) & L d (X) n Remove b-d-AND2D and d-c-AND2D from R d R d * (X,Y,A) = R d (X,Y,A) & L b (X)’ & L c (X)’ n Remove b-c-AND2A from R(X,Y,A) R * (X,Y,A) = R(X,Y,A)&( R bc (X,Y) )’ n Replace d-type cut-points for b-type cut-points R ** (X,Y,A) =  z [R bd (X,Z) & R d * (Z,Y,A)] n Add this relation to the structural representation R(X,Y,A) = R(X,Y,A) + R d ** (X,Y,A)

27 Universal Search Algorithm n Step1: Traverse the fragment starting from the outputs and mark the overlapping cut-points n Step 2. Recursively call the search procedure for each output of the fragment

28 Recursive Procedure (sketch) n In this node ä Call the procedure for two (or more) siblings ä When they return the sets of cut-points –If the incoming sets of the node are disjoint, multiply their images –If the incoming sets are non-disjoint (the branches are symmetric or quasi-symmetric), apply the following transformation (see next slide) –At the meeting points of two overlapping branches, find the intersection of sets of possible cut-points ä Return the result

29 (Quasi-)Symmetric Branches n Computing the two related sets of ordered output cut-points R(Z 1,Z 2 ) =  Y [R(Y,Z 1,AND2R) & R(Y,Z 2,AND2R) & Z 1  Z 2 ] S 1 (Z 1 ) =  Z 2 [R(Z 1,Z 2 )] S 2 (Z 2 ) =  Z 1 [R(Z 1,Z 2 )] n Computing the “merged set” S(Y) =(  Z 1 [R(Y,Z 1,AND2R) & S 1 (Z 1 )]&  Z 2 [R(Y,Z 2,AND2R) & S 2 (Z 2 )]) + (  Z 1 [R(Y,Z 1,AND2R) & S 2 (Z 1 )]&  Z 1 [R(Y,Z 2,AND2R) & S 1 (Z 2 )]) Z2Z2 Z1Z1 Y


Download ppt "A New Approach to Structural Analysis and Transformation of Networks Alan Mishchenko November 29, 1999."

Similar presentations


Ads by Google