About the Domain and Range Calculator
Before you can graph a function, invert it or solve an equation involving it, you need to know which inputs it accepts and which outputs it can produce. Those two sets are the domain and the range. Finding the domain is mostly about spotting forbidden operations; finding the range is harder, because it asks which heights the graph actually reaches.
This calculator finds both for polynomials, rational functions, roots, logarithms, exponentials, absolute values and basic trigonometric functions. It lists each restriction, solves it, and then studies the function on each piece of its domain to assemble the range. Answers are given in interval notation with exact endpoints wherever possible.
What are domain and range?
The domain of a function is the set of all inputs for which the formula produces a real number. The range is the set of all outputs obtained as runs through the domain. On a graph, the domain is the shadow the curve casts on the -axis and the range is its shadow on the -axis.
Three operations restrict real-valued formulas: division, which forbids a zero denominator; even roots, which need a non-negative radicand; and logarithms, which need a positive argument. A function built without these, such as any polynomial, has every real number in its domain.
How to use the Domain and Range Calculator
- Type the function in terms of , for example (x + 1)/(x - 2), sqrt(x - 3) or log(x + 2).
- Press Find domain and range.
- Read the list of restrictions and how each one is solved.
- Follow the range steps, which examine the function on each interval of the domain.
- Copy the domain and range in interval notation.
Formulas
Denominator
Even root
Logarithm
Vertex of a parabola
Worked example: (x + 1)/(x − 2)
The example analyses . The only restriction is that the denominator cannot be zero, so is removed from the domain.
For the range, the engine examines each side of the gap separately. On both pieces the function approaches the horizontal asymptote without ever equalling it, so 1 is the single value missing from the range.
The solution below is generated by the same engine that powers the calculator above.
Final answer
How we read your problem
Find every real x for which f(x) = (x + 1) / (x - 2) is defined (domain) and every value it takes (range).
Step-by-step solution
Write the function
List the restrictions
the denominator (x - 2) cannot be 0.
Solve (x - 2) ≠ 0
The expression can only change sign at 2. Testing a value in each interval gives the solution set (-∞, 2) ∪ (2, ∞).
Range on (-∞, 2)
as x → -∞, f → 1; as x → 2⁻, f → -∞. There are no turning points inside this interval, so f is monotonic or constant there. The function is continuous on this interval, so it takes every value between the lowest (-∞, not attained) and the highest (1, not attained).
Range on (2, ∞)
as x → 2⁺, f → ∞; as x → ∞, f → 1. There are no turning points inside this interval, so f is monotonic or constant there. The function is continuous on this interval, so it takes every value between the lowest (1, not attained) and the highest (∞, not attained).
Combine the pieces
Formulas used
Restrictions
The domain is found by solving every restriction in the formula and intersecting the solution sets. The range follows from continuity: on each interval of the domain the function sweeps every value between its extreme values and the limits at the ends of the interval.
Verification
- Domain checked at about 4,000 sample points: f is real and finite exactly where the domain says ✓
- Every sampled value of f lies inside the computed range ✓
Detailed explanation
Finding the domain
Start with all real numbers and remove what is forbidden. Set every denominator unequal to zero, every expression under a square root greater than or equal to zero and every logarithm argument greater than zero, then intersect the results. For the condition gives . For two points are removed, so the domain splits into three intervals.
Do not simplify first. reduces to , but is still excluded from the original function, and the calculator reports the domain with that gap.
Finding the range
The range depends on the shape of the graph. A parabola has its extreme value at the vertex: for the vertex is at with value , so the range is . A square root starts at zero and grows, so has range . A logarithm takes every real value, and takes every positive value.
For rational functions the calculator works piece by piece, finding where the function increases or decreases and what it approaches at the ends of each interval. That is how it finds that has range and that stays between and . When a range cannot be determined reliably, as happens for , the calculator says it was not computed rather than guessing.
Reading interval notation
A square bracket includes an endpoint and a round bracket excludes it; infinity always takes a round bracket. The symbol joins separate pieces, so means every real number except 2. Writing results this way makes it easy to check them against a graph.
Common mistakes
- Simplifying a rational function before finding its domain and losing a hole.
- Using for a square root (zero is allowed) or for a logarithm (zero is not).
- Assuming the range is all real numbers because the domain is.
- Forgetting that a horizontal asymptote can exclude a value from the range.
- Using a square bracket next to infinity.
Tips
- Write down every denominator, radicand and log argument before solving anything.
- Sketch the function with the graphing calculator to confirm the range visually.
- For a quadratic, find the vertex; the range starts or ends at its -value.
- Remember that the range of becomes the domain of its inverse.
- Check an endpoint by substituting it into the function.
Frequently asked questions
How do you find the domain of a function?
Start with all real numbers and remove values that cause a zero denominator, a negative number under an even root or a non-positive logarithm argument. What remains is the domain.
How do you find the range of a function?
Determine which output values the function actually reaches, using its vertex, asymptotes, increasing and decreasing behaviour and end behaviour on each piece of the domain.
What is the domain of a polynomial?
All real numbers, written (−∞, ∞), because polynomials involve no division by x, roots or logarithms.
Why is 1 missing from the range of (x + 1)/(x − 2)?
The graph has a horizontal asymptote at y = 1. Solving (x + 1)/(x − 2) = 1 leads to 1 = −2, which is impossible, so the function never outputs 1.
What do the brackets in interval notation mean?
A square bracket means the endpoint is included and a round bracket means it is excluded. Infinity is never included, so it always has a round bracket.
Does the calculator handle trigonometric functions?
Yes for basic cases. It finds that sin x has range [−1, 1] and that tan x excludes π/2 plus multiples of π, and it says so when a range is not computed.
What does log mean in the calculator?
log(x) is the natural logarithm, so log(x + 2) is defined for x > −2 and takes every real value.
Find the domain and range
Type a function above to get both sets in interval notation with each restriction explained.