In this explainer, we will learn how to identify and tell the difference between rational and irrational numbers.

We recall that the set of rational numbers is the set of all numbers that can be written as the quotient of integers. More formally, we have

It is also worth noting that we can cancel any shared factors between and . This means we can write any rational number as a quotient that cannot be simplified. In other words, we can write any rational number in the form where the highest common factor of and is 1. We can then ask this question: Are all numbers rational?

The answer to this question is no; an example of a number that is not rational is . To see why this is the case, letβs assume that is a rational number. This means that for some integers and , where is nonzero and their highest common factor is 1. We now square both sides of the equation to get

If we multiply through by , we have

The left-hand side of the equation is even, so the right-hand side must also be even. However, is an integer, so must be even. Letβs say for some integer . Substituting this into the equation and simplifying gives

Now, the right-hand side of the equation is even, so the left-hand side must also be even. Since is an integer, then must be even. This means both and share a factor of 2. But we assumed that and have no common factors. This shows that our original assumption that is a rational number cannot be true. Therefore, is not rational.

This exact same reasoning can be used to show that the square root of any number that is not a perfect square is not rational.

We can now define irrational numbers as follows.

### Definition: The Set of Irrational Numbers

An irrational number is one that cannot be written in the form , where and are integers and is nonzero. Since this set contains every number that is not rational, we can write this set as the complement of .

We have therefore shown the following property and we can also extend this property to cube roots.

### Property: Square Roots and Cube Roots of Non-Perfect Squares and Non-Perfect Cubes

If is a positive integer and not a perfect square, then is irrational.

If is an integer and not a perfect cube, then is irrational.

In general, it is very difficult to determine if a number is rational or irrational. There are a few properties of the rational and irrational numbers that we can use to help us to determine if a number is rational or irrational.

### Property: Properties of Rational and Irrational Numbers

- If a number has a finite (or terminating) decimal expansion, then it is rational.
- If a number has a repeating decimal expansion (e.g., ), then it is rational.
- If a number has a decimal expansion that does not terminate or repeat, then it is irrational.

The reverse of these properties is also true: all rational numbers either have a terminating or repeating decimal expansion, and all irrational numbers have a nonterminating nonrepeating decimal expansion.

These properties allow us to determine if some numbers are rational or irrational. For example, it is known that the digits of never end and do not have a repeating pattern; therefore, is irrational.

Letβs now see an example of determining if a number is rational or irrational.

### Example 1: Identifying Whether an Integer is Rational or Irrational

Is 7 a rational or an irrational number?

### Answer

We recall that rational numbers are ones that can be written in the form , where and are integers and is nonzero. Irrational numbers are ones that are not rational. We can see that , so it is a rational number. All integers can be written in this way. Hence, all integers are rational.

In particular, 7 is rational.

In our next example, we will consider the possibility of a number being both rational and irrational.

### Example 2: Finding the Intersection of the Rational and Irrational Numbers

What is ?

### Answer

We can answer this question in terms of only set operations. We know that the intersection of any set with its complement is empty. In particular, .

However, it can be useful to think about this in terms of numbers. We recall that is the set of rational numbers, that is, the set of numbers that can be written as the quotient of two integers. Similarly, we recall that is the set of irrational numbers, that is, all the numbers that cannot be written as the quotient of two integers.

We see that a number cannot be both in and as either the number can be written as a quotient of two integers or it cannot. Hence,

Letβs now see an example of determining if a given number is rational or irrational.

### Example 3: Identifying Whether a Number with a Recurring Decimal Is Rational or Irrational

Is a rational or an irrational number?

### Answer

We recall that all numbers with a recurring decimal expansion are rational. Since has a recurring decimal expansion, we can conclude that the number is rational.

We can find the exact of the rational number by using a calculator. If we write into a calculator, we get

In our next example, we will determine whether the cube root of a given number is rational or irrational.

### Example 4: Identifying Whether a Cube Root is Rational or Irrational

Is a rational or an irrational number?

### Answer

We recall that rational numbers are ones that can be written as the quotient of two integers and that if is an integer and not a perfect cube, then is irrational.

Therefore, we should start by checking if 27 is a perfect cube. We note that

So,

Since all integers are rational, we know that 3 is rational.

Hence, is rational.

In our next example, we will determine if the solution to an equation is rational or irrational.

### Example 5: Identifying Whether the Solution to an Equation is Rational or Irrational

If is a solution to the equation , determine if or .

### Answer

We can solve this equation by taking the square roots of both sides of the equation, where we note we will have a positive and a negative root. So, we get

In both cases, we can subtract 1 from both sides of the equation to get

We can then recall that the square root of any non-perfect square is irrational. So, is irrational. This tells us that the decimal expansion of is nonrepeating and nonterminating. Multiplying by will not change the decimal expansion; it will only change the sign. Similarly, subtracting 1 will only change the unit digit. Hence, both and have nonrepeating and nonterminating decimal expansions; they are both irrational.

It is worth noting that we did not need to find the value of this solution. We could have just noted that is irrational and then found that the solution only involves subtracting and multiplying by nonzero rational numbers to this irrational number. This is enough to show that is irrational.

Another way of saying this is that since there is no rational number whose square is 8, there is no rational number we can add 1 to and then square to get 8.

Therefore, .

In our final example, we will use the area of a square to determine if its length is rational or irrational.

### Example 6: Identifying Whether the Side of a Square is Irrational given the Area

A square of side length cm has an
area of 280 cm^{2}. Which of the following is true about
?

- It is an integer number.
- It is a rational number.
- It is an irrational number.
- It is a natural number.
- It is a negative number.

### Answer

We recall that the area of a square of side length is given by

We are told that the area of this square is 280 cm^{2}. Substituting this value into the equation gives

We can solve for by taking the square root of both sides of the equation, where we note that cm is a length and so it must be positive. This gives us

We then recall that if is a positive integer and not a perfect square, then is irrational. We check the square numbers to see that 280 is not a perfect square. Therefore, is irrational.

Hence, the answer is C: it is an irrational number.

Letβs finish by recapping some of the important points from this explainer.

### Key Points

- An irrational number is one that cannot be written in the form , where and are integers and is nonzero.
- The set of irrational numbers is written as .
- A number cannot be both rational and irrational. In particular, .
- If is a positive integer and not a perfect square, then is irrational.
- If is an integer and not a perfect cube, then is irrational.
- If a number has a finite (or terminating) decimal expansion, then it is rational.
- If a number has a repeating decimal expansion, then it is rational.
- If a number has a decimal expansion that does not terminate or repeat, then it is irrational.