Tutorial2

CompSci 210 - Semester One 2017
𝑨
CompSci 210 - Semester One 2017
𝑩
𝑩𝑨
𝑩 + 𝑩𝑨
𝑨
𝑩
0
0
0
1
1
0
1
1
𝑩𝑨
𝐡 + 𝐡𝐴
CompSci 210 - Semester One 2017
𝑩 + 𝑩𝑨
𝑨
𝑩
𝑩𝑨
0
0
0
0
1
0
1
0
0
1
1
1
𝐡 + 𝐡𝐴
CompSci 210 - Semester One 2017
𝑩 + 𝑩𝑨
𝑨
𝑩
𝑩𝑨
𝑩 + 𝑩𝑨
0
0
0
0
0
1
0
1
1
0
0
0
1
1
1
1
𝐡 + 𝐡𝐴
CompSci 210 - Semester One 2017
𝑨
𝑩
𝑩𝑨
𝑩 + 𝑩𝑨
0
0
0
0
0
1
0
1
1
0
0
0
1
1
1
1
𝐡 + 𝐡𝐴
CompSci 210 - Semester One 2017
A.
B.
C.
CompSci 210 - Semester One 2017
β€’
β€’
β€’
NOT
AND
OR
β€’
NAND
β€’
NOR
β€’
XOR
𝐴
𝐴
𝐴
𝐴𝐡
𝐡
𝐴
𝐴+𝐡
𝐡
𝐴
𝐡
𝐴𝐡
𝐴
𝐴+𝐡
𝐡
𝐴
𝐴⨁𝐡
𝐡
CompSci 210 - Semester One 2017
β€’
β€’
ALL
ANY
𝐴
𝐡
𝐢
𝐴
𝐡
𝐢
𝐴𝐡𝐢
𝐴+𝐡+𝐢
NAND Gate
NOT-AND
X
W
X
Z
Z
Y
Y
W =
_ X.Y
____
Z = W = X.Y
X
0
0
1
1
Y
0
1
0
1
NAND
____
Z = X.Y
nand(Z,X,Y)
Z
1
1
1
0
9
NOR Gate
NOR
NOT-OR
X
W
Y
X
Z
Y
_______
W = X + Y
_
Z
Z = (X + Y)
nor(Z,X,Y)
_______
Z = W = (X + Y)
X
0
0
1
1
Y
0
1
0
1
Z
1
0
0
0
10
β€’
x
y
CompSci 210 - Semester One 2017
β€’
x
y
CompSci 210 - Semester One 2017
π‘₯+𝑦
β€’
x
y
π‘₯+𝑦
𝑦
CompSci 210 - Semester One 2017
β€’
x
y
π‘₯+𝑦
π‘₯+𝑦 𝑦
𝑦
CompSci 210 - Semester One 2017
β€’
x
y
CompSci 210 - Semester One 2017
β€’
x
π‘₯
y
𝑦
CompSci 210 - Semester One 2017
β€’
x
π‘₯
y
𝑦
CompSci 210 - Semester One 2017
π‘₯⋅𝑦
β€’
x
y
CompSci 210 - Semester One 2017
π‘₯
π‘₯⋅𝑦
𝑦
π‘₯⋅𝑦
β€’
CompSci 210 - Semester One 2017
β€’
π‘₯
x
y
CompSci 210 - Semester One 2017
𝑦
β€’
π‘₯
x
y
CompSci 210 - Semester One 2017
β€’
π‘₯+𝑦
x
y
CompSci 210 - Semester One 2017
β€’
CompSci 210 - Semester One 2017
β€’
π‘₯
CompSci 210 - Semester One 2017
𝑦
π‘₯
β€’
π‘₯+𝑦
CompSci 210 - Semester One 2017
β€’
π‘₯+𝑦
CompSci 210 - Semester One 2017
β€’
π‘₯+𝑦 β‹…
CompSci 210 - Semester One 2017
β€’
π‘₯+𝑦 β‹…π‘₯
CompSci 210 - Semester One 2017
β€’
CompSci 210 - Semester One 2017
CompSci 210 - Semester One 2017
𝑨
CompSci 210 - Semester One 2017
𝑩
0
0
0
1
1
0
1
1
𝑨
CompSci 210 - Semester One 2017
𝑩
𝑨
0
0
1
0
1
1
1
0
0
1
1
0
𝑨
CompSci 210 - Semester One 2017
𝑩
𝑨
𝑨𝑩
0
0
1
0
0
1
1
1
1
0
0
0
1
1
0
0
𝑨
CompSci 210 - Semester One 2017
𝑩
𝑨
𝑨𝑩
𝑨 + 𝑨𝑩
0
0
1
0
0
0
1
1
1
1
1
0
0
0
1
1
1
0
0
1
𝑨
CompSci 210 - Semester One 2017
𝑩
𝑨
𝑨𝑩
𝑨 + 𝑨𝑩
0
0
1
0
0
0
1
1
1
1
1
0
0
0
1
1
1
0
0
1
β€’
CompSci 210 - Semester One 2017
𝑨
𝑩
π‘ͺ
0
0
0
0
0
1
0
1
0
0
1
1
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
1
0
1
0
1
0
0
1
1
1
1
0
1
0
1
1
0
1
1
1
1
0
0
0
0
0
0
CompSci 210 - Semester One 2017
𝑨
𝑩
π‘ͺ
𝑩
π‘ͺ
𝑨𝑩π‘ͺ π‘ͺ𝑩
𝑩𝑨
𝑨𝑩π‘ͺ + π‘ͺ𝑩 + 𝑩𝑨
0
0
0
1
1
0
0
0
0
0
0
1
0
1
0
0
0
0
0
1
0
1
0
0
1
0
1
0
1
1
0
0
0
0
0
0
1
0
0
1
1
0
0
1
1
1
0
1
0
1
0
0
1
1
1
1
0
1
0
1
1
0
1
1
1
1
0
0
0
0
0
0
CompSci 210 - Semester One 2017
β€’
CompSci 210 - Semester One 2017
De Morgan’s Theorem
β€’ NOT all variables
β€’ Change . to + and + to .
β€’ NOT the result_______
______
_______
__ __
(X . Y) =
(X + Y) = X + Y
__ __
β€’ -------------------------------------------__________
(X + Y) =
__
__
__
X . Y
__
X+Y=
46
β€’
x
y
CompSci 210 - Semester One 2017
π‘₯
π‘₯⋅𝑦
𝑦
π‘₯⋅𝑦
β€’
x
y
CompSci 210 - Semester One 2017
π‘₯
π‘₯⋅𝑦
𝑦
π‘₯+𝑦
β€’
x
y
CompSci 210 - Semester One 2017
π‘₯
π‘₯⋅𝑦
𝑦
π‘₯+𝑦
Latches
β€’ The SR Latch (NOR)
– Consider the following circuit
R
Q
R
R
Q
Q
S
S
Q
Q
Q
S
Symbol
Circuit
R
0
0
1
1
S
1
0
1
Qn+1
Qn (HOLD)
1
0
?
Function Table
n+1 represents
output at some future
time
n represents current
output.
50
Latches
β€’ The SR Latch(NAND)
– NAND Form produces similar result from inverted inputs
R
Q
R
R
Q
Q
S
Q
S
S
Q
Q
Circuit
Symbol
R
0
0
1
1
S Qn+1
0
?
1
0
0
1
1
Qn
Function Table
You ought to be able to figure this one out
yourself!
51