← AC9M9SP03 Geometric algorithms

Testing an algorithm with cases

AC9M9SP03 n2 · waypoint 2 of 3 · Year 9 Maths · Space · Hinge

Draft, from Waypoints Kit v0.2. Generated from Kit's node data and not yet reviewed by a specialist in Maths: treat it as a starting suggestion and check it before use.

Checkpoint

Students can test an algorithm using specific inputs, identify failure cases, and describe what the algorithm does correctly and incorrectly.

Make a primer for this
Opens Create with a Primer starter: title, goals from the success criteria, the misconception and width suggestions to choose from. Nothing is published until you send it in.

Lessons on this site

Success criteria

Prior knowledge

Waypoint 1: Representing a geometric process as an algorithm.

Width

Minimum
Test one algorithm using at least three input cases (including at least one edge case or failure case); record the output for each; identify any case where the algorithm gives an incorrect or unexpected result.
Typical
Design and execute a test plan with at least three cases (typical, boundary, edge/failure); record expected and actual outputs; identify which cases the algorithm handles correctly and which it does not; explain what makes an edge case or boundary case significant.
Wider
  • Test an algorithm for generating Pythagorean triples — explore what happens at the boundary (n=1, m=1) and for non-integer or negative inputs
  • Test an angle bisection algorithm against a variety of angles including 0°, 180° and obtuse angles — identify where the algorithm assumptions break down
  • Develop an algorithm and test it against a data set to evaluate whether it produces correct results for all valid inputs

Hinge

Students who test only typical cases and miss edge cases cannot identify failure modes — and therefore cannot refine the algorithm in N3. Refinement without prior test failures is superficial or impossible.

Response modes

Where extra effort goes at this waypoint (width), not what kind of lesson it is.

Structured reasoning: a worked chain of reasons, then a write-and-compare (reasoning) checkStudents commonly test only 'typical' cases (the algorithm works for the obvious input) and miss edge cases. Scaffolding the reasoning about what makes a good test — including boundary and failure cases — is the key investment before algorithm refinement is possible.

Kit node file for AC9M9SP03 (JSON; this waypoint is node 2)

Descriptors: Australian Curriculum v9 (ACARA, CC BY 4.0). Waypoints, success criteria, width and response modes: Waypoints Kit v0.2 (CC BY-NC-SA 4.0), waypoints-kit 834ceb8. Corrections go to Kit, not this site.