Fix the failed tests with a smaller change, retest, and say what changed and why. Then extend the algorithm to say whether the triangle has a right, acute or obtuse angle.
The tests found two faults. What is the smallest change that fixes both?
The tests showed the S >= L check fails when S equals L and when a length is zero. A refinement fixes the fault with the smallest change, then retests. Once the check is right, it can do more: using Pythagoras, compare L² with the sum of the squares of the other two to say whether the largest angle is right, acute or obtuse. Have a guess how L² compares with the others when the triangle is acute, and we'll come back to the machine at the end.
How this lesson works: Predict, Try, Investigate, Modify, Practise, Make
Predict: Read the problem and decide what you think before you try anything. A wrong guess is fine: it shows you what to look for.
Try: Try it on the board and compare the result with your prediction.
Investigate: Work out why it happens, one step at a time.
Modify: Change the problem on purpose and see what happens.
Practise: A few on your own, to check you have it.
Make: Make your own problem using what you have learned. Expect a few tries; that is normal.
Make your prediction first. Help opens once you've locked it in.
PredictRead the problem and decide what you think before you try anything. A wrong guess is fine: it shows you what to look for.
The smallest fix
TryTry it on the board and compare the result with your prediction.
Retest
InvestigateWork out why it happens, one step at a time.
Explain and extend
Worked exampleBefore each step, say what you think comes next.
S>L and all lengths>0Refined triangle check.
L2−(a2+b2)=0⇒rightPythagoras.
<0⇒acute;>0⇒obtuseCompare with zero.
Build up to it
Right, acute or obtuse? For 4, 5 and 6, L² is 36 and the squares of the others sum to 16 + 25 = 41. What is L² minus that sum?
For 2, 3 and 4: L² is 16 and the squares of the others sum to 4 + 9 = 13. What is L² minus that sum?
Mia adds the right-angle test. Click the step that is wrong.
ModifyChange the problem on purpose and see what happens.
Apply the refined version
For 5, 12 and 13: L² is 169 and the others' squares sum to 25 + 144 = 169. What is the difference?
PractiseA few on your own, to check you have it.
Classify by sides
Strips 6, 8 and 11. L² is 121 and the others' squares sum to 36 + 64 = 100. What is L² minus that sum?
MakeMake your own problem using what you have learned. Expect a few tries; that is normal.
The machine's final check
Write the final algorithm as numbered steps and mark each decision.
Also used in
Computer graphics. Meshes are checked for valid triangles before they are drawn.
Surveying. A land surveyor tests a triangle of measurements for errors in the same way.
Next unit. Year 10: proof and then Pythagoras and trigonometry in practice.
Run the refined algorithm on 6, 8 and 11. First check it is a triangle, then compare L² with the sum of the other two squares. What is L² minus that sum? (The lengths are made up for the task.)
Work it out on paper first, one step per line. Then type your answer.
Put your page beside this and compare, step by step.
Fix the failed tests with a smaller change, retest, and say what changed and why. Then extend the algorithm to say whether the triangle has a right, acute or obtuse angle. About 40 minutes.
Students need the last two lessons and Pythagoras (Year 8).
The one idea: fix with a small change, retest everything, and explain. The right/acute/obtuse test is the converse of Pythagoras and its extension. Lengths are made up.
Running the lesson
Predict: show of hands before the check.
Make: the working is done on paper first.
The hard part (on purpose)
Changing everything at once. Ask: what is the smallest change that fixes the failed case?
When students get stuck
A student rewrites the algorithm. Ask: Which single comparison caused the fault? Fix: Change one thing and retest.
Stretch and support
Stretch: Write the algorithm in pseudocode with a loop that tests a list of strip sets and prints a verdict for each.
Support: A printed copy of the situation and a blank table to fill in.
Where it leads
Completes AC9M9SP03 node 3.
Where it leads: Year 10 proof and trigonometry.
What each step is for
the smallest fix: Choosing the minimal change shows whether students change the comparison (> not >=) rather than rebuild everything.
retest: After a change, rerun the failed cases: a fix is only done when the old failures now pass.
explain and extend: A refinement is explained by what changed, why, and what the retest shows; extending an algorithm adds a new decision using a new geometric idea.
apply the refined version: Running the whole refined algorithm on new strips, and explaining a change.
classify by sides: Using the L² comparison on new strips, and a review of testing.
the machine's final check: Returning to the machine: run the finished algorithm and report the result, on paper.