Learn
Lesson · Lines, Functions and Graphs · Functions

Domain and Range

The domain is the set of inputs a function accepts; the range is the set of outputs it actually produces. Among the formulas available so far, a zero denominator and an even root of a negative are the two domain failures; finding a range needs an argument about the outputs.

domain = every input the rule accepts range = every output the rule produces exclude: denominator = 0 even root of a negative [a, b] includes the ends (a, b) excludes them U joins pieces
The two sets, and the two exclusions used here

Core ideas

What this lesson establishes

“What a Function Is” said a function must give an output for each input it claims. This lesson is about stating exactly what it claims.

1

The domain is part of the function

A function is a rule together with the set it accepts. f(x) = x² on every real number and f(x) = x² on x ≥ 0 are different functions with the same formula, and “Inverse Functions” depends on the difference. When no domain is stated, the convention is the largest set of real numbers for which the formula gives a real value.

2

Two checks cover every formula in this lesson

Among the formulas used here, a real input fails for one of two reasons: it makes a denominator zero, or it puts a negative number under a square root or another even root. Logarithms add a new condition in Exponential and Logarithmic Functions; for now, adding, multiplying, cubing and taking an odd root accept every real number.

3

The range is what actually comes out

The domain can be read off the formula by inspection. The range usually cannot: it needs a graph landmark or an argument about which outputs are reachable. f(x) = x² accepts every real input but produces only non-negative outputs, while g(x) = 2x − 3 reaches every real output.

The material

Finding the domain, then the range

Two exclusions to test for, interval notation to write the answer in, and the reason ranges are harder.

Definition · Domain and range

The domain of a function is the set of inputs it is defined on. The range is the set of outputs it produces: every value y for which some x in the domain has f(x) = y. The range is a set of values actually attained, not a set of values that look permitted.

When a function arrives as a bare formula, the domain is not stated and has to be inferred. The convention is the natural domain: every real number for which the formula produces a real value. This is a convention, chosen because it is the largest sensible default, and a problem is free to override it by naming a smaller set.

The two exclusions

  • A zero denominator. Division by zero is undefined, so set every denominator equal to zero, solve, and exclude the solutions. For (x + 2)/((x − 2)(x − 3)), the denominator is already displayed as factors, so the excluded inputs are 2 and 3. Producing such a factorisation is Polynomials and Factoring work, not a hidden prerequisite here.
  • An even root of a negative. √(2x − 7) needs 2x − 7 ≥ 0, so x ≥ 7/2. Write the exact fraction, not 3.5. Fourth roots, sixth roots and so on behave the same way; cube roots do not: the cube root of −8 is −2, a perfectly real value.

When both appear, both conditions must hold at once. For √(x + 4)/(x − 1) the numerator demands x ≥ −4 and the denominator forbids x = 1, so the domain is [−4, 1) ∪ (1, ∞). Note that −4 is included: √0 = 0 is a perfectly good output. It is the denominator, not the root, that produces an open end.

f(x) = (x + 2)/((x - 2)(x - 3)) bottom is already factored domain: x =/= 2, x =/= 3 g(x) = sqrt(2x - 7) 2x - 7 >= 0 -> x >= 7/2 h(x) = sqrt(x + 4)/(x - 1) x >= -4 AND x =/= 1 domain: [-4, 1) U (1, inf) k(x) = sqrt(9 - x^2) 9 - x^2 >= 0 -> -3 <= x <= 3

The last one is worth slowing down for. 9 − x² ≥ 0 is x² ≤ 9, and the inputs whose square is at most 9 are those between −3 and 3 inclusive. Taking a square root of both sides of x² ≤ 9 and writing x ≤ 3 loses the whole left half of the answer; this is the absolute value inequality from “Absolute Value Inequalities” in Linear Equations and Inequalities, in a new costume.

Why the range is harder

The domain is a question about the formula: which inputs does it choke on. The range is a question about the function's behaviour across its whole domain, and there is no equivalent checklist. Three tools cover most cases at this level.

  1. Use non-negativity, for a square or absolute value. x² ≥ 0, with equality at x = 0, and every non-negative y is (√y)²; the range of x² is [0, ∞). Likewise |x| − 2 has range [−2, ∞).
  2. Track the outer operation, for a root. √(9 − x²) takes the square root of something running from 0 up to 9, so the outputs run from 0 to 3, giving [0, 3].
  3. Solve for the input, for a non-horizontal line. If y = 2x − 3, then x = (y + 3)/2 exists for every real y, so the line reaches every real output.
Example · An excluded input removes an output, not its own number

Let q(x) = 2x + 1 with the stated domain x ≠ 3. The formula is a non-horizontal line, so each output comes from exactly one input. Removing x = 3 therefore removes the point (3, 7) and the output 7. The domain excludes 3; the range excludes 7. Copying the input restriction into the range confuses the two axes.

Writing the answer

Interval notation from “Interval and Set-Builder Notation” in Linear Equations and Inequalities, is the expected form. A square bracket includes the endpoint, a round bracket excludes it, and ∞ always takes a round bracket because it is not a number that can be attained. Use ∪ to join the pieces when an excluded point splits the domain, and list the pieces in increasing order.

