PWC Kinematics Updated WS
PWC Kinematics Updated WS
Syllabus 2023-2025
44
BOOLEAN LOGIC
STANDARD LOGIC GATE SYMBOLS
LOGIC GATES
TRUTH TABLES
Truth tables are used to trace the output from a logic gate or logic circuit. The NOT gate is the
only logic gate with one input; the other five gates have two inputs.
When constructing truth tables all possible combinations of 1s and 0s which can be input are
considered. For the Not Gate (one input) there are only 21 = 2 possible binary combinations.
Although each logic gate can only have one or two inputs, the number of inputs to a logic
circuit can be more than 2; for example, three inputs give a possible 23 = 8 binary
combinations. And for four inputs, the number of possible binary combinations is 24 = 16. It is
clear that the number of possible binary combinations is a multiple of the number 2 in every
case. The possible inputs in a truth table can be summarized as shown:
45
FUNCTIONS OF THE SIX LOGIC GATES
NOT GATE
AND GATE
46
OR GATE
47
XOR GATE
When logic gates are combined together to carry out a particular function, such as controlling
a robot, they form a logic circuit. The output from the logic circuit is checked using a truth table.
Following 8 examples show how to carry out the task
48
EXAMPLE 1
Produce a truth table for the following logic circuit [note the use of black circles at the junctions
between wires.
There are three inputs to this logic circuit, therefore, there will be eight possible binary values
that can be input. To show stepwise how the truth table is produced, the logic circuit has been
split up into three parts, as shown by the dotted lines, and intermediate values are shown as
P. Q and R.
PART 1
This is the first part of the logic circuit; the first task is to find the intermediate values P and Q.
The value of P is found from the AND gate where the inputs are A and B. The value of Q is
found from the NOR gate where the inputs are B and C. An intermediate truth table is produced
using the logic function descriptions.
49
PART 2
The second part of the logic circuit has P and Q as inputs and the intermediate output. R:
This produces the following intermediate truth table. (Note: even though there are only two
inputs to the logic gate, we have generated eight binary values in part 1 and these must all be
used in this second truth table.
PART 3
The final part of the logic circuit has R and C as inputs and the final output. X:
50
Putting all three intermediate truth tables together produces the final truth table, which
represents the original logic circuit:
The intermediate values can be left out of the final truth table, but it is good practice to leave
them in until you become confident about producing the truth tables. The final truth table would
then look like this:
51
EXAMPLE 2:
The first action is to look at the gates connected to the inputs A. B and C:
logic gate 2: (B OR C)
[(A AND B)] XOR [(B OR C)] which gives us the required logic expression.
(Note: the square brackets 11" in the expression are not necessary and are used here just
for clarity.)
Again, we will do this in the order of logic gates 1 and 2 first (connected to the three inputs):
52
logic gate 2: [B AND C]
However, logic gate 3 is also connected to one of the inputs so that should be done next:
EXAMPLE 3:
A logic circuit can be represented by the following logic expression: [A XOR C] OR [NOT C
NANO B]
Produce a logic circuit and a truth table from the above statement.
53
The Truth Table is shown:
EXAMPLE 4:
Look at the two truth tables below; in each case produce a logic expression and the
corresponding logic circuit:
54
So we have the logic expression: [NOT A AND B] OR [A AND B]
̅ . B + A . B]
[This could be written as: A
EXAMPLE 5:
55
We only need to consider those rows where the output is a 1. This gives us following three
logic expressions:
If we now join the three expressions with an OR Gate, we end up with the final logic
expressions
(NOT A AND NOT B AND NOT C) OR (A AND NOT B AND NOT C) OR (A AND B AND NOT
C)
I. We only need to consider those rows where the output is a 1. This gives us the
following four Boolean Expressions:
If we now join the four expressions with an OR gate we end up with the following logic
expression:
II. To show that [B AND C] OR [A AND C] OR [A AND B] produces the same output as
shown in part I we need to produce a new truth table and show that the output is the
same as the one in the given truth table:
56
As the second truth table shows, the outputs from logic expressions are both the same;
thus the logic expression [B AND C] OR [A AND C] OR [A AND B] gives the same
output as the logic expression in part I.
EXAMPLE 6
A safety system uses three inputs to a logic circuit. An alarm, X, sounds if input A represents
ON and input B represents OFF; or if input B represents ON and input C represents OFF.
Produce a logic circuit and truth table to show the conditions that cause the output X to be 1.
The first thing to do is to write down the logic statement representing the scenario in this
example. To do this, it is necessary to recall that ON a 1 and OFF a 0 and also that 0 is usually
considered to be NOT 1.
̅) + (B . C̅)
(A . B
The logic circuit is made up of two parts as shown in the logic expression. We will produce the
logic gate for the first second part. Then join both parts together with the OR gate.
57
Now combining both parts with the OR gate gives us:
In order to produce the truth table, there are two ways to do this:
Trace through the logic circuit using the method described in example 1
Produce the truth table using the original logic expression; this second method has the
advantage that it allows you to check that your logic circuit is correct.
[Note: it is optional whether to leave in the intermediate values or simply remove them giving
a four column truth table with headings: A, B, C, X]
EXAMPLE 7
58
A wind turbine has a safety system which uses three inputs to a logic circuit. A certain
combination of conditions results in an output, X, from the logic circuit being equal to 1. When
the value of X = 1 then the wind turbine is shut down.
The following table shows which parameters are being monitored and form the three inputs to
the logic circuit.
The output. X, will have a value of 1 if any of the following combination of conditions occur:
Either turbine speed <=1000 rpm and bearing temperature > 80°C
Or turbine speed > 1000 rpm and wind velocity > 120 kph
Or bearing temperature <= 80°C and wind velocity > 120 kph
Design the logic circuit and complete the truth table to produce a value of X = 1 when either
of the three conditions above occur.
In this example, a real situation is given and it is necessary to convert the information into a
logic expression and then produce the logic circuit and truth table. It is advisable in problems
as complex as this to produce the logic circuit and truth table separately [based on the
conditions given] and then check them against each other to see if there are any errors.
STAGE 1
The first thing to do is to convert each of the three statements into logic expressions. Use the
information given in the table and the three condition statements to find how the three
parameters S, T and W are linked. We usually look for the key words AND. OR and NOT when
converting actual statements into logic.
I. Turbine speed <a 1000 rpm and bearing temperature > 80°C
logic expression: (NOT S AND TI
II. Turbine speed > 1000 rpm and wind velocity > 120 kph
logic expression: IS AND WI
III. Bearing temperature <= 80°C and wind velocity > 120 kph
logic expression: (NOT T AND WI
STAGE 2
59
This now produces three intermediate logic circuits:
Each of the three original statements were joined together by the word "OR'. Thus, we need
to join all of the three intermediate logic circuits by two OR gates to get the final logic circuit.
The final part is to produce the truth table. We will do this using the original logic statement.
This method has the bonus of allowing an extra check to be made on the logic circuit in Figure
to see whether or not it is correct. It is possible, however, to produce the truth table straight
from the logic circuit in Figure.
There were three parts to the problem, so the truth table will first evaluate each part. Then, by
applying OR gates. as shown below, the final value, X, is obtained:
i. [NOT S AND T]
ii. [S AND W]
iii. [NOT T AND W]
We find the outputs from parts and lid and then OR these two outputs together to obtain a new
intermediate, which we will now label part (iv).
60
We then OR parts bid and (iv) together to get the value of X.
EXAMPLE 8:
i. P = [A NOR B]
61
ii. Q = [A OR NOT B]
iii. R = [P AND C]
Now draw the logic gates for statements i to iii and connect them together:
We can then fill out the truth table in stages, starting with P, Q and then R, followed finally by
X:
62