Lecture 4: more on functions


A function \(f : A → B\) is

If \(f : A → B\) and \(g : B → C\) then the composition of \(g\) and \(f\) (written \(g \circ f\)) is the function \(g \circ f : A → B\) given by \((g \circ f)(a) := g(f(a))\).

The image of \(f : A → B\) is the set of elements of \(b\) that are "hit" by \(f\), i.e. \(\{b \in B \mid ∃a ∈ A. f(a) = b\}\).

Some sources use "range" to refer to the image, while others use range to refer to the codomain. For this reason, I avoid the term range.

Cardinality definitions

If \(A\) and \(B\) are sets, then

Note: these are definitions; however they are motivated by the intuition from finite sets.

Note: as always, the quantifiers are important. Students sometimes write \(|A| ≤ |B|\) if \(A\) and \(B\) is injective, or something similar. This doesn't make sense; injectivity is a property of functions. There may be many functions between \(A\) and \(B\), some of which are injections, and some of which are not.

These definitions are dangerous, in the sense that we have a lot of intuition about how \(≤\) and \(≥\) behave, and it is not clear a priori that these definitions match our intuition. Whenever giving new definitions for preexisting symbols, it is good to enumerate your intuitions and check that they still hold, so that you don't accidentally use false things in proofs. For example, the following are all true but not obvious:

We will prove them in coming lectures/homeworks