Professional Documents
Culture Documents
1
high
low
0
t t
1
high
low
0
t t
1
high
low
0
t t
1
high
low
0
t t
1
high
low
0
t t
5 V VCC 4
Vo (Volts)
RC 3
Vo 2
Vi RB 1
0
0 1 2 3 4 5
Vi (Volts)
5 V VCC 4
Vo (Volts)
RC 3
Vo 2
Vi RB 1
0
0 1 2 3 4 5
Vi (Volts)
5 V VCC 4
Vo (Volts)
RC 3
Vo 2
Vi RB 1
0
0 1 2 3 4 5
Vi (Volts)
5 V VCC 4
Vo (Volts)
RC 3
Vo 2
Vi RB 1
0
0 1 2 3 4 5
Vi (Volts)
5 V VCC 4
Vo (Volts)
RC 3
Vo 2
Vi RB 1
0
0 1 2 3 4 5
Vi (Volts)
V1
t
original data
Digital circuits
V1
t
original data
V2
t
corrupted data
Digital circuits
V1
t
original data
V2
V2
Vref V3
Vref
t
corrupted data comparator
Digital circuits
V1
t
original data
V3
V2
V2
Vref V3
Vref
t
t
corrupted data comparator recovered data
V1
t
original data
V3
V2
V2
Vref V3
Vref
t
t
corrupted data comparator recovered data
* A major advantage of digital systems is that, even if the original data gets distorted (e.g., in transmitting
through optical fibre or storing on a CD) due to noise, attenuation, etc., it can be retrieved easily.
V1
t
original data
V3
V2
V2
Vref V3
Vref
t
t
corrupted data comparator recovered data
* A major advantage of digital systems is that, even if the original data gets distorted (e.g., in transmitting
through optical fibre or storing on a CD) due to noise, attenuation, etc., it can be retrieved easily.
* There are several other benefits of using digital representation:
V1
t
original data
V3
V2
V2
Vref V3
Vref
t
t
corrupted data comparator recovered data
* A major advantage of digital systems is that, even if the original data gets distorted (e.g., in transmitting
through optical fibre or storing on a CD) due to noise, attenuation, etc., it can be retrieved easily.
* There are several other benefits of using digital representation:
- can use computers to process the data.
V1
t
original data
V3
V2
V2
Vref V3
Vref
t
t
corrupted data comparator recovered data
* A major advantage of digital systems is that, even if the original data gets distorted (e.g., in transmitting
through optical fibre or storing on a CD) due to noise, attenuation, etc., it can be retrieved easily.
* There are several other benefits of using digital representation:
- can use computers to process the data.
- can store in a variety of storage media.
V1
t
original data
V3
V2
V2
Vref V3
Vref
t
t
corrupted data comparator recovered data
* A major advantage of digital systems is that, even if the original data gets distorted (e.g., in transmitting
through optical fibre or storing on a CD) due to noise, attenuation, etc., it can be retrieved easily.
* There are several other benefits of using digital representation:
- can use computers to process the data.
- can store in a variety of storage media.
- can program the functionality. For example, the behaviour of a digital filter can be changed simply
by changing its coefficients.
M. B. Patil, IIT Bombay
Logical operations
Gate
Truth table
Notation
Logical operations
Gate A Y
A Y
Truth table 0 1
1 0
Notation Y=A
Logical operations
A
Gate A Y Y
B
A B Y
A Y 0 0 0
Truth table 0 1 0 1 0
1 0 1 0 0
1 1 1
A A
Gate A Y Y Y
B B
A B Y A B Y
A Y 0 0 0 0 0 0
Truth table 0 1 0 1 0 0 1 1
1 0 1 0 0 1 0 1
1 1 1 1 1 1
Gate
Truth table
Notation
Logical operations
A
Gate Y
B
A B Y
0 0 1
Truth table 0 1 1
1 0 1
1 1 0
Notation Y= A·B
= AB
Logical operations
A A
Gate Y Y
B B
A B Y A B Y
0 0 1 0 0 1
Truth table 0 1 1 0 1 0
1 0 1 1 0 0
1 1 0 1 1 0
A A A
Gate Y Y Y
B B B
A B Y A B Y A B Y
0 0 1 0 0 1 0 0 0
Truth table 0 1 1 0 1 0 0 1 1
1 0 1 1 0 0 1 0 1
1 1 0 1 1 0 1 1 0
* Theorem: A = A.
* Theorem: A = A.
The theorem can be proved by constructing a truth table:
A A A
0 1 0
1 0 1
* Theorem: A = A.
The theorem can be proved by constructing a truth table:
A A A
0 1 0
1 0 1
Therefore, for all possible values that A can take (i.e., 0 and 1), A is the same as A.
⇒ A = A.
* Theorem: A = A.
The theorem can be proved by constructing a truth table:
A A A
0 1 0
1 0 1
Therefore, for all possible values that A can take (i.e., 0 and 1), A is the same as A.
⇒ A = A.
* Similarly, the following theorems can be proved:
A+0=A A·1=A
A+1=1 A·0=0
A+A=A A·A=A
A+A=1 A·A=0
* Theorem: A = A.
The theorem can be proved by constructing a truth table:
A A A
0 1 0
1 0 1
Therefore, for all possible values that A can take (i.e., 0 and 1), A is the same as A.
⇒ A = A.
* Similarly, the following theorems can be proved:
A+0=A A·1=A
A+1=1 A·0=0
A+A=A A·A=A
A+A=1 A·A=0
Note the duality: (+ ←→ ·) and (1 ←→ 0).
1. A · (B + C ) = A B + A C .
1. A · (B + C ) = A B + A C .
A B C B +C A · (B + C ) AB AC AB + AC
0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
1. A · (B + C ) = A B + A C .
A B C B +C A · (B + C ) AB AC AB + AC
0 0 0 0
0 0 1 1
0 1 0 1
0 1 1 1
1 0 0 0
1 0 1 1
1 1 0 1
1 1 1 1
1. A · (B + C ) = A B + A C .
A B C B +C A · (B + C ) AB AC AB + AC
0 0 0 0 0
0 0 1 1 0
0 1 0 1 0
0 1 1 1 0
1 0 0 0 0
1 0 1 1 1
1 1 0 1 1
1 1 1 1 1
1. A · (B + C ) = A B + A C .
A B C B +C A · (B + C ) AB AC AB + AC
0 0 0 0 0 0
0 0 1 1 0 0
0 1 0 1 0 0
0 1 1 1 0 0
1 0 0 0 0 0
1 0 1 1 1 0
1 1 0 1 1 1
1 1 1 1 1 1
1. A · (B + C ) = A B + A C .
A B C B +C A · (B + C ) AB AC AB + AC
0 0 0 0 0 0 0
0 0 1 1 0 0 0
0 1 0 1 0 0 0
0 1 1 1 0 0 0
1 0 0 0 0 0 0
1 0 1 1 1 0 1
1 1 0 1 1 1 0
1 1 1 1 1 1 1
1. A · (B + C ) = A B + A C .
A B C B +C A · (B + C ) AB AC AB + AC
0 0 0 0 0 0 0 0
0 0 1 1 0 0 0 0
0 1 0 1 0 0 0 0
0 1 1 1 0 0 0 0
1 0 0 0 0 0 0 0
1 0 1 1 1 0 1 1
1 1 0 1 1 1 0 1
1 1 1 1 1 1 1 1
1. A · (B + C ) = A B + A C .
A B C B +C A · (B + C ) AB AC AB + AC
0 0 0 0 0 0 0 0
0 0 1 1 0 0 0 0
0 1 0 1 0 0 0 0
0 1 1 1 0 0 0 0
1 0 0 0 0 0 0 0
1 0 1 1 1 0 1 1
1 1 0 1 1 1 0 1
1 1 1 1 1 1 1 1
2. A + B · C = (A + B) · (A + C ).
2. A + B · C = (A + B) · (A + C ).
2. A + B · C = (A + B) · (A + C ).
2. A + B · C = (A + B) · (A + C ).
2. A + B · C = (A + B) · (A + C ).
2. A + B · C = (A + B) · (A + C ).
2. A + B · C = (A + B) · (A + C ).
2. A + B · C = (A + B) · (A + C ).
* A + A B = A.
To prove this theorem, we can follow two approaches:
* A + A B = A.
To prove this theorem, we can follow two approaches:
(a) Construct truth tables for LHS and RHS for all possible input combinations, and show that they are
the same.
* A + A B = A.
To prove this theorem, we can follow two approaches:
(a) Construct truth tables for LHS and RHS for all possible input combinations, and show that they are
the same.
(b) Use identities and theorems stated earlier to show that LHS=RHS.
* A + A B = A.
To prove this theorem, we can follow two approaches:
(a) Construct truth tables for LHS and RHS for all possible input combinations, and show that they are
the same.
(b) Use identities and theorems stated earlier to show that LHS=RHS.
A + AB = A · 1 + A · B
= A · (1 + B)
= A · (1)
=A
* A + A B = A.
To prove this theorem, we can follow two approaches:
(a) Construct truth tables for LHS and RHS for all possible input combinations, and show that they are
the same.
(b) Use identities and theorems stated earlier to show that LHS=RHS.
A + AB = A · 1 + A · B
= A · (1 + B)
= A · (1)
=A
* A · (A + B) = A.
* A + A B = A.
To prove this theorem, we can follow two approaches:
(a) Construct truth tables for LHS and RHS for all possible input combinations, and show that they are
the same.
(b) Use identities and theorems stated earlier to show that LHS=RHS.
A + AB = A · 1 + A · B
= A · (1 + B)
= A · (1)
=A
* A · (A + B) = A.
Proof: A · (A + B) = A · A + A · B
= A + AB
=A
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
Dual of A + (A B) (LHS): A B → A + B
A + A B → A · (A + B).
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
Dual of A + (A B) (LHS): A B → A + B
A + A B → A · (A + B).
Dual of A (RHS) = A (since there are no operations ivolved).
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
Dual of A + (A B) (LHS): A B → A + B
A + A B → A · (A + B).
Dual of A (RHS) = A (since there are no operations ivolved).
⇒ A · (A + B) = A.
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
Dual of A + (A B) (LHS): A B → A + B
A + A B → A · (A + B).
Dual of A (RHS) = A (since there are no operations ivolved).
⇒ A · (A + B) = A.
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
Dual of A + (A B) (LHS): A B → A + B
A + A B → A · (A + B).
Dual of A (RHS) = A (since there are no operations ivolved).
⇒ A · (A + B) = A.
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
Dual of A + (A B) (LHS): A B → A + B
A + A B → A · (A + B).
Dual of A (RHS) = A (since there are no operations ivolved).
⇒ A · (A + B) = A.
A + AB = A ←→ A · (A + B) = A.
Note the duality between OR and AND.
Dual of A + (A B) (LHS): A B → A + B
A + A B → A · (A + B).
Dual of A (RHS) = A (since there are no operations ivolved).
⇒ A · (A + B) = A.
* A + A B = A + B.
* A + A B = A + B.
* A + A B = A + B.
* A B + A B = A.
* A + A B = A + B.
* A B + A B = A.
In an India-Australia match, India will win if one or more of the following conditions are met:
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
Let T ≡ Tendulkar scores a century.
S ≡ Sehwag scores a century.
W ≡ Warne fails.
I ≡ India wins.
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
Let T ≡ Tendulkar scores a century.
S ≡ Sehwag scores a century.
W ≡ Warne fails.
I ≡ India wins.
I =T +TW +TS
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
Let T ≡ Tendulkar scores a century.
S ≡ Sehwag scores a century.
W ≡ Warne fails.
I ≡ India wins.
I =T +TW +TS
=T +T +TW +TS
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
Let T ≡ Tendulkar scores a century.
S ≡ Sehwag scores a century.
W ≡ Warne fails.
I ≡ India wins.
I =T +TW +TS
=T +T +TW +TS
= (T + T W ) + (T + T S)
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
Let T ≡ Tendulkar scores a century.
S ≡ Sehwag scores a century.
W ≡ Warne fails.
I ≡ India wins.
I =T +TW +TS
=T +T +TW +TS
= (T + T W ) + (T + T S)
= (T + T ) · (T + W ) + (T + T ) · (T + S)
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
Let T ≡ Tendulkar scores a century.
S ≡ Sehwag scores a century.
W ≡ Warne fails.
I ≡ India wins.
I =T +TW +TS
=T +T +TW +TS
= (T + T W ) + (T + T S)
= (T + T ) · (T + W ) + (T + T ) · (T + S)
=T +W +T +S
=T +W +S
In an India-Australia match, India will win if one or more of the following conditions are met:
(a) Tendulkar scores a century.
(b) Tedulkar does not score a century AND Warne fails (to get wickets).
(c) Tedulkar does not score a century AND Sehwag scores a century.
Let T ≡ Tendulkar scores a century.
S ≡ Sehwag scores a century.
W ≡ Warne fails.
I ≡ India wins.
I =T +TW +TS
=T +T +TW +TS
= (T + T W ) + (T + T S)
= (T + T ) · (T + W ) + (T + T ) · (T + S)
=T +W +T +S
=T +W +S
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0
0 0 1
0 1 0 1
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0
0 0 1 0
0 1 0 1
0 1 1 0
1 0 0 0
1 0 1 0
1 1 0 0
1 1 1 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0
0 0 1 0
0 1 0 1
0 1 1 0 1
1 0 0 0
1 0 1 0
1 1 0 0
1 1 1 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0 0
0 0 1 0 0
0 1 0 1 0
0 1 1 0 1
1 0 0 0 0
1 0 1 0 0
1 1 0 0 0
1 1 1 0 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0 0
0 0 1 0 0
0 1 0 1 0
0 1 1 0 1
1 0 0 0 0 1
1 0 1 0 0
1 1 0 0 0
1 1 1 0 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0 0 0
0 0 1 0 0 0
0 1 0 1 0 0
0 1 1 0 1 0
1 0 0 0 0 1
1 0 1 0 0 0
1 1 0 0 0 0
1 1 1 0 0 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0 0 0
0 0 1 0 0 0
0 1 0 1 0 0
0 1 1 0 1 0
1 0 0 0 0 1
1 0 1 0 0 0
1 1 0 0 0 0 1
1 1 1 0 0 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0 0 0 0
0 0 1 0 0 0 0
0 1 0 1 0 0 0
0 1 1 0 1 0 0
1 0 0 0 0 1 0
1 0 1 0 0 0 0
1 1 0 0 0 0 1
1 1 1 0 0 0 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0 0 0 0
0 0 1 0 0 0 0
0 1 0 1 0 0 0 1
0 1 1 0 1 0 0 1
1 0 0 0 0 1 0 1
1 0 1 0 0 0 0
1 1 0 0 0 0 1 1
1 1 1 0 0 0 0
“Sum of products” form
X = X1 + X2 + X3 + X4 = A B C + A B C + A B C + A B C
A B C X1 X2 X3 X4 X
0 0 0 0 0 0 0 0
0 0 1 0 0 0 0 0
0 1 0 1 0 0 0 1
0 1 1 0 1 0 0 1
1 0 0 0 0 1 0 1
1 0 1 0 0 0 0 0
1 1 0 0 0 0 1 1
1 1 1 0 0 0 0 0
This form is called the “product of sums” form (“sum” corresponding to OR,
and “product” corresponding to AND).
This form is called the “product of sums” form (“sum” corresponding to OR,
and “product” corresponding to AND).
We can construct the truth table for Y in a systematic manner:
This form is called the “product of sums” form (“sum” corresponding to OR,
and “product” corresponding to AND).
We can construct the truth table for Y in a systematic manner:
(1) Enumerate all possible combinations of A, B, C .
Since each of A, B, C can take two values (0 or 1), we have 23 possibilities.
This form is called the “product of sums” form (“sum” corresponding to OR,
and “product” corresponding to AND).
We can construct the truth table for Y in a systematic manner:
(1) Enumerate all possible combinations of A, B, C .
Since each of A, B, C can take two values (0 or 1), we have 23 possibilities.
(2) Tabulate Y1 = A + B + C , etc. Note that Y1 is 0 only if A = B = C = 0;
Y1 is 1 otherwise.
This form is called the “product of sums” form (“sum” corresponding to OR,
and “product” corresponding to AND).
We can construct the truth table for Y in a systematic manner:
(1) Enumerate all possible combinations of A, B, C .
Since each of A, B, C can take two values (0 or 1), we have 23 possibilities.
(2) Tabulate Y1 = A + B + C , etc. Note that Y1 is 0 only if A = B = C = 0;
Y1 is 1 otherwise.
(3) Since Y = Y1 Y2 Y3 Y4 ,
Y is 0 if any of Y1 , Y2 , Y3 , Y4 is 0; else Y is 1.
→ tabulate Y .
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0
0 0 1 1
0 1 0 1
0 1 1 1
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 1
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0
0 0 1 1 0
0 1 0 1
0 1 1 1
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 1
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1
0 0 1 1 0
0 1 0 1 1
0 1 1 1 1
1 0 0 1 1
1 0 1 1 1
1 1 0 1 1
1 1 1 1 1
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1
0 0 1 1 0
0 1 0 1 1
0 1 1 1 1
1 0 0 1 1
1 0 1 1 1 0
1 1 0 1 1
1 1 1 1 1
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1 1
0 0 1 1 0 1
0 1 0 1 1 1
0 1 1 1 1 1
1 0 0 1 1 1
1 0 1 1 1 0
1 1 0 1 1 1
1 1 1 1 1 1
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1 1
0 0 1 1 0 1
0 1 0 1 1 1
0 1 1 1 1 1
1 0 0 1 1 1
1 0 1 1 1 0
1 1 0 1 1 1
1 1 1 1 1 1 0
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1 1 1
0 0 1 1 0 1 1
0 1 0 1 1 1 1
0 1 1 1 1 1 1
1 0 0 1 1 1 1
1 0 1 1 1 0 1
1 1 0 1 1 1 1
1 1 1 1 1 1 0
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1 1 1 0
0 0 1 1 0 1 1 0
0 1 0 1 1 1 1
0 1 1 1 1 1 1
1 0 0 1 1 1 1
1 0 1 1 1 0 1 0
1 1 0 1 1 1 1
1 1 1 1 1 1 0 0
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1 1 1 0
0 0 1 1 0 1 1 0
0 1 0 1 1 1 1 1
0 1 1 1 1 1 1 1
1 0 0 1 1 1 1 1
1 0 1 1 1 0 1 0
1 1 0 1 1 1 1 1
1 1 1 1 1 1 0 0
“Product of sums” form
Y = Y1 Y2 Y3 Y4 = (A + B + C) (A + B + C) (A + B + C) (A + B + C)
A B C Y1 Y2 Y3 Y4 Y
0 0 0 0 1 1 1 0
0 0 1 1 0 1 1 0
0 1 0 1 1 1 1 1
0 1 1 1 1 1 1 1
1 0 0 1 1 1 1 1
1 0 1 1 1 0 1 0
1 1 0 1 1 1 1 1
1 1 1 1 1 1 0 0
Note that Y is identical to X (seen two slides back). This is an example of how the same function can be written in two
seemingly different forms (in this case, the sum-of-products form and the product-of-sums form).
M. B. Patil, IIT Bombay
Standard sum-of-products form
I want to design a box (with inputs A, B, C , and output S) which will help in scheduling my appointments.
A ≡ I am in town, and the time slot being suggested for the appointment is free.
B ≡ My favourite player is scheduled to play a match (which I can watch on TV).
C ≡ The appointment is crucial for my business.
S ≡ Schedule the appointment.
I want to design a box (with inputs A, B, C , and output S) which will help in scheduling my appointments.
A ≡ I am in town, and the time slot being suggested for the appointment is free.
B ≡ My favourite player is scheduled to play a match (which I can watch on TV).
C ≡ The appointment is crucial for my business.
S ≡ Schedule the appointment.
The following truth table summarizes the expected functioning of the box.
A B C S
0 X X 0
1 0 X 1
1 1 0 0
1 1 1 1
I want to design a box (with inputs A, B, C , and output S) which will help in scheduling my appointments.
A ≡ I am in town, and the time slot being suggested for the appointment is free.
B ≡ My favourite player is scheduled to play a match (which I can watch on TV).
C ≡ The appointment is crucial for my business.
S ≡ Schedule the appointment.
The following truth table summarizes the expected functioning of the box.
A B C S
0 X X 0
1 0 X 1
1 1 0 0
1 1 1 1
I want to design a box (with inputs A, B, C , and output S) which will help in scheduling my appointments.
A ≡ I am in town, and the time slot being suggested for the appointment is free.
B ≡ My favourite player is scheduled to play a match (which I can watch on TV).
C ≡ The appointment is crucial for my business.
S ≡ Schedule the appointment.
The following truth table summarizes the expected functioning of the box.
A B C S
0 X X 0
1 0 X 1
1 1 0 0
1 1 1 1
I want to design a box (with inputs A, B, C , and output S) which will help in scheduling my appointments.
A ≡ I am in town, and the time slot being suggested for the appointment is free.
B ≡ My favourite player is scheduled to play a match (which I can watch on TV).
C ≡ The appointment is crucial for my business.
S ≡ Schedule the appointment.
The following truth table summarizes the expected functioning of the box.
A B C S
0 X X 0
1 0 X 1
1 1 0 0
1 1 1 1
A B C Y
0 0 0 0
0 0 1 1
0 1 0 1
0 1 1 0
1 0 0 X
1 0 1 0
1 1 0 0
1 1 1 1
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB
0 1 0 1 00 01 11 10
C
0 1 1 0 0
1 0 0 X 1
1 0 1 0
1 1 0 0
1 1 1 1
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB
0 1 0 1 00 01 11 10
C
0 1 1 0 0
1 0 0 X 1 1
1 0 1 0
1 1 0 0
1 1 1 1
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB
0 1 0 1 00 01 11 10
C
0 1 1 0 0 1
1 0 0 X 1 1
1 0 1 0
1 1 0 0
1 1 1 1
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB
0 1 0 1 00 01 11 10
C
0 1 1 0 0 1 X
1 0 0 X 1 1
1 0 1 0
1 1 0 0
1 1 1 1
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB
0 1 0 1 00 01 11 10
C
0 1 1 0 0 1 X
1 0 0 X 1 1 1
1 0 1 0
1 1 0 0
1 1 1 1
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB AB
0 1 0 1 00 01 11 10 00 01 11 10
C C
0 1 1 0 0 1 X 0 0 1 0 X
1 0 0 X 1 1 1 1 1 0 1 0
1 0 1 0
1 1 0 0
1 1 1 1
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB AB
0 1 0 1 00 01 11 10 00 01 11 10
C C
0 1 1 0 0 1 X 0 0 1 0 X
1 0 0 X 1 1 1 1 1 0 1 0
1 0 1 0
1 1 0 0
1 1 1 1
* A K-map is the same as the truth table of a function except for the way the entries are arranged.
K-maps
A B C Y
0 0 0 0
0 0 1 1
AB AB
0 1 0 1 00 01 11 10 00 01 11 10
C C
0 1 1 0 0 1 X 0 0 1 0 X
1 0 0 X 1 1 1 1 1 0 1 0
1 0 1 0
1 1 0 0
1 1 1 1
* A K-map is the same as the truth table of a function except for the way the entries are arranged.
* In a K-map, the adjacent rows or columns differ only in one variable. For example, in going from the
column A B = 01 to A B = 11, there is only one change, viz., A = 0 → A = 1.
A B C D Y
0 0 0 0 0
0 0 0 1 1
0 0 1 0 1
0 0 1 1 1
0 1 0 0 0 AB
CD 00 01 11 10
0 1 0 1 1 00 0 0 0 0
0 1 1 0 0 01 1 1 0 X
0 1 1 1 0 11 1 0 1 1
1 0 0 0 0 10 1 0 0 0
1 0 0 1 X
1 0 1 0 0
1 0 1 1 1
1 1 0 0 0
1 1 0 1 0
1 1 1 0 0
1 1 1 1 1
M. B. Patil, IIT Bombay
K-maps
AB
CD 00 01 11 10
00 0 0 1 0
01 0 0 0 0
11 0 0 0 0
10 0 0 0 0
X1 = A B C D
K-maps
AB AB
CD 00 01 11 10 CD 00 01 11 10
00 0 0 1 0 00 0 0 0 0
01 0 0 0 0 01 1 1 0 0
11 0 0 0 0 11 0 0 0 0
10 0 0 0 0 10 0 0 0 0
X1 = A B C D X2 = A C D
K-maps
AB AB AB
CD 00 01 11 10 CD 00 01 11 10 CD 00 01 11 10
00 0 0 1 0 00 0 0 0 0 00 0 0 0 0
01 0 0 0 0 01 1 1 0 0 01 0 0 0 0
11 0 0 0 0 11 0 0 0 0 11 0 0 1 1
10 0 0 0 0 10 0 0 0 0 10 0 0 1 1
X1 = A B C D X2 = A C D X3 = A C
AB AB AB
CD 00 01 11 10 CD 00 01 11 10 CD 00 01 11 10
00 0 0 1 0 00 0 0 0 0 00 0 0 0 0
01 0 0 0 0 01 1 1 0 0 01 0 0 0 0
11 0 0 0 0 11 0 0 0 0 11 0 0 1 1
10 0 0 0 0 10 0 0 0 0 10 0 0 1 1
X1 = A B C D X2 = A C D X3 = A C
*
No. of variables No. of 1’s
4 20
3 21
2 22
AB AB AB
CD 00 01 11 10 CD 00 01 11 10 CD 00 01 11 10
00 0 0 1 0 00 0 0 0 0 00 0 0 0 0
01 0 0 0 0 01 1 1 0 0 01 0 0 0 0
11 0 0 0 0 11 0 0 0 0 11 0 0 1 1
10 0 0 0 0 10 0 0 0 0 10 0 0 1 1
X1 = A B C D X2 = A C D X3 = A C
*
No. of variables No. of 1’s
4 20
3 21
2 22
01 0 0 0 0 01 1 1 0 0 01 0 0 0 0
11 0 0 0 0 11 0 0 0 0 11 0 0 1 1
10 0 0 0 0 10 0 0 0 0 10 0 0 1 1
X1 = A B C D X2 = A C D X3 = A C
K-maps
AB AB AB
CD 00 01 11 10 CD 00 01 11 10 CD 00 01 11 10
00 0 0 1 0 00 0 0 0 0 00 0 0 0 0
01 0 0 0 0 01 1 1 0 0 01 0 0 0 0
11 0 0 0 0 11 0 0 0 0 11 0 0 1 1
10 0 0 0 0 10 0 0 0 0 10 0 0 1 1
X1 = A B C D X2 = A C D X3 = A C
AB
CD 00 01 11 10
00 0 0 1 0
01 1 1 0 0
11 0 0 1 1
10 0 0 1 1
Y = X1 + X2 + X3
01 0 0 0 0 01 1 1 0 0 01 0 0 0 0
11 0 0 0 0 11 0 0 0 0 11 0 0 1 1
10 0 0 0 0 10 0 0 0 0 10 0 0 1 1
X1 = A B C D X2 = A C D X3 = A C
AB
CD 00 01 11 10
00 0 0 1 0
01 1 1 0 0
11 0 0 1 1
10 0 0 1 1
Y = X1 + X2 + X3
01 0 0 0 0 01 1 1 0 0 01 0 0 0 0
11 0 0 0 0 11 0 0 0 0 11 0 0 1 1
10 0 0 0 0 10 0 0 0 0 10 0 0 1 1
X1 = A B C D X2 = A C D X3 = A C
AB
CD 00 01 11 10
00 0 0 1 0
01 1 1 0 0
11 0 0 1 1
10 0 0 1 1
Y = X1 + X2 + X3
AB
C 00 01 11 10
0 0 1 1 0
1 0 0 0 0
AB
C 00 01 11 10
0 0 1 1 0
1 0 0 0 0
AB
C 00 01 11 10
0 0 1 1 0
1 0 0 0 0
AB
C 00 01 11 10
0 0 1 1 0
1 0 0 0 0
AB
C 00 01 11 10
0 0 1 1 0
1 0 0 0 0
AB
C 00 01 11 10
0 0 1 1 0
1 0 0 0 0
→ Y =B C
AB
C 00 01 11 10
0 0 0 1 0
1 0 0 0 1
AB
C 00 01 11 10
0 0 0 1 0
1 0 0 0 1
AB
C 00 01 11 10
0 0 0 1 0
1 0 0 0 1
AB
C 00 01 11 10
0 1 0 0 1
1 0 0 0 0
K-maps
AB
C 00 01 11 10
0 1 0 0 1
1 0 0 0 0
AB
C 00 01 11 10
0 1 0 0 1
1 0 0 0 0
AB AB
C 00 01 11 10 C 10 00 01 11
0 1 0 0 1 0 1 1 0 0
1 0 0 0 0 1 0 0 0 0
AB AB
C 00 01 11 10 C 10 00 01 11
0 1 0 0 1 0 1 1 0 0
1 0 0 0 0 1 0 0 0 0
AB AB
C 00 01 11 10 C 10 00 01 11
0 1 0 0 1 0 1 1 0 0
1 0 0 0 0 1 0 0 0 0
AB AB
C 00 01 11 10 C 10 00 01 11
0 1 0 0 1 0 1 1 0 0
1 0 0 0 0 1 0 0 0 0
AB AB
C 00 01 11 10 C 10 00 01 11
0 1 0 0 1 0 1 1 0 0
1 0 0 0 0 1 0 0 0 0
AB
CD 00 01 11 10
00 1 0 0 1
01 0 0 0 0
11 0 0 0 0
10 1 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 0 0 1
01 0 0 0 0
11 0 0 0 0
10 1 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 0 0 1
01 0 0 0 0
X1 = B D
11 0 0 0 0
10 1 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 0 0 1
01 0 0 0 0
X1 = B D
11 0 0 0 0
10 1 0 0 1
AB
CD 00 01 11 10
00 1 0 0 1
01 1 0 0 1
11 0 0 0 0
10 0 0 0 0
K-maps
AB
CD 00 01 11 10
00 1 0 0 1
01 0 0 0 0
X1 = B D
11 0 0 0 0
10 1 0 0 1
AB
CD 00 01 11 10
00 1 0 0 1
01 1 0 0 1
11 0 0 0 0
10 0 0 0 0
K-maps
AB
CD 00 01 11 10
00 1 0 0 1
01 0 0 0 0
X1 = B D
11 0 0 0 0
10 1 0 0 1
AB
CD 00 01 11 10
00 1 0 0 1
01 1 0 0 1
X2 = B C
11 0 0 0 0
10 0 0 0 0
AB
CD 00 01 11 10
00 0 0 1 0
01 0 1 1 0
11 0 0 0 0
10 0 0 0 0
AB
CD 00 01 11 10
00 0 0 1 0
01 0 1 1 0
11 0 0 0 0
10 0 0 0 0
X1 = A B C D + A B C D + A B C D + A B C D (using Y=Y+Y)
= A B C (D + D) + B C D (A + A)
= ABC + BCD
K-maps
AB
CD 00 01 11 10
00 0 0 1 0
01 0 1 1 0
11 0 0 0 0
10 0 0 0 0
X1 = A B C D + A B C D + A B C D + A B C D (using Y=Y+Y)
= A B C (D + D) + B C D (A + A)
= ABC + BCD
K-maps
AB
CD 00 01 11 10
00 0 0 1 0
01 0 1 1 0
11 0 0 0 0
10 0 0 0 0
X1 = A B C D + A B C D + A B C D + A B C D (using Y=Y+Y)
= A B C (D + D) + B C D (A + A)
= ABC + BCD
M. B. Patil, IIT Bombay
K-maps
AB
CD 00 01 11 10
00 1 1 0 1
X1 : 01 1 1 0 1
11 0 0 1 0
10 0 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 1 0 1
X1 : 01 1 1 0 1
11 0 0 1 0
10 0 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 1 0 1
X1 : 01 1 1 0 1
11 0 0 1 0
10 0 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 1 0 1
X1 : 01 1 1 0 1
11 0 0 1 0
10 0 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 1 0 1
X1 : 01 1 1 0 1
11 0 0 1 0
10 0 0 0 1
K-maps
AB
CD 00 01 11 10
00 1 1 0 1
X1 : 01 1 1 0 1 X1 = A C + B C + A B C D + A B D
11 0 0 1 0
10 0 0 0 1
AB
CD 00 01 11 10
00 0 0 X 0
Z: 01 1 1 0 0
11 0 0 0 0
10 1 X 1 1
K-maps
AB
CD 00 01 11 10
00 0 0 X 0
Z: 01 1 1 0 0
11 0 0 0 0
10 1 X 1 1
Since X represents a “don’t care” condition, we can assign 0 or 1 to the corresponding minterm to arrive at a
minimal expression.
K-maps
AB AB
CD 00 01 11 10 CD 00 01 11 10
00 0 0 X 0 00 0 0 0 0
Z: 01 1 1 0 0 01 1 1 0 0
11 0 0 0 0 11 0 0 0 0
10 1 X 1 1 10 1 1 1 1
Since X represents a “don’t care” condition, we can assign 0 or 1 to the corresponding minterm to arrive at a
minimal expression.
K-maps
AB AB
CD 00 01 11 10 CD 00 01 11 10
00 0 0 X 0 00 0 0 0 0
Z: 01 1 1 0 0 01 1 1 0 0
11 0 0 0 0 11 0 0 0 0
10 1 X 1 1 10 1 1 1 1
Since X represents a “don’t care” condition, we can assign 0 or 1 to the corresponding minterm to arrive at a
minimal expression.
K-maps
AB AB
CD 00 01 11 10 CD 00 01 11 10
00 0 0 X 0 00 0 0 0 0
Z: 01 1 1 0 0 01 1 1 0 0 Z = CD + ACD
11 0 0 0 0 11 0 0 0 0
10 1 X 1 1 10 1 1 1 1
Since X represents a “don’t care” condition, we can assign 0 or 1 to the corresponding minterm to arrive at a
minimal expression.
* Digits: 0,1,2,..,9
* example: 4 1 5 3
* example: 4 1 5 3
8 0 1 5 second number
1 1 carry
1 1 1 9 4 sum
Addition of binary numbers
1 1 carry 1 1 1 carry
1 1 carry 1 1 1 carry
* 0 + 1 = 1 + 0 = 1 → S = 1, C = 0
Addition of binary numbers
1 1 carry 1 1 1 carry
* 0 + 1 = 1 + 0 = 1 → S = 1, C = 0
* 1 + 1 = 10 (dec. 2) → S = 0, C = 1
Addition of binary numbers
1 1 carry 1 1 1 carry
* 0 + 1 = 1 + 0 = 1 → S = 1, C = 0
* 1 + 1 = 10 (dec. 2) → S = 0, C = 1
* 1 + 1 + 1 = 11 (dec. 3) → S = 1, C = 1
example
24 23 22 21 20 weight
1 0 1 1 first number
1 1 1 0 second number
1 1 1 0 − carry
1 1 0 0 1 sum
Addition of binary numbers
24 23 22 21 20 weight 2N 22 21 20 weight
1 1 0 0 1 sum SN S2 S1 S0 sum
Addition of binary numbers
24 23 22 21 20 weight 2N 22 21 20 weight
1 1 0 0 1 sum SN S2 S1 S0 sum
AN BN A2 B2 A1 B1 A 0 B0
A A A A
FA B FA B FA B HA B
SN S2 S1 S0
Addition of binary numbers
24 23 22 21 20 weight 2N 22 21 20 weight
1 1 0 0 1 sum SN S2 S1 S0 sum
AN BN A2 B2 A1 B1 A 0 B0
A A A A
FA B FA B FA B HA B
SN S2 S1 S0
* The rightmost block (corresponding to the LSB) adds two bits A0 and B0 ; there is no input carry.
This block is called a “half adder.”
Addition of binary numbers
24 23 22 21 20 weight 2N 22 21 20 weight
1 1 0 0 1 sum SN S2 S1 S0 sum
AN BN A2 B2 A1 B1 A 0 B0
A A A A
FA B FA B FA B HA B
SN S2 S1 S0
* The rightmost block (corresponding to the LSB) adds two bits A0 and B0 ; there is no input carry.
This block is called a “half adder.”
* Each of the subsequent blocks adds three bits (Ai , Bi , Ci−1 ) and is called a “full adder.”
M. B. Patil, IIT Bombay
Half adder implementation
A B Co S
A A0
HA B
0 0 0 0
B0
Co S 0 1 0 1
C0 1 0 0 1
1 1 1 0
S0
Half adder implementation
A B Co S
A A0
HA B
0 0 0 0
B0 S = AB + AB = A ⊕ B
Co S 0 1 0 1
C0 Co = A B
1 0 0 1
1 1 1 0
S0
Half adder implementation
A B Co S
A A0
HA B
0 0 0 0
B0 S = AB + AB = A ⊕ B
Co S 0 1 0 1
C0 Co = A B
1 0 0 1
1 1 1 0
S0
Implementation 1
A AB
B
S
AB
A
Co
B
Half adder implementation
A B Co S
A A0
HA B
0 0 0 0
B0 S = AB + AB = A ⊕ B
Co S 0 1 0 1
C0 Co = A B
1 0 0 1
1 1 1 0
S0
Implementation 1 Implementation 2
A AB
B A A+B
S B
S
AB Co
AB
A
Co
B
A
FA B
Co S Cin
A B Cin Co S
0 0 0 0 0
0 0 1 0 1
0 1 0 0 1
0 1 1 1 0
1 0 0 0 1
1 0 1 1 0
1 1 0 1 0
1 1 1 1 1
Full adder implementation
A
FA B AB
Cin 00 01 11 10
Co S Cin 0 0 1 0 1
S:
1 1 0 1 0
A
FA B AB
Cin 00 01 11 10
Co S Cin 0 0 1 0 1
S:
1 1 0 1 0
The NOT, AND, OR operations can be realised by using only NAND gates:
Implementation of functions with only NAND gates
The NOT, AND, OR operations can be realised by using only NAND gates:
NOT
A= A·A
A A
Implementation of functions with only NAND gates
The NOT, AND, OR operations can be realised by using only NAND gates:
NOT AND
A
A A AB
B
Implementation of functions with only NAND gates
The NOT, AND, OR operations can be realised by using only NAND gates:
NOT AND OR
A
A
A A AB A+B
B
B
A= A·A
A·B =A·B
A+B= A·B
Implementation of functions with only NAND gates
Y = AB ·BCD · AD
A= A·A
A·B =A·B
A+B= A·B
Implementation of functions with only NAND gates
Y = AB ·BCD · AD
AB A= A·A
A·B =A·B
A+B= A·B
Y
BCD
AD
Implementation of functions with only NAND gates
Y = AB ·BCD · AD
A AB A= A·A
B A·B =A·B
A+B= A·B
Y
BCD
AD
Implementation of functions with only NAND gates
Y = AB ·BCD · AD
A AB A= A·A
B A·B =A·B
B
C A+B= A·B
Y
D BCD
AD
Implementation of functions with only NAND gates
Y = AB ·BCD · AD
A AB A= A·A
B A·B =A·B
B
C A+B= A·B
Y
D BCD
A
D AD
A A= A·A
B A·B= A·B
B
A+B= A·B
C Y
D
D
A
Implementation of functions with only NAND gates
A A= A·A
B A·B= A·B
B
A+B= A·B
C Y
D
D
A
Implementation of functions with only NAND gates
A A= A·A
B A·B= A·B
B
A+B= A·B
C Y
D
D
A
Implementation of functions with only NAND gates
A A= A·A
B A·B= A·B
B
A+B= A·B
C Y
D
D
A
Implementation of functions with only NAND gates
A A= A·A
B A·B= A·B
B
A+B= A·B
C Y
D
D
A
Implementation of functions with only NAND gates
A A= A·A
B A·B= A·B
B
A+B= A·B
C Y
D
D
A
Implementation of functions with only NAND gates
A A= A·A
B A·B= A·B
B
A+B= A·B
C Y
D
D
A=A·A
A·B =A·B
A+B =A·B
Implementation of functions with only NAND gates
Y = (A + B) + C
= (A + B) · C
A=A·A
A·B =A·B
A+B =A·B
Implementation of functions with only NAND gates
Y = (A + B) + C
= (A + B) · C
A=A·A
A·B =A·B
A+B
A+B =A·B
C
Implementation of functions with only NAND gates
Y = (A + B) + C
= (A + B) · C
A=A·A
A·B =A·B
A+B
A+B =A·B
C C
Implementation of functions with only NAND gates
Y = (A + B) + C
= (A + B) · C
= A·B·C
A=A·A
A·B =A·B
A+B
A+B =A·B
C C
Implementation of functions with only NAND gates
Y = (A + B) + C
= (A + B) · C
= A·B·C
A=A·A
A·B =A·B
A+B
A+B
A+B =A·B
C C
Implementation of functions with only NAND gates
Y = (A + B) + C
= (A + B) · C
= A·B·C
A=A·A
A A A·B =A·B
A+B
A+B
A+B =A·B
B B
Y
C C
The NOT, AND, OR operations can be realised by using only NOR gates:
Implementation of functions with only NOR gates
The NOT, AND, OR operations can be realised by using only NOR gates:
NOT
A= A+A
A A
Implementation of functions with only NOR gates
The NOT, AND, OR operations can be realised by using only NOR gates:
NOT AND
A
A A AB
B
Implementation of functions with only NOR gates
The NOT, AND, OR operations can be realised by using only NOR gates:
NOT AND OR
A
A
A A AB A+B
B
B
Implementation of functions with only NOR gates
The NOT, AND, OR operations can be realised by using only NOR gates:
NOT AND OR
A
A
A A AB A+B
B
B
Implementation of functions with only NOR (or only NAND) gates is more than a theoretical curiosity. There
are chips which provide a “sea of gates” (say, NOR gates) which can be configured by the user (through
programming) to implement functions.
A= A+A
A+B= A+B
A·B =A+B
Implement Y = A B + B C D + A D using only NOR gates.
Y = AB + BCD + AD
A= A+A
A+B= A+B
A·B =A+B
Implement Y = A B + B C D + A D using only NOR gates.
Y = AB + BCD + AD
A= A+A
AB
A+B= A+B
A·B =A+B
Y
BCD
AD
Implement Y = A B + B C D + A D using only NOR gates.
Y = AB + BCD + AD
= (A + B) + (B + C + D) + (A + D)
A= A+A
AB
A+B= A+B
A·B =A+B
Y
BCD
AD
Implement Y = A B + B C D + A D using only NOR gates.
Y = AB + BCD + AD
= (A + B) + (B + C + D) + (A + D)
A
A A= A+A
AB
B A+B= A+B
B
A·B =A+B
Y
BCD
AD
Implement Y = A B + B C D + A D using only NOR gates.
Y = AB + BCD + AD
= (A + B) + (B + C + D) + (A + D)
A
A A= A+A
AB
B A+B= A+B
B
A·B =A+B
C
C Y
BCD
D
AD
Implement Y = A B + B C D + A D using only NOR gates.
Y = AB + BCD + AD
= (A + B) + (B + C + D) + (A + D)
A
A A= A+A
AB
B A+B= A+B
B
A·B =A+B
C
C Y
BCD
D
A
AD
D
D
S1 S0 Z
I0
0 0 I0
I1
Z 0 1 I1
I2
I3 1 0 I2
S1 S0
1 1 I3
Multiplexers
S1 S0 Z
I0
0 0 I0
I1
Z 0 1 I1
I2
I3 1 0 I2
S1 S0
1 1 I3
* A multiplexer or data selector (MUX in short) has N Select lines, 2N input lines, and it routes one of the
input lines to the output.
Multiplexers
S1 S0 Z
I0
I0 SW0
0 0 I0 I1 SW1
I1
Z 0 1 I1 I2 SW2
I2 Z
I3 1 0 I2 I3 SW3
S1 S0 S1 S0
1 1 I3
* A multiplexer or data selector (MUX in short) has N Select lines, 2N input lines, and it routes one of the
input lines to the output.
Multiplexers
S1 S0 Z
I0
I0 SW0
0 0 I0 I1 SW1
I1
Z 0 1 I1 I2 SW2
I2 Z
I3 1 0 I2 I3 SW3
S1 S0 S1 S0
1 1 I3
* A multiplexer or data selector (MUX in short) has N Select lines, 2N input lines, and it routes one of the
input lines to the output.
* Conceptually, a MUX may be thought of as 2N switches. For a given combination of the select inputs,
only one of the switches closes (makes contact), and the others are open.
S1 S0 Z
I0
I0 SW0
0 0 I0 I1 SW1
I1
Z 0 1 I1 I2 SW2
I2 Z
I3 1 0 I2 I3 SW3
S1 S0 S1 S0
1 1 I3
* A multiplexer or data selector (MUX in short) has N Select lines, 2N input lines, and it routes one of the
input lines to the output.
* Conceptually, a MUX may be thought of as 2N switches. For a given combination of the select inputs,
only one of the switches closes (makes contact), and the others are open.
* SEQUEL file: mux test 1.sqproj
I0
S1 S0 Z
I0 I1
0 0 I0
I1
Z 0 1 I1 Z
I2 I2
I3 1 0 I2
S1 S0
1 1 I3
I3
S1 S0
I0
S1 S0 Z
I0 I1
0 0 I0
I1
Z 0 1 I1 Z
I2 I2
I3 1 0 I2
S1 S0
1 1 I3
I3
S1 S0
I0
S1 S0 Z
I0 I1
0 0 I0
I1
Z 0 1 I1 Z
I2 I2
I3 1 0 I2
S1 S0
1 1 I3
I3
S1 S0
I0
S1 S0 Z
I0 I1
0 0 I0
I1
Z 0 1 I1 Z
I2 I2
I3 1 0 I2
S1 S0
1 1 I3
I3
S1 S0
S1 S0 Z
I0
0 0 I0
I1
Z 0 1 I1
I2
I3 1 0 I2
1 1 I3
S1 S0
Select inputs are active high.
Active high and active low inputs/outputs
S1 S0 Z
I0
0 0 I0
I1
Z 0 1 I1
I2
I3 1 0 I2
1 1 I3
S1 S0
Select inputs are active high.
S1 S0 Z
I0
1 1 I0
I1
Z 1 0 I1
I2
I3 0 1 I2
0 0 I3
S1 S0
Select inputs are active low.
E E
Active high enable pin Active low enable pin
E E
Active high enable pin Active low enable pin
* Many digital ICs have an “Enable” (E) pin. If the Enable pin is active, the IC functions as desired; else, it
is “disabled,” i.e., the outputs are set to some default values.
E E
Active high enable pin Active low enable pin
* Many digital ICs have an “Enable” (E) pin. If the Enable pin is active, the IC functions as desired; else, it
is “disabled,” i.e., the outputs are set to some default values.
* The Enable pin can be active high or active low.
E E
Active high enable pin Active low enable pin
* Many digital ICs have an “Enable” (E) pin. If the Enable pin is active, the IC functions as desired; else, it
is “disabled,” i.e., the outputs are set to some default values.
* The Enable pin can be active high or active low.
* If the Enable pin is active low, it is denoted by Enable or E. When E = 0, the IC functions normally; else,
it is disabled.
D0 I0 S3 S2 S1 S0 X
D1 I1
D2 I2 0 0 0 0 D0
D3 I3
0 0 0 1 D1
D4 I4 74151 Z X1
D5 I5 0 0 1 0 D2
D6 I6
D7 I7 0 0 1 1 D3
D8 S2 S1 S0
0 1 0 0 D4
D9
D10 E 0 1 0 1 D5
D11
D12 X 0 1 1 0 D6
D13 0 1 1 1 D7
D14
D15 I0 1 0 0 0 D8
I1
1 0 0 1 D9
I2
I3 1 0 1 0 D10
I4 74151 Z X2
I5 1 0 1 1 D11
I6
1 1 0 0 D12
I7
S2 S1 S0 1 1 0 1 D13
E 1 1 1 0 D14
1 1 1 1 D15
A B C X
0 0 0 0 I0
I1
0 0 1 0
I2
0 1 0 D
I3
MUX Z X
0 1 1 0 I4
1 0 0 D I5
I6
1 0 1 0
I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
Implement X = A B C D + A B C D using an 8-to-1 MUX.
A B C X
0 0 0 0 I0
I1
0 0 1 0
I2
0 1 0 D
I3
MUX Z X
0 1 1 0 I4
1 0 0 D I5
I6
1 0 1 0
I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
A B C X
0 0 0 0 I0
I1
0 0 1 0
I2
0 1 0 D
I3
MUX Z X
0 1 1 0 D I4
1 0 0 D I5
I6
1 0 1 0
I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
A B C X
0 0 0 0 I0
I1
0 0 1 0
I2
0 1 0 D
I3
MUX Z X
0 1 1 0 D I4
1 0 0 D I5
I6
1 0 1 0
I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
A B C X
0 0 0 0 I0
I1
0 0 1 0
D I2
0 1 0 D
I3
MUX Z X
0 1 1 0 D I4
1 0 0 D I5
I6
1 0 1 0
I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
A B C X
0 0 0 0 I0
I1
0 0 1 0
D I2
0 1 0 D
I3
MUX Z X
0 1 1 0 D I4
1 0 0 D I5
I6
1 0 1 0
I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
A B C X
0 0 0 0 0 I0
0 I1
0 0 1 0
D I2
0 1 0 D
0 I3
MUX Z X
0 1 1 0 D I4
1 0 0 D 0 I5
0 I6
1 0 1 0
0 I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
A B C X
0 0 0 0 0 I0
0 I1
0 0 1 0
D I2
0 1 0 D
0 I3
MUX Z X
0 1 1 0 D I4
1 0 0 D 0 I5
0 I6
1 0 1 0
0 I7 S2 S1 S0
1 1 0 0
1 1 1 0 A B C
0 1 0 0 0 D I0
0 1 0 1 0 I1
I2
0 1 1 0 0
I3
0 1 1 1 1 MUX Z X
I4
1 0 0 0 1 I5
1 0 0 1 0 I6
I7 S2 S1 S0
1 0 1 0 1
1 0 1 1 1
A B C
1 1 0 0 0
1 1 0 1 0
1 1 1 0 0
1 1 1 1 0
A B C D X
Implement the function X using an 8-to-1 MUX.
0 0 0 0 1
0 0 0 1 0 * When ABC = 000, X = D → I0 = D.
0 0 1 0 1 * When ABC = 001, X = 1 → I1 = 1,
0 0 1 1 1 and so on.
0 1 0 0 0 D I0
0 1 0 1 0 1 I1
I2
0 1 1 0 0
I3
0 1 1 1 1 MUX Z X
I4
1 0 0 0 1 I5
1 0 0 1 0 I6
I7 S2 S1 S0
1 0 1 0 1
1 0 1 1 1
A B C
1 1 0 0 0
1 1 0 1 0
1 1 1 0 0
1 1 1 1 0
A B C D X
Implement the function X using an 8-to-1 MUX.
0 0 0 0 1
0 0 0 1 0 * When ABC = 000, X = D → I0 = D.
0 0 1 0 1 * When ABC = 001, X = 1 → I1 = 1,
0 0 1 1 1 and so on.
0 1 0 0 0 D I0
0 1 0 1 0 1 I1
0 I2
0 1 1 0 0
D I3
0 1 1 1 1 MUX Z X
D I4
1 0 0 0 1 1 I5
1 0 0 1 0 0 I6
0 I7 S2 S1 S0
1 0 1 0 1
1 0 1 1 1
A B C
1 1 0 0 0
1 1 0 1 0
1 1 1 0 0
1 1 1 1 0
A B C D X
Implement the function X using an 8-to-1 MUX.
0 0 0 0 1
0 0 0 1 0 * When ABC = 000, X = D → I0 = D.
0 0 1 0 1 * When ABC = 001, X = 1 → I1 = 1,
0 0 1 1 1 and so on.
S2 S1 S0 O0 O1 O2 O3 O4 O5 O6 O7
0 0 0 I 0 0 0 0 0 0 0 O0
0 0 1 0 I 0 0 0 0 0 0 O1
0 1 0 0 0 I 0 0 0 0 0 O2
O3
0 1 1 0 0 0 I 0 0 0 0 I DEMUX
O4
1 0 0 0 0 0 0 I 0 0 0 O5
1 0 1 0 0 0 0 0 I 0 0 O6
1 1 0 0 0 0 0 0 0 I 0 S2 S1 S0 O7
1 1 1 0 0 0 0 0 0 0 I
S2 S1 S0 O0 O1 O2 O3 O4 O5 O6 O7
0 0 0 I 0 0 0 0 0 0 0 O0
0 0 1 0 I 0 0 0 0 0 0 O1
0 1 0 0 0 I 0 0 0 0 0 O2
O3
0 1 1 0 0 0 I 0 0 0 0 I DEMUX
O4
1 0 0 0 0 0 0 I 0 0 0 O5
1 0 1 0 0 0 0 0 I 0 0 O6
1 1 0 0 0 0 0 0 0 I 0 S2 S1 S0 O7
1 1 1 0 0 0 0 0 0 0 I
* A demultiplexer takes a single input (I) and routes it to one of the output lines (O0, O1,· · · ).
S2 S1 S0 O0 O1 O2 O3 O4 O5 O6 O7
0 0 0 I 0 0 0 0 0 0 0 O0
0 0 1 0 I 0 0 0 0 0 0 O1
0 1 0 0 0 I 0 0 0 0 0 O2
O3
0 1 1 0 0 0 I 0 0 0 0 I DEMUX
O4
1 0 0 0 0 0 0 I 0 0 0 O5
1 0 1 0 0 0 0 0 I 0 0 O6
1 1 0 0 0 0 0 0 0 I 0 S2 S1 S0 O7
1 1 1 0 0 0 0 0 0 0 I
* A demultiplexer takes a single input (I) and routes it to one of the output lines (O0, O1,· · · ).
* For N Select inputs (S0, S1,· · · ), the number of output lines is 2N .
S2 S1 S0 O0 O1 O2 O3 O4 O5 O6 O7
0 0 0 I 0 0 0 0 0 0 0 O0
0 0 1 0 I 0 0 0 0 0 0 O1
0 1 0 0 0 I 0 0 0 0 0 O2
O3
0 1 1 0 0 0 I 0 0 0 0 I DEMUX
O4
1 0 0 0 0 0 0 I 0 0 0 O5
1 0 1 0 0 0 0 0 I 0 0 O6
1 1 0 0 0 0 0 0 0 I 0 S2 S1 S0 O7
1 1 1 0 0 0 0 0 0 0 I
* A demultiplexer takes a single input (I) and routes it to one of the output lines (O0, O1,· · · ).
* For N Select inputs (S0, S1,· · · ), the number of output lines is 2N .
* SEQUEL file: demux test 1.sqproj
O1
O2
O0
O1
O2 O3
O3
I DEMUX
O4 O4
O5
O6 O5
S2 S1 S0 O7
O6
O7
A0 O0
A1 O1
N inputs Decoder M outputs
AN−1 OM−1
A0 O0
A1 O1
N inputs Decoder M outputs
AN−1 OM−1
* For each input combination, an associated bit pattern appears at the output.
A2 A1 A0 O0 O1 O2 O3 O4 O5 O6 O7
0 0 0 1 0 0 0 0 0 0 0
O0
O1 0 0 1 0 1 0 0 0 0 0 0
O2 0 1 0 0 0 1 0 0 0 0 0
A0
O3
A1 Decoder 0 1 1 0 0 0 1 0 0 0 0
O4
A2 1 0 0 0 0 0 0 1 0 0 0
O5
O6 1 0 1 0 0 0 0 0 1 0 0
O7 1 1 0 0 0 0 0 0 0 1 0
1 1 1 0 0 0 0 0 0 0 1
* Example:
Decimal 75
* Example:
Decimal 75
Binary 1001011
* Example:
Decimal 75
Binary 1001011
BCD 0111 0101
* Example:
Decimal 75
Binary 1001011
BCD 0111 0101
* BCD coding is commonly used to display numbers in electronic systems.
* Example:
Decimal 75
Binary 1001011
BCD 0111 0101
* BCD coding is commonly used to display numbers in electronic systems.
BCD 0111 0101
input
BCD−to−7−seg
decoder
7−segment
display
* Example:
Decimal 75
Binary 1001011
BCD 0111 0101
* BCD coding is commonly used to display numbers in electronic systems.
BCD 0111 0101
input
BCD−to−7−seg
decoder
7−segment
display
* In some electronic systems (e.g., calculators), all computations are performed in BCD.
VCC
a
common
a anode
b
f b
c
e g
f e c
0000 0001 0010 0011 0100 0101 0110 0111 1000 1001
M. B. Patil, IIT Bombay
BCD-to-7 segment decoder
VCC
a
a common
anode
MSB b
D c f b
C d
7446
B e g
A f
LSB e c
g
0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111
M. B. Patil, IIT Bombay
BCD-to-7 segment decoder
VCC
a
a common
* The resistors serve to limit the diode
anode
b current. For VCC = 5 V , VD = 2 V , and
MSB
ID = 10 mA, R = 300 Ω.
D c f b
C d
7446
B e g
A f
LSB e c
g
0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111
M. B. Patil, IIT Bombay
BCD-to-7 segment decoder
VCC
a
a common
* The resistors serve to limit the diode
anode
b current. For VCC = 5 V , VD = 2 V , and
MSB
ID = 10 mA, R = 300 Ω.
D c f b * Home work: Write the truth table for
C d c (in terms of D, C , B, A). Obtain a
7446 minimized expression for c using a K
B e map.
g
A f
LSB e c
g
0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111
M. B. Patil, IIT Bombay
BCD-to-decimal decoder
A3 A2 A1 A0 Active output
0 0 0 0 O0
0 0 0 1 O1
0 0 1 0 O2
O0 0 0 1 1 O3
O1 0 1 0 0 O4
O2
A0 0 1 0 1 O5
O3
A1 0 1 1 0 O6
7442 O4
A2
O5 0 1 1 1 O7
A3
O6 1 0 0 0 O8
O7
1 0 0 1 O9
O8
1 0 1 0 none
O9
1 0 1 1 none
1 1 0 0 none
1 1 0 1 none
1 1 1 0 none
1 1 1 1 none
M. B. Patil, IIT Bombay
BCD-to-decimal decoder
A3 A2 A1 A0 Active output
0 0 0 0 O0
0 0 0 1 O1
0 0 1 0 O2
O0 0 0 1 1 O3
O1 0 1 0 0 O4
O2
A0 0 1 0 1 O5
O3
A1 0 1 1 0 O6
7442 O4
A2
O5 0 1 1 1 O7
A3
O6 1 0 0 0 O8
O7
1 0 0 1 O9
O8
1 0 1 0 none
O9
1 0 1 1 none
1 1 0 0 none
1 1 0 1 none
1 1 1 0 none
1 1 1 1 none
M. B. Patil, IIT Bombay
Encoders
A0 O0
A1 O1
M inputs Encoder N outputs
AM−1 ON−1
A0 O0
A1 O1
M inputs Encoder N outputs
AM−1 ON−1
* Only one input line is assumed to be active. The binary number corresponding to the active input line
appears at the output pins.
A0 O0
A1 O1
M inputs Encoder N outputs
AM−1 ON−1
* Only one input line is assumed to be active. The binary number corresponding to the active input line
appears at the output pins.
* The N output lines can represent 2N binary numbers, each corresponding to one of the M input lines, i.e.,
we can have M = 2N . Some encoders have M < 2N .
A0 O0
A1 O1
M inputs Encoder N outputs
AM−1 ON−1
* Only one input line is assumed to be active. The binary number corresponding to the active input line
appears at the output pins.
* The N output lines can represent 2N binary numbers, each corresponding to one of the M input lines, i.e.,
we can have M = 2N . Some encoders have M < 2N .
* As an example, for N = 3, we can have a maximum of 23 = 8 input lines.
A1 A2 A3 A4 A5 A6 A7 A8 A9 O3 O2 O1 O0
1 1 1 1 1 1 1 1 1 1 1 1 1
A1 X X X X X X X X 0 0 1 1 0
A2
X X X X X X X 0 1 0 1 1 1
A3
O0 X X X X X X 0 1 1 1 0 0 0
A4
O1 X X X X X 0 1 1 1 1 0 0 1
A5 74147
O2
A6 X X X X 0 1 1 1 1 1 0 1 0
O3
A7
X X X 0 1 1 1 1 1 1 0 1 1
A8
X X 0 1 1 1 1 1 1 1 1 0 0
A9
X 0 1 1 1 1 1 1 1 1 1 0 1
0 1 1 1 1 1 1 1 1 1 1 1 0
A1 A2 A3 A4 A5 A6 A7 A8 A9 O3 O2 O1 O0
1 1 1 1 1 1 1 1 1 1 1 1 1
A1 X X X X X X X X 0 0 1 1 0
A2
X X X X X X X 0 1 0 1 1 1
A3
O0 X X X X X X 0 1 1 1 0 0 0
A4
O1 X X X X X 0 1 1 1 1 0 0 1
A5 74147
O2
A6 X X X X 0 1 1 1 1 1 0 1 0
O3
A7
X X X 0 1 1 1 1 1 1 0 1 1
A8
X X 0 1 1 1 1 1 1 1 1 0 0
A9
X 0 1 1 1 1 1 1 1 1 1 0 1
0 1 1 1 1 1 1 1 1 1 1 1 0
* Note that the higher input lines get priority over the lower ones.
For example, A7 gets priority over A1 , A2 , A3 , A4 , A5 , A6 . If A7 is active (low), the binary output is 1000
(i.e., 0111 inverted bit-by-bit) which corresponds to decimal 7, irrespective of
A1 , A2 , A3 , A4 , A5 , A6 .
A1 A2 A3 A4 A5 A6 A7 A8 A9 O3 O2 O1 O0
1 1 1 1 1 1 1 1 1 1 1 1 1
A1 X X X X X X X X 0 0 1 1 0
A2
X X X X X X X 0 1 0 1 1 1
A3
O0 X X X X X X 0 1 1 1 0 0 0
A4
O1 X X X X X 0 1 1 1 1 0 0 1
A5 74147
O2
A6 X X X X 0 1 1 1 1 1 0 1 0
O3
A7
X X X 0 1 1 1 1 1 1 0 1 1
A8
X X 0 1 1 1 1 1 1 1 1 0 0
A9
X 0 1 1 1 1 1 1 1 1 1 0 1
0 1 1 1 1 1 1 1 1 1 1 1 0
* Note that the higher input lines get priority over the lower ones.
For example, A7 gets priority over A1 , A2 , A3 , A4 , A5 , A6 . If A7 is active (low), the binary output is 1000
(i.e., 0111 inverted bit-by-bit) which corresponds to decimal 7, irrespective of
A1 , A2 , A3 , A4 , A5 , A6 .
* The lower input lines are therefore shown as “don’t care” (X) conditions.
M. B. Patil, IIT Bombay