Skip to the Main Content

Note:These pages make extensive use of the latest XHTML and CSS Standards. They ought to look great in any standards-compliant modern browser. Unfortunately, they will probably look horrible in older browsers, like Netscape 4.x and IE 4.x. Moreover, many posts use MathML, which is, currently only supported in Mozilla. My best suggestion (and you will thank me when surfing an ever-increasing number of sites on the web which have been crafted to use the new standards) is to upgrade to the latest version of your browser. If that's not possible, consider moving to the Standards-compliant and open-source Mozilla browser.

January 15, 2025

The Dual Concept of Injection

Posted by Tom Leinster

We’re brought up to say that the dual concept of injection is surjection, and of course there’s a perfectly good reason for this. The monics in the category of sets are the injections, the epics are the surjections, and monics and epics are dual concepts in the usual categorical sense.

But there’s another way of looking at things, which gives a different answer to the question “what is the dual concept of injection?”

This different viewpoint comes from the observation that in the category of sets, the injections are precisely the coproduct inclusions (coprojections)

AA+B. A \to A + B.

Certainly every coproduct inclusion in the category of sets is injective. And conversely, any injection is a coproduct inclusion, because every subset of a set has a complement.

So, the injections between sets are the specialization to Set\mathbf{Set} of the general categorical concept of coproduct coprojection. The dual of that general categorical concept is product projection. Hence one can reasonably say that the dual concept of injection is that of product projection

A×BA, A \times B \to A,

where AA and BB are sets.

Which maps of sets are product projections? It’s not hard to show that they’re exactly the functions f:XYf: X \to Y whose fibres are all isomorphic:

