abstractmath.org
help with abstract math
Produced by Charles Wells. Home Website TOC Website Index Blog
Back to Functions Head
Last edited 7/15/2009 7:21:00 PM
EXAMPLES OF FUNCTIONS
The examples given here:
¨ are basic types of functions that are used everywhere in abstract math
¨ are functions you need to be familiar with
¨ are (sigh) boring.
For any set A, the identity
function is the function that takes an element
to itself; in other words, for every element ,
.
Its graph is the diagonal of .
¨
Warning: The word identity has two other
commonly used meanings. This causes trouble because people
may refer to the identity function as simply “the identity”, especially in
conversation.
¨ The notation for the identity function on A is fairly common, but so is .
Properties
The
identity function is injective
and surjective.
¨ The identity function on a set A is the function that does nothing to each element of A.
¨ The identity function on is the familiar function defined by .
Its graph in the plane is the diagonal line from lower left to upper right through
the origin. Its derivative is the
constant function defined by g(x) = 1.
¨ There is a different
identity function for each different set.
See overloaded notation. These functions all have the “same”
formula: for every a in A. But they are technically different
functions because they have different domains.

If (see inclusion), then
there is an inclusion function that takes every element in A to the
same element. In other words, inc(a) = a for every element .
This fits the property of codomain that
requires (in this case) that because that is what “ ” means every element of A is an element of B.
¨ The notation for the identity function on A show which set A we are using, but the notation “inc” does not show either set.
¨ The notation “inc” is my own and is not common. Other notations I have seen are: and
¨ Many mathematicians who use the looser definition of function never talk about the inclusion function. For them, it is merely the identity function.
Properties
The inclusion function is injective. It is surjective if and only if A = B.
¨ The definition says the inclusion function “takes every element in A to the same element.” I could have worded it this way:
“The inclusion function takes each element of A to the same element regarded as an element of B.”
This wording incorporates elements of “how you think about X” into the definition of X. This is loose and unrigorous. But I’ll bet a lot of readers would understand it more quickly that way!
¨ The graph of inc is the same as the graph of and they have the same domain, so that the
only difference between them is what is
considered the codomain (A for ,
B for the inclusion of A in B). So inc is different from if you require that functions with different
codomains be different (discussed here).
If A and B are
nonempty sets and b is a specific element of B, then the constant
function is the function that takes every element of A to b; that is, for all .
The notation is not common. There is no standard notation for constant functions.
Properties
The constant function is injective only if A has exactly one element. It is surjective only if B has exactly one element.
¨ A constant function takes everything to the same thing. It has a onetrack mind.
¨ A constant function from to has a horizontal line as its graph.
¨ The constant function is not the same thing as the element b of B.
If A is any set, there is exactly one function .
Such a function is an empty function.
Its graph is empty, and it has no values. An identity function does
nothing. An empty function has nothing to do.
Properties
The empty function is vacuously
injective. It is surjective only if A is empty.
If A and B are sets, there are two coordinate
functions (or projection functions) and . Thus
for and ,
and . (See cartesian product).
In general for an nfold cartesian product, the function takes an ntuple to its i th coordinate.
Properties
¨ is injective if and only if either A is empty or B has at most one element.
¨ It is surjective if and only if A is empty or B is nonempty.
¨ If A (or B) is empty, then so is . In that case is the empty function.
¨ For any set S, there are two different coordinate functions and . For example, if S is the set of real numbers, then and .
The coordinate function may be denoted by or sometimes (for projection).
A binary operation on a set S is a function . (See cartesian product).
¨ The operation of adding two real numbers gives a binary operation
¨ Subtraction is also a binary operation on the real numbers. Observe that, unlike addition, it cannot be regarded as a binary operation on the positive real numbers.
¨ Multiplication of real numbers is also a binary operation .
¨ Division is not a
binary operation on the real numbers because you can’t divide by 0. However, it is a binary operation on the nonzero real numbers ( is standard
notation for the nonzero reals). You
could also look at the function since 0 / y is defined even
though y / 0 is not. But
it is not a binary operation because by definition a
binary operation has to fit the pattern where all three sets are the same.
¨ For any set S, the two
projections and are both binary operations on S.
¨ With a binary operation symbol, infix notation is usually used: the name of the binary operation is put between the arguments. For example we write 3 + 5 = 8, not +(3, 5) = 8.
¨ Binary operations are the basis of most of algebra. See groups for more examples.
In this section I give you examples of really weird functions that you may never have thought of as functions before, because if you are a beginner in abstract math, you probably need to:
Loosen up narrowminded ideas about what a function is
Other consciousnessexpanding examples of functions are listed in an appendix.
Let be defined by
The graph of this function is pictured on the right.
¨ F is given by a split definition. It is defined by one formula for part of its domain and by another on the rest. F is nevertheless one function, defined on the closed interval [0,1].
¨ F is discontinuous at .
¨ F is
neither injective nor surjective.
¨ F does not have a derivative at x = 0.5.
¨ The graph does not and cannot show the precise behavior of the function near .
a.
The point is on the graph, because the definition of F says that F(x) is for x
between
b. For
any point x to the right
of
c. but .
d. Nevertheless, F(
¨ It would be wrong to say something like: “ starting at the
first point to the right of x = 0.5”. There is no first point to the right
of x = 0.5. See density.
A function can be given by different rules on different parts of its domain.
It is still one function.
Let the
function F be defined on the set as follows: .
¨
F is defined only for inputs
¨ F is not injective since F(1) = F(2).
¨ F is not defined by a formula.
F(2) = 3 because the definition says it
is.
¨ F could be defined by the formula for . (This is given by an interpolation formula (MW, Wik)). But it is not obligatory that a function be defined by a formula, only that a mathematical definition of the function be given. See Conceptual and Computational.
¨ You could give the function as a table, as in (a).
¨ You can show the function in an picture, with arrows going from each input to its output, as in (b).
A function does not have to be given by a formula.
Another finite function is studied here.
Let S be some set of English words, for example the set of words
in a given dictionary. Then the length
of a word is a function; call it L.
¨ L takes words as inputs.
¨ L outputs the number of letters in the word. For example, and .
¨ L is not injective. For example, .
¨ L is not surjective onto since there is a longest word in the set of words in any dictionary.
¨ This function illustrates the fact that a function can have one kind of input and another kind of output.
¨ There is a method of computation for this function (count the number of letters) but most people would not call it a formula.
A function can have one kind of input and another kind of output.
Let F be defined on the natural numbers by requiring that is the nth prime in order. Thus and .
There is a procedure for calculating . For example to calculate F(
The definition of a function must tell you
what the value is at every element of the domain,
but it doesn’t have to tell you how to calculate that value.
For example, is the prime in order, but there is no way in the world you will ever find out the decimal representation of that prime. There are faster methods for calculating F(n), in particular the sieve method. but the number is so humongous that no method could calculate in anyone’s lifetime. See Conceptual and Computational.
Note that we know F is injective even though we can’t calculate its value for large n.
Let
for real numbers . Its graph is shown to the right. It has asymptotes (shown in green) at .
Now let
Since E(x) is a continuous
function on the interval, this integral exists for every t. So G(t) is a properly
defined function of the real variable t.
Notes
¨ G is a function of t, not of x. The variable x is a bound variable (dummy variable) used in the integral. The definition of G(t) therefore depends on the value of E(x) for every value of x from 0 to t (or from t to 0). After all, the integral is the area under the curve between those values of x, so every little twist in the curve matters.
¨ If you try to use methods you learned in Calc 1 to find the indefinite integral of
with respect to x, you will fail. It’s known that this integral cannot be expressed in terms of familiar functions (polynomials, rational functions, log, exp, trig functions.) Nevertheless, for all real t with , the integral
exists and and has a specific value.
¨ The definition of G(t) makes it very easy to find the derivative (!): .
¨ This function is an example of an elliptic integral. Elliptic integrals have a long (190 years) and rich history, and are best studied as functions of complex variables.
A definition integral may still be meaningful
even if you don’t know a “formula” for the antiderivative
Let for all real x.
¨ (F(1/3)=1, F(42) = 1, but because is not rational.
¨ If all you know about x is that it is 3.14159 correct to five decimal places, then you don’t know what F(x) is. No matter how many decimal places you are given for x, you cannot tell what F(x) is. You need to have other information about x (whether it is rational or irrational) to determine its value.
¨ There is no way to draw the graph of this function since both the rationals and the irrationals are dense in the set of real numbers.
¨ This function is
not continuous, and therefore
does not have a derivative.
¨ This function is not injective.
¨ You can read more about this
function here.
A function need not have a drawable graph.
Let .
The frequency goes up rapidly as you get close to the yaxis from the left, since grows very rapidly as x moves toward 0. Drawing
the graph near the yaxis is impractical
because the curve
between x = 0 and x = any bigger number is infinitely long even though it
occurs in a finite interval.
The graph of a real valued function on a finite interval can
be an infinitely long curve.
Let f be a
function that has a derivative, and let D(f) be its derivative. Then D is a function from a set of functions
to a set of functions.
¨ If then , or, using barred arrow notation, .
¨ If then , or .
These are pictured below.
D takes a function
as input and outputs
another function, namely the derivative of the first one. The whole function is the input, not some value of the function, not the rule that
defines the function, not the graph. You
have to think of the function as a thing, in other words as a math object.
¨ Functions whose inputs are
complicated structures such as functions may be called operators . (Usage varies in different specialties.) This function D is the differentiation operator.
¨ The differentiation operator
is not injective.
For example, and have the same derivative, namely 2x.
¨ The domain of D must include only
differentiable function (duh).
A function can
have a set of functions as its domain or codomain.

In each picture, the differentiation operator takes the blue function
thought of as a single math object to the red one.
More pictures here like those above
¨ The functions
denoted (a, b).