Documente Academic
Documente Profesional
Documente Cultură
BOOLEAN ALGEBRA
O/L ICT
A/L GIT
Logic generally has only 2 states, ON or The AND gate will only switch on its output Q,
OFF, represented by 1 or 0. Logic gates if Input A is ON and Input B is ON. This can be
react to inputs in certain ways. shown in a Truth Table, 0=OFF and 1=ON.
A B Q
INPUT A 0 0 0
OUTPUT Q 0 1 0
INPUT B
1 0 0
1 1 1
Symbol for AND gate
Logic can be used to control devices according to certain conditions, such as “switch on a fan if it’s hot
AND the sun is out”. Look at the diagrams below.
AND gate
The AND gate is an electronic circuit that gives a high output (1) only if all its inputs
are high. A dot (.) is used to show the AND operation
i.e. A.B.
Bear in mind that this dot is sometimes omitted
i.e. AB
A
Logic Gate: A*B Truth Table:
B
A B A*B
0 0 0
0 1 0
A B 1 0 0
Series Circuit: 1 1 1
A*B
A
Logic Gate: A+B Truth Table:
B
A B A+B
A
0 0 0
0 1 1
1 0 1
Parallel Circuit: 1 1 1
B
A+B
AND OR
A XOR
A A
Q Q Q
B B B
A B Q A B Q A B Q
0 0 0 0 0 0
0 1 0 1 0 1
1 0 1 0 1 0
1 1 1 1 1 1
A B Q A B Q A Q
0 0 0 0 0
0 1 0 1 1
1 0 1 0
1 1 1 1
A B Q A B Q A B Q
0 0 0 0 0 0 0 0 0
0 1 0 0 1 1 0 1 1
1 0 0 1 0 1 1 0 1
1 1 1 1 1 1 1 1 0
A B Q A B Q A Q
0 0 1 0 0 1 0 1
0 1 1 0 1 0 1 0
1 0 1 1 0 0
1 1 0 1 1 0
Dasun Nilanjana (BIT-HDIT,MIEEE)
n-b it In p u t s
Fo r c o n ve n ie n c e , it is s o m e t im e s u s e fu l t o
t h in k o f t h e lo g ic g a t e s p ro c e s s in g n-b it s a t
a t im e . Th is re a lly re fe rs t o n in s t a n c e s o f
t h e lo g ic g a t e , n o t a s in g le lo g ic d a t e wit h n-
in p u t s .
1101100101
1101110111
0100110111
10001111
00001100
00111100
110001 001110
NAND
e q u iva le n t s :
He re a re t h e
NOR
e q u iva le n t s :
NAND a n d NOR
ca n be use d to
re d u c e t h e
num be r of
re q u ire d g a t e s
in a c irc u it .
e xp re s s io n
Ho w t o in t e rp re t A B+ C?
Is it AB ORed with C ?
Is it A ANDed with B+C ?
Order of precedence for Boolean algebra: AND
before OR. Parentheses make the expression
clearer, but they are not needed for the case on
the preceding slide.
Firs t , p e rfo rm a ll in ve rs io n s o f s in g le
t e rm s
Pe rfo rm a ll o p e ra t io n s wit h p a re t h e s e s
o p e ra t io n u n le s s p a re n t h e s e s in d ic a t e
o t h e rwis e
If a n e xp re s s io n h a s a b a r o ve r it ,
p e rfo rm t h e o p e ra t io n s in s id e t h e
e xp re s s io n firs t a n d t h e n in ve rt t h e
re s u lt
Dasun Nilanjana (BIT-HDIT,MIEEE)
3-8 Implementing Circuits
From Boolean Expressions
Wh e n t h e o p e ra t io n o f a c irc u it is
d e fin e d b y a Bo o le a n e xp re s s io n , we
c a n draw a logic-circuit d ia g ra m d ire c t ly
from that expression.
Dra w t h e c irc u it d ia g ra m t o im p le m e n t
t h e e xp re s s io n
x =( A +B )( B +C)
26