f 1(y)f 1(y) f^{-1}(y) \cong f^{-1}(y')

for all y,yYy, y' \in Y. You could reasonably call these “uniform” maps, or “even coverings”, or maybe there’s some other good name, but in this post I’ll just call them projections (with the slightly guilty feeling that this is already an overworked term).

Projections are always surjections, except in the trivial case where the fibres are all empty, which means that our map is of the form Y\varnothing \to Y. On the other hand, most surjections aren’t projections. A surjection is a function whose fibres are nonempty, but there’s no guarantee that all the fibres will be isomorphic, and usually they’re not.

A projection appears in a little puzzle I heard somewhere. Suppose someone hands you a tangle of string, a great knotted mass with who knows how many bits of string all jumbled together. How do you count the number of pieces of string?

The slow way is to untangle everything, separate the strands, then count them. But the fast way is to simply count the ends of the pieces of string, then divide by two. The point is that there’s a projection — specifically, a two-to-one map — from the set of ends to the set of pieces of string.

String theory aside, does this alternative viewpoint on the dual concept of injection have any importance? I think it does, at least a little. Let me give two illustrations.

Factorization, graphs and cographs

It’s a standard fact that any function between sets can be factorized as a surjection followed by an injection, and the same is true in many other familiar categories. But here are two other methods of factorization, dual to one another, that also work in many familiar categories. One involves injections, and the other projections.

  • In any category with finite coproducts, any map f:XYf: X \to Y factors as

    XX+Y(f1)Y, X \to X + Y \stackrel{\binom{f}{1}}{\to} Y,

    where the first map is the coproduct coprojection. This is a canonical factorization of ff as a coproduct coprojection followed by a (canonically) split epic. In Set\mathbf{Set}, it’s a canonical factorization of a function ff as an injection followed by a surjection (or “split surjection”, if you don’t want to assume the axiom of choice).

    Unlike the usual factorization involving a surjection followed by an injection, this one isn’t unique: there are many ways to factor ff as an injection followed a surjection. But it is canonical.

  • In any category with finite products, any map f:XYf: X \to Y factors as

    X(1,f)X×YY, X \stackrel{(1, f)}{\to} X \times Y \to Y,

    where the second map is the product projection. This is a canonical factorization of ff as a split monic followed by a projection. In Set\mathbf{Set}, “split monic” just means a function with a retraction, or concretely, an injection with the property that if the domain is empty then so is the codomain.

    (I understand that in some circles, this or a similar statement is called the “fundamental theorem of reversible computing”. This seems like quite a grand name, but I don’t know the context.)

    Again, even in Set\mathbf{Set}, this factorization is not unique: most functions can be factored as a split monic followed by a projection in multiple ways. But again, it is canonical.

These factorizations have a role in basic set theory. Let’s consider the second one first.

Take a function f:XYf: X \to Y. The resulting function

(1,f):XX×Y (1, f): X \to X \times Y

is injective, which means it represents a subset of X×YX \times Y, called the graph of ff. A subset of X×YX \times Y is also called a relation between XX and YY; so the graph of ff is a relation between XX and YY.

The second factorization shows that ff can be recovered from its graph, by composing with the projection X×YYX \times Y \to Y. Thus, the set of functions from XX to YY embeds into the set of relations between XX and YY. Which relations between XX and YY correspond to functions? The answer is well-known: it’s the set of relations that are “functional”, meaning that each element of XX is related to exactly one element of YY.

This correspondence between functions and their graphs is very important for many reasons, which I won’t go into here. But it has a much less well known dual, which involves the first factorization.

Here I have to take a bit of a run-up. The injections into a set SS, taken up to isomorphism over SS, correspond to the subsets of SS. Dually, the surjections out of SS, taken up to isomorphism under SS, correspond to the equivalence relations on SS. (This is more or less the first isomorphism theorem for sets.) And just as we define a relation between sets XX and YY to be a subset of X×YX \times Y, it’s good to define a corelation between XX and YY to be an equivalence relation on X+YX + Y.

Now, given a function XYX \to Y, the resulting function

(f1):X+YY \binom{f}{1}: X + Y \to Y

is surjective, and so represents an equivalence relation on X+YX + Y. This equivalence relation on X+YX + Y is called the cograph of ff, and is a corelation between XX and YY.

The first of the two factorizations above shows that ff can be recovered from its cograph, by composing with the injection XX+YX \to X + Y. Thus, the set of functions from XX to YY embeds into the set of corelations between XX and YY. Which corelations between XX and YY correspond to functions? This isn’t so well known, but — recalling that a corelation between XX and YY is an equivalence relation on X+YX + Y — you can show that it’s the corelations with the property that every equivalence class contains exactly one element of YY.

I’ve digressed enough already, but I can’t resist adding that the dual graph/cograph approaches correspond to the two standard types of picture that we draw when talking about functions: graphs on the left, and cographs on the right.

        

For example, cographs are discussed in Lawvere and Rosebrugh’s book Sets for Mathematics.

Back to the injection-projection duality! I said I’d give two illustrations of the role it plays. That was the first one: the canonical factorization of a map as an injection followed by a split epic or a split monic followed by a projection. Here’s the second.

Free and cofree presheaves

Let AA be a small category. If you’re given a set P(a)P(a) for each object aa of AA then this does not, by itself, constitute a functor ASetA \to \mathbf{Set}. A functor has to be defined on maps too. But PP does generate a functor ASetA \to \mathbf{Set}. In fact, it generates two of them, in two dual universal ways.

More exactly, we’re starting with a family (P(a)) aA(P(a))_{a \in A} of sets, which is in object of the category Set obA\mathbf{Set}^{ob\ A}. There’s a forgetful functor

Set ASet obA, \mathbf{Set}^A \to \mathbf{Set}^{ob\ A},

and the general lore of Kan extensions tells us that it has both a left adjoint LL and a right adjoint RR. Better still, it provides explicit formulas: the functors L(P),R(P):ASetL(P), R(P): A \to \mathbf{Set} are given by

(L(P))(a)= bA(b,a)×P(b) (L(P))(a) = \sum_b A(b, a) \times P(b)

(where \sum means coproduct or disjoint union), and

(R(P))(a)= bP(b) A(a,b). (R(P))(a) = \prod_b P(b)^{A(a, b)}.

I’ll call L(P)L(P) the free functor on PP, and R(P)R(P) the cofree functor on PP.

Example   Let GG be a group, seen as a one-object category. Then we’re looking at the forgetful functor Set GSet\mathbf{Set}^G \to \mathbf{Set} from GG-sets to sets, which has both adjoints.

The left adjoint LL sends a set PP to G×PG \times P with the obvious GG-action, which is indeed usually called the free GG-set on PP.

The right adjoint RR sends a set PP to the set P GP^G with its canonical action: acting on a family (p g) gGP G(p_g)_{g \in G} \in P^G by an element uGu \in G produces the family (p gu) gG(p_{g u})_{g \in G}. This is a cofree GG-set.

Cofree group actions are important in some parts of the theory of dynamical systems, where GG is often the additive group \mathbb{Z}. A \mathbb{Z}-set is a set equipped with an automorphism. The cofree \mathbb{Z}-set on a set PP is the set R(P)=P R(P) = P^{\mathbb{Z}} of double sequences of elements of the “alphabet” PP, where the automorphism shifts a sequence along by one. This is called the full shift on PP, and it’s a fundamental object in symbolic dynamics.

What’s this got to do with the injection-projection duality? The next example gives a strong clue.

Example   Let AA be the category (01)(0 \to 1) consisting of a single nontrivial map. Then an object of Set obA\mathbf{Set}^{ob\ A} is a pair (P 0,P 1)(P_0, P_1) of sets, and an object of Set A\mathbf{Set}^A is a function X 0fX 1X_0 \stackrel{f}{\to} X_1 between a pair of sets.

The free functor ASetA \to \mathbf{Set} on PP is the injection

AA+B. A \to A + B.

The cofree functor ASetA \to \mathbf{Set} on PP is the projection

A×BB. A \times B \to B.

More generally, it’s a pleasant exercise to prove:

  • Any free functor X:ASetX: A \to \mathbf{Set} preserves monics. In other words, if uu is a monic in AA then X(u)X(u) is an injection.

  • Any cofree functor X:ASetX: A \to \mathbf{Set} sends epics to projections. In other words, if uu is an epic in AA then X(u)X(u) is a projection.

These necessary conditions for being a free or cofree functor aren’t sufficient. (If you want a counterexample, think about group actions.) But they give you some feel for what free and cofree functors are like.

For instance, if AA is the free category on a directed graph, then every map in AA is both monic and epic. So when X:ASetX: A \to \mathbf{Set} is free, the functions X(u)X(u) are all injections, for every map uu in AA. When XX is cofree, they’re all projections. This imposes a severe restriction on which functors can be free or cofree.

(Question: do quiver representation people ever look at cofree representations? Here we’d replace Set\mathbf{Set} by Vect\mathbf{Vect}.)

In another post, I’ll explain why I’ve been thinking about this.

Posted at January 15, 2025 5:43 PM UTC

TrackBack URL for this Entry:   https://golem.ph.utexas.edu/cgi-bin/MT-3.0/dxy-tb.fcgi/3584

2 Comments & 0 Trackbacks

Re: The Dual Concept of Injection

Of course, a constructive mathematician might dispute your claim that every injection of sets is a coproduct inclusion. (-:

However, complemented injections (= coproduct inclusions) do still play an important role in constructive mathematics. One reason for that is your first factorization: they form a weak factorization system with the split surjections. For instance, this is relevant for the constructive model structure on simplicial sets.

Another possible name for product projections is “trivial bundles”.

Posted by: Mike Shulman on January 15, 2025 6:10 PM | Permalink | Reply to this

Re: The Dual Concept of Injection

Beyond the world of sets, I guess I could have emphasized that in most familiar categories where the concept of injectivity has an obvious interpretation, injections are not usually coproduct coprojections. That is, most subobjects don’t have complements.

For topological spaces, this amounts to the statement that most subspaces aren’t clopen. For modules, it’s the fact that most submodules aren’t direct summand.

Conversely, there are familiar categories where coproduct coprojections aren’t always injective (again, when “injective” has a clear interpretation). This happens a bit less often, but it’s not in any way an obscure phenomenon. For example, in the category of commutative rings, coproduct is tensor product and

/2/3=0, \mathbb{Z}/2 \otimes \mathbb{Z}/3 = 0,

so neither coprojection is injective.

Posted by: Tom Leinster on January 15, 2025 7:08 PM | Permalink | Reply to this

Post a New Comment