Find The Domain Of The Function

Which input values make your function valid and defined?

Paste or type any mathematical function and this tool analyzes it to identify all domain restrictions — division by zero, even roots of negatives, logarithms of non-positives — and returns the domain in interval notation and set-builder form.

Updated June 2026 · How this works

Example calculation — edit any field to use your own numbers

Worth knowing
How It Works
The formula, explained simply

Every function implicitly promises to deliver an output for any input you hand it -- but not every input keeps that promise. A square root rejects negative inputs because no real number squares to a negative. A fraction rejects the value that makes its bottom zero because division by zero collapses the number system. A logarithm rejects zero and negatives because its definition requires a positive argument. The domain is simply the complete set of inputs where the function keeps its promise.

The key idea is that restrictions layer. If you have sqrt(x - 3) in the numerator and (x - 9) in the denominator, the sqrt demands x >= 3 and the denominator demands x != 9. Both conditions apply simultaneously. The domain is [3, 9) union (9, +inf) -- not two separate domains, but one combined set where every input satisfies every restriction at once.

Interval notation encodes this precisely. A square bracket means the endpoint is included; a parenthesis means it is excluded. Negative infinity and positive infinity always use parentheses because they are not reachable numbers. The union symbol connects disconnected pieces. Once you read interval notation fluently, the domain tells you instantly which inputs are safe without working through each restriction individually.

When To Use This
Right tool, right situation

Use this tool before graphing any function you are unfamiliar with, before setting up integrals with variable limits, or any time a calculation returns an error and you need to confirm the input was valid. Domain analysis is also the right first step when evaluating composite functions -- the domain of f(g(x)) depends on both the domain of g and the values of g(x) that fall within the domain of f.

This tool is not appropriate as a substitute for a full symbolic algebra system when working with highly nested or piecewise expressions. It handles the most common restriction patterns -- square roots, logarithms, and rational denominators -- but complex compositions with multiple nested functions may require manual verification. If the function involves trigonometric functions, the domain may include periodicity-based restrictions not captured here. Inverse trig functions (arcsin, arccos) have range-based domain restrictions that require separate treatment.

Common Mistakes
Why results sometimes look wrong

The most common mistake is forgetting that a boundary can be both a sqrt lower bound and a denominator zero simultaneously. In sqrt(x - 3) / (x - 3), the sqrt requires x >= 3 but the denominator requires x != 3. Both apply, so x = 3 is excluded despite the bracket suggestion from the sqrt alone. The domain is (3, +inf), not [3, +inf).

A second frequent error is treating the domain of log(x^2) as all real numbers except zero. Because x^2 is always positive for any nonzero x, students correctly identify that x = 0 is excluded but fail to check whether negative x values are valid. Since x^2 > 0 for all x != 0, the domain of log(x^2) is actually all real numbers except zero -- which surprises many people who associate log with only positive inputs.

A third mistake appears when students solve each restriction independently and then union the results instead of intersecting them. Restrictions combine as intersections -- the domain must satisfy all conditions at once. Unioning restrictions gives a set that is too large and includes inputs where the function is undefined.

The Math
Worked examples and deeper derivation

For a linear expression inside a square root -- sqrt(ax + b) -- the restriction ax + b >= 0 gives x >= -b/a when a is positive, or x <= -b/a when a is negative. The boundary point is included because equality produces sqrt(0) = 0, which is valid.

For a logarithm ln(ax + b), the restriction ax + b > 0 gives a strict inequality. The boundary is excluded because ln(0) is undefined. This means logarithm restrictions always produce open intervals at their boundary, while square root restrictions produce closed intervals.

For a fraction with denominator D(x), the restriction is D(x) != 0. Solving D(x) = 0 gives the excluded points. A quadratic denominator like x^2 - 9 factors as (x-3)(x+3), giving two excluded points: x = 3 and x = -3. The domain splits into three intervals around these two points, connected by union. When restrictions combine, the final domain is their intersection -- the set of all x values that satisfy every individual restriction simultaneously.

Student graphing a square root function
f(x) = sqrt(x - 3), variable x, interval notation
The domain is [3, +inf). The square root forces x - 3 >= 0, so x must be at least 3. On a graph, the curve starts at (3, 0) and extends right -- nothing to the left of x = 3 produces a real output.
Combined restriction: sqrt and rational denominator
f(x) = sqrt(x - 3) / (x^2 - 9), variable x, both notations
The sqrt requires x >= 3, and the denominator x^2 - 9 = (x-3)(x+3) equals zero at x = 3 and x = -3. Since x >= 3 already excludes x = -3, and x = 3 is excluded by the denominator, the domain is (3, +inf). A student who only catches one restriction will get the wrong answer.
Engineer checking a signal model with a logarithm
f(t) = ln(t + 10) / (t - 2), variable t, both notations
The ln requires t > -10 and the denominator requires t != 2. The domain is (-10, 2) union (2, +inf). In a signal context this means the model is undefined at t = 2 -- a discontinuity that could represent a singularity in the physical system requiring separate treatment.
Expert Unlock
The thing most explanations skip

The implicit domain convention assumes you want all real inputs where the expression makes sense -- but context can impose a narrower domain. A population model defined by P(t) = sqrt(1000 - 5t) has mathematical domain t <= 200, but the applied domain is 0 <= t <= 200 because negative time is meaningless. The formula never tells you this -- you have to impose it. Similarly, when you compose two functions, the chain rule for domains requires that g(x) must land inside the domain of f, not just that x lands inside the domain of g. This inner restriction is almost always forgotten.

Why does my function have restrictions where it looks fine?

What does it mean when the domain excludes a single point?
It means the function is undefined at exactly that value -- usually because a denominator equals zero there. The function may look continuous everywhere else, but plugging that value in produces division by zero, which has no real result. These isolated exclusions appear as open circles on a graph and as union notation in the domain.
How do I find the domain of a function with both sqrt and a fraction?
Work from the inside out. The square root restricts the domain to values where the radicand is non-negative. The fraction restricts it further by removing any value that makes the denominator zero. The final domain is the intersection of both sets -- wherever both conditions are satisfied simultaneously. If a zero of the denominator falls inside the sqrt restriction, it still gets excluded.
Why is the domain of ln(x) only x > 0 and not x >= 0?
The natural logarithm is undefined at zero -- not just negative. ln(0) approaches negative infinity rather than producing a real number. The domain is strictly x > 0, using a parenthesis (open interval) at zero, never a bracket. This is a common source of errors when writing interval notation.

Need something this doesn't cover?

Suggest a tool — we'll build it →