Domain and range calculator
Type a function to find its domain and range, in interval notation and in words. The steps show which values of x have to be left out and why, and the graph lets you see both answers.
- A denominator can’t be zero: x² − 4 ≠ 0, which gives x ≠ −2, 2
- For the range, follow the function across its domain. Check its limits at each end of each interval, and its highest and lowest turning points.
- Those values give the range: (−∞, −1/4] ∪ (0, ∞)
The range is found numerically from limits and turning points, then matched to exact values. Check it against the graph.
Open in the graphing calculator →How to find the domain and range here
- 1Type your function of x, such as
1/(x - 2),sqrt(x + 3)orln(x). - 2Read the domain and range, in interval notation and in words.
- 3Check them on the graph. The domain is how far the curve spreads left and right, and the range is how far it spreads up and down.
How to find the domain
Start with all real numbers, then remove any value of x that breaks a rule:
| If the function has | Then you need | Example |
|---|---|---|
| A fraction | The denominator isn’t 0 | 1/(x − 2): x ≠ 2 |
| A square root | The inside is at least 0 | √(x + 3): x ≥ −3 |
| A logarithm | The inside is above 0 | ln(x − 1): x > 1 |
| arcsin or arccos | The inside is from −1 to 1 | arcsin(x): −1 ≤ x ≤ 1 |
| tan or sec | The cosine isn’t 0 | tan(x): x ≠ π/2 + nπ |
| Anything else | No restriction | x³ + 1, eˣ, sin(x), |x| |
If a function has several of these, all the conditions must hold at once. For √x/(x − 4), you need x ≥ 0 and x ≠ 4.
How to find the range
The range is harder, since no single rule covers it. Ask what values the function really reaches, working across its domain:
- Find its highest and lowest turning points.
- Check what happens at each end: as x goes to ±∞, and as x approaches any value left out of the domain.
- Decide whether each boundary is reached. The value 0 isn’t in the range of eˣ, for example, because eˣ only gets closer to it.
For a parabola, this is simple, because the range starts at the vertex. For a rational function, horizontal asymptotes often mark the missing values. Our guide to domain and range works through each type.
Reading interval notation
| Notation | Means |
|---|---|
| (2, 5) | 2 < x < 5, with neither end included |
| [2, 5] | 2 ≤ x ≤ 5, with both ends included |
| [2, ∞) | x ≥ 2 |
| (−∞, 2) ∪ (2, ∞) | Every number except 2 |
| (−∞, ∞) | All real numbers |
Examples
| Function | Domain | Range |
|---|---|---|
| x² | (−∞, ∞) | [0, ∞) |
| 1/x | (−∞, 0) ∪ (0, ∞) | (−∞, 0) ∪ (0, ∞) |
| √(x − 2) | [2, ∞) | [0, ∞) |
| √(4 − x²) | [−2, 2] | [0, 2] |
| eˣ | (−∞, ∞) | (0, ∞) |
| ln(x) | (0, ∞) | (−∞, ∞) |
| sin(x) | (−∞, ∞) | [−1, 1] |
| arctan(x) | (−∞, ∞) | (−π/2, π/2) |
| 1/(x² + 1) | (−∞, ∞) | (0, 1] |
How the answers are found
The domain is worked out from the formula, and it’s exact when the conditions are fractions of polynomials. The range is found by following the function numerically through its turning points and limits, then matching the results to exact values such as 1/4, √2 or π/2. Anything that doesn’t match is shown as a decimal marked ≈. This works well for the functions in most courses, but it isn’t a proof, so compare it with the graph. If a domain repeats forever in a complicated pattern, as with √(sin x), the calculator says so rather than giving part of the answer.
Frequently asked questions
What is the difference between domain and range?
How do I find the domain of a fraction?
What is the domain of a square root?
What are the domain and range of a parabola?
Why does (x² − 1)/(x − 1) leave out x = 1?
Is it free?
Related tools and guides
Find them from an equation or a graph, with interval notation.
f⁻¹(x) with steps, its domain and range, and a graph showing the reflection.
Vertical, horizontal and slant asymptotes, and holes.
Find vertical, horizontal and slant asymptotes, with the rules.
The basic shapes every graph is a transformation of.
Holes, asymptotes and intercepts, in a worked example.
Graph any function in the calculator to see its domain and range, with holes and asymptotes drawn correctly.