One habit is worth building: after writing a domain, test a value just inside each end and one value that should be excluded. For [−4, 1) ∪ (1, ∞) try x = −4, which gives 0/(−5) = 0, and x = 1, which divides by zero. Two substitutions confirm both boundary decisions in about ten seconds.

Interactive

Domain and range

What the formula forbids, and what it can produce

A function
fthe second curvedashed: y = x, or a discarded halfwhere it fails

Method

Finding a domain in four passes

Scan for each exclusion separately, then combine. Combining first is where answers go missing.

1

List every denominator

Including denominators buried inside a root or a compound fraction. Set each to zero, solve, and mark those inputs as excluded. This lesson supplies denominators already factored when there is more than one zero; Polynomials and Factoring teaches how to produce the factorisation.

2

List every even root

Square roots, fourth roots, and any rational exponent with an even denominator. Each contributes an inequality of the form "the inside is at least zero". Odd roots contribute nothing.

3

Solve each condition on its own

Keep the conditions separate while you solve them. 9 − x² ≥ 0 needs the two-sided answer −3 ≤ x ≤ 3, and mixing it with another condition before it is solved is how one half of it disappears.

4

Intersect, then write it in intervals

Every condition must hold at once, so take the overlap, not the union. The union symbol appears in the written answer only because excluded points cut the overlap into pieces.

In, out and excluded

Score 0 / 0

Four domains and two ranges

The domains first, since they are mechanical. The ranges afterwards, since they are not.

1. f(x) = (x + 2)/((x - 2)(x - 3)) (x - 2)(x - 3) = 0 -> x = 2, x = 3 domain (-inf, 2) U (2, 3) U (3, inf) 2. g(x) = sqrt(2x - 7) 2x - 7 >= 0 -> x >= 7/2 domain [7/2, inf) note 7/2, not 3.5 3. h(x) = sqrt(x + 4)/(x - 1) x + 4 >= 0 -> x >= -4 x - 1 =/= 0 -> x =/= 1 domain [-4, 1) U (1, inf) check x = -4: 0/(-5) = 0 defined, so -4 is IN x = 1: division by 0 excluded 4. k(x) = sqrt(9 - x^2) 9 - x^2 >= 0 -> x^2 <= 9 -> -3 <= x <= 3 domain [-3, 3] ranges 5. p(x) = x^2 x^2 >= 0, and equals 0 at x = 0 every y >= 0 is reached at x = sqrt(y) range [0, inf) 6. r(x) = |x| - 2 |x| >= 0, and equals 0 at x = 0 range [-2, inf) r(0) = -2

Line 3 is the one that decides whether the technique has been understood. Both exclusions are present, they come from different parts of the expression, and the left end is closed while the interior point is open. Reading [−4, 1) ∪ (1, ∞) back out loud as "from −4 inclusive, everything except 1" is a fair test.

Lines 5 and 6 use facts already taught in Foundations of Algebra: a square and an absolute value are non-negative. Subtracting 2 changes every output of |x| and therefore changes the range endpoint, not the domain.

For a faded domain, take s(x) = √(x + 2)/(x − 4). The root condition x ≥ −2 is supplied. Find the denominator exclusion, intersect the conditions, write the intervals, and test both −2 and 4. Then find the range of t(x) = |x + 1| − 3 from its minimum and show an input that produces two different allowed output values.

Common mistakes

1
Copying a missing input into the rangeFor q(x) = 2x + 1 on x ≠ 3, the domain misses 3 and the range misses 7. Domain values live on the input axis; pass an excluded input through the formula to find which output its absence removes.
2
Opening an endpoint that a root leaves closed√(x + 4) is defined at x = −4, because √0 = 0. Only a strict inequality or a zero denominator opens an end, and a square root produces a non-strict one.
3
Losing half of a squared inequality9 − x² ≥ 0 is x² ≤ 9, which is −3 ≤ x ≤ 3. Rooting both sides to get x ≤ 3 keeps every large negative input, all of which make the inside negative. Solve it as an absolute value inequality: |x| ≤ 3.

Check your understanding

✓
Finish when you can state a domain from the formula in one pass, and can justify the range of a line, square, absolute-value rule or simple root with a reason attached.

Given formulas with displayed linear denominators and square roots you should produce the domain in interval notation, with the right bracket at each end, and be able to justify each excluded input by naming which condition caused it. For a range, state the minimum or the input recovered from a requested output; do not read the answer from a sketch alone.

Note: Domain restrictions are the reason “Inverse Functions” needs a restriction at all, and the reason a composite in “Composition of Functions” can have a smaller domain than either function it was built from. “Piecewise Functions” takes the idea one step further: a function whose domain is deliberately cut into pieces, with a different formula on each.

Kept in this browser only, for you. Nothing is sent anywhere and nothing checks it. Carry it to another device.

Feedback and recommendations

Something to change about this lesson? Write it down, tick it off when it is handled, and export the list when you want to act on it. Kept in this browser only: nothing is sent anywhere, and nobody is notified.

No recommendations yet for this lesson.