Introduction to Functions
High School Math · Algebra 1Preview
1. Introduction
Functions are the single most important idea in all of high school mathematics, and they quietly power almost everything you will study afterward — calculus, statistics, physics, economics, and computer science. The reason is simple: a function is the mathematical word for a dependable relationship. Whenever one quantity is determined by another — the cost of gas depending on the number of gallons, the height of a thrown ball depending on time, the area of a circle depending on its radius — you are looking at a function.
Informally, a function is a machine. You feed it an input, it performs some fixed rule, and it returns exactly one output. The crucial words are exactly one: a function is never allowed to be indecisive. If you put the same input in twice, you must get the same output both times. This single restriction is what separates functions from arbitrary relations, and it is what makes them so useful for prediction.
In this article we build the concept from the ground up. We start with the intuition of inputs and outputs, formalize the definition, learn the universal language of function notation, and then study the two most important sets attached to any function: its domain (allowed inputs) and its range (resulting outputs). Along the way we learn to read graphs, apply the vertical line test, compose functions, perform arithmetic on outputs, and avoid the classic mistakes that trip up nearly every student the first time around. By the end you should be able to evaluate functions fluently, determine domains by inspection, and recognize functions in tables, graphs, equations, and words.
Functions are the language in which calculus, physics, and data science are written. Investing time now to make function notation second nature — especially domain, range, and composition — pays compound interest throughout your mathematical education.
2. Core Concepts
2.1 What a function really is
Picture a vending machine. You press B4 and out comes a specific snack. Press B4 again and you get the same snack. A vending machine that sometimes gave you chips and sometimes gave you gum for the same button would be broken — and that is exactly what a "broken" relation looks like in mathematics.
Formally, a function from a set to a set is a rule that assigns to each element exactly one element . We call the domain and the codomain. The element assigned to is written , read " of ."
Two requirements are hidden in this definition:
- Existence: every input in the domain must produce an output (no input is left unmatched).
- Uniqueness: no input may produce two different outputs.
Uniqueness is the part people forget. The relation " is a number whose square is " is not a function of , because would give both and . By contrast " is the non-negative square root of " is a function.
2.2 Relations versus functions
A relation is any pairing of inputs with outputs — it does not require uniqueness. Every function is a relation, but not every relation is a function. The set of all ordered pairs satisfying a rule is called the graph of the relation. A relation is a function exactly when no input appears with two different outputs .
2.3 Function notation and why we use it
The notation is one of the best inventions in mathematics because it does two jobs at once: it names the function () and it names the input (). When we write
we are giving the rule: "take the input, double it, and add one." The letter is a placeholder. We can replace it with any number or even another expression:
A common beginner error is to read as " times ." It is not multiplication. It is the output of at . The parentheses here mean "evaluate," not "multiply."
We are free to use other letters. , , and are all functions; the letter inside the parentheses just tells us what the input variable is called. Writing instantly signals that volume depends on radius.
2.4 Domain: the allowed inputs
The domain is the set of all inputs for which the rule produces a valid real-number output. Sometimes the domain is stated explicitly; more often you must infer it from the formula by asking: what inputs would break the arithmetic?
There are three classic "forbidden operations" to watch for in high school:
- Division by zero. Any input that makes a denominator zero is excluded. For , the value is not allowed, so the domain is all real numbers except .
- Even roots of negatives. A square root (or fourth root, etc.) requires a non-negative radicand. For , we need , so the domain is .
- Logarithms of non-positive numbers: the argument must be strictly positive.
Odd roots, like , accept every real number, since you can take the cube root of a negative.
2.5 Range: the resulting outputs
The range is the set of all outputs the function actually produces as the input runs over the entire domain. Range is usually harder to find than domain because it depends on the behavior of the rule, not just on forbidden operations.
For , every output is a square, so the range is even though the domain is all real numbers. For (a line), every real number is hit exactly once, so the range is all real numbers. A reliable strategy is to think about the graph: the domain is the set of -values covered (horizontal shadow), and the range is the set of -values covered (vertical shadow).
2.6 Representations of a function
The same function can appear in four forms, and fluency means moving between them:
- Verbal: "Output is one more than twice the input."
- Algebraic: .
- Numerical (table): input , input , input .
- Graphical: the straight line through those points.
These are four pictures of one object. A table is a function only if no input is listed twice with different outputs.
2.7 Mapping diagrams and arrow notation
A mapping diagram shows the domain on the left, the codomain on the right, and arrows from each input to its unique output. If any input has two arrows leaving it, the diagram does not represent a function. Arrow notation means "the input is sent to the output ." This picture is especially helpful when the domain is a small finite set, such as .
2.8 The vertical line test
A graph in the -plane represents as a function of exactly when no vertical line crosses the graph more than once. The reasoning is direct: a vertical line collects every point with input . If the line hits the graph twice, then the input has two outputs, violating uniqueness.
A parabola passes the test. A full circle fails it, because the line meets it at both and . So a circle is a relation but not a function.
2.9 Function arithmetic
Given two functions and with overlapping domains, we can combine their outputs:
The domain of each combined function is the intersection of the individual domains, with extra exclusions for division. For example, if and , then has domain .
2.10 Composition of functions
Composition applies one function after another. The composition means "apply first, then apply to the result":
Order matters: in general . The domain of requires that be in the domain of and that be a legal input of .
2.11 Piecewise-defined functions
A piecewise function uses different formulas on different parts of the domain. The absolute value is the classic example:
Each piece must cover its region without overlap (except at boundaries, where the outputs must agree if the function is to be well-defined). Piecewise functions model real situations with different rules in different regimes — tax brackets, shipping rates, or speed limits.
2.12 Inverse functions (preview)
If sends to and never repeats an output, we can define an inverse function that sends back to . Formally, for every in the domain of , and for every in the range of . The notation does not mean ; it means "undo ." Linear functions with always have inverses .
Continue reading with Premium
Upgrade to read the full article and unlock all Premium features.
Free
- Unlimited practice — all difficulties
- 3 hints / day
- Community solutions
- 2 timed mocks / month
Premium
- ✓Full article + all 57+ theory guides
- ✓Unlimited hints on practice problems
- ✓Unlimited timed mock exams & PDF worksheets