Which Of These Relations Is A Function

9 min read

You're staring at a set of ordered pairs. So or a mapping diagram. Or maybe a graph. And the question hits: *which of these relations is a function?

It's one of those math questions that looks simple until you actually have to explain why the answer is what it is. I've watched students freeze on this exact prompt — not because they don't get functions, but because the wording trips them up.

Not obvious, but once you see it — you'll see it everywhere The details matter here..

Let's clear it up once and for all That alone is useful..

What Is a Function (Really)

A relation is just a set of ordered pairs. That's it. Still, nothing fancy. On top of that, you take some inputs, you get some outputs, you write them as (x, y). A function is a special kind of relation — one where every input has exactly one output That alone is useful..

That's the whole rule. One input, one output. No exceptions.

The Input-Output Way to Think About It

Imagine a vending machine. In practice, you press A1 (input). So never water. Day to day, never chips. In real terms, every time you press A1, you get a soda. You get a soda (output). Because of that, just soda. That's a function.

Now imagine a broken machine. So naturally, you press A1. Sometimes you get soda. Sometimes you get chips. Sometimes nothing comes out. Same input, different outputs. That's a relation — but not a function Still holds up..

The technical definition: a relation f from set A to set B is a function if for every a in A, there exists exactly one b in B such that (a, b) is in f.

But you don't need to memorize that. You just need to check: does any x-value show up more than once with different y-values?

If yes → not a function.
If no → it's a function.

Why This Distinction Actually Matters

You might wonder: *who cares?Also, * Fair question. But this distinction shows up everywhere.

In Algebra and Beyond

Functions are the backbone of algebra, calculus, and basically all higher math. That's why you can't do derivatives of relations that aren't functions. And you can't reliably solve equations. You can't model real-world phenomena cleanly But it adds up..

Think about it: if you're modeling the height of a ball over time, each moment in time (input) has exactly one height (output). Because of that, time doesn't branch. That's a function. But if you tried to model "all points on a circle" as y = f(x), you'd fail — because for most x-values, there are two y-values (top and bottom of the circle). That's why we use parametric equations or implicit functions instead Simple, but easy to overlook. And it works..

In Programming

Ever written a function in code? Same concept. Day to day, a function takes arguments and returns one value. If your "function" sometimes returns a string, sometimes an integer, sometimes null — that's a bug waiting to happen. Pure functions in functional programming? They're mathematical functions. Deterministic. No side effects. One input → one output. Every time.

In Data Science

When you're cleaning data, you're essentially asking: *is this column a function of that column?That's why * If user_id maps to multiple different email addresses, you've got a data quality issue. That's not a function — it's a messy relation Small thing, real impact..

How to Tell If a Relation Is a Function

Here's where the rubber meets the road. That said, you'll encounter relations in four main forms. Each has its own test Not complicated — just consistent..

1. Set of Ordered Pairs

This is the most direct form. Just list the pairs and check for duplicate x-values with different y-values It's one of those things that adds up..

Example 1:
{(1, 2), (2, 4), (3, 6), (4, 8)}
Every x is unique. Function.

Example 2:
{(1, 2), (2, 4), (1, 3), (3, 6)}
x = 1 maps to both 2 and 3. Not a function.

Example 3:
{(-2, 4), (-1, 1), (0, 0), (1, 1), (2, 4)}
Different x's can share the same y. That's fine. x = -2 and x = 2 both give y = 4. Still a function.

The rule is one-way: one x → one y. Not one y → one x Still holds up..

2. Mapping Diagrams

You've seen these. In real terms, two ovals. Arrows from inputs to outputs.

Function: Every input has exactly one arrow leaving it.
Not a function: At least one input has two or more arrows leaving it Simple, but easy to overlook..

That's it. Don't overthink it. Count the arrows from each input.

3. Tables

x y
1 3
2 5
3 7
2 9

Stop. In real terms, x = 2 appears twice with different y-values (5 and 9). **Not a function Small thing, real impact. Took long enough..

x y
-3 9
-2 4
-1 1
0 0
1 1
2 4
3 9

