Skip to content
Family Table Math

Domain and Range

The domain of a function is the set of all inputs it accepts, and the range is the set of all outputs it can produce. Knowing them tells you where a graph exists and what values a formula can actually give, which matters for graphing, solving, and real-world problems.

  • Domain: all possible xx-values (inputs).
  • Range: all possible yy-values (outputs).
MeaningSet notation
all real numbers{x∈R}\{x \in \mathbb{R}\}
xx is at least 22{x∈R∣x≥2}\{x \in \mathbb{R} \mid x \ge 2\}
xx is any real number except −3-3{x∈R∣x≠−3}\{x \in \mathbb{R} \mid x \ne -3\}
yy is from −1-1 up to, but not including, 44{y∈R∣−1≤y<4}\{y \in \mathbb{R} \mid -1 \le y \lt 4\}
a few separate values{1,2,5}\{1, 2, 5\}

Read {x∈R∣x≥2}\{x \in \mathbb{R} \mid x \ge 2\} as “all real numbers xx such that xx is greater than or equal to 22”.

  • Domain: scan from left to right. Which xx-values does the graph cover?
  • Range: scan from bottom to top. Which yy-values does it cover?
  • A closed dot ● means that point is included. An open dot ○ means it isn’t.
  • An arrow means the graph keeps going forever in that direction.

In this course, watch for two restrictions:

  1. You can’t divide by zero. For 1x−3\dfrac{1}{x - 3}, the domain excludes x=3x = 3.
  2. You can’t take the square root of a negative number (in the real numbers). For x−5\sqrt{x - 5}, you need x−5≥0x - 5 \ge 0, so x≥5x \ge 5.

If neither happens, as with lines and parabolas, the domain is all real numbers.

In context, the situation can limit the domain and range: time can’t be negative, a number of people must be a whole number, and a ball’s height can’t go below the ground. The parent functions page lists the domain and range of the four basic graphs.

Find the domain and range of the function graphed below.

Graph of y = f(x) from a closed dot at (-3, 6) to an open dot at (4, 2.5), lowest point (1, -2) −4 −2 2 4 −2 2 4 6 (−3, 6) (4, 2.5) (1, −2) y = f(x)

Solution.

  • Domain: the graph runs from x=−3x = -3 (closed dot, included) to x=4x = 4 (open dot, not included): {x∈R∣−3≤x<4}\{x \in \mathbb{R} \mid -3 \le x \lt 4\}.
  • Range: the lowest point is (1,−2)(1, -2) and the highest is (−3,6)(-3, 6). Every height in between is covered: {y∈R∣−2≤y≤6}\{y \in \mathbb{R} \mid -2 \le y \le 6\}.

Notice that the range does not come from the endpoints alone. The lowest point is in the middle of the graph.

Find the domain and range of each function.

(a) f(x)=2x−7f(x) = 2x - 7 \qquad (b) g(x)=x2+3g(x) = x^2 + 3 \qquad (c) h(x)=x−5h(x) = \sqrt{x - 5} \qquad (d) k(x)=1x+2k(x) = \dfrac{1}{x + 2}

Solution.

(a) A slanted line goes forever in both directions. Domain {x∈R}\{x \in \mathbb{R}\}, range {y∈R}\{y \in \mathbb{R}\}.

(b) Any xx works. Since x2≥0x^2 \ge 0, the smallest output is 0+3=30 + 3 = 3. Domain {x∈R}\{x \in \mathbb{R}\}, range {y∈R∣y≥3}\{y \in \mathbb{R} \mid y \ge 3\}.

(c) Need x−5≥0x - 5 \ge 0, so x≥5x \ge 5. A square root is never negative, and it can be 00 (at x=5x = 5). Domain {x∈R∣x≥5}\{x \in \mathbb{R} \mid x \ge 5\}, range {y∈R∣y≥0}\{y \in \mathbb{R} \mid y \ge 0\}.

(d) Need x+2≠0x + 2 \ne 0, so x≠−2x \ne -2. A fraction with numerator 11 can never equal 00. Domain {x∈R∣x≠−2}\{x \in \mathbb{R} \mid x \ne -2\}, range {y∈R∣y≠0}\{y \in \mathbb{R} \mid y \ne 0\}.

Find the domain and range of f(x)=6−2x+1f(x) = \sqrt{6 - 2x} + 1.

Solution. The expression under the root must not be negative:

6−2x≥0−2x≥−6x≤3dividing by −2 flips the inequality\begin{aligned} 6 - 2x &\ge 0 \\ -2x &\ge -6 \\ x &\le 3 && \text{dividing by } -2 \text{ flips the inequality} \end{aligned}

The square root itself is at least 00, so f(x)f(x) is at least 0+1=10 + 1 = 1.

Domain {x∈R∣x≤3}\{x \in \mathbb{R} \mid x \le 3\}, range {y∈R∣y≥1}\{y \in \mathbb{R} \mid y \ge 1\}.

A ball is thrown upward from the ground. Its height in metres after tt seconds is h(t)=−5t2+20th(t) = -5t^2 + 20t, until it lands. Find the domain and range.

Solution. The ball is on the ground when h(t)=0h(t) = 0:

