You are on page 1of 14

LESSON 4

Analysing logic gates

Common terminology of logic gates

NOT gate

Logic gate

An electronic circuit with a


single output and one or more
inputs .

The symbol of for a NOT gate is:

Truth table

A table that summarises all the


possible input and output of a
logic gate.

The Boolean algebraic is:

A form of symbolic logic which


provides a mathematical
procedure for manipulating
logical relationships in symbolic
form.

The truth table is:

Boolean algebraic:

Input
A
0
1

Number of possibilities inputs and outputs..


N = 2n
N = number of outputs
n = number of inputs

Output
X
1
0

An equivalent circuit to a NOT gate:

Types of logic gates


There are seven types of logic gates:
(a) NOT gate
(b) AND gate
(c) OR gate
(d) NAND gate
(e) NOR gate
Input
A
Switch off
Switch on

38

Output
X
Lights up
Goes off

AND gate

OR gate

The symbol of for an AND gate is:

The symbol of for an OR gate is:

The Boolean algebraic is:

The Boolean algebraic is:

The truth table is:

The truth table is:

Input
A
0
0
1
1

B
0
1
0
1

Output
X
0
0
0
1

Input
A
0
0
1
1

An equivalent circuit to an AND gate:

Input
A
B
Switch off Switch off
Switch off Switch on
Switch on Switch off
Switch on Switch on

Output
X
0
1
1
1

B
0
1
0
1

An equivalent circuit to an OR gate:

Output
X
Goes off
Goes off
Goes off
Lights up

Input
A
Switch off
Switch off
Switch on
Switch on

39

B
Switch off
Switch on
Switch off
Switch on

Output
X
Goes off
Lights up
Lights up
Lights up

NAND gate

Example 1

The symbol of for an NAND gate is:

The figure shows a logic gate with inputs P and Q.

If the input P = 0011010 and the input S = 1100011 ,


what is the output X?

The Boolean algebraic is:

Solution
Example 2
The truth table is:
Input
A
0
0
1
1

B
0
1
0
1

The diagram shows two signals are connected to the


inputs A and B of an OR gate.

Output
X
1
1
1
0

Draw the output signal X.

NOR gate

Solution

The symbol of for an NOR gate is:

The Boolean algebraic is:


Example 3
Work out the truth for the combination of logic gates in
figure below.
The truth table is:
Input
A
0
0
1
1

B
0
1
0
1

Output
X
1
0
0
0

Solution

40

Applications of Logic Gates in Control Systems


(1) Automatic Fan for cooling system
Input
Smoke
Heat
detector
detector
0
0
0
1
1
0
1
1
Light
Detector
0
0
1
1

Temperature
Detector
0
1
0
1

(4) Automatic Heater

Fan
0
0
0
1

(2) Fire Alarm system


Switch

Smoke
Detector
0
0
1
1

Heat
Detector
0
1
0
1

Output
Fire
Fire
extinguisher
Alarm
0
0
0
1
0
1
1
1

0
1
0
1
0
1
0
1

Siren
Not activated
Activated
Activated
Activated

Input
Temperature
detector
0
0
0
0
1
1
1
1

Output
Light
detector
0
0
1
1
0
0
1
1

1
0
0
1
0
1
0
1

(5) Control system for street lights

(3) Fire Control system

Input
Switch
0
0
1
1

41

Light sensor
0
1
0
1

Output
Street light
1
0
1
1

TUTORIAL 4
1

What is the possible number of outputs of a


logic gate which has five inputs?
A
C
E

10
25
64

B
D

16
32

The diagram shows an electric circuit.

M
0
1
0
1
A
C

Which of the following symbol is equivalent to


the circuit above?

The diagram shows a logic gate G whose truth


table is a shown in the table below.

X
0
0
0
1
B
D

OR gate
NOR gate

The circuit represents a Boolean algebraic


principle with output Z.

Which of the Boolean algebraic expression


represents the output Z?
__
A Z=X Y
B Z=X Y
__
_____
C Z=X Y
D Z=X Y

The diagram shows an electric circuit.

6
Which of the following logic gate is equivalent to
the circuit above?
A
B
C
D

AND gate
NAND gate

N
0
0
1
1

AND gate
OR gate
NAND gate
NOR gate

42

Which of the following is equivalent to a NOT


gate?

The diagram shows a circuit containing three


logic gates.

10

A NOR gate with input signals M = 01010101


and N = 011010100 . What is the output signal
of the logic gate.
A
C

11
Which of the following logic gate is equivalent to
the circuit above?
A
C
8

OR gate
NOT gate

B
D