Every x appears once. Function. (And yes, this is y = x².

4. Graphs — The Vertical Line Test

It's the one everyone remembers. Draw vertical lines across the graph. If any vertical line hits the graph more than once, **it's not a function.

Why? Because a vertical line represents a single x-value. If it crosses the graph twice, that x has two y-values. Violates the rule.

Passes vertical line test:

  • Lines (except vertical ones)
  • Parabolas opening up/down
  • Cubic curves
  • Exponential curves
  • Sine and cosine waves

Fails vertical line test:

  • Circles
  • Ellipses
  • Sideways parabolas (x = y²)
  • Any graph that loops back on itself horizontally

Here's a trap: a vertical line itself (x = 3) fails the test spectacularly. Every point on that line has x = 3. Infinite y-values for one x. Definitely not a function.

Common Mistakes (And Why They're Wrong)

I've seen these trip up students for years. Let's kill them off.

"But the y-values repeat!"

So what? But the definition says nothing about y-values being unique. On the flip side, y = x² gives y = 4 for both x = 2 and x = -2. Practically speaking, that's a perfectly good function. One-to-one functions do have unique y-values — but that's a stricter category (injective functions). Not required for "function Worth keeping that in mind..

"It's not a function because it's not a straight line."

Functions can be curves. The shape doesn't matter. They can be piecewise. Even so, they can be absolute value, square root, rational, trigonometric. Now, they can be wiggly. Only the vertical line test matters.

"The domain and range are swapped, so it's not a function."

Swapping domain and range gives you the inverse relation. The inverse of a function might be a function (if the original was one-to-one). But the inverse of a function might not be a function.

5. Inverses and Why Swapping Doesn’t Matter

When we talk about “swapping the domain and range,” we’re really describing the inverse relation of a given rule. Imagine you have a function (f) that maps each (x) to a unique (y). The inverse relation, often written (f^{-1}), tries to map each (y) back to its original (x) Which is the point..

Not obvious, but once you see it — you'll see it everywhere.

What can go wrong?

  • If the original function is one‑to‑one (each (y) comes from exactly one (x)), then the inverse relation is also a function. Think of (f(x)=2x+3); its inverse (f^{-1}(y)=\frac{y-3}{2}) works perfectly.
  • If the original function is not one‑to‑one—like (g(x)=x^{2})—the inverse relation pairs a single (y) (say, (4)) with two possible (x) values ((-2) and (2)). In that case the inverse fails the “one arrow per input” rule and is not a function.

The crucial point: the status of the original mapping does not change when you swap axes. So the statement “the domain and range are swapped, so it’s not a function” is a red herring. In practice, whether the original rule is a function is a property of how each input (x) behaves, not of how the inverse behaves. The original relation either satisfies the one‑arrow rule or it doesn’t, regardless of any later manipulation.

6. Quick Checklist for “Is This a Function?”

  • Mapping diagram: Count arrows leaving each input. One arrow per input → function.
  • Table: No repeated (x) values with different (y) values.
  • Graph: Pass the vertical line test—no vertical line cuts the graph more than once.
  • Formula: For every permissible (x), the expression must produce a single, well‑defined (y). If the formula involves something like (\sqrt{x}) (principal root) or a piecewise definition that assigns a unique output, you’re good.

If you can tick all three boxes, you have a function. If any box fails, you’re looking at a relation that isn’t a function.

7. Why the Definition Matters

The “one input → one output” rule might seem restrictive, but it’s the backbone of calculus, algebra, and virtually every higher‑level math you’ll encounter. Functions let us:

  1. Predict outputs from inputs (modeling real‑world phenomena).
  2. Compose operations (build complex rules from simple ones).
  3. Invert when appropriate (solve equations, find inverses).
  4. Analyze behavior (limits, derivatives, integrals all rely on functional relationships).

Understanding what doesn’t qualify as a function—multiple outputs for a single input, vertical‑line failures, ambiguous mappings—helps you avoid subtle errors later on Simple as that..

8. Final Takeaway

A function is simply a reliable one‑way street: every driver (input) follows exactly one route (output). So whether the road is a straight line, a looping curve, a table of values, or a set of arrows on a diagram doesn’t matter. In real terms, what matters is that no input ever branches into two different outputs. Once you internalize this principle, the vertical line test, mapping diagrams, and tables become just different ways of checking the same rule That alone is useful..

You'll probably want to bookmark this section.

So next time you encounter a graph, a table, or a formula, ask yourself: Does every (x) have a single, unambiguous (y)? If the answer is yes, you’re dealing with a function. If not, you’re looking at something else—and that’s perfectly fine too, as long as you know what you’re working with Took long enough..

New Content

Fresh Off the Press

Connecting Reads

Good Company for This Post

Thank you for reading about Which Of These Relations Is A Function. We hope the information has been useful. Feel free to contact us if you have any questions. See you next time — don't forget to bookmark!
⌂ Back to Home