−5t2+20t=0⇒−5t(t−4)=0⇒t=0 or t=4-5t^2 + 20t = 0 \quad\Rightarrow\quad -5t(t - 4) = 0 \quad\Rightarrow\quad t = 0 \text{ or } t = 4

So the ball is in the air from t=0t = 0 to t=4t = 4 seconds.

The parabola is symmetric, so its highest point is halfway between the zeros, at t=2t = 2: h(2)=−20+40=20h(2) = -20 + 40 = 20 metres.

Domain {t∈R∣0≤t≤4}\{t \in \mathbb{R} \mid 0 \le t \le 4\}, range {h∈R∣0≤h≤20}\{h \in \mathbb{R} \mid 0 \le h \le 20\}.

Swapping domain and range. Domain is about xx (inputs, left to right). Range is about yy (outputs, bottom to top).

Including an open-dot value. In Example 1, x=4x = 4 is not in the domain, because the dot there is open.

Finding the range from the endpoints only. A graph can dip or rise in the middle. Look for the lowest and highest points, not just where it starts and stops.

Writing x≠5x \ne 5 for a square root. For x−5\sqrt{x - 5}, values like x=2x = 2 don’t work either. The restriction is x≥5x \ge 5. Save ≠\ne for dividing by zero.

Forgetting to flip the inequality when dividing by a negative number, as in Example 3.

Ignoring the real world. In Example 4, the formula works for any tt, but negative times and times after the ball lands make no sense.

1. (Warm-up) State the domain and range of {(−2,5),(0,3),(1,5),(4,8)}\{(-2, 5), (0, 3), (1, 5), (4, 8)\}.

Solution

Domain {−2,0,1,4}\{-2, 0, 1, 4\}. Range {3,5,8}\{3, 5, 8\} (list 55 only once).

2. (Warm-up) State the domain and range of f(x)=−4x+1f(x) = -4x + 1.

Solution

It’s a slanted line. Domain {x∈R}\{x \in \mathbb{R}\}, range {y∈R}\{y \in \mathbb{R}\}.

3. (Warm-up) State the domain and range of f(x)=x2−6f(x) = x^2 - 6.

Solution

Domain {x∈R}\{x \in \mathbb{R}\}. Since x2≥0x^2 \ge 0, the smallest output is −6-6: range {y∈R∣y≥−6}\{y \in \mathbb{R} \mid y \ge -6\}.

4. (Core) State the domain and range of g(x)=x+7g(x) = \sqrt{x + 7}.

Solution

Need x+7≥0x + 7 \ge 0, so x≥−7x \ge -7. Domain {x∈R∣x≥−7}\{x \in \mathbb{R} \mid x \ge -7\}, range {y∈R∣y≥0}\{y \in \mathbb{R} \mid y \ge 0\}.

5. (Core) State the domain and range of h(x)=1x−3h(x) = \dfrac{1}{x - 3}.

Solution

Need x−3≠0x - 3 \ne 0, so x≠3x \ne 3. The fraction can never equal 00.

Domain {x∈R∣x≠3}\{x \in \mathbb{R} \mid x \ne 3\}, range {y∈R∣y≠0}\{y \in \mathbb{R} \mid y \ne 0\}.

6. (Core) State the domain and range of f(x)=10−2xf(x) = \sqrt{10 - 2x}.

Solution10−2x≥0⇒−2x≥−10⇒x≤510 - 2x \ge 0 \quad\Rightarrow\quad -2x \ge -10 \quad\Rightarrow\quad x \le 5

Domain {x∈R∣x≤5}\{x \in \mathbb{R} \mid x \le 5\}, range {y∈R∣y≥0}\{y \in \mathbb{R} \mid y \ge 0\}.

7. (Core) Field trip tickets cost $6 each, and a school can buy at most 120. The cost in dollars is C(n)=6nC(n) = 6n, where nn is the number of tickets. State the domain and range.

Solution

You can only buy a whole number of tickets, from 00 to 120120.

Domain {0,1,2,…,120}\{0, 1, 2, \dots, 120\}. Range {0,6,12,…,720}\{0, 6, 12, \dots, 720\}, the multiples of 66 from 00 to 720720.

8. (Challenge) State the domain and range of f(x)=−2(x−1)2+8f(x) = -2(x - 1)^2 + 8.

Solution

Any xx works: domain {x∈R}\{x \in \mathbb{R}\}.

Since (x−1)2≥0(x - 1)^2 \ge 0, the term −2(x−1)2-2(x - 1)^2 is at most 00. So f(x)f(x) is at most 88, and it equals 88 when x=1x = 1.

Range {y∈R∣y≤8}\{y \in \mathbb{R} \mid y \le 8\}.

9. (Challenge) Find the domain of f(x)=x−2x−5f(x) = \dfrac{\sqrt{x - 2}}{x - 5}.

Solution

There are two restrictions:

  • the square root needs x−2≥0x - 2 \ge 0, so x≥2x \ge 2
  • the denominator needs x−5≠0x - 5 \ne 0, so x≠5x \ne 5

Domain {x∈R∣x≥2, x≠5}\{x \in \mathbb{R} \mid x \ge 2, \ x \ne 5\}.