CIE IGCSE | Logic Symbols and Functions

Lesson objective

Identify standard logic-gate symbols and explain the functions and truth tables of NOT, AND, OR, NAND, NOR and XOR.

Learn

10. 0 | LOGIC SYMBOLS AND FUNCTIONS

01 | A DECISION WITH TWO POSSIBLE STATES

A security light needs a clear decision: switch on or stay off. Its inputs might say whether movement is detected and whether it is dark. Each input has two possible states.

Boolean data has two values, TRUE and FALSE. In logic tables, 1 represents TRUE and 0 represents FALSE. A 1 does not necessarily mean “good” or “safe”: its meaning comes from the input definition. If A means DoorOpen, A = 1 means the door is open.

A logic gate applies a fixed Boolean rule to its inputs and produces a Boolean output. The gates here are NOT, AND, OR, NAND, NOR and XOR. XOR is also called EOR, exclusive OR.

02 | READ THE SYMBOL BEFORE THE RULE

Letters such as A and B label inputs; X labels the output. They are names for signals, not fixed values. A can be 0 in one case and 1 in another.

Read the standard symbols from left to right. Lines carry signals into the gate, and the line leaving it carries the result. NOT has one input. The other gates in this syllabus use two inputs.

The small circle at an output means inversion: reverse the Boolean result. The extra curved line on the input side distinguishes XOR from OR. Learn the shapes as well as the written gate names.

03 | NOT REVERSES ONE INPUT

NOT has one input and produces the opposite value. If A = 0, X = 1; if A = 1, X = 0. It does not need a second input.

If A means DoorOpen, X = NOT A means “the door is not open”. This reverses the proposition, rather than changing the physical door.

AX
NOT | Inputs left, output X right
Two possible states for one input
AX = NOT A
01
10

04 | AND REQUIRES BOTH INPUTS

AND produces 1 only when both inputs are 1. One true input is insufficient.

Let A mean MovementDetected and B mean Dark. A light controlled by X = A AND B switches on only when movement is detected and it is dark. Movement in daylight gives 1 AND 0, so the output is 0.

ABX
AND | Inputs left, output X right
Both conditions must hold
ABX = A AND B
000
010
100
111

05 | OR ACCEPTS EITHER OR BOTH

OR produces 1 if at least one input is 1. Both inputs being 1 also gives 1. This is inclusive OR.

Let A mean SmokeDetected and B mean HeatDetected. An alarm using A OR B sounds when either sensor detects danger, including when both do. It is off only when neither does.

ABX
OR | Inputs left, output X right
At least one input is true
ABX = A OR B
000
011
101
111

06 | XOR REQUIRES EXACTLY ONE

XOR gives 1 when exactly one input is 1. It gives 0 when both inputs are the same. Unlike OR, two true inputs do not give a true output.

If A and B represent two alternative options, XOR can test that exactly one has been selected. Neither selected and both selected fail this rule.

ABX
XOR | Inputs left, output X right
XOR and EOR name the same function
ABX = A XOR B
000
011
101
110

07 | NAND IS NOT AND

NAND reverses the result of AND. Work out A AND B first, then invert it. NAND gives 0 only when both inputs are 1, and gives 1 for the other three combinations.

The symbol is an AND shape with a small output circle. In X = NOT (A AND B), the parentheses make clear that the combined result is inverted.

ABX
NAND | Inputs left, output X right
Calculate AND, then reverse its output
ABA AND BX = NOT (A AND B)
0001
0101
1001
1110

08 | NOR IS NOT OR

NOR reverses the result of OR. It gives 1 only when both inputs are 0. If either input is 1, the OR result is 1 and its inversion is 0.

Let A mean AlarmActive and B mean MaintenanceActive. NOR can indicate that neither condition is active. The symbol is an OR shape with an output circle.

ABX
NOR | Inputs left, output X right
Neither input is true
ABA OR BX = NOT (A OR B)
0001
0110
1010
1110

09 | BUILD A TRUTH TABLE SYSTEMATICALLY

A truth table lists every possible input combination and the output for each. One input has two combinations. Two inputs have four. In general, n binary inputs have 2 to the power n combinations.

For two inputs, use 00, 01, 10 and 11 so no case is missed. Apply the gate’s rule independently to each row. The table is not a sequence in which values accumulate: each row is a separate possible situation.

For three inputs, the combinations run 000 through 111, giving eight rows. The next lesson uses intermediate columns to follow several connected gates.

10 | COMPARE ALL FIVE TWO-INPUT GATES

