Skip to content
Family Table Math
Auto

Relations and Functions

A relation is any rule or set of ordered pairs that connects inputs to outputs. A function is a special relation where every input has exactly one output. Almost everything you’ll study this year is a function, so learning to recognize one is the first step.

A relation pairs each input xx with an output yy, written as ordered pairs (x,y)(x, y). You can show the same relation in several ways:

  • a list of ordered pairs, like {(1,4),(2,5),(3,4)}\{(1, 4), (2, 5), (3, 4)\}
  • a table of values
  • a mapping diagram, with arrows from each input to its output(s), like 1↦41 \mapsto 4
  • a graph
  • an equation, like y=x2y = x^2

A relation is a function if each input has exactly one output.

  • Two different inputs can share the same output. That’s fine.
  • One input with two different outputs is not allowed.

Think of a vending machine: press B4 and you should get the same snack every time. If B4 sometimes gave chips and sometimes gave a granola bar, the machine wouldn’t be a function.

  • One-to-one function: every output comes from just one input. Example: y=2xy = 2x.
  • Many-to-one function: some output comes from more than one input. Example: y=x2y = x^2, where both x=2x = 2 and x=−2x = -2 give y=4y = 4.
  • One-to-many (one input, several outputs) is not a function.

On a graph, an input is an xx-value, so all the points with that input lie on one vertical line.

A graph is a function if no vertical line crosses it more than once.

Vertical line test on two graphs −2 2 2 Function y = x² − 2 2 −2 2 Not a function x = y² − 2
The line x=1x = 1 crosses y=x2−2y = x^2 - 2 once, but crosses x=y2−2x = y^2 - 2 twice.

To check an equation, ask: can one xx-value give two different yy-values? A quick way is to try a value of xx and solve for yy.

  • y=x2−2y = x^2 - 2: each xx gives one yy. Function.
  • x=y2−2x = y^2 - 2: x=2x = 2 gives y2=4y^2 = 4, so y=2y = 2 or y=−2y = -2. Not a function.

Is each relation a function?

(a) {(1,4),(2,5),(3,4),(4,7)}\{(1, 4), (2, 5), (3, 4), (4, 7)\}

(b) {(2,1),(2,3),(5,0)}\{(2, 1), (2, 3), (5, 0)\}

Solution.

(a) The inputs are 1,2,3,41, 2, 3, 4, and each appears once. It’s a function. The output 44 appears twice (from 11 and 33), which is allowed. It’s a many-to-one function.

(b) The input 22 is paired with both 11 and 33. Not a function.

xx−1-1001122
yy33113399

Is this relation a function? If so, is it one-to-one or many-to-one?

Solution. Each input appears once, so it’s a function. The output 33 comes from two inputs (−1-1 and 11), so it is many-to-one.

Which of these are functions?

(a) y=3x−4y = 3x - 4 \qquad (b) x2+y2=9x^2 + y^2 = 9 \qquad (c) y=xy = \sqrt{x}

Solution.

(a) Each xx gives one value of 3x−43x - 4. Function (one-to-one; its graph is a slanted line).

(b) Try x=0x = 0: y2=9y^2 = 9, so y=3y = 3 or y=−3y = -3. One input, two outputs. Not a function. (Its graph is a circle, which fails the vertical line test.)

(c) x\sqrt{x} means the positive square root, so each x≥0x \ge 0 gives exactly one yy. Function.

Thinking a repeated output breaks the rule. {(1,5),(2,5)}\{(1, 5), (2, 5)\} is a function. The rule is about inputs: one input can’t have two outputs.

Using a horizontal line instead of a vertical one. The vertical line test checks for a function. A horizontal line test checks something else (whether the function is one-to-one), which matters later for inverse functions.

Worrying about a repeated pair. If (2,5)(2, 5) is listed twice, it’s still the same input with the same output. That’s fine.

Assuming every equation is a function. Circles, like x2+y2=9x^2 + y^2 = 9, and sideways parabolas, like x=y2x = y^2, are relations but not functions. Test a value of xx when you’re unsure.

1. (Warm-up) Is {(−3,2),(0,2),(4,2)}\{(-3, 2), (0, 2), (4, 2)\} a function?

Solution

Yes. Each input (−3-3, 00, 44) has exactly one output. All three share the output 22, which is allowed (many-to-one).

2. (Warm-up) Is {(1,5),(3,−2),(1,7),(6,0)}\{(1, 5), (3, -2), (1, 7), (6, 0)\} a function?

Solution

No. The input 11 is paired with both 55 and 77.

3. (Warm-up) The points (2,5)(2, 5) and (2,−1)(2, -1) are both on a graph. Can the graph be a function?

Solution

No. Both points have the input x=2x = 2 but different outputs, so the vertical line x=2x = 2 crosses the graph twice.

4. (Core) Is this relation a function? If so, is it one-to-one or many-to-one?

xx−2-2−1-1001122
yy4411001144
Solution

Each input appears once, so it’s a function. Outputs 44 and 11 each come from two inputs, so it’s many-to-one. (These values fit y=x2y = x^2.)

5. (Core) Decide whether each equation is a function.

  • (a) y=2x2−1y = 2x^2 - 1
  • (b) y2=x+4y^2 = x + 4
  • (c) y=1xy = \dfrac{1}{x}
  • (d) x=3x = 3
Solution

(a) Function. Each xx gives one value of 2x2−12x^2 - 1.

