Prime number facts for kids
A composite number is a whole number that can be made by multiplying two smaller whole numbers (not including 1). Think of it like building with blocks! If you can make a rectangle with a number of blocks, and the sides are longer than 1 block, then it's a composite number. The smallest composite number is 4, because you can make it by multiplying 2 x 2. The number 1 is special and is not considered a composite number.
A prime number is a whole number greater than 1 that can only be made by multiplying 1 and itself. It's like a number of blocks that can only form a long, thin rectangle (like 1 block by 7 blocks). The smallest prime number is 2. There is no biggest prime number; they go on forever! Some other small prime numbers are 3, 5, 7, 11, and 13.
Mathematicians find it tricky to figure out how prime numbers appear. The bigger a number gets, the harder it is to tell if it's prime. There are special rules and ideas, like the Prime number theorem, that help us understand them better.
Contents
Discovering Prime Numbers
Using the Sieve of Eratosthenes
There's a cool and simple way to find prime numbers called the Sieve of Eratosthenes. An ancient Greek mathematician named Eratosthenes came up with it. It works like a sieve, which is a tool that lets small things pass through while holding back bigger things. In this case, it "catches" the composite numbers and lets the prime numbers "pass through."
Here's how you can use the Sieve of Eratosthenes:
- Get a piece of paper and write down all the whole numbers starting from 2, up to the number you want to check. Remember, don't write down 1, because it's not a prime number.
- At the beginning, none of the numbers should be crossed out.
Now, follow these steps:
- Start with the number 2. Let's call this number p.
- Look at your list. If p is the last number you haven't checked yet, then you're almost done! If not, go to the next step.
- Starting from p, count out p numbers and cross out that number. Keep doing this until you reach the end of your list. This means you're crossing out all the numbers that are multiples of p (like p x 2, p x 3, and so on). These are composite numbers.
- For example, the first time you do this (with p = 2), you'll cross out 4, 6, 8, and so on.
- The next time (with p = 3), you'll cross out 6, 9, 12, and so on. (Some numbers might already be crossed out, which is fine!)
- Now, add 1 to p.
- Check the new value of p. If it's already crossed out, it means it's a composite number. Go back to the previous step and add 1 to p again.
- If the new value of p is not crossed out, it means it's a prime number! Go back to step 2 and repeat the process with this new prime p.
- When you're finished, all the numbers that are crossed out are composite numbers. All the numbers that are not crossed out are prime numbers!
For example, if you do this up to the number 10, you will find that 2, 3, 5, and 7 are prime numbers. The numbers 4, 6, 8, 9, and 10 are composite numbers.
This method is great for finding smaller prime numbers. However, for very, very large numbers, mathematicians use more complex computer programs and tests, like Fermat's primality test or the Miller-Rabin primality test. These tests help them quickly check if a huge number is prime or not.
Why Prime Numbers Are Important
Prime numbers are super important in mathematics and computer science. They have many real-world uses, especially when it comes to keeping information secret! It's very hard to break down extremely large numbers into their prime factors (the prime numbers that multiply to make them). This difficulty makes them perfect for creating secret codes.
Keeping Information Secret
- When you use a bank card at an ATM, your secret access code needs to be protected. It can't just be stored openly on the card. Instead, it's hidden using a process called encryption. This encryption often uses huge prime numbers, along with multiplication, division, and finding remainders. A common method is called RSA.
- If you have a digital signature for your email, it also uses encryption. This makes sure that no one can pretend to be you and send fake emails. Before your email is sent, a special "hash value" is created from your message. This value is then combined with your digital signature to make sure the email is truly from you. The methods used are similar to those for bank cards.
The Search for Giant Primes
Finding the largest known prime number has become a bit like a sport for mathematicians and computer enthusiasts! It's a huge challenge to test if a number is prime when it's incredibly large. The biggest primes found so far are usually a special type called Mersenne primes. This is because there's a very fast test for them called the Lucas-Lehmer test.
Images for kids
-
The sieve of Eratosthenes starts with all numbers unmarked (gray). It repeatedly finds the first unmarked number, marks it as prime (dark colors) and marks its square and all later multiples as composite (lighter colors). After marking the multiples of 2 (red), 3 (green), 5 (blue), and 7 (yellow), all primes up to the square root of the table size have been processed, and all remaining unmarked numbers (11, 13, etc.) are marked as primes (magenta).
-
Construction of a regular pentagon using straightedge and compass. This is only possible because 5 is a Fermat prime.
See also
In Spanish: Número primo para niños