If the input signals P and Q are respectively


1001 and 1100 what is the output signal at X?

12

The truth table for the combination of three logic


gates is as follows.
Input
Output
P
Q
R
0
0
1
0
1
1
1
0
1
1
1
0

OR
NOR

The diagram shows a circuit containing four


NAND gates.

Which of the following logic gate is equivalent to


the circuit above?
A
C

OR gate
NOR gate

B
D

0001
1010

B
D

0010
1110

The diagram shows a logic gates circuit.

Which of the following truth table represents


output R in the circuit?

What is the gate X?


B
D

10000010
01000000

The diagram shows a circuit containing three


logic gates.

A
C

AND
NAND

B
D

AND gate
NAND gate

The diagram shows the combination three logic


gates.

A
C

01010101
01111101

AND gate
NAND gate

43

A P
0
0
1
1

Q
0
1
0
1

R
1
0
1
0

P
0
0
1
1

Q
0
1
0
1

R
0
1
0
1

C P
0
0
1
1

Q
0
1
0
1

R
0
1
0
0

P
0
0
1
1

Q
0
1
0
1

R
0
1
1
0

13

The diagram shows a combination of three logic


gates.

15

Which of the following is the correct truth table


for output R?

Which truth table is correct for the combination


of three logic gates?

14

A P
0
1
0
1

Q
0
0
1
1

R
1
1
1
1

C P
0
1
0
1

Q
0
0
1
1

R
0
0
0
0

P
0
1
0
1

Q
0
0
1
1

R
0
0
1
0

P
0
1
0
1

Q
0
0
1
1

R
1
1
0
1

The diagram shows a circuit containing two logic


gates.

16

P
0
0
1
1

Q
0
1
0
1

R
0
0
0
1

P
0
0
1
1

Q
0
1
0
1

R
0
1
0
0

P
0
0
1
1

Q
0
1
0
1

R
0
0
1
0

X
0
0
1
1

Y
0
1
0
1

Q
1
0
0
0

The diagram shows a circuit containing three


logic gates.

The diagram shows the combination of four logic


gates.

Which of the following is the correct truth table


for output R?
Which of the following is the correct truth table
for output X?
A X
0
0
1
1

Y
0
1
0
1

Q
0
1
1
0

C X
0
0
1
1

Y
0
1
0
1

Q
1
0
0
1

X
0
0
1
1

Y
0
1
0
1

Q
1
1
1
0

X
0
0
1
1

Y
0
1
0
1

Q
0
1
1
1

44

A P
0
0
1
1

Q
0
1
0
1

R
0
1
1
1

P
0
0
1
1

Q
0
1
0
1

R
1
0
1
1

C P
0
0
1
1

Q
0
1
0
1

R
1
0
1
0

X
0
0
1
1

Y
0
1
0
1

Q
1
0
0
1

17

The diagram shows the combination of AND


gate , OR gate and NOT gate.

19

The figure shows a OR gate with input signals P


and Q.

Which of the following is the correct truth table


for output C?

18

A A
0
0
1
1

B
0
1
0
1

C
0
0
0
0

C A
0
0
1
1

B
0
1
0
1

C
0
1
0
1

A
0
0
1
1

B
0
1
0
1

C
1
1
1
1

A
0
0
1
1

B
0
1
0
1

C
1
0
1
0

Which of the following is the output signal of the


OR gate?

The table shows a truth table for a combination


of logic gates.
P Q R
0 0 1
0 1 0
1 0 0
1 1 0
Which of the following is true to show a circuit
according to the truth table above?

20

The figure shows a OR gate with input signals P


and Q.

Which of the following is the output signal


of the OR gate?

45

22 (a) The diagram shows a logic gate ,L with


input signals A and B.

21

The diagram shows a logic gate circuit with input


signals, K and L.
(i)

Name the logic gate L.

(ii)

..
Draw the output signal C in the graph
below.

Which of the following output signals is


produced by the logic gate circuit?
(c)

Later , logic gate L is connected to logic


gates M and N as shown in the diagram
below.

(i)

Complete the truth table below.


X
0
0
1
1

46

Y
0

Z
1
1

(ii)

23

State the Boolean algebraic to relate


X, Y and Z.

(iii) Give two methods to open the door


and the gate simultaneously.

..........................................................
The diagram shows a circuit is used as a safety
system in a house.

............................................................
............................................................
............................................................
24

............................................................
(a) Figure shows a circuit made up from a
combination of a few basic logic gates.

(a) Name logic gate R.


.............................................................................
(b) Using two switches , two dry cells and a
bulb draw a circuit that equivalent to logic
gate S.

