Prime Factorisation of Positive Integers

Prime Factorisation of Positive Integers
Loading the math board and drawing, please wait…
2020-08-18 06:29
This GeoGebra example demonstrates the prime factorisation of positive integers, providing an interactive visualisation of how any positive integer can be decomposed into a product of prime factors. The core mathematical concepts involved include prime numbers, factorisation, and the fundamental theorem of arithmetic. In terms of construction, it employs commands such as PrimeFactors to compute prime factors automatically, Append and Zip for list manipulation, Sequence to generate sequences of factors, and Textfield and TableText to display results. LaTeX is used for formatting mathematical expressions, and IsPrime checks for primality. Key objects include lists for storing factors, input boxes for user interaction, and buttons to trigger calculations. This example is suitable for educational purposes in middle or high school mathematics, particularly in number theory units, aiding students in understanding the principles of prime factorisation.

GeoGebra Commands & Parameters

  1. PrimeFactors(a) → list1
  2. Append(1, Sequence[Product[list1, k], k, 1, Length[list1]]) → list1P
  3. Zip(a / k, k, list1P) → listA
  4. Sequence(Append[First[list1, i], listA(i + 1)], i, 1, Length[listA] - 2) → listM1
  5. Append(listM1, list1) → listM2
  6. Textfield(a) → InputBox1
  7. TableText({First[listA, step + 1]}, "|100 _01vr") → text1
  8. Factors(a) → M1
  9. Unique(PrimeFactors[a]) → listUniqueFactors
  10. Append(Zip[Text[p] + (UnicodeToLetter[8901]), p, Take[listM3, 1, Length[listM3] - 1]], Text[Element[listM3, Length[listM3]]]) → listFactorText
  11. Zip(((Element[p, 1] * If[Element[p, 2] ≠ 1, (("^{" * Element[p, 2]) * "}")]) * If[{p} ≠ Last[M1], UnicodeToLetter[8901], ""]), p, M1) → listTextA
  12. LaTeX("=" + (Sum[listFactorText])) → text3
  13. IsPrime(a) → prime
  14. TableText({First[list1, step]}, "rv") → text2
  15. LaTeX("=\underline\underline{" + (Sum[listTextA]) + "}") → textA

AI Drawing Prompt Reference

Create an interactive number-theory visualization for prime factorization of positive integers: include a text input box where a user enters a positive integer and a control (such as a button) to trigger the calculation. Display, in a table-like presentation, the computed prime factors and their repeated exponents, and render the factorization as a product of terms. Show the equation by placing the input integer on the left and formatting the prime-factor product on the right, emphasizing the equality structure with clear text and typesetting (including an underlined/structured layout similar to an equation display).
The prompt above was compiled from the original drawing commands and is for reference only.