A function gives one answer to each input
Quick review (2 minutes)
Picture a vending machine with a fixed menu.
A relation is a set of ordered pairs (input, output). It is a function when every input in its domain has exactly one output. The range is the set of outputs it produces.
Name what you are starting with; that quantity is the input.
Name what you want to find; that quantity is the output.
Inspect every input and its assigned outputs.
Accept shared outputs. Reject an input with two different outputs.
List distinct inputs as the domain and distinct outputs as the range.
Decide whether each relation gives one output per input.
(a) {(1, 2), (2, 4), (3, 6), (4, 8), (5, 10)}
(b) {(1, 3), (2, 5), (1, 7)}
(a) function.
Domain: {1, 2, 3, 4, 5}.
Range: {2, 4, 6, 8, 10}.
(b) Not a function. Input 1 has outputs 3 and 7.
Checking for repeated outputs instead of conflicting inputs. Two arrows arriving together are allowed; two arrows leaving one input for different answers are not.
Name what you are starting with; that quantity is the input.
Name what you want to find; that quantity is the output.
Inspect every input and its assigned outputs.
Accept shared outputs. Reject an input with two different outputs.
List distinct inputs as the domain and distinct outputs as the range.
Relation
A set of ordered pairs that connects inputs with outputs. It can have conflicting outputs and need not be a function.
Set
A collection of distinct members. Braces list them, and repeating a member does not create a new member.
Natural numbers
The counting numbers 1, 2, 3 and so on, using this convention.
Variable
A letter that represents a number or another chosen value.
Function
A relation assigning exactly one output to every input in its domain.
Input
A value chosen for a function. The definition decides which values are allowed.
Output
The result a function assigns to a particular input.
Independent variable
The input variable. You choose its value from the domain before the rule gives a result.
Dependent variable
The output variable. Its value is determined by the chosen input and the rule.
Domain
The set of all inputs accepted by the defined relation or function.
Range
The set of all outputs actually produced by the defined relation or function.
Equation
A statement that two expressions are equal, shown with an equals sign.
Solve
Find every allowed input that satisfies a stated equation or produces a specified output.
Graph
A picture of ordered pairs at their coordinate locations. A graph of a function contains every pair (x, f(x)) for its allowed inputs.
Coordinate
One number in a point's ordered address.
Odd
An integer that is not divisible by 2 into an integer result.
Even
An integer divisible by 2 into an integer result.
→
An arrow showing which output is paired with an input. Read it goes to.
1 In plain words
Picture a vending machine with a fixed menu. You choose a button. That choice is the input. The snack it gives you is the output. Any collection of these matched choices and results is a relation, like a list of (button, snack) pairs. A function is a relation that gives exactly one answer for each allowed choice.
Two buttons may both give crackers. Each button still has one answer. Trouble begins if one button is assigned both crackers and pretzels, with no instruction choosing between them.
The domain lists the allowed inputs. The range lists only outputs that actually appear. You will read the same matched pairs in lists, tables, pictures, and formulas.
2 Picture it
Reminder
Reminder: Ordered pairs and sets
- Ordered pairs and sets. (1, 2) records input 1 followed by output 2. A set such as {2, 4} lists distinct values.
3 Why
A relationship is useful as a function because knowing an input settles the output. If one input had two different assigned outputs, a request for its value would have no definite answer. Repeated outputs do not cause that problem: you still know what happens at each input. You must choose the direction first. A menu can identify a price from an item even when a price cannot identify a unique item.
4 The rule
A relation is a set of ordered pairs (input, output).
It is a function when every input in its domain has exactly one output. The range is the set of outputs it produces.
The same idea, five ways
y is a function of x.
Each allowed input has exactly one output. In f(x) = 2x, f names the doubling rule, x is the input, and f(x), read f of x, is its output.
- {(1, 2), (2, 4), (3, 6)}
- y = 2x
- f(x) = 2x
- On a graph, each allowed horizontal input has one height.
One accepted vending-machine button selects one snack.
The same idea, other ways
One allowed button must settle which snack the rule gives. A missing choice is outside the domain.
Many arrows may arrive at the same output. Each input must send exactly one arrow.
Start with an item and ask its price. If the menu has one price per item, your question has a definite answer.
The rule gives 4 at both 2 and −2. Each individual input still has only one square.
| Given as | How to check |
|---|---|
| Ordered pairs | No input has two different paired outputs. |
| A table | Compare all columns sharing the same input. |
| A graph | Slide an upright ruler across the graph. Two contacts at the same horizontal position mean one input has two outputs. The line-test lesson explains this picture. |
| An equation | Choose an input and find every permitted output. For + = 1 at x = 0, y = 1 and y = −1 both work, so this relation fails. |
Part 1: Domain and range
The domain is the menu of accepted inputs. The range is the collection of answers actually reached. A relation has a domain and range even if it fails to be a function. Read each pair as input first, output second. The range lists only outputs that actually appear.
- Domain: first coordinates of the ordered pairs.
- Range: second coordinates of the ordered pairs, without duplicate set members.
- Inputs may be numbers or labels. Natural numbers are 1, 2, 3 and so on.
The same idea, five ways
Domain means what may go in. Range means what comes out.
List each distinct input once for domain and each distinct output once for range.
- Domain: {−2, 0, 2}
- Range: {0, 4}
The available buttons and the available snacks are different lists.
Worked example
Shared outputs do not add extra range members
For the relation {(−2, 4), (0, 0), (2, 4)}, decide function status and list its domain and range.
What it asks. Decide whether the three listed inputs each have one output, then list domain and range.
Show the steps and the answer
The plan. Read every first coordinate, then every second coordinate. Remove repeated set members, then check the input arrows.
- Plan. Read every first coordinate, then every second coordinate. Remove repeated set members, then check the input arrows.
- The first numbers are −2, 0, and 2.
- The output 4 appears twice, but it is one range member.
- Read the three first coordinates: , 0 and 2.These are the accepted inputs.
- Read the second coordinates: 4, 0 and 4, then list the distinct values 0 and 4.Range is a set, so a repeated output is listed once.
- Check each input's arrows. Each input points to only one output.Different inputs may share the output 4 without creating ambiguity at either input.
- Function.
- Domain: {−2, 0, 2}.
- Range: {0, 4}.
Counterexamples
What it is not, and the tempting wrong moves.
Tips and tricks
- Read first coordinates for domain and second coordinates for range.
- As a guest list: The domain names who may enter; the range names results that actually occur.
- As two collections: In {(1, 2), (3, 2)}, the domain has two members and the range has one.
Part 2: Odd and even labels
Odd and even sort whole counting numbers into two labels. Even numbers split into pairs with nothing left over; odd numbers leave one unpaired object. A label can describe many numbers, so starting with the label does not choose one particular number.
- 2 and 4 are even because 2 = 2 × 1 and 4 = 2 × 2.
- 1, 3 and 5 are odd because each leaves one after pairing.
- Number to label, odd or even, is a function for these inputs. Label to number is not, because one label names several numbers.
The same idea, five ways
An even number makes complete pairs. An odd number leaves one over.
Starting with a number tells you its label; starting with the label does not identify one number.
- 2 → even
- 4 → even
- 1 → Odd
- 3 → Odd
- Odd → 1 and Odd → 3
Four chairs form two pairs. Three chairs leave one chair unpaired.
Worked example
Odd and even labels do not determine a unique number
In the pictured relation, each label points to natural numbers of that type. Does the label determine a number as a function?
What it asks. Starting with Odd or even, can you recover one number?
Show the steps and the answer
The plan. Read every arrow leaving each label. If a label has several different destinations, label to number is not a function.
- Plan. Read every arrow leaving each label. If a label has several different destinations, label to number is not a function.
- Odd is the starting label in three of the arrows.
- A label input must obey the same one-output condition as a number input.
- Odd means a counting number not divisible into whole-number pairs; even means one divisible into such pairs.The input labels need meanings before their outputs can be interpreted.
- Input Odd points to 1, 3 and 5.Each of those listed natural numbers is odd.
- Input even points to 2 and 4.Each of those listed natural numbers is even.
- Reject function status for the direction label to number.Each input label is assigned several different outputs.
Counterexamples
What it is not, and the tempting wrong moves.
Tips and tricks
- Labels can be inputs; test their assigned outputs the same way you test numeric inputs.
- As pairing: Four chairs form two pairs. Five chairs form two pairs and one leftover chair.
- As grouped labels: The word Odd describes several choices, so it cannot tell you which number was chosen.
Part 3: Choose the direction
You decide which row is the starting row. A price list can answer 'What does tea cost?' even when it cannot answer 'What item costs three dollars?' Directions are part of the question, not a feature you can ignore.
- The independent variable is the input you choose from the domain.
- The dependent variable is the output determined by that input.
The same idea, five ways
Price is a function of item.
Start with the item to find its price. Reversing the direction asks a different question.
- Tea → 3
- Juice → 3
- 3 → Tea and 3 → Juice
Two snacks can have the same price, so the receipt alone may not name the snack.
Worked example
Read a menu in both directions
The pictured menu assigns a price to each item. Is price a function of item? Is item a function of price?
What it asks. Check item to price, then check price to item.
Show the steps and the answer
The plan. Choose the input row first. Follow each column to its partner. Reverse the rows and check again.
- Plan. Choose the input row first. Follow each column to its partner. Reverse the rows and check again.
- Tea and Juice both give 3 dollars.
- When 3 dollars becomes the input, count all the item outputs.
- Read the columns from item to price: tea gives 3, cocoa gives 4, and juice gives 3.Each item has a single listed price.
- Reverse the direction. Input price 3 gives both tea and juice.The reversed relationship has one input with two different outputs.
- Conclude that item-to-price is a function and price-to-item is not.Function status depends on which quantity you chose as input.
- Price is a function of item.
- Item is not a function of price.
Counterexamples
What it is not, and the tempting wrong moves.
Tips and tricks
- Write 'input → output' in words before deciding function status.
- As a menu: An item selects one price, while one price can name several items.
- As a reversed lookup: Start with Tea and the answer is 3. Start with 3 and both Tea and Juice match.
5 How
- Name what you are starting with; that quantity is the input.
- Name what you want to find; that quantity is the output.
- Inspect every input and its assigned outputs.
- Accept shared outputs. Reject an input with two different outputs.
- List distinct inputs as the domain and distinct outputs as the range.
Check one output for each input
- Name what you are starting with; that quantity is the input.
- Name what you want to find; that quantity is the output.
- Inspect every input and its assigned outputs.
- Accept shared outputs. Reject an input with two different outputs.
- List distinct inputs as the domain and distinct outputs as the range.
6 Worked example
Worked example
Function or not from ordered pairs
Decide whether each relation gives one output per input.
(a) {(1, 2), (2, 4), (3, 6), (4, 8), (5, 10)}
(b) {(1, 3), (2, 5), (1, 7)}
What it asks. For each list, does one input have two different outputs? Also list the first relation’s allowed inputs and actual outputs.
Show the steps and the answer
The plan. Read the first number in each pair as input. Compare pairs with the same input, then collect distinct first and second numbers.
- Plan. Read the first number in each pair as input. Compare pairs with the same input, then collect distinct first and second numbers.
- In (1, 3), 1 is the input and 3 is its output.
- In list (b), find both pairs whose first number is 1.
- For (a), each of the inputs 1, 2, 3, 4 and 5 has one paired output.The first coordinate is the input, and none has conflicting outputs.
- Collect the domain {1, 2, 3, 4, 5} and the range {2, 4, 6, 8, 10}.Domain lists accepted inputs; range lists produced outputs.
- For (b), input 1 pairs with both 3 and 7.A function cannot give two different answers for the same input.
- (a) function.
- Domain: {1, 2, 3, 4, 5}.
- Range: {2, 4, 6, 8, 10}.
- (b) Not a function. Input 1 has outputs 3 and 7.
Counterexamples
What it is not, and the tempting wrong moves.
Tips and tricks
- First identify the input. The phrase 'B is a function of A' means start with A and find B.
- Memory cue: one arrow OUT of each input. Many arrows IN to one output are allowed.
- On the exam, give the evidence: not a function, because input 1 has outputs 3 and 7.
- A few separate values go in braces, such as {0, 4}. An interval means a whole stretch, such as [0, 4], which also contains 1 and 2.5.
7 The trap
Checking for repeated outputs instead of conflicting inputs. Two arrows arriving together are allowed; two arrows leaving one input for different answers are not.
Comes back in
Problems marked OpenStax come from Precalculus 2e by Jay Abramson, published by OpenStax, under the CC BY-NC-SA 4.0 licence. Access for free at https://openstax.org/books/precalculus-2e/pages/1-introduction-to-functions.