📚 Flow Charts | 流程图
A flow chart is a diagram that represents an algorithm or process, using standard symbols linked by arrows to show the order of steps. For Edexcel A-Level Decision Mathematics, you need to read, interpret, construct and trace flow charts precisely.
流程图是表示算法或过程的图形,使用标准符号并通过箭头表示步骤顺序。在 Edexcel A-Level 决策数学中,你需要准确读图、释图、绘图并追踪流程图。
1. What Is a Flow Chart? | 什么是流程图?
A flow chart is a graphical representation of a sequence of steps in an algorithm or decision process. Each step is shown inside a standard symbol, and arrows connect the symbols to indicate the order in which the steps are executed.
流程图是算法或决策过程中一系列步骤的图形化表示。每一个步骤都放在标准符号中,箭头把符号连接起来以表示执行的先后顺序。
In the Edexcel Decision Mathematics module, flow charts are used to communicate algorithms clearly before they are implemented as pseudocode or computer code. They help identify the structure of sequence, selection and iteration.
在 Edexcel 决策数学模块中,流程图用于在把算法写成伪代码或程序代码之前清晰地表达算法。它们有助于识别顺序、选择和迭代结构。
2. Standard Symbols and Their Meanings | 标准符号及其含义
The main symbols you must recognise are terminals, input/output boxes, process boxes, decision diamonds and arrows. The table below summarises their meanings.
你必须识别的主要符号包括端点、输入/输出框、处理框、判断菱形和箭头。下表总结了它们的含义。
| Symbol | 符号 | Name | 名称 | Meaning | 含义 |
|---|---|---|
| Oval / 椭圆形 | Terminal | Start or end of the process / 过程的开始或结束 |
| Parallelogram / 平行四边形 | Input/Output | Enter data or display results / 输入数据或显示结果 |
| Rectangle / 矩形 | Process | Arithmetic, assignment or calculation / 算术、赋值或计算 |
| Diamond / 菱形 | Decision | A condition with Yes/No or True/False branches / 判断条件,产生是/否或真/假分支 |
| Arrow / 箭头 | Flow line | Shows direction of control / 显示控制方向 |
3. Start and End Terminals | 开始与结束端点
Every flow chart must begin with a single Start terminal and end with a Stop or End terminal. The terminal symbol is normally an oval or rounded rectangle. It must not contain calculations or conditions.
每个流程图都必须以唯一的“开始”端点开始,并以“停止”或“结束”端点结束。端点符号通常是椭圆形或圆角矩形。端点内不能包含计算或条件。
Examiners often penalise diagrams that have multiple start points or that terminate without a clear End symbol. Ensure the first and last symbols are unambiguous.
考官通常会扣掉有多个起点或没有明确结束符号的图表分数。确保首尾符号清晰明确。
4. Input/Output Boxes | 输入/输出框
A parallelogram represents an input or output operation, such as READ X, INPUT N, or PRINT SUM. In exams you should write the operation inside the box, not just the variable name.
平行四边形表示输入或输出操作,例如 READ X、INPUT N 或 PRINT SUM。考试中应在框内写出操作,而不仅仅是变量名。
For example, writing only SUM inside an output box is not sufficient because it does not state whether the value is being read or printed. Use PRINT SUM or OUTPUT SUM to make the operation explicit.
例如,在输出框中只写 SUM 是不够的,因为没有说明该值是被读取还是被打印。应使用 PRINT SUM 或 OUTPUT SUM 使操作明确。
5. Process Boxes and Assignment | 处理框与赋值
A rectangular process box carries out a calculation or assignment. Use a left arrow or equals sign consistently, for example X ← X + 1 or X = X + 1, depending on the convention stated in the question.
矩形处理框执行计算或赋值。应一致地使用左箭头或等号,例如 X ← X + 1 或 X = X + 1,具体取决于题目规定的约定。
X ← X + 1
The box should contain one clear operation. If two changes are needed, use two separate process boxes. This makes tracing easier and reduces ambiguity.
每个处理框内应只写一个明确的操作。如果需要两个变化,应使用两个独立的处理框。这样更容易追踪,也能减少歧义。
6. Decision Boxes and Branching | 判断框与分支
A diamond contains a condition or question, such as N > 10? or IS X = 0?. Two labelled arrows leave the decision box, usually labelled Yes and No, or True and False. Exactly one branch is followed each time the condition is tested.
判断菱形包含一个条件或问题,例如 N > 10? 或 IS X = 0?。从判断框引出两条带标记的箭头,通常标记为“是”和“否”,或“真”和“假”。每次测试条件时只能沿着一个分支执行。
Do not place arithmetic operations inside a decision diamond. The decision should be a logical test that produces a yes or no answer.
不要把算术运算放在判断菱形内。判断应是一个逻辑测试,产生是或否的答案。
7. Arrows and Flow of Control | 箭头与控制流
Arrows must show the direction of flow. Do not allow unclear or missing arrowheads. Where lines cross, use a connector or draw clean paths; crossing without a connector should not be assumed to join.
箭头必须显示流程方向。不要出现不明确或缺少箭头的情况。当线条交叉时,应使用连接符或画清晰的路径;交叉但没有连接符不应视为连接。
The standard direction is top to bottom, but loops often return upward or to the left. Always show an arrowhead on every path, including backward loop paths.
标准方向是从上到下,但循环通常返回向上或向左。每条路径都必须有箭头,包括向后的循环路径。
8. Iteration: Loop Structures | 迭代:循环结构
Flow charts often include loops created by a decision box and a backward arrow. A pre-tested loop checks the condition before the process, while a post-tested loop checks it after. You must be able to trace how many times a loop executes.
流程图常通过判断框和回指箭头构成循环。前测循环先检查条件再执行过程;后测循环先执行再检查条件。你必须能够追踪循环执行的次数。
- Pre-tested loop: decision before process | 前测循环:先判断后处理
- Post-tested loop: process before decision | 后测循环:先处理后判断
In decision mathematics, pre-tested loops are common for initialising a counter and testing it before each repetition. This avoids executing the loop body when the initial condition is false.
在决策数学中,前测循环常用于初始化计数器并在每次重复前测试它。当初始条件为假时,这可以避免执行循环体。
9. Tracing a Flow Chart | 追踪流程图
To trace a flow chart, build a trace table with columns for variables and one row for each step or iteration. Start with initial values, update cells whenever a process or input changes a value, and record the output at the end.
追踪流程图时,建立一个包含各变量列的追踪表,每执行一步或一次迭代添加一行。从初始值开始,每当处理或输入改变值时更新单元格,并在最后记录输出。
A trace table helps you check the number of iterations, the changing values of counters and accumulators, and whether the correct output is produced. It is often the safest way to answer exam questions that ask for the output of a given flow chart.
追踪表可以帮助你检查迭代次数、计数器和累加器的变化值,以及是否产生了正确的输出。这通常是回答考试中要求给出给定流程图输出问题的最安全方法。
10. Worked Example: Sum of First n Integers | 实例:前 n 个整数求和
Consider an algorithm that reads a positive integer n and outputs the sum 1 + 2 + … + n. Before the loop, set SUM = 0 and N = 1. While N <= n, add N to SUM, then increase N by 1. After the loop, print SUM.
考虑一个读取正整数 n 并输出和 1 + 2 + … + n 的算法。在循环前设置 SUM = 0 和 N = 1。当 N <= n 时,把 N 加到 SUM,然后 N 增加 1。循环结束后输出 SUM。
The flow chart has an input box for n, two process boxes for initialisation, a decision diamond N <= n?, a process box SUM ← SUM + N, a process box N ← N + 1, and an output box.
该流程图中有一个输入框读取 n、两个初始化处理框、一个判断菱形 N <= n?、一个处理框 SUM ← SUM + N、一个处理框 N ← N + 1 和一个输出框。
| Step | 步骤 | N | SUM | Output | 输出 |
|---|---|---|---|
| Input n=3 | 输入 n=3 | – | – | – |
| Initialise | 初始化 | 1 | 0 | – |
| 1st loop | 第1次循环 | 2 | 1 | – |
| 2nd loop | 第2次循环 | 3 | 3 | – |
| 3rd loop | 第3次循环 | 4 | 6 | – |
| Exit and print | 退出并输出 | 4 | 6 | 6 |
When n = 3, the trace table shows that the loop runs three times and the final output is 6. This matches 1 + 2 + 3 = 6.
当 n = 3 时,追踪表显示循环执行三次,最终输出为 6。这符合 1 + 2 + 3 = 6。
11. Common Errors and Exam Tips | 常见错误与应试技巧
Many marks are lost because students use incorrect symbols, forget to label Yes/No branches, or place a condition inside a rectangle. Always label every decision path, give one clear operation per process box, and check that loop counters are updated before the condition is retested.
很多失分是因为学生用了错误的符号、忘记标记 Yes/No 分支,或把条件放在矩形框内。务必为每条判断路径加标记,每个处理框只写一个清晰操作,并检查循环计数器在重新测试条件前已经更新。
- Use a diamond only for decisions and a rectangle only for processing | 判断用菱形,处理用矩形
- Always include a Start and an End terminal | 始终包含“开始”和“结束”端点
- Label loop arrows so the flow is unambiguous | 标记循环箭头以确保流程无歧义
- Trace with a table to catch off-by-one errors | 用追踪表捕捉差一错误
When drawing flow charts from a written algorithm, convert each written instruction into exactly one standard symbol. Do
Published by TutorHao | A-Level Revision Series | aleveler.com
更多咨询请联系16621398022(同微信)
屏轩国际教育cambridge primary/secondary checkpoint, cat4, ukiset,ukcat,igcse,alevel,PAT,STEP,MAT, ibdp,ap,ssat,sat,sat2课程辅导,国外大学本科硕士研究生博士课程论文辅导