Definition · applies to functions

Elementary

Think of a function as a machine that takes inputs and gives outputs. The domain of the function is the set of inputs that it accepts.

High school

Consider a function $f$ given by a rule, such as a formula. The domain of $f$ is the set of inputs $x$ for which $f(x)$ is defined.

Caveat. In high school, the domain is usually found as the largest set on which a formula makes sense. At higher levels, the domain is chosen as part of the definition of the function, and can be smaller than the set where the formula makes sense.
Undergraduate

Consider a function $f : X \to Y$. The domain of $f$ is the set $X$.

Examples

Worked examples

Distinctions involving this term

  • Domain vs. Range vs. Codomain vs. Image vs. Preimage: A function comes with several sets that describe its inputs and outputs. The domain is where inputs come from, and the codomain is where outputs are allowed to land. The range is the set of outputs that actually occur. For a set $A$ of inputs, the image $f(A)$ is the set of outputs for inputs in $A$, so the range is the image of the whole domain. For a set $B$ of outputs, the preimage $f^{-1}(B)$ is the set of inputs that land in $B$.

All definitions · All distinctions · All examples · Notation