Identifying Prime and Composite Numbers

Identifying Prime and Composite Numbers

Some numbers, like \(72,\) have many factors. Other numbers, such as \(7,\) have only two factors: \(1\) and the number. A number with only two factors is called a prime number. A number with more than two factors is called a composite number. The number \(1\) is neither prime nor composite. It has only one factor, itself.

Prime Numbers and Composite Numbers

A prime number is a counting number greater than \(1\) whose only factors are \(1\) and itself.

A composite number is a counting number that is not prime.

The figure below lists the counting numbers from \(2\) through \(20\) along with their factors. The highlighted numbers are prime, since each has only two factors.

This figure shows a table with twenty rows and three columns. The first row is a header row. It labels the columns as “Number”, “Factor” and “Prime or composite?” The second row lists the number 2, in red, under the “Number” column, the numbers 1 and 2 under the “Factors” column and the word prime under the “Prime or Composite?” column. The third row lists the number 3, in red, under the “Number” column, the numbers 1 and 3 under the “Factors” column and the word prime under the “Prime or Composite?” column. The fourth row lists the number 4 under the “Number” column, the numbers 1, 2 and 4 under the “Factors” column and the word composite under the “Prime or Composite?” column. The fifth row lists the number 5, in red, under the “Number” column, the numbers 1 and 5 under the “Factors” column and the word prime under the “Prime or Composite?” column. The sixth row lists the number 6 under the “Number” column, the numbers 1, 2, 3 and 6 under the “Factors” column and the word composite under the “Prime or Composite?” column. The seventh row lists the number 7, in red, under the “Number” column, the numbers 1 and 7 under the “Factors” column and the word prime under the “Prime or Composite?” column. The eighth row lists the number 8 under the “Number” column, the numbers 1, 2, 4 and 8 under the “Factors” column and the word composite under the “Prime or Composite?” column. The ninth row lists the number 9 under the “Number” column, the numbers 1, 3 and 9 under the “Factors” column and the word composite under the “Prime or Composite?” column. The tenth row lists the number 10 under the “Number” column, the numbers 1, 2, 5 and 10 under the “Factors” column and the word composite under the “Prime or Composite?” column. The eleventh row lists the number 11, in red, under the “Number” column, the numbers 1 and 11 under the “Factors” column and the word prime under the “Prime or Composite?” column. The twelfth row lists the number 12 under the “Number” column, the numbers 1, 2, 3, 4, 6 and 12 under the “Factors” column and the word composite under the “Prime or Composite?” column. The thirteenth row lists the number 13, in red, under the “Number” column, the numbers 1 and 13 under the “Factors” column and the word prime under the “Prime or Composite?” column. The fourteenth row lists the number 14 under the “Number” column, the numbers 1, 2, 7 and 14 under the “Factors” column and the word composite under the “Prime or Composite?” column. The fifteenth row lists the number 15 under the “Number” column, the numbers 1, 2, 3, 5 and 15 under the “Factors” column and the word composite under the “Prime or Composite?” column. The sixteenth row lists the number 16 under the “Number” column, the numbers 1, 2, 4, 8 and 16 under the “Factors” column and the word composite under the “Prime or Composite?” column. The seventeenth row lists the number 17, in red, under the “Number” column, the numbers 1 and 17 under the “Factors” column and the word prime under the “Prime or Composite?” column. The eighteenth row lists the number 18 under the “Number” column, the numbers 1, 2, 3, 6, 9 and 18 under the “Factors” column and the word composite under the “Prime or Composite?” column. The nineteenth row lists the number 19, in red, under the “Number” column, the numbers 1 and 19 under the “Factors” column and the word prime under the “Prime or Composite?” column. The twentieth row lists the number 20 under the “Number” column, the numbers 1, 2, 4, 5, 10 and 20 under the “Factors” column and the word composite under the “Prime or Composite?” column.

Factors of the counting numbers from \(2\) through \(20,\) with prime numbers highlighted

The prime numbers less than \(20\) are \(2,3,5,7,11,13,17,\text{and}\phantom{\rule{0.2em}{0ex}}19.\) There are many larger prime numbers too. In order to determine whether a number is prime or composite, we need to see if the number has any factors other than \(1\) and itself. To do this, we can test each of the smaller prime numbers in order to see if it is a factor of the number. If none of the prime numbers are factors, then that number is also prime.

Determine if a number is prime.

  1. Test each of the primes, in order, to see if it is a factor of the number.
  2. Start with \(2\) and stop when the quotient is smaller than the divisor or when a prime factor is found.
  3. If the number has a , then it is a . If it has no prime factors, then the number is prime.

Example

Identify each number as prime or composite:

  1. \(\phantom{\rule{0.2em}{0ex}}83\phantom{\rule{0.2em}{0ex}}\)
  2. \(\phantom{\rule{0.2em}{0ex}}77\)

Solution

Test each prime, in order, to see if it is a factor of \(83\), starting with \(2,\) as shown. We will stop when the quotient is smaller than the divisor.

Prime Test Factor of \(83?\)
\(2\) Last digit of \(83\) is not \(0,2,4,6,\text{or}\phantom{\rule{0.2em}{0ex}}8.\) No.
\(3\) \(8+3=11,\) and \(11\) is not divisible by \(3.\) No.
\(5\) The last digit of \(83\) is not \(5\) or \(0.\) No.
\(7\) \(83÷7=11.857\text{….}\) No.
\(11\) \(83÷11=7.545\text{…}\) No.

We can stop when we get to \(11\) because the quotient \(\text{(7.545…)}\) is less than the divisor.

We did not find any prime numbers that are factors of \(83,\) so we know \(83\) is prime.

Test each prime, in order, to see if it is a factor of \(77.\)

Prime Test Factor of \(77?\)
\(2\) Last digit is not \(0,2,4,6,\text{or}\phantom{\rule{0.2em}{0ex}}8.\) No.
\(3\) \(7+7=14,\) and \(14\) is not divisible by \(3.\) No.
\(5\) the last digit is not \(5\) or \(0.\) No.
\(7\) \(77÷11=7\) Yes.

Since \(77\) is divisible by \(7,\) we know it is not a prime number. It is composite.

This lesson is part of:

The Language of Algebra

View Full Tutorial

Track Your Learning Progress

Sign in to unlock unlimited practice exams, tutorial practice quizzes, personalized weak area practice, AI study assistance with Lexi, and detailed performance analytics.