(b) Not a function. For x=0x = 0, y2=4y^2 = 4, so y=2y = 2 or y=−2y = -2.

(c) Function. Each x≠0x \ne 0 gives one value of 1x\dfrac{1}{x}. It’s one-to-one.

(d) Not a function. Every point on this graph has x=3x = 3, so the single input 33 has infinitely many outputs. (The graph is itself a vertical line.)

6. (Core) Is each relation a function? Explain.

  • (a) Each student in your class is paired with the month they were born in.
  • (b) Each month is paired with the students in your class born in that month.
Solution

(a) Function. Every student has exactly one birth month. Many students can share a month, so it’s many-to-one.

(b) Not a function (in most classes). A month like March could be paired with several students, so one input has several outputs.

7. (Challenge) For which values of kk is {(k,2),(3,5),(1,2)}\{(k, 2), (3, 5), (1, 2)\} a function?

Solution

The only problem would be the input 33 having two different outputs. That happens if k=3k = 3, because then (3,2)(3, 2) and (3,5)(3, 5) are both in the relation.

If k=1k = 1, the pair (1,2)(1, 2) just appears twice, which is fine.

So the relation is a function for every value of kk except 33.

8. (Challenge) The circle x2+y2=25x^2 + y^2 = 25 is not a function, but its top half, y=25−x2y = \sqrt{25 - x^2}, is. Explain why.

Solution

Solving the circle’s equation for yy gives y=±25−x2y = \pm\sqrt{25 - x^2}. For any xx between −5-5 and 55, that’s two outputs (one positive, one negative), so the circle fails the vertical line test.

The top half keeps only the positive square root, y=25−x2y = \sqrt{25 - x^2}. Now each xx from −5-5 to 55 gives exactly one yy, so every vertical line crosses it at most once.

Try these independently after the practice questions. Show your setup and explain your reasoning. Use exact answers where possible, and check that your answers fit the question. Homework solutions are not provided on the published site.

H1. (Foundations) Decide whether each relation is a function. For every function, say whether it is one-to-one or many-to-one. A repeated listing of the same pair represents the same point.

  • (a) {(−4,6),(0,6),(3,6)}\{(-4,6),(0,6),(3,6)\}
  • (b) {(2,7),(5,1),(2,7)}\{(2,7),(5,1),(2,7)\}
  • (c) {(1,−2),(4,3),(1,5)}\{(1,-2),(4,3),(1,5)\}

H2. (Foundations) A mapping diagram has input set {1,2,3}\{1,2,3\} and possible output set {4,5,6,7}\{4,5,6,7\}. Its arrows are 1↦41\mapsto4, 2↦62\mapsto6, and 3↦43\mapsto4. Is this a function on the stated input set? Does not using outputs 55 and 77 violate the function rule? What changes if an arrow 2↦72\mapsto7 is added?

H3. (Core) Convert this table into ordered pairs and sketch the discrete points. Use a vertical line argument to classify the relation. Is it one-to-one?

xx−2-2−1-1001122
yy5522112255

H4. (Core) For each equation, determine whether yy is a function of xx over all points satisfying the equation. Support a negative answer with one input and two distinct outputs.

  • (a) y=4−3xy=4-3x
  • (b) (x−1)2+y2=16(x-1)^2+y^2=16
  • (c) y=x+2y=\sqrt{x+2}
  • (d) y=2x−3y=\dfrac{2}{x-3}

H5. (Core) Consider the circle x2+y2=16x^2+y^2=16.

  • (a) Is the whole circle a function of xx?
  • (b) Keep only points with y≥0y\ge0. Write an equation for this part and explain why it is a function.
  • (c) Is this restricted function one-to-one? Give a pair of distinct inputs to support your answer.

H6. (Core) Decide whether each rule defines a function on its stated input set. Explain any assumptions needed.

  • (a) Each library member is paired with their unique membership number.
  • (b) Each member who currently has at least one borrowed book is paired with every book they have borrowed.
  • (c) Each membership number currently issued is paired with its registered member.
  • (d) Each book title in the catalogue is paired with all physical copies of that title.

H7. (Challenge) For which real values of aa is {(a,4),(2,a),(5,4)}\{(a,4),(2,a),(5,4)\} a function? Among those values, when is the function one-to-one? Explain repeated pairs separately from conflicting outputs.

H8. (Challenge) You may delete ordered pairs, but cannot change any coordinates, from

{(0,2),(0,5),(1,3),(1,7),(2,3),(3,9)}.\{(0,2),(0,5),(1,3),(1,7),(2,3),(3,9)\}.
  • (a) What is the smallest number of deletions needed to leave a function?
  • (b) List every resulting function obtainable with that smallest number.
  • (c) Which of them are one-to-one?

H9. (Challenge) Compare the graphs x=6x=6 and y=6y=6. Explain why exactly one is a function of xx. For the graph that is a function, classify it as one-to-one or many-to-one. Why does using a horizontal line test answer a different question?

H10. (Challenge) Consider the relation y2=x2y^2=x^2.

  • (a) Explain why it is not a function of xx.
  • (b) Does restricting only x≥0x\ge0 fix the problem?
  • (c) Restrict instead to y≥0y\ge0, with all real xx allowed. Write the resulting function and determine whether it is one-to-one.
  • (d) Restrict both x≥0x\ge0 and y≥0y\ge0. Write the resulting function and classify it.