2017-06-07 6 views
0

Lorsque vous essayez de faire une multiplexor comment allez-vous de ceci:Comment simplifier Logic Gate - simulation MUX

Not(in=a, out=nota); 
    Not(in=b, out=notb); 
    Not(in=sel, out=notsel); 
    And(a=a, b=b, out=aAndb); 
    And(a=a, b=notb, out=aAndNotb); 
    And(a=nota, b=b, out=bAndNota); 
    And(a=aAndb, b=sel, out=aAndBAndSel); 
    And(a=aAndb, b=notsel, out=aAndBAndNotSel); 
    And(a=aAndNotb, b=notsel, out=aAndNotBAndNotSel); 
    And(a=bAndNota, b=sel, out=bAndNotaAndSel); 
    Or(a=aAndBAndSel, b=aAndBAndNotSel, out=o1); 
    Or(a=o1, b=aAndNotBAndNotSel, out=o2); 
    Or(a=o2, b=bAndNotaAndSel, out=out); 

à ceci:

Nand(a=sel, b=sel, out=notsel); 
    Nand(a=a, b=notsel, out=asel); 
    Nand(a=b, b=sel, out=bnotsel); 
    Nand(a=asel, b=bnotsel, out=out); 

ma réponse est toujours très long et je Je ne sais pas comment vous allez trouver une solution plus élégante.

MUX Truth Table Answers 
| a | b | sel | out | 
| 0 | 0 | 0 | 0 | 
| 0 | 0 | 1 | 0 | 
| 0 | 1 | 0 | 0 | 
| 0 | 1 | 1 | 1 | 
| 1 | 0 | 0 | 1 | 
| 1 | 0 | 1 | 0 | 
| 1 | 1 | 0 | 1 | 
| 1 | 1 | 1 | 1 | 

Répondre

1

Notez la table de vérité de l'expression que vous avez, utilisez Karnaugh pour minimiser, utilisez alors l'algèbre booléenne pour obtenir la deuxième expression. (En ajoutant deux pas et l'application de la loi morgan)

1

Cela simplifie à:

BS + AS' 

Ou utiliser différentes notations:

(B & S) ∨ (A & ~S)