Computer Science AS CIE
-
data-representation as5 主题
-
multimedia as3 主题
-
compression as2 主题
-
networks-and-the-internet as11 主题
-
computers-and-components as5 主题
-
logic-gates-and-logic-circuits as2 主题
-
central-processing-unit-cpu-architecture as6 主题
-
assembly-language- as4 主题
-
bit-manipulation as1 主题
-
operating-systems as3 主题
-
language-translators as2 主题
-
data-security as3 主题
-
data-integrity as1 主题
-
ethics-and-ownership as3 主题
-
database-concepts as3 主题
-
database-management-systems-dbms- as1 主题
-
data-definition-language-ddl-and-data-manipulation-language-dml as1 主题
-
computational-thinking-skills as1 主题
-
algorithms as4 主题
-
data-types-and-records as2 主题
-
arrays as2 主题
-
files as1 主题
-
introduction-to-abstract-data-types-adt as1 主题
-
programming-basics as1 主题
-
constructs as2 主题
-
structured-programming as1 主题
-
program-development-life-cycle as1 主题
-
program-design- as2 主题
-
program-testing-and-maintenance as3 主题
logic-construction as
Exam code:9618
From problem statements
-
A problem statement is typically a written interpretation of a scenario that requires a specific logical outcome
-
Logic circuits can be constructed using from problem statements
Worked Example
A server room has an automatic cooling fan (F)
The fan turns on based on the following input parameters:
|
Parameter |
Description |
Binary Value |
Condition |
|---|---|---|---|
|
T |
Temperature |
1 = Too high |
0 = Acceptable |
|
H |
Humidity |
1 = Too high |
0 = Acceptable |
|
M |
Maintenance mode |
1 = Active |
0 = Inactive |
|
D |
Door sensor |
1 = Door open |
0 = Door closed |
The fan (F = 1) turns on if:
-
The temperature is too high
-
AND humidity is too high
-
AND the door is closed
-
UNLESS maintenance mode is active (if maintenance is active, the fan must stay off)
Draw a logic circuit to represent how the fan (F) operates based on the input conditions. [3]
Answer

-
NOT gates on D and M inputs [1 mark]
-
AND gate combines T AND H or NOT D AND NOT M [1 mark]
-
Combines two previous AND outputs (e.g. (T AND H) AND (NOT D AND NOT M)) [1 mark]
From logic expressions
-
A logic expression is a way of showing how a logic circuit works using symbols and Boolean logic (AND, OR, NOT)
-
It describes the conditions that must be met for the output to be true (1) or false (0)
-
From a logic expression, a logic circuit and/or truth table can be constructed
Worked Example
A logic expression is given:
S = (A AND B AND C) OR (B XOR C)
(a) Draw the logic circuit for the given expression [4]
(b) Complete the truth table for the logic expression: [2]
S = (A AND B AND C) OR (B XOR C)
Answer
(a)

-
Each correct gate [1 mark]
(b)
|
A |
B |
C |
S |
|---|---|---|---|
|
0 |
0 |
0 |
0 |
|
0 |
0 |
1 |
1 |
|
0 |
1 |
0 |
1 |
|
0 |
1 |
1 |
0 |
|
1 |
0 |
0 |
0 |
|
1 |
0 |
1 |
1 |
|
1 |
1 |
0 |
1 |
|
1 |
1 |
1 |
1 |
-
Rows 1 to 4 correct [1 mark]
-
Rows 5 to 8 correct [1 mark]
From truth tables
-
To create a truth table for the expression P = (A AND B) AND NOT C
-
Calculate the numbers of rows needed (2number of inputs)
-
In this example there are 3 inputs (A, B, C) so a total of 8 rows are needed (23)
-
To not miss any combination of inputs, start with 000 and count up in 3-bit binary (0-7)
-
|
A |
B |
C |
|---|---|---|
|
0 |
0 |
0 |
|
0 |
0 |
1 |
|
0 |
1 |
0 |
|
0 |
1 |
1 |
|
1 |
0 |
0 |
|
1 |
0 |
1 |
|
1 |
1 |
0 |
|
1 |
1 |
1 |
-
Add a new column to show the results of the brackets first (A AND B)
|
A |
B |
C |
A AND B |
|---|---|---|---|
|
0 |
0 |
0 |
0 |
|
0 |
0 |
1 |
0 |
|
0 |
1 |
0 |
0 |
|
0 |
1 |
1 |
0 |
|
1 |
0 |
0 |
0 |
|
1 |
0 |
1 |
0 |
|
1 |
1 |
0 |
Responses