[b]Definition:[/b] A [b]prime number [/b]is a positive integer [math]p>1[/math] that has no positive integer divisors other than [math]1[/math] and [math]p[/math] itself. More concisely, a prime number [math]p[/math] is a positive integer having exactly one positive divisor other than [math]1[/math], meaning it is a number that cannot be factored.[br]Positive integers other than 1 which are not prime are called [b]composite numbers[/b].[br][br][b]Example:[/b] the only divisors of [math]13[/math] are [math]1[/math] and [math]13[/math], making [math]13[/math] a prime number, while the number [math]24[/math] has divisors [math]1,2,3,4,6,8,12[/math], and [math]24[/math] (corresponding to the factorization [math]24=2^3\cdot3[/math]), making [math]24[/math] not a prime number.
[list=1][*]Data Pointed is the home of Stephen Von Worley's data visualization research; a journal of interesting information imagery and news from around the world; and a place where you can spend a few minutes, have a laugh or two, and discover something new. Follow this link to find a very nice visualization of prime and composite numbers: http://www.datapointed.net/visualizations/math/factorization/animated-diagrams/[/*][*]In mathematics, [b]the sieve of Eratosthenes [/b]is an ancient algorithm for finding all prime numbers up to any given limit.[br][b]Method:[/b][br][br]2.1. Create a list of consecutive integers from [math]2[/math] through [math]n[/math]: [math]2,3,4,\ldots,n[/math].[br]2.2. Initially, let [math]p=2[/math], the smallest prime number.[br]2.3. Enumerate the multiples of [math]p[/math] by counting in increments of [math]p[/math] from [math]2p[/math] to [math]n[/math], and mark them in the list (these will be [math]2p,3p,4p,\ldots[/math]; [math]p[/math] itself should not be marked).[br]2.4. Find the smallest number in the list greater than [math]p[/math] that is not marked. If there was no such number, stop. Otherwise, let [math]p[/math] now equal this new number (which is the next prime), and repeat from step 2.3.[br]2.5. When the algorithm terminates, the numbers remaining not marked in the list are all the primes below [math]n[/math].[br][/*][/list]
The purpose of the applet below is to sort out prime numbers from composite numbers.[br]Click on the squares that contain prime numbers and then click on check.[br]Try it as many times as you may need.
[url=https://mathworld.wolfram.com/PrimeNumber.html][i]Animated Factorization Diagrams – Data Pointed[/i]. Data Pointed RSS. (n.d.). http://www.datapointed.net/visualizations/math/factorization/animated-diagrams/. [br][br]amelka12. (2019, October 14). [i]Kopia Liczby pierwsze / Prime numbers[/i]. GeoGebra. https://www.geogebra.org/m/ntrhsppk. [br][br][br][/url]Weisstein, Eric W. "Prime Number." From [url=https://mathworld.wolfram.com/][i]MathWorld[/i][/url]--A Wolfram Web Resource. [url=https://mathworld.wolfram.com/PrimeNumber.html]https://mathworld.wolfram.com/PrimeNumber.html[br][br][/url][url=https://mathworld.wolfram.com/about/author.html]Vuković, A. M. (n.d.). [i]Sieve of Eratosthenes[/i]. GeoGebra. https://www.geogebra.org/m/uGX53dy7. [br][br]Wikimedia Foundation. (2021, July 16). [i]Sieve of Eratosthenes[/i]. Wikipedia. https://en.wikipedia.org/wiki/Sieve_of_Eratosthenes. [br][/url]