Prime & Composite Numbers
Definition:Aprime numberis awhole numberwith exactly two integral divisors,and itself.
The numberis not a prime, since it has only one divisor.
So the smallest prime numbers are:
The numberis not prime, since it has three divisors (,, and), andis not prime, since it has four divisors (,,, and).
Definition:Acomposite numberis a whole number with more than two integral divisors.
So all whole numbers (exceptand) are either prime or composite.
Example:
is prime, since its only divisors areand.
is composite, since it hasandas divisors.
How can you tell if a number is prime?
First of all, here are some ways to tell if a number is NOT prime:
Any number greater thanwhich is a multiple ofis not a prime, since it has at least three divisors:,, and itself. (This meansis the only even prime.)
Any number greater thanwhich is a multiple ofis not a prime, since it has,and itself as divisors. (For example,is not prime, since.)
Any number which is a multiple ofis also a multiple of, so we can rule these out.
Any number greater thanwhich is a multiple ofis not a prime. (So the only prime number ending with aorisitself.)
Any number which is a multiple ofis also a multiple ofand, so we can rule these out too.
You can continue like this... basically, you just have to test for divisibility by primes!
Example 1:
Isprime?
First test for divisibility by.is odd, so it's not divisible by.
Next,test for divisibility by. Add the digits:. Sinceis not a multiple of, neither is. (Remember, this trick only works to test divisibility byand.)
Sincedoesn't end in aor a,这不是整除.
Next, test for divisibility by. You'll find that.
So the answer is NO...is not prime.
Example 2:
Isprime?
First test for divisibility by.is odd, so it's not divisible by.
Next,test for divisibility by. Add the digits:. Sinceis not a multiple of, neither is.
Sincedoesn't end in aor a,这不是整除.
Next, test for divisibility by. You'll find thatdoesn't go in evenly.
The next prime is. Butdoesn't go in evenly, either.
You can stop now... it must be prime! You don't need to keep checking for divisibility by the next primes (etc.). The reason is that ifwent in evenly, then we would havefor some number. But thenwould have to be less than... and we already know thatis not divisible by any number smaller than.
So the answer is YES...is prime.
For more advanced topics and a list of the firstprimes, go to thePrime Pageor the page onprime factorization.