LCM by Listing Multiples
Loading the math board and drawing, please wait…
This example demonstrates how to find the Least Common Multiple (LCM) of two natural numbers by listing their multiples. Core math concepts involved include natural numbers, multiples, and LCM. Construction highlights the use of GeoGebra commands like Append, If, Sequence, and objects such as box1, listNum, n1 to dynamically generate and highlight multiples. Suitable for middle school mathematics education to help students understand and calculate LCM.
GeoGebra Commands & Parameters
Append("", Sequence[Text[i], i, 1, 30]) → listNumIf(SelectedIndex[listNum1] > 1, SelectedIndex[listNum1] - 1) → n1If(SelectedIndex[listNum2] > 1, SelectedIndex[listNum2] - 1) → n2If(n1 > 0 ∧ n2 > 0, LCM[n1, n2], 0) → aIf(t2 ≥ 1, Sequence[(n2 * i), i, 1, t2], {0}) → listMultiple2If(t1 ≥ 1, Sequence[(n1 * i), i, 1, t1], {0}) → listMultiple1Sequence((i * a), i, 1, 30) → listCMIf(listMultiple1 ≟ {0} ∨ t1 ≟ 0, {0}, First[listMultiple1, t1]) → listM1If(t1 > 0, Sequence[If[IndexOf[listM1(i), listCM] ≥ 1 ∧ box1, "\blue{\bold{", ""] + (Text[listM1(i)]) + (If[IndexOf[listM1(i), listCM] ≥ 1 ∧ box1, "}}", ""]) + "\,,\," + (If[i ≟ 10 ∨ i ≟ 20, "\\", ""]), i, 1, t1], {"0"}) → listMultiText1If(listMultiple2 ≟ {0} ∨ t2 ≟ 0, {0}, First[listMultiple2, t2]) → listM2If(t2 > 0, Sequence[If[IndexOf[listM2(i), listCM] ≥ 1 ∧ box1, "\blue{\bold{", ""] + (Text[listM2(i)]) + (If[IndexOf[listM2(i), listCM] ≥ 1 ∧ box1, "}}", ""]) + "\,,\," + (If[i ≟ 10 ∨ i ≟ 20, "\\", ""]), i, 1, t2], {"0"}) → listMultiText2If(listMultiText1 ≟ {"0"}, " ", Sum[listMultiText1]) → textSum1If(listMultiText2 ≟ {"0"}, " ", Sum[listMultiText2]) → textSum2If(t1 > 1, "the first " + t1 + " multiples", t1 ≟ 1, "the first multiple") → text1If(t2 > 1, "the first " + t2 + " multiples", t2 ≟ 1, "the first multiple") → text2
AI Drawing Prompt Reference
Create a graphic for the least common multiple of two natural numbers. First, input two natural numbers and list their first 30 multiples. Then, find their least common multiple and highlight it in blue. Finally, compare these multiples with the least common multiple to find the common multiples and mark them in blue.
The prompt above was compiled from the original drawing commands and is for reference only.