# Algebras of filter-related monads: I. Ultrafilters and Manes’ theorem

In 1969, Ernest Manes proved the following remarkable result: the algebras of the ultrafilter monad on Set are exactly the compact Hausdorff spaces . This is remarkable, because it gives a purely algebraic/category-theoretic of the otherwise purely topological notion of compact Hausdorff spaces. I will explain how this is proved, and I will give a few pointers to some extension results of the same kind.

I have talked about monads a long time ago, and about algebras of monads at about the same time, namely, in 2015. I have come back to the subject much more recently, in a 2022 post where I explained Andrea Schalk’s result that the algebras of the Qfin monad on the category of T0 topological spaces are exactly the T0 deflationary topological semilattices with small semilattices.

## Monads, and their algebras

Let me give back the necessary definitions. A monad on a category C is a triple (T, η, †) consisting of the following data:

• for each object X of C, an object TX in C
• for each object X of C, a morphism ηXX → TX called the unit of the monad
• an extension operation †, transforming every morphism fX → TY into a morphism fTX → TY, so that the following equations are satisfied:
1. ηX = idTX
2. for every morphism fX → TYf o ηX = f
3. for all morphisms fX → TY and gY → TZ, (g o f) = g o f.

We then say that (T, η, †) is a monad, or, by abuse of language, that T itself is a monad. For example, there is a powerset monad P on Set, where PX is the set of all subsets of X, ηX(x)={x}, and f(A)=∪{f(x) | xA}.

I will be more interested in the filter monad F and its variants on Set. A filter F on a set X is a non-empty, upwards-closed collection of subsets of X that is closed under binary intersections. (There are some variants in that definition. For example, it is sometimes allowed to include the empty set as a member of F; we don’t. Also, what we call a filter on X here is really the special case of a filter of subsets of X, and more general notions of filters of elements of arbitrary lattices are possible.) The filter monad is defined as follows:

• FX is the set of all filters on X;
• ηX(x) is the principal ultrafilter at x, namely the collection of all subsets A of X that contain x;
• for every function fX → FYf(F) is the filter consisting of all the subsets B of Y such that f–1(B#) ∈ F. I use the notation B# to denote the collection of filters G on Y such that BG. Its inverse image f–1(B#) by f is then a subset of X, so f–1(B#) ∈ F makes sense.

Similarly, we have the ultrafilter monad U on Set: simply replace “filter” by “ultrafilter” throughout in the previous definition (and be careful to redefine B# as the the collection of ultrafilters that contain B—I will use that notation over and over with that meaning). An ultrafilter is a maximal filter (with respect to inclusion), or equivalently a filter F on X such that every subset A of X is in F or has its complement in F.

Given any monad (T, η, †) on C, T extends to a functor from C to C. Its action on morphisms fX → Y is given by Tf ≝ (ηY o f)†. For example, Pf is direct image: Pf(A) = {f(x) | xA}. The case of the filter monad F defines Ff(F) as what I have already called the direct image (as well) f[F] of the filter F by the function f, namely f[F] ≝ {BY | f–1(B) ∈ F}. The action of the ultrafilter monad is the same: for every ultrafilter F on X, Uf(F) = f[F], and that happens to be an ultrafilter.

Every monad also has a multiplication μX : TTXTX, which is simply idX†. For the powerset monad P, multiplication PPXPX is a form of flattening, and maps a set A of subsets of X to its union ∪A (namely, ∪{A | AA}). For the filter and ultrafilter monads, multiplication is the so-called Kowalsky sum operation, which maps every (ultra)filter F of (ultra)filters on X to the (ultra)filter of subsets A of X such that A#F.

An algebra of a monad (T, η, †) is an object X together with a morphism α : TXX (the structure map of the algebra) such that:

• α o ηX = idX
• α o μX = α o Tα.

I will simply say that α : TXX itself is an algebra of the monad T, or a T-algebra.

This is a fundamental construction. Let me simply say that algebras of monads on Set generalize the notion of varieties of algebras defined by operators and equations; and that the algebras of a monad T on a category C form a category CT (the Eilenberg-Moore category of T), such that the forgetful functor from CT to C has a left adjoint, and such that the resulting adjunction has exactly T as associated monad. (A morphism from α : TXX to β : TYY in CT is a morphism f : XY in C such that f o α = β o Tf.)

It is a standard routine in mathematics to attempt and determine the algebras of various naturally occurring monads. For example, the algebras of the P monad on Set are exactly the complete (sup-)semilattices: namely, a P-algebra α : PXX equips X with an ordering ≤ (defined by xy if and only if α({x,y})=y) such that every subset A of X has a supremum (which turns out to be α(A)), and morphisms of P-algebras are those functions that preserve such suprema.

In general, it is hard to give an explicit description of T-algebras for arbitrary T (except for so-called finitary monads on Set and a few exceptional monads such as P). It is therefore pretty remarkable that the algebras of the ultrafilter monad U were completely characterized . A nice exposition of the matter is given in Marius Stekelenburg’s Bachelor thesis , and I will shamelessly borrow a lot from it.

## The algebras of the ultrafilter monad on Set

Given an algebra α : UXX of the ultrafilter monad U, one may rightly guess that α will map every ultrafilter on X to its limit. For that, every ultrafilter needs to have a limit, and that forces X to be compact. It is at least believable that α will pick the unique limit of the ultrafilter given as its argument, forcing X to be Hausdorff. The deep part of the theorem is that the equations defining the algebra will force X to be a topological convergence space, that is, one whose convergence is entirely determined by a topology, in the sense that an ultrafilter converges to a point if and only if every open neighborhood of that point is in the ultrafilter.

All right. Before we start dealing with that argument, let us check that a compact Hausdorff topological space X gives rise to a U-algebra. In other words, let us check the easy part first.

### All compact T2 spaces are algebras of the ultrafilter monad on Set

So let us assume that X is a compact Hausdorff topological space.

• Every ultrafilter F has at least one limit. This is a well-known characterization of compactness, but let me spell that out.
A limit of a filter F is a point x such that every open neighborhood U of x is in F.
In general, we show that, on a compact space, every filter has at least one cluster point, namely a point x such that every open neighborhood U of x intersects every set A in F. This is easy: consider the family F’ of all closed sets that lie in F. F’ is a filtered family of non-empty closed subsets of X. Since X is compact, F’ has a non-empty intersection (see Proposition 4.4.9 in the book, for example). Let x be a point in that intersection. For every AF, the closure cl(A) is also in F, hence contains x; then every open neighborhood U of x intersects cl(A) (at x), hence also intersects A.
If F is not just a filter, but an ultrafilter, any cluster point x of F must actually be a limit of F: for every open neighborhood U of x, either U is in F, and we are done, or its complement XU is; but in that case U must intersect XU by definition of x as a cluster point, and that is plainly impossible.
• Every ultrafilter has at most one limit; in fact every filter has at most one limit. Now that is a characterization of Hausdorffness. Let us assume that a filter F has two limits x and y. If X is Hausdorff (a.k.a. T2), then x has an open neighborhood U, and y has a disjoint open neighborhood V. Since x is a limit of F, U is in F. Similarly, V is in F. This forces UV to be in F. But UV is empty, and the empty set belongs to no filter.
• We can therefore define a map α : UXX that sends every ultrafilter to its unique limit. Let us check the algebra equations:
• α o ηX = idX means that for every xX, the limit of the principal filter at x is x. That is straightforward.
• α o μX = α o Uα: this one is more intimidating. We consider any ultrafilter of ultrafilters FUUX, and we must show that the unique limit of the Kowalsky sum μX(F) of F is equal to the unique limit of Uα(F).
A point x is the limit of μX(F) if and only if:
— every open neighborhood U of x is in μX(F),
— namely if and only if every open neighborhood U of x is such that U#F.
A point x is the limit of Uα(F) if and only if:
— every open neighborhood U of x is in Uα(F),
— i.e., every open neighborhood U of x is such that α–1(U) ∈ F.
Now we recall that U# is the collection of ultrafilters G on X such that UG, while α–1(U) is the collection of ultrafilters G on X whose limit α(G) is in U. For any open subset U, if the limit α(G) of G is in U then U is in G. Therefore α–1(U) ⊆ U#.
This immediately implies that every limit of Uα(F) is a limit of μX(F). But limits exist and are unique, so the unique limit α(Uα(F)) of the former is equal to the unique limit α(μX(F)) of the latter.

### Building a compact Hausdorff space from a U-algebra

In the converse direction, we start from a U-algebra α : UXX, and we need to show several things: that X can be given a topology that is compact and Hausdorff, and such that α maps every ultrafilter F to its unique limit.

If we can nurture any hope of achieving such a result, then for every open subset U of X (in the topology that is yet to be defined), we must have that for every ultrafilter F on X, α(F) ∈ U implies UF. Let us simply take that as a definition:

A subset U of X is called open (relatively to α)
if and only if for every ultrafilter F on X such that α(F) ∈ U, U is in F.

That is not an arbitrary choice: a topology is uniquely determined by its notion of convergence. Hence, if X can be equipped with a topology such that α characterizes its notion of convergence, the above choice is the unique possible choice.

We claim that this is a topology:

• Let (Ui)iI be any family of open subsets of X (under that definition), and U be their union. For every ultrafilter F on X such that α(F) ∈ U, α(F) is in some Ui, so Ui is in F, using the fact that Ui is open. Since F is upwards-closed, U is also in F. This shows that U is open as per our definition.
• Let (Ui)iI be any finite family of open subsets of X, and U be their intersection. For every ultrafilter F on X such that α(F) ∈ U, α(F) is in every Ui, so Ui is in F, for every i in I. Since F is closed under finite intersections, U is also in F. Therefore U is open.

For further reference, let us call this the α-topology. Its open subsets the α-open subsets of X, its closed subsets are the α-closed subsets of X, and so on.

Let us practice a bit and express some related notions.

A subset C of X is α-closed if and only if it is the complement of an α-open subset, namely if and only if for every ultrafilter F on X such that α(F) ∉ C, the complement of C is in F. The complement of C is in F if and only if C is not in F, since F is an ultrafilter. By contraposition, C is α-closed if and only if for every ultrafilter F on X that contains C, α(F) is in C. We recognize the familiar idea that a set C is closed if and only if it contains every limit of every ultrafilter containing C, with α used instead of forming limits.

We remember that C# is exactly the collection of ultrafilters F that contain F. Therefore C is α-closed if and only if:

• α sends every F in C# to an element of C,
• or equivalently if C# ⊆ α–1(C),
• or equivalently α(C#) ⊆ C, where α(C#) is the (direct) image of C# by α, namely {α(G) | GC#}.

Lemma A. The closure of any subset A of X in the α-topology is exactly the direct image α(A#) of A# by α.

Proof. Let C be that image. We first observe that AC. In order to show this, we pick any point x in A, and we wish to show that x is in C, namely that there is an ultrafilter G in A# such that α(G)=x. We define G as ηX(x). We verify that G is in A#, namely that A is in G, since that is equivalent to x being in A. And α(G)=α(ηX(x))=x, by the first algebra law α o ηX = idX.

We claim that C is α-closed. This is a lot harder! We must show that for every FC#, α(F) is in C. Henceforth, let us fix FC#. Showing that namely that α(F) is in C means finding an ultrafilter GA# such that α(F)=α(G). One might think of simply defining G as F, as then α(F)=α(G) would be obvious; but there is no reason why F would be in A#. Instead, we will build a well-designed element F of UUX, and apply the two sides of the second algebra law α o μX = α o Uα to it.

• We start by defining E ≝ {A#} ∪ {α–1(B) | BF}; this is a family of sets of ultrafilters on X, namely a subset of PUX. We will show that E is included in some ultrafilter FUUX. In order to this, it suffices to verify that it has the finite intersection property, namely that any finite intersection of elements of E is non-empty: then the family ↑E of all subsets of PUX that contain some element of E will be a filter; by Zorn’s Lemma, that filter will be included in a maximal filter, which will be the desired ultrafilter F.
• E consists of sets of two kinds: the set A#, and the sets of the form α–1(B), BF. In order to check the finite intersection property for E, we first observe that any finite intersection of sets of the second kind, namely any intersection of α–1(B1), …, α–1(Bn) where B1, …, BnF, is equal to α–1(B1 ∩ … ∩ Bn), and that B1 ∩ … ∩ Bn is in F, since F is a filter. In other words, any finite intersection of sets of the second kind is a set of the second kind.
Hence, in order to show that every finite intersection of elements of E is non-empty, it suffices to show that the unique set of the first kind, A#, intersects every set of the second kind, namely every set α–1(B), for any BF.
Let therefore B be any element of F. We must find an ultrafilter G in A# such that α(G) is in B. Since FC#, C is in F, so BC is also in F. Since F does not contain the empty set, BC is non-empty, and we can therefore pick a point x in BC. Since x is in C, by definition of C, we can write x as α(G) for some G in A#. This is the desired ultrafilter G: G is in A#, and α(G)=x is in BC, hence in B.
• Now that we have shown that E has the finite intersection property, we obtain an ultrafilter FUUX that contains E by Zorn’s Lemma, as previously stated. We now use the second algebra law α o μX = α o Uα as follows.
• μX(F) is the collection of sets B such that B# is in F, by definition. In particular, it contains the collection of sets B such that B# is in E. One such set B is A. (Remember that A# is the set of the first kind in E.) Therefore A is in μX(F), meaning that G ≝ μX(F) is in A#.
• Uα(F) is the collection of sets B such that α–1(B) is in F, by definition. In particular, it contains the collection of sets B such that α–1(B) is in E. Remember the shape of the sets of the second kind in E: exactly the sets α–1(B) with B in F. Therefore Uα(F) contains every element B of F. This means that FUα(F).
Since ultrafilters are maximal filters, any two ultrafilters such that one is included in the other one must be equal. Hence F = Uα(F).
It follows that α(Uα(F)) = α(F).
• The second algebra law says that α(μX(F))=α(Uα(F)). Hence α(G)=α(F). We recall that G is in A#. This completes our task of finding an ultrafilter GA# such that α(F) is equal to α(G); hence, as promised, we have shown that α(F) is in C. This holds for every FC#, so C is α-closed.

Let us summarize: C is an α-closed set containing A. It remains to show that every α-closed set C’ containing A must contain C. For any such α-closed set C’ (containing A), C’# contains A#: every ultrafilter G that contains A must contain its superset C’. Hence the image of C’# by α contains the image of A# by α. The former is included in C’ since C’ is α-closed, and the latter is C, by definition. ☐

The non-trivial technique used in the proof of Lemma A proceeds as follows: we build a family E as the union of two kinds of sets E1 and E2, we verify that E has the finite intersection property, so that E is included in some ultrafilter FUUX; we use the second algebra law in the form of the equality α(μX(F))=α(Uα(F)); we use the fact that F contains E1 to deduce something about α(μX(F)), and we use the fact that F contains E2 to deduce something about α(Uα(F)), and then we compare what we have gotten in the two cases. We will use that technique once more below (in Lemma C).

Lemma B. In any topological space, the limits of an ultrafilter F are exactly the points that lie in the closure of every element A of F.

Proof. That one is much easier (whew!); and I have already spelled out part of the argument earlier in this post. Let x be any limit of F, and let AF. If x is not in the closure of A, then it lies in its complement U, which is open. Since x is a limit of F, U must be in F, and since F is a filter, UA must be in F, too. This is impossible, since UA is empty.

Conversely, let x be a point that lies in the closure of every AF. For every open neighborhood U of x, U intersects the closure of A (at x), hence it also intersects A. This implies that the collection G of subsets B of X that contain UA for some AF is a filter. Trivially, F is included in G. Since F is an ultrafilter, hence a maximal filter, we must therefore have G=F. In particular, U, which is trivially in G, must be in F. This shows that x is a limit of F. ☐

We can now prove the following important result.

Lemma C. Let α : UXX be a U-algebra. For every ultrafilter F on X, a point x is a limit of F in the α-topology if and only if α(F)=x. In particular, every ultrafilter has exactly one limit.

Proof. In one direction, we claim that α(F) is a limit of F: we take any open neighborhood U of α(F); by our definition of the α-topology, since α(F) ∈ U, we obtain that U is in F.

In the other direction, we consider any limit x of F, and we claim that α(F)=x. This is the harder part. By Lemma B, x is in the closure of every AF. By Lemma A, that closure is just the direct image α(A#). Hence x is in α(A#) for every AF.

• We consider the family E ≝ {A# | AF} ∪ {α–1({x})}; this is a family of sets of ultrafilters on X, namely a subset of PUX. We will show that E is included in some ultrafilter FUUX. In order to this, it suffices to verify that E has the finite intersection property, as before: then the family ↑E of all subsets of PUX that contain some element of E will be a filter; by Zorn’s Lemma, that filter will be included in a maximal filter, which will be the desired ultrafilter F.
• Given any two elements A# and B#, their intersection A#B# is the collection of ultrafilters on X that contains both A and B, equivalently AB; hence A#B# = (AB)#. In particular, if both A and B are in F, then so is AB. In general, the intersection of any finite family of elements A1#, …, An# where A1, …, An are in F is equal to (A1 ∩ … ∩ An)#, and A1 ∩ … ∩ An is in F.
Hence it remains to show that for every A in F, A# intersects α–1({x}). In other words, we must show that x is in the direct image α(A#) of A# for every AF. We have noticed that this is indeed the case, as a consequence of Lemma A and Lemma B.
• As announced, we form an ultrafilter FUUX containing E. We now use the second algebra law α o μX = α o Uα as follows.
• μX(F) is the collection of sets B such that B# is in F, by definition. In particular, it contains the collection of sets B such that B# is in E, and therefore every A in F. Therefore F is included in μX(F), and by maximality, is equal to it. It follows that α(μX(F))=α(F).
• Uα(F) is the collection of sets B such that α–1(B) is in F, by definition. In particular, it contains the collection of sets B such that α–1(B) is in E. One such set is {x}, so {x} is in the ultrafilter Uα(F). Since Uα(F) is upwards-closed, Uα(F) must contain every superset of x, so the principal ultrafilter ηX(x) is included in Uα(F). By the maximality of ultrafilters, Uα(F)=ηX(x). By the first algebra law, α(ηX(x))=x, so α(Uα(F))=x.
• From α(μX(F))=α(Uα(F)), it follows that α(F)=x. We are done! ☐

### Morphisms of U-algebras = continuous maps

Given two U-algebras α : UXX and β : UYY, a morphism f from α to β in the Eilenberg-Moore category SetU is a function f : XY such that f o α = β o Uf, namely a function such that, for every ultrafilter F on X, f applied to the α-limit of F is equal to the β-limit of f[F].

That is exactly the definition of a continuous map between convergence spaces (provided convergence spaces are defined in terms of ultrafilters). I will therefore skip the proof that such maps are exactly the continuous maps from X (with the α-topology) to Y (with the β-topology).

Let us recapitulate what we have obtained, in a formal way.

• There is a functor K that maps every U-algebra α : UXX to X, seen as a topological space, when equipped with the α-topology. Then X is compact Hausdorff, so K is a functor from the Eilenberg-Moore category SetU to CompHaus, the category of compact Hausdorff spaces and continuous maps.
• In the opposite direction, there is a functor A from CompHaus to SetU. We have already given its action on objects: every compact Hausdorff space X gives rise to a U-algebra α : UXX, where α maps every ultrafilter to its unique limit in X. On morphisms, we simply observe that every continuous map preserves limits, hence defines a morphism of U-algebras.
• The functors K and A are mutually inverse (on the nose, as category theorists say!). If we start from a compact Hausdorff space X, then KAX has the same points as X, and its topology is the unique topology that induces the same notion of convergence as X; that must be the topology of X. If we start from a U-algebra α : UXX instead, then Lemma C tells us that α must map every ultrafilter on X to its limit in the α-topology, hence that α=AK(α).

Category theorists are less interested in isomorphisms of categories (which is a rarely occurring event) than in equivalence of categories, and will therefore usually sum up all that by saying that CompHaus and SetU are equivalent categories. But they really are isomorphic categories. This is the contents of Manes’ theorem .

## Beyond Manes’ theorem

Quite some work has been done in the wake of Manes’ theorem, which after all is already 53 years old. I have already said that determining the algebras of monads is a difficult task, and we only have a sparse collection of results characterizing the algebras of various filter-related monads. For example, and unless I have overlooked something, we have no explicit description of the algebras of the filter monad on Set, or of the prime filter monad on Set. Symmetrically, we have a limited number of characterizations of notions of topological spaces (or of convergence spaces) as algebras of monads. For example, I don’t know whether there is any characterization of stably compact spaces as algebras of some monad (apart from the trivial identity monad on the category of stably compact spaces!).

Still, let me cite some results akin to Manes’ theorem in the literature.

Michael Barr showed the following variant . Instead of Set, consider the category Rel on sets are binary relations between them as morphisms. The idea is that, outside the realm of compact Hausdorff spaces, taking limits of ultrafilters no longer defines a function, but a mere binary relation between ultrafilters and points. There is still a way of defining an ultrafilter functor on Rel. This no longer defines a monad, rather a weaker form one may call an oplax monad; in it, the unit η and the multiplication are no longer natural, and rather satisfy so-called oplax naturality conditions ηY o RUR o ηX and μY o RUUR o μX (for every relation R between X and Y, and where ⊆ refers to inclusion of relations, seen as sets of pairs). Correspondingly, the right notion is not that of an algebra, but of a lax algebra, where we only require α o ηX ⊇ idX and α o μX ⊇ α o Tα. Barr then showed that the lax U-algebras on Rel are exactly the topological spaces, without any other restriction such as being compact or T2. The most readable introduction to this is probably Stekelenburg’s bachelor thesis [2, Section 4]. He also notes that the proof is essentially the same as the proof given above of Manes’ theorem, replacing functions by relations.

In another direction, Bob Flagg replaces Set by the category Poset of posets and monotone maps, and ultrafilters on X by prime filters of upwards-closed subsets of a poset X . Note that, if X has equality as ordering, then a prime filter of upwards-closed subsets of X is just a prime filter of subsets of X, namely an ultrafilter. There is a monad U’ on Poset which maps every poset to its set of prime filters of upwards-closed subsets, itself ordered by inclusion. Flagg shows that the U’-algebras are exactly the compact pospaces, and that the morphisms of U’-algebras are exactly the monotone, continuous maps between them. The proof is necessarily different from the proof I have given of Manes’ theorem, since in that proof, we have repeatedly used the fact that ultrafilters are maximal; something that does not hold for prime filters.

Since compact pospaces and stably compact spaces are essentially the same thing (see Chapter 9 in the book), one may think that the U’-algebras are the stably compact spaces. While this holds some truth at the level of objects, the difficulty lies in morphisms: that would be true if we decided that the morphisms of stably compact spaces had to be the perfect maps. It is not clear whether the category of stably compact spaces and continuous maps is equivalent to the category of algebras of any non-trivial monad.

I will conclude by mentioning a result obtained by Day  and Wyler  independently. Instead of considering the ultrafilter monad, look at the filter monad. Not on Set, though, rather on the category Top0 of T0 topological spaces. In other words, for every T0 space X, we let FX be the collection of filters of open subsets of X (instead of filters of arbitrary subsets), with the topology generated by the subsets ☐U ≝ {FFX | UF}, where U ranges over the open subsets of X. Then F defines a monad on Top0, and Day and Wyler showed that its algebras are exactly the continuous lattices, with their Scott topologies. I am tempted to explain Martín Escardó’s elegant proof of that result  in a future post, and that is the main reason why this post’s title has a “I.” in it. Escardó’s proof rests on the amazing notion of a KZ-monad, a notion, originally due to Anders Kock, and which deserves to be better known.

1. Ernest Manes. A triple theoretic construction of compact algebras. In B. Eckmann and M. Tierney, editors, Seminar on Triples and Categorical Homology Theory, volume 80 of Lecture Notes in Mathematics. Springer, 1969. Also Reprints in Theory and Applications of Categories 18 (2008), 73–94.
2. Marius Stekelenburg. Ultrafilters and topology. Bachelor project in mathematics, Leiden University, 2014.
3. Michael Barr. Relational algebras. Reports of the Midwest Category Seminar, no. 137, pages 39–55, Springer, 1970.
4. Bob Flagg. Algebraic theories of compact pospaces. Topology and its Applications 77(3), pages 277–290.
5. Alan Day. Filter monads, continuous lattices and closure systems. Canadian Journal of Mathematics, XXVII(1):50–59, 1975.
6. Oswald Wyler. Algebraic theories for continuous semilattices. Archive for Rational Mechanics and Analysis, 90(2):99–113, 1985.
7. Martín Escardó. Injective spaces via the filter monad. Topology Proceedings 22(2), 1997.

Jean Goubault-Larrecq (August 20th, 2022)