Functions
This chapter covers notes on functions.
In these materials, functions are a particular type of map. A function is a relation from to where every element of is paired with exactly one element of We say that is the domain of and is the range of Here's the working definition we'll use:
function. Let and be sets, and a relation. We call a function if, and only if, for each there is one element with We call the domain of denoted We call the range of denoted
A few more bits of terminology: We can expression a function in general with the expression which we read as " is a function from to " Given the element is called the result of at the argument Given an argument we say that sends or maps or transforms onto Specifically for binary functions, given we call the abscissa of the tuple and the ordinate of
It's important to remember that all functions are relations. However, the converse — all relations are functions — is false. This means that, given a function with and all these expressions mean the same thing:
Clearly, some notations are superior to others in terms of readability. Option (3) is clearly needlessly unclear, and options (4) and (5) are just short of being too long. We also see that In fact, is quite removed from — it's the ordinate of a tuple in the relation
A bit more terminology: Functions can be classified according to relations between their domain and range. Note that the definition below does not establish that is a function from to — it's just some function.
classification of functions. Let and be sets, and some function.
- If then is a function on
- If then is a function into
- If then is a function onto
Images
While some authors treat image and range synonymously, we distinguish the two terms. From the definition of a function, it's clear that we can have function where In this case, we say that maps onto and we call the domain and the range, using the usual syntax:
If, however, it turns out that we say that is the image of and use the following syntax:
We use this different notation and wording to make it clear that the codomain is a subset of the domain (in later sections, we'll see that for some situations, a function's range is often more important than the function itself). If it turns out that we say that is an embedding of into For this case, we simply use the notation and
Preimage
Let's suppose we're playing some game consisting of two sets, and The set consists of a variety of buttons, and the set consists of various checks — a check for ten, a check for a hundred, a checking for a thousand ... incrementing by powers of ten all the way up to a billion. Now suppose that every button in if pushed, returns some check in
Anyone playing this game is likely interested in the set of buttons where each button returns a check of a particular subset of — perhaps the subset of checks such that is at least a million. In this case, we're only interested in a function such that is at least a million. But, even more importantly, we're interested in the set We call a preimage of
preimage. Let be a function from to Then the preimage of a set under is defined as:
Restrictions and Extensions
In the case where we call the identity map. The identity map introduces us to a special kind of relation called the restriction.
restriction. Let be a function from to and the set be a subset of (i.e., ). Where and the function:
is called the restriction of to . We may denote such a function with:
Informally, restrictions are simply a more convenient way of defining functions for a common scenario. Suppose we have the function:
We want to define a function but That is, we want to communicat that there's a relationship between the members of and the members of that doesn't include the members of The identity map allows us to say that:
where The function is called the restriction of to and the function is called the extension of to
Compositions
Suppose we had a function and a funtion In many applications, we want to have some function that takes the result in as the argument in That is, a function whose result is some value:
We call the function the composition of with and the result a composite of with Simply a put, a composition is a function whose domain consists of the results of another function.
composition. Let and be sets with and Then the composition of with denoted is defined as a function from where
for all
Compositions are relations that appear in everyday life. For example, a recipe is a composition. Each step in a recipe is a function. E.g., cracking an egg takes an argument — an egg — accompanied with a result — an albumen (egg white) usually encasing a vitellus (yolk). Using the result of the previous step to perform another a step is a composition. E.g., whisking the cracked eggs (the result of the previous step) to produce a mixture.
Partial Orders of Functions
Now that we've defined the concepts of restriction and extension, one interesting consequence is examining them as they relate to partial orders. Suppose and are sets, where is the set of all functions whose domain is included in and whose range is included in Now suppose we have the relation:
That is, is a restriction of (or, equivalently, is an extension of ). Given that all the functions in are just subsets of the Cartesian product it follows that the relation:
Surjections
A function is called surjective if every element of is mapped to at least once.
surjection. Let be a map from the set to the set If, for each in there exists an such that:
then is a surjection, and we write:
In other words, every element of gets at least one of They can get many of but they must at least have one. For example, this the functions below are surjective functions.
But the functions below are not.
If are sets, and is a surjective function mapping elements from to then:
It follows that either
- has more members than or
- and have the same number of members.
Injections
A function is called injective if every element of is mapped to at most once.
injection. Let be a map from the set to the set and If, for each
then is an injection, and we write:
That is, every element of gets at most one of They can get none of but if they do get something from they can only get one. For example, these are injective functions:
But these are not:
Another way of thinking about injections: They're functions that map distinct elements of the domain to distinct elements of the codomain.
If and are sets, and is an injective function mapping elements from to then:
Thus, it follows that:
- has less members than or
- and have the same number of members.
Bijections
A function is called bijective iff it is both surjective and injective.
bijection. Let be a map from the set to the set If, for each there exists a unique such that:
then is an bijection, and we write:
For example, these functions only take one appearance:
That is, every element of maps to one, and only one, element of and every element of is mapped to once, and only once. None of these functions are bijective:
From top-left to bottom-right: The first is surjective but not injective, the second is injective but not surjective, and the last two are not functions.
If and are sets and is a bijective function mapping elements from to then:
That is, and have the same number of members.
Valued Functions
A function whose codomain is some number set is called a valued function. Such functions are of particular interest in many other areas of mathematics. For example, a function whose codomain is is called a real-valued function, a functions whose codomain is is called an integer-valued function, and so on. Both real-valued functions and integer-valued functions have some special properties. In the examples that follow, let's suppose the domain and codomain is
Addition of Valued Functions
Say we had the functions and We can add these two functions:
Here is a more explicit definition:
addition of functions. Let and with Then is defined for all where
Note that we use the notation to denote that is a member of the function We do so to emphasize the fact that is a set, and is an element of the set. Some authors write but this isn't quite correct. Nevertheless, no one ever really writes the notation above. We use it here to make the underlying ideas clearer.
Families
Now that we've seen functions, we introduce another special relation called the family.
family. Let and be sets, and a function defined as follows:
- Where and
We call the index set, an index, the indexed set, a term, and the function a family.
A particularly special type of family is the sequence. But before we examine sequences, we need a special set called the natural numbers.