There are many ways to describe or write functions. The method used depends on many factors such as the domain of the function, the complexity of the function or even the subject matter in which the function arises. We describe a few common methods here.
(1) If the domain is small we might just list all function values. Let
and
. If I tell you that f(1)=b, f(2)=b and f(3)=d then I have completely defined a function
.
Observe that this f neither 1-1 nor onto and has range
, a proper
subset of Y.
(2) We could list all pairs in the graph of f, again if the domain is
small. The function in (1) could be given by
.
(3) Quite often simple functions like the example in (1) are indicated by
just listing the elements of both the domain and codomain and connecting x
values to function values by arrows. Here's how that's done.
(4) For numerical functions, a formula might be given in terms of x that
calculates the value of f(x). For X=Y=R the set of real numbers,
would define
. Since
, the
point (2,7) would be a point in the graph but there certainly are too many
points to list as in (2).
(5) A picture of the graph in (4) would be a good way to visually represent f instead of just supplying the formula. The picture is simple a plot of
the points (x,y) in the plane
that satisfy the equation
.
(6) It is sometimes possible to describe a function in words without resorting to lists, formulas or pictures. For example, the air temperature where you are sitting right now can be considered a function of time. That is, to each point in time we associate the corresponding temperature at that time. The domain consists of whatever scale is used to record time (12 or 24 hr. clock, minutes or fractions of hours, etc.) and the range is a subset of the real numbers (whatever temperature scale is used). This is a function by definition, yet you probably don't have a formula for this correspondence (well, unless the temperature is constant where you are).