Functions

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 Dom ( f )
Codomain Target set containing potential outputs B in f : A B
Range Set of all actual outputs f ( x ) Rng ( f )
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 y = f ( x ) .

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 f : A B .

  • If y = f ( x ) , 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 f : A B 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, f ( x ) is the value of f at x, but we often talk about "the function f ( x ) " or "the function y = f ( x ) ." For example, consider a function f : that takes a number x and gives its square x 2 . In this case, we can simply say: "the function f ( x ) = x 2 ."

Domain and Range

For a function f : A B :

  • The set A is called the domain of f, denoted by Dom ( f ) .
  • The set of all possible values of f ( x ) as x varies throughout A is called the range of f, denoted by Rng ( f ) : Rng ( f ) = { y B there exists  x A  such that  f ( x ) = y }

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 f is the set of all ordered pairs ( x , f ( x ) ) in the x y -plane such that x Dom ( f ) :

Graph ( f ) = { ( x , f ( x ) ) x Dom ( f ) }

Visualizing the graph allows us to observe domain (projected onto the x-axis) and range (projected onto the y-axis).

Graph of a function showing domain projected on x-axis and range projected on y-axis
Visualizing domain (on x-axis) and range (on y-axis) from a function graph.

The Vertical Line Test

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