Skip to content
Study Hall
Lesson 1 of 12Characteristics of Functions
Unit 1 · Lesson 1 of 12

Relations vs. Functions

A function is a special kind of relation where every input produces exactly one output — learn to spot the difference and use function notation.

7 min read12 practice questionsAsk AI about this →

Key things to remember

  1. 1A relation is a function iff every input has exactly one output (no repeated with different ).
  2. 2Vertical line test: if a vertical line crosses the graph more than once, it is not a function.
  3. 3 names the output of at input ; it is not .
  4. 4To evaluate , replace every in the rule with , then simplify.
  5. 5Independent variable = input = (domain); dependent variable = output = or (range).
  6. 6To solve , set the rule equal to and solve for ; a many-to-one function can give several solutions.

Think of a vending machine. You press button B4 and you expect exactly one product to come out — never two different products from the same button, and never nothing. That "one input, one guaranteed output" behaviour is exactly what makes something a function. A lot of the relationships you already know (a person's height over time, the cost of litres of gas) behave this way. Others don't — a single -value can sometimes correspond to more than one -value, and those relationships are still relations, just not functions. Everything else in this course (transformations, inverses, quadratics, exponentials, trig) is built on this one definition, so it is worth getting completely solid now.

A drinks vending machine in Japan with rows of bottles and cans, each with a selection button below it, and a coin slot and numbered keypad on the lower panel.
PhotoEach button on a vending machine is meant to give exactly one product, which is the same one-input, one-output rule that defines a function.Nelo Hotsuma, CC BY 2.0, via Wikimedia Commons

Relations vs. functions

A relation is any set of ordered pairs — a rule, a table, a graph, or a list of points that connects inputs to outputs, with no restriction at all. A function is a relation with one extra condition: every input value () is paired with exactly one output value (). It's fine for two different inputs to share the same output (many students can get the same test mark), but it is not fine for one input to produce two different outputs. Why insist on this? Because a function is meant to be predictable: if you know the input, you know the output with no ambiguity. A student number that could belong to two different students would be useless for looking anyone up. Functions where no two inputs share an output (like ) are called one-to-one; functions where several inputs share an output (like , where and both give ) are many-to-one. Both kinds are functions. Any relation in which some input has several outputs — one-to-many or many-to-many, like a circle — is not a function.

The one rule that matters
A relation is a function if and only if no -value repeats with a different -value. Check the -values first — if they're all different, it's automatically a function.
input: 3fmachine: y = 2x + 1output: 7Worked:f(x) = 2x + 1f(3) = 2(3)+1= 6 + 1= 7
Fig 1A function as an input–output machine: one input goes in, exactly one output comes out.

The vertical line test

On a graph, "one output per input" means: pick any vertical line — it should cross the graph at most once. If some vertical line crosses the graph two or more times, then that -value has two different -values, so the graph is not a function. This is the vertical line test, and it's the fastest way to check a graph. It works because every point on a vertical line shares the same -coordinate: two crossing points means two ordered pairs with the same input and different outputs. You only need one failing line to reject a graph, but to accept a graph you must be convinced that every vertical line crosses at most once. "At most once" includes zero times — a vertical line that misses the graph just means that -value is not in the domain.

Function ✓one output per inputNot a function ✗two outputs for one input
Fig 2A vertical line crossing the graph more than once means it fails the function test.
  • A circle () fails the vertical line test — it is not a function.
  • A sideways parabola fails the vertical line test — it is not a function.
  • A straight (non-vertical) line always passes — it is a function.
  • A vertical line such as is the worst case: every point has the same input, so it is not a function.
  • passes — every gives one , even though two different -values can share a (e.g. and ).
VideoAn Ontario teacher works through relations and functions for this course, including mapping diagrams, ordered pairs and the vertical line test. Watch it to practise spotting when one input has more than one output.Watch on YouTube

Function notation

Instead of writing , we often write . This is function notation: is read " of " and it means "the output of function when the input is ." It is a name for the output — it does not mean multiplied by . Different letters (, , , ...) let you talk about several functions in the same problem without confusion, and the notation packs the input and output into one symbol: says "the input gives the output ," which is the point on the graph. To evaluate for some value or expression , substitute for every occurrence of in the rule, then simplify. This works whether is a number, another variable, or a whole expression like — put the substituted value in brackets so that signs and exponents apply to all of it.

VideoJensenMath's Grade 11 lesson on function notation shows how to evaluate f(x) for numbers and expressions and how to read it in context, the same skills this section builds.Watch on YouTube

Representations, context and solving for an input

RepresentationExampleHow to check it is a function
EquationSolve for y: exactly one y for each x (no ± from a square root)
Table of valuesx: 0, 1, 2 → y: 1, 3, 5No x-value repeats with a different y-value
GraphA line or curveVertical line test
Ordered pairs{(0,1), (1,3), (2,5)}No repeated first coordinate with a different second coordinate
Mapping diagramTwo ovals joined by arrowsExactly one arrow leaves every input

Function notation earns its keep in real contexts. If a streaming service charges dollars for a month with movie rentals, then reads "renting 8 movies costs 35 dollars." Two different questions come up constantly, and they run in opposite directions. Evaluating ("find ") gives you the input and asks for the output — substitute. Solving ("for what is ?") gives you the output and asks for the input — set the rule equal to the output and solve the equation: , so . For a many-to-one function, solving can produce more than one input; for , the equation has two solutions, and . That is not a contradiction — two inputs sharing one output is allowed.

Quick check habit
Given a table, scan the -column first. If any value repeats, look at its paired -values — same both times is fine (still a function); different -values means it fails. Given an equation, try to solve for : if you need a (as in from ), one input gives two outputs and it is not a function.

Worked examples

Reveal one step at a time and try to beat it to the next line.

Example 1
If , find , , and .
Example 2
Is the set of points a function? Justify your answer.
Example 3
Given , find the value of for which .
Example 4
For , find all values of for which . Does your answer mean is not a function?

Where marks get lost

  • Reading as " times " instead of "the output of at ."
  • Assuming any equation or graph is automatically a function without checking (e.g. treating as a function of ).
  • Forgetting to keep brackets when substituting an expression like , leading to sign errors (writing instead of correctly expanding ).
  • Declaring a table "not a function" just because a -value repeats — repeated outputs are allowed; only repeated inputs with different outputs are not.
  • Assuming . For , , which is not — substitute into the rule, never "add to the output."

Flashcards 10

Relation
Function
Vertical line test
+ 6 more

Practice

1
Which set of ordered pairs is NOT a function?
2
If , what is ?
3
State the test used to determine, from a graph, whether a relation is a function.
4
Which graph definitely fails the vertical line test?
5
Given , find so that .
6
If , write the simplified expression for .
7
Put these steps in order for evaluating f(5) when f(x) = 3x² − 2x:
  1. 1Simplify the exponent: 3(25) − 2(5)
  2. 2Subtract: 65
  3. 3Multiply: 75 − 10
  4. 4Write f(5) = 3(5)² − 2(5)
8
Match each representation of a function to its description.
Equation
Mapping diagram
Table of values
Set of ordered pairs
9
Which statement about is correct?
10
A phone plan costs dollars for minutes of calls. How many minutes give a bill of 32 dollars?
min
11
For , how many values of satisfy ?
12
A mapping diagram shows the input 6 with two arrows, one to 1 and one to 8. Is the relation a function? Answer yes or no.

Spot a mistake on this page? Let us know