Introduction to Functions
A function is a rule that takes an input and gives back exactly one output. Feed it a number, get one number back — every time, no exceptions. The set of pairs is a function because each input appears once. The set is not, because the input can't make up its mind.
That one-output rule is the entire definition, and everything else in this article — mapping diagrams, the vertical line test, notation — is just a different way of checking or writing the same idea. Get comfortable with it now, because every graph you meet from here through Algebra 2 is a function first.
One output per input
Think of a function as a machine: input goes in, output comes out. The rule for being a function is strict about inputs but relaxed about outputs. An input may never produce two different outputs — but two different inputs are allowed to share the same output. The set is a perfectly good function even though every output is .
To test a list of ordered pairs, scan the -values. If any -value repeats with different -values, it is not a function. In a mapping diagram — inputs in one oval, outputs in the other, arrows between — the same test reads as: every input has exactly one arrow leaving it. The diagram below is a function: input and input both land on (a shared output is fine), but no single input splits into two arrows.
Function notation: what f(x) means
Instead of writing , we often write . Nothing about the rule changed — is just a smarter name for . The letter names the function, the in parentheses is the input, and is the output the rule produces.
The payoff is that the notation carries the input with it. means the output when the input is : substitute everywhere you see . For , that gives . One important warning: is not times . The parentheses here mean is a function of, not multiplication.
A table lines the inputs up with their outputs — each row is one ordered pair . Reading the table for : the input sits in the same row as the output , which is the ordered pair .
The vertical line test
On a graph, the inputs run along the horizontal axis. So the one-output rule becomes a visual test: if any vertical line crosses the graph more than once, some input has two outputs, and the graph is not a function. If every vertical line crosses at most once, it is.
The parabola below passes the test. Slide an imaginary vertical line from left to right — at every position it touches the curve exactly once, so each input has exactly one output. A circle, by contrast, fails the test: most vertical lines through a circle hit it twice.
Worked examples
Example 1: is this set of pairs a function?
Is the relation a function?
Answer: Not a function — the input has two different outputs
Example 2: evaluate a function
If , find .
Answer:
Example 3: evaluate with a negative input
If , find .
Answer:
Example 4: work backwards from the output
If , what value of makes ?
Answer:
Try one yourself
Common questions
Can two different inputs have the same output?
Yes. The function rule only restricts inputs: each input gets exactly one output. Outputs are free to repeat. is a function; is not.
Is the same thing as ?
For graphing purposes, yes — and describe the same line. Function notation just adds information: tells you both the input and the output in one statement, where only tells you the output.
Does mean multiplied by ?
No. In function notation the parentheses mean the function applied to the input , not multiplication. is the output at input — you find it by substituting, never by multiplying a letter by .
Want the video version?
Allday Everyday Math has video lessons, practice, and an AI tutor for every topic, Pre-Algebra through Algebra 2.