Figure (a)
(i)

Based on the arrangement of the


logic gates in the Figure (a) complete
the truth table below.
Input

(c)

K
0
0
1
1

The following truth table represents the


logic gate in the figure above.
A
B L
M
0
0
0
1
1
0
1
1
(i)

(ii)

Output
M

State a single logic gate which


produced the same output as the
output in (a)(i).

..
(b) Figure(b) shows a circuit diagram of a
vending machine . The vending machine
accepts 10 sen coins, 20 sen coins and 50
sen coins. Three light dependent resistors
(LDR) , X , Y and Z are used to check the
size of coins slotted in the machine. The
light sources of the slot machine where the
coins are slotted are as shown in Figure
(c).

Complete the truth table above.

(ii) State the Boolean algebraic to relate


L, A and B.
(ii)

L
0
1
0
1

............................................................
What happen to door and the gate
when the main switch is closed?
............................................................
............................................................
47

25

The diagram shows a logic gate system is used


in a factory to ensure the volume of paint in
containers is within the predetermined range.

The operation of the system is shown in the


truth table below.

Figure (b)

Volume
of the
paint
less
in the
range
exceed

Figure (c)
(i)

Complete the truth table in the table below.

State of LDR
X
Y

Z
No
coin
10
sen
20
sen Bright Dark Dark
50
sen
(ii)

Input
K
L

(a) (i)

Output
S

(ii)

Input X

Input Y

Output Z

1
1

Name the detector used.


..
Explain why input X is 0 when the
volume of the paint exceed.

1
(b) (i)

Name the gate that is probably in the black


box.

..
Using two NOT gates and an AND
gate, draw a circuit to represent the
truth table above.

(ii)

State the Boolean algebraic to relate


X, Y and Z.

48

26
Ali wishes to design a
security system in his
house as shown in Figure (a). When a person
crosses the infrared beam at night, the infrared
sensor will send a signal to a logic gate which
then lights up a spotlight. The spotlight has a
240 V alternating current (a.c.) supply and will
only light up at night.

(ii)

..
Why is component S necessary in the
circuit?
..
..
..

..
(d) The following truth table shows the
operation of a logic gate in the circuit in
Figure (b).
Key:

Figure (a)
The circuit that could help Ali to develop the
security system is shown in Figure (b).

Figure (b)
(a) If the potential difference across resistor W
is 2V, what is the potential difference
across the infrared sensor?

Dark
surroundings

high input
voltage at P

logic1

Bright
surroundings

low input
voltage at P

logic0

Person
crossing
the path

high input
voltage at Q

logic1

Nobody
crossing
the path

low input
voltage at Q

logic0

Switch S
is ON

high input
voltage at R

logic1

Switch S
is OFF

low input
voltage at R

logic0

Input P
Output Q
Surroundings Input
Person
Input Output
R
voltage crossing voltage
at P
at Q
Bright
0
No
0
Bright
Yes
Dark
No
Dark
Yes
(i) Using the given key, complete the
truth table above.
(ii) Name the logic gate in the
circuit in Figure (a).

.
(b) Component X has a high resistance when
the surroundings are dark and a low
resistance in bright surroundings.
Name the component X.
.
(c) Component S is a switch that connects the
240 V a.c. spotlight circuit.
(i)
What type of switch is component S?

49

.
(iii) Sketch the symbol of the logic
gate in (d) (ii).

27

(c) The door of the lift is fitted with a light


transmitter and a detector which is a light
dependent resistor.
If the light dependent resistor detects light,
the relay switch is activated and the lift
door will close.
Figure (b) shows an electronic circuit for
the control system of the lift door.

A student wants to build s simple lift motor


control system which operates using two
buttons, A and B, for a two-storey building.
A:
B:

Up button
Down button

The lift motor only activates when someone


presses any one of the buttons.
Figure (a) shows the circuit that can be used to
activate the motor.

(i)

Figure (b)
State the relationship between the
resistance and the intensity of light
received by the light dependent
resistor.
.

Figure (a)
Keys:

(ii)

Buttons A and B: When pressed, logic 1


Not pressed,
logic 0
X Output
: Motor is activated,logic 1

..
Complete the circuit in Figure (b), by
drawing the resistor and the light
dependent resistor using the symbols
given below.

(a) The table is a truth table which shows the


operations of the logic gates in a lift motor.
Using the keys given, complete the table.
A
0
0
1
1

B
0
1
0
1

(iii) Explain how the circuit functions.


..

(b) Why is a relay switch needed in the circuit?

..

..

50

..

51

You might also like