Functions are the primary objects of study in calculus. A function describes how an output variable depends deterministically on an input variable.
Quick Reference
| Term | Definition / Condition | Symbol |
|---|---|---|
| Domain | Set of all valid inputs | |
| Codomain | Target set containing potential outputs | B in |
| Range | Set of all actual outputs | |
| Vertical Line Test | Intersects graph at most once | Test for function graphs |
Definition of a Function
A function can be thought of as a machine or a computer program that assigns one output to every allowable input.
A function f from a set A to a set B is a rule that assigns, to each element x in A, one and only one element y in B. We then write .
Sets A and B are called the domain and codomain of f, respectively. To state that f is a function with domain A and codomain B, we write .
- If , we call x the independent variable, the argument of the function, or the input of the function, and y the dependent variable, the value of f at x, the image of x under f, or the output of the function.
- The definition of a function does not restrict the nature of the elements of A and B, but in elementary calculus we assume that the elements of A and B are numbers; that is, A and B are subsets of the real numbers , unless stated otherwise.
Strictly speaking, is the value of f at x, but we often talk about "the function " or "the function ." For example, consider a function that takes a number x and gives its square . In this case, we can simply say: "the function ."
Domain and Range
For a function :
- The set A is called the domain of f, denoted by .
- The set of all possible values of as x varies throughout A is called the range of f, denoted by :
If a function is defined by an algebraic formula and the domain is not explicitly stated, the convention is that the domain is the natural domain: the set of all real numbers for which the formula is defined and yields a real number.
The Graph of a Function
The graph of a function is the set of all ordered pairs in the -plane such that :
Visualizing the graph allows us to observe domain (projected onto the x-axis) and range (projected onto the y-axis).

The Vertical Line Test
Vertical Line Test: A curve in the -plane is the graph of a function of x if and only if no vertical line intersects the curve more than once.