Suppose you and 2 of your friends were out for lunch and decide to buy tacos. Together you have $15 to spend on lunch, and tacos are $1.25 each. It is clear that the total cost could be graphed as a function of the number of tacos purchased, but how would you specify that the graph should not include values greater than $15 or less than $3.75 (one taco each)?

### Intervals and Interval Notation

#### Real Values and Intervals

A function is defined as a **real function** if both the domain and the range are sets of real numbers. Many of the functions you have likely encountered before are real functions, and many of these functions have Domain = \begin{align*}\mathbb R\end{align*}. Consider, for example, the function \begin{align*}y=3x\end{align*}. A section of the graph of this function is shown below.

You may already be familiar with the graphs of lines. In particular, you may already be in the habit of placing arrows at the ends. We do this in order to indicate that the line will continue forever in both the positive and negative directions, both in terms of the domain and the range. The line above, however, only shows the function \begin{align*} y=3x\end{align*} on the **interval** [-3, 3]. The square brackets indicate that the graph includes the endpoints of the interval, where *x* = -3 and *x* = 3. We call this a **closed interval**. A closed interval contains its endpoints. In contrast, an **open interval** does *not* contain its endpoints. We indicate an open interval with parentheses. For example, (-3, 3) indicates the set of numbers between -3 and 3, *not including* -3 and 3. You may have noticed that the open interval notation looks like the notation for a point (*x, y*) in the plane. It is important to read an example or a homework problem carefully to avoid confusing a point with an interval! The difference is generally quite clear from the context.

The table below summarizes the kinds of intervals you may need to consider while studying functions and their domains:

Interval notation | Inequality notation | Description |
---|---|---|

\begin{align*}\,\! [a,b]\end{align*} | \begin{align*}\,\! a \leq x \leq b\end{align*} | The value of x is between a and b, including a and b, where a, b are real numbers. |

\begin{align*}\,\! (a,b) \end{align*} | \begin{align*}\,\! a < x < b\end{align*} | The value of x is between a and b, not including a and b. |

\begin{align*}\,\! [a,b)\end{align*} | \begin{align*}\,\! a \leq x < b\end{align*} | The value of x is between a and b, including a, but not including b. |

\begin{align*}\,\! (a,b]\end{align*} | \begin{align*}\,\! a < x \leq b\end{align*} | The value of x is between a and b, including b, but not including a. |

\begin{align*}(a, \infty)\end{align*} | \begin{align*}\,\!x > a\end{align*} | The value of x is strictly greater than a. |

\begin{align*}[a, \infty)\end{align*} | \begin{align*}\,\!x \geq a \end{align*} | The value of x is greater than or equal to a |

\begin{align*}(-\infty, a)\end{align*} | \begin{align*}\,\!x <a \end{align*} | The value of x is strictly less than a |

\begin{align*}(-\infty, a]\end{align*} | \begin{align*}\,\! x \leq a \end{align*} | The value of x is less than or equal to a. |

### Examples

#### Example 1

Earlier, you were given a problem about buying tacos for lunch.

Together, you have $15 to spend on lunch, and tacos are $1.25 each. It is clear that the total cost could be graphed as a function of the number of tacos purchased, but how would you specify that the graph should not include values greater than $15 or less than $3.75 (one taco each)?

To specify that the graph of the cost of lunch only includes values between $3.75 and $15.00, specify the interval of the domain as: [3.75, 15].

#### Example 2

Identify the sets described:

- \begin{align*}(-3, 9]\end{align*}

The set of numbers between -3 and 9, ‘‘not including’’ the actual value of -3, but ‘‘including’’ 9.

- \begin{align*}[-23, 12]\end{align*}

The set of numbers between -23 and 12, ‘‘including’’ the values -23 and 12.

- \begin{align*}(-\infty, 0)\end{align*}

All numbers less than 0, not including 0 itself.

#### Example 3

Sketch the graph of the function \begin{align*} f(x)=\frac{1}{2}x-6 \end{align*} on the interval [-4, 12).

The figure below shows a graph of \begin{align*} f(x)=\frac{1}{2}x-6 \end{align*} on the given interval:

#### Example 4

Describe the specified intervals, use interval notation:

- All positive numbers

\begin{align*}(0, +\infty)\end{align*}

Zero is neither positive nor negative, so the “(“ is used to specify that zero is ‘‘not’’ included. Since there is no maximum positive number, we specify that infinity is the upper value, and use “)” since it cannot be reached.

- The numbers between negative eight and two hundred forty two, including both.

\begin{align*}[-8, 242]\end{align*}

The “[“ is used on both ends, since both values are included.

- All negative numbers, zero, and the positive numbers up to and including nine.

\begin{align*}(-\infty, 9]\end{align*}

The “(“ denotes that negative infinity cannot be reached, and “]” on the other end specifies that 9 is included in the set.

#### Example 5

Describe the domain and range in the sets in the images below using interval notation.

a. | b. |
---|

- The domain is the set of
*x*values starting with the included*-6*and ending at*4*, which is not included: [-6, 4).

The range is the set of *y* values from -3 (not included) to 4 (included): (-3, 4].

- Domain: [-6, 7) (from above)

Range: [-1, 6) (from above)

### Review

Write the following in interval notation.

- \begin{align*}-3 \leq x <1\end{align*}
- \begin{align*}0 < x <2\end{align*}
- \begin{align*}x > -3\end{align*}
- \begin{align*}x \leq 2\end{align*}

Solve and put your answer in interval notation.

- \begin{align*}-2x + 3 < 1\end{align*}
- \begin{align*}7x + 4 \leq 2x - 6\end{align*}

For each number line, write the given set of numbers in interval notation.

Name the domain and range for each relation using interval notation.

Express the following sets using interval notation, then sketch them on a number line.

- {\begin{align*}x : −1 \leq x \leq 3\end{align*}}
- {\begin{align*}x : −2 \leq x < 1\end{align*}}
*A is the set of all numbers bigger than 2 but less than or equal to 5.*- {\begin{align*}x: – 3 < x < \infty \end{align*}}

### Review (Answers)

To see the Review answers, open this PDF file and look for section 1.3.