Subtraction on a Number Line

Subtraction on a Number Line
Loading the math board and drawing, please wait…
2021-08-18 18:38
This example dynamically demonstrates the process of performing subtraction on a number line, covering core math concepts like the intuitive understanding of subtraction, representation of movements on a number line, and various interpretations of subtraction (e.g., moving backward, finding the difference). It uses GeoGebra commands and objects such as Textfield, Join, Element, Sequence, Point, Shuffle, Zip, Polygon, Vector to create an interactive number line and calculation process, making it suitable for 5-6th grade students to understand and practice subtraction.

GeoGebra Commands & Parameters

  1. Textfield(aInput) → InputBox1
  2. Join(Sequence[Shuffle[{1, 2, 3, 5, 10}], m, 1, 25]) → listeFaktoren
  3. Element(listeFaktoren, Mod[questionCount, 100] + 1) → faktor
  4. Sequence((m, heightA), m, 0, x(O2) - 1) → PA
  5. Point(PA) → A2
  6. Sequence((m, heightB), m, 0, x(O2) - 1) → PB
  7. Point(PB) → B2
  8. Shuffle(Sequence[Random[6, x(O2) - 1], i, 1, 100]) → randomNosForA1, {17, 17, 6, 19, 12, 11, 11, 7, 8, 6, 18, 16, 9, 19, 8, 15, 15, 6, 15, 18, 10, 12, 19, 11, 12, 14, 18, 15, 12, 17, 16, 6, 6, 8, 12, 19, 6, 17, 13, 8, 14, 8, 14, 6, 14, 14, 15, 16, 19, 19, 10, 19, 15, 6, 14, 15, 19, 7, 10, 15, 19, 14, 9, 11, 12, 8, 7, 14, 14, 14, 10, 11, 16, 13, 8, 15, 9, 6, 13, 17, 15, 17, 18, 16, 17, 8, 15, 8, 18, 9, 14, 12, 10, 8, 7, 7, 10, 19, 19, 19}
  9. Element(randomNosForA1, Mod[questionCount, 100] + 1) → a1
  10. Zip(Random[2, m - 1], m, randomNosForA1) → randomNosForB1
  11. Element(randomNosForB1, Mod[questionCount, 100] + 1) → b1
  12. Textfield(bInput) → InputBox2
  13. Polygon(Corner[InputBox1, 1] - (dx00, dy00), (x(Corner[InputBox1, 3] + (dx00, dy00 + dy01)), y(Corner[InputBox1, 1] - (dx00, dy00))), Corner[InputBox1, 3] + (dx00, dy00 + dy01), (x(Corner[InputBox1, 1] - (dx00, dy00)), y(Corner[InputBox1, 3] + (dx00, dy00 + dy01)))) → rectangleCorrect, f, g, h, i
  14. Vector(O1, O2) → strahl
  15. Sequence(Segment[O1 - (0, (1 / 2 * heightlines)) + (m, 0), O1 + (0, (1 / 2 * heightlines)) + (m, 0)], m, 0, x(O2) - 1) → lines
  16. Sequence(Text["\textsf{" + ((m * faktor)) + "}", (m + 0.1, -1.2), true, true, -0, 1], m, 0, x(O2) - 1) → text
  17. Vector(A1, A2) → va
  18. Vector(B1, B2) → vb
  19. Vector(A1 + (0, heightSolution), Acorrect + (0, heightSolution)) → vacorrect
  20. Vector((x(Acorrect), heightB + heightSolution), Bcorrect + (0, heightSolution)) → vbcorrect
  21. Vector((x(D1), heightB + heightSolution), (x(D2), heightB + heightSolution)) → vd
  22. Point(vacorrect) → P1
  23. Polygon(P1 + (0, width), P2 + (0, width), P2 - (0, width), P1 - (0, width)) → v2, j, k, l, m
  24. Point(vd) → P3
  25. Point(vbcorrect) → P4
  26. Sequence(Polygon[RecPunkte(i) + (0, width), RecPunkte(i + 1) + (0, width), RecPunkte(i + 1) - (0, width), RecPunkte(i) - (0, width)], i, 1, 4, 1) → l2
  27. Vector((x(D1), heightB), (x(D2), heightB)) → vd0

AI Drawing Prompt Reference

Draw a horizontal number line with evenly spaced ticks and labels whose spacing is set by a random factor. Add two input boxes for the minuend and subtrahend. When values are entered, mark the corresponding points on the line and draw an arrow vector pointing left from the minuend by the subtrahend length to illustrate subtraction. Also render a correct‑answer vector and a highlighted polygon to show the result, and an alternative vector with a feedback region for incorrect answers. The whole construction updates with new random numbers each problem.
The prompt above was compiled from the original drawing commands and is for reference only.