📚 GCSE WJEC Computer Science: Boolean Algebra - Key Concepts Explained | GCSE WJEC 计算机:布尔代数 考点精讲
Boolean algebra is a fundamental topic for GCSE WJEC Computer Science. It underpins all digital logic and helps you understand how computers process binary data. This revision guide covers every essential point: from basic operators and truth tables to De Morgan's laws and expression simplification, exactly as required by the WJEC specification.
布尔代数是 GCSE WJEC 计算机科学的基础内容,支撑着所有数字逻辑,帮助理解计算机如何处理二进制数据。本复习指南覆盖所有必考要点:从基本运算符、真值表到德摩根定律与表达式化简,完全针对 WJEC 考纲。
1. Introduction to Boolean Algebra | 布尔代数简介
Boolean algebra works with variables that can only take the values 0 (false) or 1 (true). It is named after George Boole and forms the language of logic gates and circuits.
布尔代数处理的变量只能取 0(假)或 1(真)。它以乔治·布尔命名,构成了逻辑门和电路的语言。
In WJEC computer science, you use Boolean algebra to describe, analyse and simplify logic circuits. You will meet three basic operations: AND, OR and NOT.
在 WJEC 计算机科学中,你使用布尔代数来描述、分析和化简逻辑电路。你将会遇到三种基本运算:与、或、非。
2. Basic Logic Operators and Truth Tables | 基本逻辑运算符与真值表
The AND operator (∧) outputs 1 only when all inputs are 1. Two‑input AND truth table:
与运算符 (∧) 仅在所有输入都为 1 时才输出 1。两输入 AND 真值表:
| A | B | A ∧ B |
| 0 | 0 | 0 |
| 0 | 1 | 0 |
| 1 | 0 | 0 |
| 1 | 1 | 1 |
The OR operator (∨) outputs 1 if at least one input is 1. Two‑input OR truth table:
或运算符 (∨) 在至少一个输入为 1 时输出 1。两输入 OR 真值表:
| A | B | A ∨ B |
| 0 | 0 | 0 |
| 0 | 1 | 1 |
| 1 | 0 | 1 |
| 1 | 1 | 1 |
The NOT operator ( ¬ or ' ) inverts the input: ¬0 = 1, ¬1 = 0.
非运算符 ( ¬ 或 ' ) 会将输入取反:¬0 = 1,¬1 = 0。
3. Logic Gate Symbols | 逻辑门符号
WJEC often uses rectangular logic gate symbols with the function written inside. However, the distinctive shapes are also common in exams. You need to recognise both.
WJEC 通常使用内部写有功能名称的矩形逻辑门符号,但独特形状的门符号在考试中也很常见。你需要识别这两种。
AND gate: D‑shaped symbol with two inputs, output is A·B or A∧B.
与门:D 形符号,两个输入,输出为 A·B 或 A∧B。
OR gate: shield‑shaped symbol, output is A+B or A∨B.
或门:盾形符号,输出为 A+B 或 A∨B。
NOT gate: triangle with a small circle (bubble) at the output, output is ¬A or A'.
非门:三角形输出端带一个小圆(气泡),输出为 ¬A 或 A'。
A small circle on any input also indicates inversion. Combine gates to build more complex circuits.
任何输入上的小圆也表示取反。组合逻辑门可以构建更复杂的电路。
4. Writing Boolean Expressions | 布尔表达式的写法
Boolean expressions describe the logic of a circuit. Use letters for inputs (e.g. A, B, C) and combine them with operators.
布尔表达式描述电路的逻辑。使用字母表示输入(如 A, B, C),并用运算符将它们组合起来。
Operator precedence in WJEC: brackets first, then NOT, then AND, then OR. Always use parentheses to avoid ambiguity.
WJEC 中的运算符优先级:先算括号,然后 NOT,然后 AND,最后 OR。始终使用括号避免歧义。
Example: (A ∧ B) ∨ (¬C) means A AND B, then OR with NOT C.
示例:(A ∧ B) ∨ (¬C) 表示先计算 A AND B,再与 NOT C 进行 OR 运算。
5. Constructing Truth Tables | 构建真值表
A truth table lists every possible input combination and the resulting output. For n inputs, there are 2ⁿ rows.
真值表列出所有可能的输入组合及其对应的输出。对于 n 个输入,共有 2ⁿ 行。
To build one: write columns for all inputs, then intermediate columns if needed, and finally the output. Fill in binary order (000, 001, 010 …).
构建方法:为所有输入写出列,如果需要可添加中间列,最后写出输出列。按二进制顺序(000, 001, 010 …)填入。
For the expression Q = (A ∨ B) ∧ ¬B, the truth table has 4 rows. Work step‑by‑step: calculate A∨B, ¬B, then Q.
对于表达式 Q = (A ∨ B) ∧ ¬B,真值表共有 4 行。逐步计算:先算 A∨B,再算 ¬B,最后求 Q。
6. Basic Boolean Identities and Laws | 基本布尔恒等式与定律
These laws let you simplify expressions without changing their logic. Memorising them is essential for the exam.
这些定律使你能在不改变逻辑的情况下化简表达式。在考试中记忆它们至关重要。
Identity: A ∧ 1 = A, A ∨ 0 = A
同一律:A ∧ 1 = A,A ∨ 0 = A
Null element: A ∧ 0 = 0, A ∨ 1 = 1
零元律:A ∧ 0 = 0,A ∨ 1 = 1
Idempotent: A ∧ A = A, A ∨ A = A
幂等律:A ∧ A = A,A ∨ A = A
Complement: A ∧ ¬A = 0, A ∨ ¬A = 1
互补律:A ∧ ¬A = 0,A ∨ ¬A = 1
Commutative: A ∧ B = B ∧ A, A ∨ B = B ∨ A
交换律:A ∧ B = B ∧ A,A ∨ B = B ∨ A
Associative: (A ∧ B) ∧ C = A ∧ (B ∧ C), (A ∨ B) ∨ C = A ∨ (B ∨ C)
结合律:(A ∧ B) ∧ C = A ∧ (B ∧ C),(A ∨ B) ∨ C = A ∨ (B ∨ C)
Distributive: A ∧ (B ∨ C) = (A ∧ B) ∨ (A ∧ C), A ∨ (B ∧ C) = (A ∨ B) ∧ (A ∨ C)
分配律:A ∧ (B ∨ C) = (A ∧ B) ∨ (A ∧ C),A ∨ (B ∧ C) = (A ∨ B) ∧ (A ∨ C)
Absorption: A ∧ (A ∨ B) = A, A ∨ (A ∧ B) = A
吸收律:A ∧ (A ∨ B) = A,A ∨ (A ∧ B) = A
Apply these laws step by step to reduce gate count in logic circuits.
逐步应用这些定律可以减少逻辑电路中的门数量。
7. De Morgan's Laws | 德摩根定律
De Morgan's laws describe how negation distributes over AND and OR. They are frequently tested in WJEC papers.
德摩根定律描述如何将非运算分配到与和或运算上,在 WJEC 试卷中经常考查。
¬(A ∧ B) = ¬A ∨ ¬B
¬(A ∨ B) = ¬A ∧ ¬B
These laws can be proved using truth tables. Check that both sides of each equation give identical output columns.
这些定律可以用真值表来证明。验证每个等式两边给出完全相同的输出列。
De Morgan's laws are essential for converting a NAND gate into an OR gate with inverted inputs, or a NOR gate into an AND gate with inverted inputs.
德摩根定律对于将与非门转换为输入取反的或门,或将或非门转换为输入取反的与门至关重要。
8. Simplifying Boolean Expressions Algebraically | 使用代数法化简布尔表达式
Simplification reduces the complexity of a circuit. Use the Boolean laws to rewrite an expression in its simplest form.
化简可以降低电路的复杂度。使用布尔定律将表达式重写为最简形式。
Example: Simplify Q = (A ∧ B) ∨ (A ∧ ¬B).
示例:化简 Q = (A ∧ B) ∨ (A ∧ ¬B)。
Factor out A: Q = A ∧ (B ∨ ¬B). Use complement law: B ∨ ¬B = 1. Then Q = A ∧ 1 = A.
提取公因子 A:Q = A ∧ (B ∨ ¬B)。利用互补律:B ∨ ¬B = 1。于是 Q = A ∧ 1 = A。
Another example: Simplify Q = ¬(¬A ∧ B) using De Morgan and double negation.
另一个例子:利用德摩根和双重否定化简 Q = ¬(¬A ∧ B)。
Apply De Morgan: Q = ¬(¬A) ∨ ¬B = A ∨ ¬B. (Double negation: ¬(¬A) = A.)
应用德摩根定律:Q = ¬(¬A) ∨ ¬B = A ∨ ¬B。(双重否定:¬(¬A) = A。)
9. Deriving Boolean Expressions from Truth Tables (SOP) | 从真值表推导布尔表达式(积之和)
When given a truth table, you can write a Boolean expression in Sum‑of‑Products (SOP) form. Each row where output is 1 contributes a product term.
当给出真值表时,你可以写出积之和 (SOP) 形式的布尔表达式。每一个输出为 1 的行贡献一个乘积项。
For each 1‑output row: include a variable as itself if it is 1, or as its complement if it is 0. Then OR all these product terms together.
对于每一个输出为 1 的行:若变量为 1 就取原变量,若为 0 就取其反变量。然后将所有这些乘积项进行 OR 运算。
Example: an XOR truth table yields Q = (¬A ∧ B) ∨ (A ∧ ¬B). This is the SOP form.
示例:异或真值表得到 Q = (¬A ∧ B) ∨ (A ∧ ¬B),这就是 SOP 形式。
This method guarantees a correct expression that can later be simplified.
这种方法保证得到正确的表达式,之后可以进一步化简。
10. Converting Between Logic Circuits and Expressions | 逻辑电路与表达式互转
You must be able to read a circuit diagram and write its Boolean expression, and vice versa.
你必须能够读懂电路图并写出其布尔表达式,反之亦然。
From circuit to expression: label each gate's output, write the intermediate expression, then combine moving from inputs to final output.
从电路到表达式:标出每个门的输出,写出中间表达式,然后从输入向最终输出组合起来。
From expression to circuit: identify the order of operations (use brackets) and draw the corresponding gates. Start with the deepest parenthesised parts.
从表达式到电路:识别运算顺序(利用括号),画出对应逻辑门。从最深的括号部分开始。
Practise with mixed gates: AND, OR, NAND, NOR, XOR. Always check by generating a truth table.
多练习混合门:与门、或门、与非门、或非门、异或门。始终通过生成真值表来检查。
11. Exam Tips and Common Pitfalls | 考试技巧与常见错误
WJEC exam questions often ask you to draw a truth table from an expression, simplify using laws, or draw a circuit. Show all working clearly.
WJEC 考试题常常要求根据表达式画出真值表、使用定律化简或绘制电路。要清晰地展示所有步骤。
Mistake: forgetting operator precedence. Always use brackets when translating expressions to circuits.
错误:忘记运算符优先级。将表达式转化为电路时始终使用括号。
Mistake: confusing AND (∧) and OR (∨) in De Morgan's law. Check the output column of a truth table as proof.
错误:在德摩根定律中混淆 AND (∧) 和 OR (∨)。用真值表的输出列来验证。
Mistake: leaving out possible input combinations. For 3 inputs, there must be 8 rows.
错误:遗漏可能的输入组合。3 个输入必须有 8 行。
Tip: learn the Boolean identities by heart; they are the key to scoring full marks in simplification questions.
技巧:熟记布尔恒等式;这是在化简题中获得满分的关键。
Tip: when simplifying, write the law you are using at each step to earn method marks even if the final answer is slightly wrong.
技巧:化简时,在每一步写出所使用的定律,这样即使最终答案稍有错误也能获得步骤分。
12. Summary | 总结
Boolean algebra provides the mathematical foundation for digital electronics. Master the basic operators, truth tables, Boolean laws, De Morgan's rules, and SOP derivation. Practise simplifying expressions and drawing circuits until it becomes second nature.
布尔代数为数字电子学提供了数学基础。掌握基本运算符、真值表、布尔定律、德摩根规则和 SOP 推导。反复练习化简表达式和画电路图,直到变成你的第二本能。
This topic regularly appears in the WJEC Component 2 exam. Use this guide alongside past papers to consolidate your understanding.
本主题经常出现在 WJEC 第二部分的考试中。将本指南与历年真题结合使用,巩固你的理解。
Published by TutorHao | Computer Science Revision Series | aleveler.com
更多咨询请联系16621398022(同微信)

或截图后用「扫一扫 → 相册」选择本图