Check the last row to separate OR from XOR: both true gives OR = 1 but XOR = 0. Check paired columns to see inversion: AND and NAND always differ; OR and NOR always differ.

A compact comparison after learning each gate
ABANDORXORNANDNOR
0000011
0101110
1001110
1111000

11 | TRY THE INPUTS YOURSELF

Choose a gate and its inputs. Predict the output before running the tester. The matching truth-table row is highlighted so you can connect the rule to the result. For NOT, only A is used.

12 | TRANSLATE WORDS INTO A GATE

“Both” usually points to AND. “At least one” points to OR. “Exactly one” points to XOR. “Neither” points to NOR. “Not both” points to NAND, while reversing one condition uses NOT.

Define the inputs first. If A means DoorClosed rather than DoorOpen, the expression needed for a given situation may change. A gate name alone does not explain a real-world system without knowing what its signals represent.

For an enable output requiring PowerAvailable and GuardClosed, AND is appropriate. A true enable condition is a Boolean model of the rule, not a claim that a real machine has every safety requirement covered.

13 | LOGIC IS NOT ORDINARY ARITHMETIC

A gate applies a truth rule. OR with inputs 1 and 1 produces one Boolean output, 1; it does not produce the arithmetic sum 2. XOR with the same inputs produces 0 because exactly one is not true.

NAND does not mean “invert A only, then AND B”. NOT (A AND B) reverses the completed conjunction. Inverting a combined result and inverting a single input are different operations.

When explaining, state the rule and apply the values: “Both inputs are 1, therefore AND outputs 1; NAND reverses that result, so its output is 0.”

MATCH THE GATE TO ITS FUNCTION

Terminology

Terminology

Boolean

A two-value system using TRUE and FALSE.

Logic gate

A component applying a Boolean rule to inputs to produce an output.

Input

A Boolean signal supplied to a gate.

Output

The Boolean result produced by a gate.

Binary 1

Represents TRUE in these logic tables.

Binary 0

Represents FALSE in these logic tables.

NOT

A one-input gate reversing the input value.

AND

Outputs 1 only when both inputs are 1.

OR

Outputs 1 when at least one input is 1, including both.

XOR

Outputs 1 when exactly one of two inputs is 1.

EOR

Another name for XOR, exclusive OR.

NAND

Outputs the inversion of AND.

NOR

Outputs the inversion of OR.

Inversion

Reversing 0 to 1 or 1 to 0.

Output circle

Symbol marking inversion at the gate output.

Truth table

Lists all input combinations and their corresponding outputs.

Input combination

One particular set of input states, such as A = 0 and B = 1.

Boolean expression

A statement combining named Boolean values with logical operations.

Questions

Questions

CHECK YOUR UNDERSTANDING

Select all correct choices. Each exact set earns one point.

1. Which statements about signals are correct?
2. Which gate statements are correct?
3. With A = 1 and B = 0, which outputs are 1?
4. With A = 1 and B = 1, which outputs are 1?
5. Which describe NAND?
6. Which describe NOR?
7. Which symbol details are correct?
8. Which truth-table claims are correct?

EXPLAIN AND COMPARE

Write your answers before revealing each sample.

1. Define a logic gate and explain the roles of inputs and output.

2. Describe the NOT function and complete its truth table.

3. Compare OR and XOR for two inputs.

4. Explain NAND for inputs A = 1, B = 1.

5. Describe how to recognise NOR and explain its function.

6. Draw standard symbols for AND, OR, XOR and NOT, labelling inputs and output.

7. Suggest a gate for a light that switches on only when it is dark and movement is detected. Explain your choice.

8. Explain why input definitions matter when designing a logic rule.

APPLY IT | FOUR DIFFERENT RULES

Inputs A and B represent two selected options. Choose a gate for each rule: both selected; at least one selected; exactly one selected; neither selected. Draw each symbol, complete its four-row truth table and explain the 11 case.

Reveal sample answers

Both: AND. At least one: OR. Exactly one: XOR. Neither: NOR. For inputs 11 their outputs are respectively 1, 1, 0 and 0. AND and OR accept both true; XOR rejects both because exactly one is required; NOR rejects either true input.

Flashcards

Flashcards

Click to flip. Select the ideas you need to revisit.

0 cards selected for revision.

    Selections are kept while this page is open.

    Workbook

    Workbook

    COMING SOON

    The workbook for Logic Symbols and Functions is coming soon. Complete the matching task and written questions in your exercise book.