Domain and Range of a Relation

Find the domain and range of a relation from ordered pairs, tables and mapping diagrams, and use them to decide whether the relation is a function.

Domain and Range of a Relation (Ordered Pairs, Mappings)

The domain and range of a relation start with the first input you cannot use and the first output the relation never reaches. For an Algebra 1 student working with ordered pairs and mapping diagrams, the rule is: list every x in the pair, then remove any that make a denominator zero or a square root radicand negative. The remaining inputs form the domain. The outputs that actually appear, after evaluating every allowed input, form the range. OpenStax Precalculus 2e, Section 3.2 covers the full definition; the Common Core State Standards HSF-IF.A.1 define a function as assigning to each element of the domain exactly one element of the range.

Domain and Range From Ordered Pairs

Given a set of ordered pairs, extract the domain by listing every first coordinate and the range by listing every second coordinate. For the set {(2,5), (3,8), (2,6), (5,8)}, the domain is {2,3,5} and the range is {5,6,8}. Write each set only once; duplicates are irrelevant. A common failure mode is listing the domain as {2,3,2,5}. Include each input once. If an ordered pair contains a denominator zero or a negative radicand in the input, that input is excluded from the domain. For example, the pair (0,4) in a rational relation with denominator x means 0 is excluded from the domain. OpenStax College Algebra 2e, Section 3.1 reinforces this with function notation: f(x) is only defined when the input is in the domain.

Domain and Range From Tables and Mapping Diagrams

A table lists inputs in one column and outputs in another. The domain is the column of inputs; the range is the column of outputs. A mapping diagram draws arrows from each input to its corresponding output. The domain is the set of inputs with at least one arrow leaving. The range is the set of outputs with at least one arrow arriving. For a mapping diagram, check that each input has exactly one arrow leaving. If any input sends an arrow to two different outputs, the relation is not a function. Common Core HSF-IF.B.5 expects you to relate the domain to a graph; for a mapping diagram, the domain is the left-side oval and the range is the right-side oval. If the table includes an input that makes a denominator zero or a radicand negative in the rule, that input is not part of the domain.

Mapping Diagram Domain Range: Relation Vs Function

A function is a relation where each input (x) has exactly one output (y). The mapping diagram makes this visible: if any x in the left oval has more than one arrow leaving it, the relation is not a function. This is the same as the vertical line test applied to a graph. OpenStax Precalculus 2e, Section 3.1 states: a function from one set (domain) to another set (range) assigns to each element of the domain exactly one element of the range. For a mapping diagram, if an output in the right oval never appears, if the range excludes it, that is fine. The only rule is that each input in the domain points to exactly one output. The distinction between relation and function matters because the domain and range of a relation are defined for any set of ordered pairs, but the vertical line test only applies to functions.

Vertical Line Test

The vertical line test is the fastest way to decide if a graph represents a function. Draw a vertical line at any x-value. If the line touches the graph at more than one point, the relation is not a function. For a set of ordered pairs, the test translates to: does any input appear more than once with a different output? If yes, the relation is not a function. The vertical line test works because a function must have exactly one y for each x. OpenStax Precalculus 2e uses this test in Section 3.1. A common failure case is applying the test to a mapping diagram: draw a vertical line through the left oval; if any input has more than one arrow, the relation fails the test. The vertical line test does not help with the domain and range of the relation, it only checks whether the relation is a function.

Is It a Function?

To answer 'is it a function?' from a set of ordered pairs, check whether any input repeats with a different output. For the set {(1,2), (1,3), (2,4)}, the input 1 appears twice with different outputs, so the relation is not a function. For a table, scan the x column for duplicates with different outputs. For a mapping diagram, look for any input with multiple arrows leaving. OpenStax College Algebra 2e, Section 3.1 defines a function by this exact property. If the relation is not a function, the domain and range are still defined, the domain is the set of all inputs, and the range is the set of all outputs, but the vertical line test fails. The question usually appears in Algebra 1 to separate the concept of a relation from the stricter definition of a function.

Domain and Range of a Table

A table of values shows you the domain and range directly. For the table below, the domain is the set of inputs and the range is the set of outputs.

xy
25
49
613

Domain: {2,4,6}. Range: {5,9,13}. If the table includes an input that, when plugged into the relation's rule, causes a denominator zero or a negative radicand, that input is excluded. For example, a table for the relation y = 1/x would not include x=0 because 1/0 is undefined. The domain and range of a table are always finite sets unless the table represents a function with an infinite domain.

Practice With Answers

Try these problems. The answers follow.

Problem 1: Find the domain and range of the relation {(3,7), (5,7), (3,8), (6,7)}. Is it a function?

Problem 2: A mapping diagram shows inputs {2,4,6} and outputs {3,5,7}. Arrows go from 2 to 3, 4 to 5, and 6 to 7. What are the domain and range? Is it a function?

Problem 3: A table has inputs {1,1,2} and outputs {4,5,6}. What are the domain, range, and is it a function?

Answers:

1. Domain: {3,5,6}. Range: {7,8}. Not a function because x=3 maps to both 7 and 8.

2. Domain: {2,4,6}. Range: {3,5,7}. It is a function because each input maps to exactly one output.

3. Domain: {1,2}. Range: {4,5,6}. Not a function because x=1 maps to both 4 and 5.

Common Questions

What is the difference between domain and range?

Domain is the set of all possible input values (x). Range is the set of all possible output values (y). For ordered pairs, domain is the first coordinate and range is the second coordinate.

How do I find the domain from a mapping diagram?

Look at the left oval (the set of inputs). The domain is the set of all inputs that have at least one arrow leaving. If any input has more than one arrow, the relation is not a function, but the domain is still the set of inputs.

Can the domain be empty?

No, a relation always has a domain and range. If you have a set of ordered pairs, the domain contains at least one input. If the relation is empty, the domain is the empty set, but that is not a typical Algebra 1 problem.

How do I decide if a relation is a function using a table?

Scan the x column for any duplicate values. If you find a duplicate input with a different output, the relation is not a function. If all inputs are unique, it is a function.

What is the vertical line test and why does it work?

Draw a vertical line at any x-value on the graph. If the line touches the graph at more than one point, the relation is not a function. It works because a function requires exactly one y for each x.