Guides / Functions

Domain and range: square roots, denominators, logs, and interval notation

Three things restrict a domain in algebra: a square root, a denominator, and a logarithm. Each has a different rule about zero, and most lost points are a ≥ that should be a >, a second excluded value that never got listed, or a square bracket next to ∞.

Short answer

The domain is every x the function accepts. Under a square root: set the inside ≥ 0 (zero is allowed). In a denominator: set it = 0, solve, and exclude those values. Inside a log: set the inside > 0 (zero is not allowed). If a function has more than one of these, apply every rule and keep what satisfies all of them. In interval notation, [ includes the endpoint, ( excludes it, and ∞ always gets a round bracket. The range is the set of outputs: [0, ∞) for a bare square root, all reals for a log, and "from the vertex up" for a parabola that opens upward.

Why it works

A square root of a negative number isn't a real number, but √0 = 0 is fine, so the boundary value stays in. Division by zero is undefined, so the values that zero a denominator come out, and nothing about the numerator matters. A logarithm asks "what power of the base gives this number?" and a positive base raised to any power is positive, so log 0 and log(−5) don't exist: the boundary value is out. Polynomials have no restrictions at all; their domain is (−∞, ∞).

Interval notation is just a compact way to write an inequality. x ≥ 4 is [4, ∞). x ≠ 3 is two pieces, (−∞, 3) ∪ (3, ∞), with the ∪ meaning "or."

Example 1: a square root, with its range

Find the domain and range of f(x) = √x − 4.

  1. x − 4 ≥ 0The inside of a square root can't be negative. Zero is allowed.
  2. x ≥ 4Add 4.
  3. Domain: [4, ∞)Square bracket at 4 because 4 is included; round bracket at ∞ always.
  4. Range: [0, ∞)The smallest output is f(4) = √0 = 0, and the outputs grow without bound. The √ symbol never gives a negative.

Example 2: a denominator that factors

Find the domain of g(x) = x + 1x2 − 9.

  1. x2 − 9 = 0Find where the denominator is zero. The numerator is irrelevant: g(−1) = 0/(−8) = 0 is a perfectly good output.
  2. (x − 3)(x + 3) = 0Difference of squares.
  3. x = 3 or x = −3Two values to exclude, not one.
  4. Domain: (−∞, −3) ∪ (−3, 3) ∪ (3, ∞)Everything except the two holes. Three pieces, all with round brackets.

Example 3: a logarithm

Find the domain and range of h(x) = log(2x − 6).

  1. 2x − 6 > 0The inside of a log must be positive. Strictly: not ≥.
  2. x > 3Add 6, divide by 2.
  3. Domain: (3, ∞)Round bracket at 3, because h(3) = log 0 is undefined.
  4. Range: (−∞, ∞)A log takes every real value: huge negatives near x = 3, and growing slowly forever after.

Example 4: two restrictions at once

Find the domain of k(x) = √x + 2x − 1.

  1. x + 2 ≥ 0, so x ≥ −2The square root rule.
  2. x − 1 ≠ 0, so x ≠ 1The denominator rule. Both must hold.
  3. Domain: [−2, 1) ∪ (1, ∞)Start at −2 (included: k(−2) = 0/(−3) = 0), punch out 1, continue to ∞.

Example 5: the range of a parabola

Find the range of p(x) = x2 − 4x + 1.

  1. x = −b2a = 42 = 2The domain is all reals (it's a polynomial). The range depends on the vertex, whose x-coordinate is −b/2a.
  2. p(2) = 4 − 8 + 1 = −3The y-coordinate of the vertex is the lowest output, because a = 1 > 0 means the parabola opens upward.
  3. Range: [−3, ∞)−3 is reached (at x = 2), so it gets a square bracket. If a were negative, the range would be (−∞, vertex y].

Common mistakes, and the exact line they happen on

1. Making the square root strict

Find the domain of f(x) = √x − 4 (Example 1).

  1. x − 4 > 0, so (4, ∞)This is the mistake. f(4) = √0 = 0 exists, so 4 belongs in the domain. The rule is ≥ 0, and the bracket is square.

2. Finding only one of the excluded values

Find the domain of g(x) = x + 1x2 − 9 (Example 2).

  1. x2 − 9 ≠ 0, so x ≠ 3This is the mistake. x = −3 also makes the denominator zero: (−3)² − 9 = 0. A quadratic denominator usually has two zeros. Factor it and take both.
  2. x + 1 ≠ 0, so x ≠ −1The other version. The numerator was set to zero. A zero on top is fine; g(−1) = 0. Only the denominator restricts the domain.

3. Giving a log the square-root rule

Find the domain of h(x) = log(2x − 6) (Example 3).

  1. 2x − 6 ≥ 0, so [3, ∞)This is the mistake. log 0 is undefined, so 3 is out. The inside of a log must be strictly positive, and the bracket at 3 is round.

The two rules are easy to swap because they look alike. Square root: zero is in. Log: zero is out. The same strictness is what removes the fake answer when solving log equations.

4. Interval notation slips

  1. [4, ∞]This is the mistake. ∞ isn't a number the function ever reaches, so it can't be "included." Always (… , ∞) and (−∞, …).
  2. (−∞, −3) ∪ (3, ∞)Also a mistake (for Example 2). The middle piece (−3, 3) was dropped, but numbers like 0 are fine: g(0) = −1/9. Two holes split the line into three pieces, not two.

5. Copying the domain as the range

For f(x) = √x − 4, writing "range: [4, ∞)" is a mistake. The domain is about inputs; the range is about outputs, and the outputs of a square root start at 0. Shifting what's under the root moves the domain; shifting what's outside the root moves the range: √x − 4 + 2 has domain [4, ∞) and range [2, ∞).

Practice

  1. Find the domain of √10 − 2x.

    Show answer

    10 − 2x ≥ 0, so −2x ≥ −10, so x ≤ 5. Dividing by −2 flips the sign. Domain: (−∞, 5].

  2. Find the domain of x − 5x2 − 16.

    Show answer

    x2 − 16 = (x − 4)(x + 4), so x ≠ ±4. Domain: (−∞, −4) ∪ (−4, 4) ∪ (4, ∞). The 5 in the numerator doesn't matter.

  3. Find the domain of ln(x + 7).

    Show answer

    x + 7 > 0, so x > −7. Domain: (−7, ∞), round bracket.

  4. Find the range of 2x2 + 8x + 3.

    Show answer

    Vertex at x = −8/4 = −2; value 2(4) − 16 + 3 = −5. Opens upward, so the range is [−5, ∞).

  5. Find the domain of √x − 1x − 5.

    Show answer

    x ≥ 1 and x ≠ 5. Domain: [1, 5) ∪ (5, ∞).