Manuscript Offprint
arXiv:2610.13201Compact Quantitative Equational Theories as Monad Restrictions
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
Proofs in quantitative algebra are, generally, infinite objects due to the presence of infinitary rules in the deductive apparatus. A quantitative equational theory is called compact if all its consequences are derivable by means of finite proofs, that is, proofs not using any instances of the infinitary rules. This definition is purely logical. In this work we give an equivalent, but categorical, characterisation based on the notion of monad restriction.
Keywords: Quantitative algebra, monads, monad restrictions, monad morphisms, compactness.
1 Introduction
Quantitative algebra, introduced in [22], is an active area of investigation (see, e.g., [8,1,2,4,5,6,7,13], [14,23,30,28,27,26,29,20,18,24,32,33,15,10,12,25]) aimed at extending the methods of universal algebra to the study of so-called quantitative algebras. In the original formulation of [22], a quantitative algebra is an algebra whose carrier is an extended metric space. More formally, it is a triple where is an extended metric space and is a -algebra, in the ordinary sense of universal algebra, for some signature of function symbols. The key novel concept is that of quantitative equation: an expression of the form indexed by a real number , whence the adjective “quantitative”, which generalises ordinary equations and makes it possible to axiomatize the interplay between the algebraic and the metric structure. The meaning of is that the distance between any interpretations of the terms and is bounded above by , i.e., .
1.1 Monads. Given a collection of quantitative equations and an extended metric space , it is possible to construct the free quantitative algebra satisfying generated by . This construction gives rise to a monad on the category of extended metric spaces and nonexpansive maps. Monads on that can be axiomatized by quantitative equations include the Kantorovich probability distribution monad [23], the Hausdorff powerset monad [23] and the Kantorovich–Hausdorff convex powerset of probability distributions monad [29]. These monads have applications in semantics and formal verification for modelling computational effects in programs having quantitative behaviours (such as, e.g., probabilistic programs). The attractiveness of quantitative algebra in this context is to provide a logical/syntactic way
This work has been partially supported by the french ANR PRCI project ATQUA (ANR-25-CE48-1428-01).
Email: matteo.mio@ens-lyon.fr
Email: colin.riba@ens-lyon.fr
MFPS 2026 Proceedings will appear in Electronic Notes in Theoretical Informatics and Computer Science to handle such monads, in the same way that ordinary universal algebra and its logical/syntactic apparatus of equational logic are used to handle (finitary) Set monads (see, e.g., [3, 3.18]).
1.2 Compact Quantitative Equational Theories. A main obstacle towards the above outlined application is that the logical apparatus of quantitative algebra is based on infinitary first order logic. Concretely, this means that the binary relations appearing in quantitative equations ( , for ) are subject to, among others, the following axiom:
(Infinitary Axiom)
It states that if the distance between and is bounded above by a set of upper bounds, then necessarily the distance is also bounded by the infimum of all these upper bounds. The presence of this infinitary axiom means that, in general, proofs are infinitely branching well-founded trees. Hence they are not finite objects and therefore cannot be represented, manipulated, enumerated and verified by machines.
On the one hand, it can be shown that an infinitary axiom, such as the one above, is necessary in any sound and complete proof system for quantitative algebra. On the other hand, it has been recently observed in [25] that, for some well behaved theories called compact quantitative equational theories T, it holds that a quantitative equation is derivable from T in the proof system if and only if it is derivable from T without any usage of infinitary axioms. Hence, compact quantitative equational theories are exactly those amenable to finitary syntactic manipulation and proofs, just as ordinary equational theories of universal algebra. Perhaps surprisingly, [25] has shown that rather than being an artificial or rare notion, the class of compact quantitative equational theories includes many interesting examples such as those axiomatizing the Met monads, mentioned earlier, useful in program semantics and verification.
1.3 Technical Contribution. The definition of compact quantitative equational theory from [25, Def. 3.1], as briefly outlined above, is purely syntactical: a theory T is compact whenever there are finite proofs for all derivable quantitative equations. The main achievement of the present work is to give an equivalent characterisation of compactness using the language of category theory and monads.
Rather than working with the notion of quantitative algebra of [25] or [22], it is technically convenient to work with an even more general definition inspired from both [11] and [28]. Namely, the base category Met is replaced and generalised to ModΠ(B), the category of models of B and their homomorphisms, where Π is a relational signature consisting only of relation symbols and B is a collection of (possibly infinitary) Horn formulas over Π. The special case Met is obtained by taking Π = {=ε | ε ≥ 0} and by defining the collection B to include, among others, the infinitary axiom mentioned above (see Example 3.1 and [28, §2.3] for a full list). The algebraic part, on top of the base category, is specified by a signature Σ consisting only of function symbols (this includes constants, as nullary functions) and a set Q of (possibly infinitary) Horn formulas over the extended signature Π + Σ having a special shape and playing the role of quantitative equations (see Section 3 for details). The category ModΠ+Σ(B + Q), over the extended signature and theory, plays the role of the category of quantitative algebras. The free algebra construction then gives rise to the following adjunction F ⊥ U and corresponding monad T = UF on ModΠ(B):
Base Category
Category of Quantitative Algebras
If we take the theories and and remove from them all infinitary Horn formulas, thus only leaving the finite formulas, we obtain finitary sub-theories and and the following adjunction and monad on :
We denote with and the obvious inclusions (every model of (resp. ) is also a model of (resp. )).
Our main result is Theorem 5.3 in Section 5. It states a correspondence between a purely logical property of the theory T and a categorical property of the corresponding monad:
Main Result: The quantitative equational theory given by and is compact (Definition 4.6)
if, and only if, T is a monad restriction of and the restriction is compatible with I.
This paper is organised as follows. In Section 2 the required notions from category theory, including monad restrictions, and of Horn logic are given. In Section 3 we define, following [11], the generalised notion of quantitative algebra outlined above. In Section 4, the definition of compact quantitative equational theory of [25] is adapted to this more general setting. The definition coincides with that of [25] when the quantitative algebras of [25] are taken as particular case. In Section 5 we present and give a full and self contained proof of our main Theorem 5.3. Lastly, we discuss directions for future work in Section 6.
2.1 Eilenberg–Moore category and Canonical Comparison Functor
Given categories C and D and an adjunct pair with unit and counit ,
there is a corresponding monad on , with underling functor , unit and multiplication (see, e.g., [21, VI.1]).
Different adjunctions may induce the same monad on . A canonical choice is given by the Eilenberg–Moore construction (see, e.g., [21, VI.2]). Given a monad on we denote with the Eilenberg–Moore category of . The objects of are called -algebras and are pairs with and in satisfying: and . The morphisms of from to are morphisms in satisfying . There is a forgetful functor defined on objects as and on morphisms as . This functor has a left adjoint defined on objects as and on morphisms as . The adjunction induces, as described above, the same monad on we started with.
The following is a key property of the Eilenberg–Moore construction (see, e.g., [21, VI.3.1]).
Proposition 2.1 (Comparison Functor) Let be an adjoint pair with unit and counit . Let be the induced monad and the associated Eilenberg-Moore category. There is a functor , called the comparison functor, defined as follows:
With the above definitions in place, one easily derives the following proposition (see, e.g. [21, VI.3.1]).
Proposition 2.2 Fix, as described above, an adjunction , the associated monad , the category, the adjunction and the comparison functor . Then it holds that:
This work relies on a strict notion of monadicity, as in, e.g., [21, VI.7].
Definition 2.3 [Strictly Monadic Functor] We say that a functor is strictly monadic if has a left adjoint and, denoting with the induced monad, the comparison functor is an isomorphism of categories.
The functor is, trivially, strictly monadic. For the following fact see, e.g., [9, 3.3.2].
A monad restriction is a natural isomorphism subject to compatibility constraints ( ).
Proposition 2.4 Every strictly monadic functor reflects isomorphisms, i.e., if is an isomorphism in then is an isomorphism in .
2.2 Monad Morphisms and Restrictions
The material presented in this section is folklore. For instance, the notion of monad morphism between monads on a given category C is developed in [9, §3]. In this work, however, we require monad morphisms between monads on different categories. This theory is naturally developed at the level of 2-categories (see, e.g., [31]), but we only need an ordinary 1-categorical treatment.
An embedding of categories is a functor which is full, faithful and injective on objects.
Definition 2.5 [Monad Morphism] Let and be categories, a monad on and a monad on . A pair , with a functor and a natural transformation, is called a monad morphism if it satisfies:
(i) (Unit compatibility) , i.e.,
(for all )
(ii) (Multiplication compatibility) , i.e.,
(for all )
The next two propositions link the definition of monad morphism, as above, with the Eilenberg–Moore construction.
Proposition 2.6 Let be a monad morphism. Then there is a canonical functor defined:
• on objects as:
• on morphisms of N-algebras as:
such that lifts , i.e., ,
Proposition 2.7 Let be a functor lifting , i.e., such that . Denote with the -algebra structure of , for :
Then there is a canonical natural transformation defined, for every , by the equation:
Furthermore, the underling natural transformation
gives a canonical monad morphism , i.e., satisfies the unit and multiplication compatibility equations of Definition 2.5.
Proposition 2.8 The two constructions (Proposition 2.6) and (Proposition 2.7) are inverse to each other, i.e.:
(i) , for every monad morphism ,
(ii) , for every functor lifting (i.e., ).
Remark 2.9 The three propositions above, for the particular case when (i.e., when and are monads on the same category) appear as [9, Theorem 3.6.3]. In fact, the latter further shows that the one-to-one correspondence also preserves composition. We will not need this additional fact.
Consider now a monad morphism such that is a natural isomorphism. By applying Proposition 2.6, we obtain a canonical functor lifting , and by Proposition 2.7 a canonical natural transformation such that, by Proposition 2.8, is . It is not obvious, a priori, that is itself a natural isomorphism. This is because the existence on an inverse of in does not necessarily imply the existence of an inverse of in . This requires showing that lives in as well, i.e., that it satisfies the constraints of -algebra morphisms. The following direct consequence of Proposition 2.4 states that this is always the case.
Proposition 2.10 Let be a monad morphism with a natural isomorphism. Then the canonical is a natural isomorphism.
Definition 2.11 [Monad Restriction] A restriction of monads is a monad morphism such that is an embedding of categories and a natural isomorphism.
The next fact states that a restriction , if it exists, is unique up to isomorphism. Hence, when a restriction exists, we can talk about the restriction of N along the embedding G. And we will say that M is a monad restriction of N along G if the restriction exists.
Proposition 2.12 Let be an embedding of categories. Any two restrictions and , are equal up to isomorphism, i.e., there is a natural isomorphism such that , defined as .
We will use this corollary of the preceding propositions.
Corollary 2.13 Let be a an embedding of categories, a monad on and a monad on . The following are equivalent:
(i) N is a restriction of M along G, i.e., there is a monad restriction (see Definition 2.11),
(ii) there is a functor that lifts and such that the associated canonical natural transformation (as in Proposition 2.7) is a natural isomorphism.
2.3 Categories of Models of Horn Theories
In the previous subsections we have considered monads on abstract categories. We now specialise the discussion to categories of models of Horn theories. We refer to [16] and [3] as standard references.
A signature is a possibly infinite collection of relation symbols and function symbols . Throughout this work we assume that all symbols have finite arity. We reserve the letters and for signatures consisting uniquely of relation symbols and function symbols, respectively.
An S-structure is a pair:
i.e., a carrier set together with interpretations and of all relations and function symbols in . Given -structures and , an -homomorphism is a map preserving all symbols in , i.e., and . We denote with the category of -structures and their homomorphisms.
We are interested in full subcategories of defined by infinitary Horn sentences in the signature . Such Horn sentences are of the form
allowing for infinitely many variables and formulas in the antecedent of the implication, and where the formulas are atomic formulas in the signature with variables from (an atomic formula in is either a relation with or an equality , where the 's are terms in ). If a Horn sentence involves only finitely many variables and finitely many formulas in the antecedent, i.e., if it belongs to ordinary first order logic, then we refer to it as finitary.
Satisfiability between -structures and Horn sentences is defined as usual and denoted with . If is a set of Horn sentences, we denote with the full subcategory of whose objects satisfy all formulas in . Note that .
Theorem 2.14 Let be signatures with , i.e., is an extension of . Let be a set of Horn sentences in and be a set of Horn sentences in with , i.e., is an extension of . Then:
(i) There is a forgetful functor that forgets the additional symbols in and the additional Horn sentences in . Furthermore, if then the functor is an embedding of as a full subcategory of .
(ii) U has a left adjoint , so there is a monad on induced by the adjunction .
Rather than providing a concrete definition of the left adjoint F, we will work with its abstract properties described in the next Subsection 2.3.1.
Remark 2.15 The forgetful functor of Theorem 2.14 is, in general, not strictly monadic (Definition 2.3). For example, taking , the category is the category . And by taking and to be the Horn implications defining partial orders, the category is the category of partial orders and monotone maps. In this case is not strictly monadic.
2.3.1 Presentations of Structures
We now review well-known material on presentations of structures by generators and relations. A standard reference is [16, §9.2]. The following notions are from [16, 1.2.2, 1.4.1 and §9.2] (see also [3, §3.10]).
Definition 2.16 An injective -homomorphism is an embedding if it reflects all relation symbols , i.e., . We say that is a substructure of if , and if moreover the inclusion function is an embedding .
Definition 2.17 Given a tuple of elements a from an S-structure A, we say that a generates A if the smallest substructure of A that contains a is A itself.
Definition 2.18 [Presentations] An -presentation is a pair where is a possibly infinite sequence of variables, and where is a possibly infinite sequence of atomic formulas in with variables from .
Definition 2.19 Let be a class of -structures. Fix a presentation and a structure . Let be a sequence of elements in , one for each , referred to as parameters. We say that presents the expanded structure in when the three following conditions hold:
(i) The S-structure A is generated by a.
(ii) for each , where this notation means that each variable in is interpreted by the parameter .
(iii) For all and elements of , if holds for all , then there is a homomorphism of expanded -structures , that is, an -homomorphism such that for all .
Remark 2.20 In item (iii) of Definition 2.19, since is generated by , the homomorphism of expanded structures is unique whenever it exists. As a consequence, if and are both presented by in , then the unique is an isomorphism of expanded structures.
For a proof of the following useful fact see [16, Lemma 9.2.1].
Lemma 2.21 Let K be a class of S-structures and consider a presentation . The following are equivalent for each expanded structure with :
(i) presents in K.
(ii) a generates the S-structure A and for every atomic formula in S, we have:
We apply this machinery to the setting of Theorem 2.14, where we have signatures , Horn theories and the adjunction : .
Definition 2.22 Given any we define the presentation , where:
• , i.e., there is one variable for each ,
- is the set of all atomic -formulas such that , i.e., that are satisfied in when interpreting by .
In model theory, the set of formulas of Pres(A) is often referred to as the positive diagram of A (see, e.g., [3, Remark 5.33] and [16]). Note that Pres(A) is a presentation in the signature (because all formulas in are atomic -formulas) and therefore, a fortiori, also a presentation in the extended signature . In the following result, which provides a logical characterisation of free objects, we use Pres(A) as a presentation in the extended signature .
Proposition 2.23 Let and be Horn theories in signatures and , respectively, with and . Let : be the corresponding adjoint pair, as in Theorem 2.14, with unit . Fix any and corresponding presentation . Then it holds that:
(i) The expanded structure is presented by in .
(ii) For each atomic formula in the extended signature ,
Proof. The universal property of FA, as a free object, is used to establish the first point. The second point is a direct consequence of Lemma 2.21.
Remark 2.24 In Proposition 2.23, is viewed as an element of the structure . Note that, formally, , and therefore , is an element of . However, by definition of the forgetful functor , the two structures and have the same carrier, i.e., . Hence is an element of .
Lemma 2.25 Let and be Horn theories in signatures and , respectively, with and . Let : be the corresponding adjoint pair, as in Theorem 2.14, with unit . Fix and let be a collection of variables, one for each . Let furthermore with parameters , such that:
(i) B is generated by the parameters , and
(ii) for every atomic formula in the signature ,
Then there exists a unique homomorphism of expanded structures , and is an isomorphism.
3 Quantitative Algebras
Quantitative algebra, as originally introduced in [22] (see also [8]), studies algebraic theories over the category of metric spaces and nonexpansive maps. The apparatus allows to explore the interactions between the metric structure and the algebraic structure. In a similar but more general way, some works [28,25] have considered algebraic theories over the category of fuzzy relations. In this paper, inspired by both [11] and [28], we adopt an even more general definition. The base category, such as metric or fuzzy relation spaces, is assumed to be , the models of a Horn theory over a purely relational (i.e., not having any constant or functions symbols) signature . The signature can be infinite but all relations must have finite arity.
Example 3.1 The category FRel of fuzzy relations and nonexpansive maps is (isomorphic to) Mod_{\Pi}(\mathbb{B}), where is an infinite set of binary relations indexed by real numbers , and is the Horn theory consisting of the following sentences:
• (Monotonicity) , for each with ,
• (Order Completeness) , for each .
Note that each instance of the order completeness implication has countably many premises. It can be shown that the category FRel requires infinitary formulas to be axiomatised. This follows, for example, from the fact that FRel is locally presentable but not locally finitely presentable. The category Met₁ of 1-bounded metric spaces and nonexpansive maps is obtained by adding to B additional Horn implications expressing the axioms of metric spaces, such as the triangle inequality (see, e.g. [28, §2.3]).
The algebraic part of the theory, on top of the base category, is formalised by considering a signature consisting only of function symbols (i.e., no relations) of finite arity (constants are functions of arity 0) and a Horn theory over the extended signature consisting of basic quantitative equations, defined as follows.
Definition 3.2 Let (II, B) be a base theory. Let consist only of constants and function symbols of finite arity. A basic quantitative equation (BQE) is a Horn implication of the form:
such that the function symbols in never appear in the antecedent. Equivalently:
-
the formulas are atomic -formulas using variables from . So is either of the form or , with ,
-
the formula is an atomic -formula using variables from . So is of the form , where is either a relation symbol or the equality symbol (=), and are -terms with variables from .
As usual, if the conjunction in the antecedent is empty, we just write .
Remark 3.3 The use of the adjective “basic” in Definition 3.1 follows the terminology adopted in the first paper on quantitative algebra [22], where arbitrary Horn implications over the signature are called quantitative inferences, the subclass having no function symbols in the antecedent, as in Definition 3.2, are called basic quantitative inferences, and the further subclass of the form are called quantitative equations. In later works the theory has developed with a focus on basic quantitative inferences (see e.g., [23,11,28]), rather than quantitative inferences. Accordingly, in this work we only work with basic quantitative equations in the sense of Definition 3.2. Somewhat confusingly, in [25] the term quantitative
See also Remark 2.12 in [25].
equation refers to a special class of basic quantitative equations (as in Definition 3.2), which we will refer to as antecedent complete BQE (Definition 4.1 of Section 4).
Definition 3.4 A quantitative equational theory is given by a base theory and an algebraic theory , with the signature consisting only of constants and function symbols and consisting of basic quantitative equations, as defined above. So we can write . The category of models of the theory , called quantitative algebras (of the theory ), is .
Remark 3.5 Note that there is nothing necessarily “quantitative” in this definition. We adopt this adjective merely to adhere with previous literature on this line of research, starting with [22], where the focus was on variants of the base theory of Example 3.1.
Example 3.6 Consider the base theory (Π, B) of fuzzy relations, from Example 3.1. Let consist of a (uncountable) collection of binary function symbols indexed by reals . Consider the set Q of basic quantitative equations given by:
• Axioms of convex algebras:
• Interpolative barycentric axiom, for all and :
The models of , i.e., the objects in , are the quantitative convex algebras of [25], or equivalently structures that are both fuzzy relations and convex algebras , with the two being compatible in the sense of the interpolative barycentric axiom, by interpreting as . Quantitative convex algebras over metric spaces where earlier introduced in [22], and can be analogously formalised by taking to be the basic theory axiomatizing 1-bounded metric spaces (see Example 3.1).
The following is a key result regarding quantitative equational theories.
Theorem 3.7 Let be a quantitative equational theory. There is a forgetful functor , from the category of models of to the base category, that forgets the additional function symbols in and the Horn implications in . Furthermore:
(i) U has a left adjoint , which constructs free quantitative algebras generated by objects in the base category.
(ii) U is strictly monadic (see Definition 2.3), i.e., by denoting with T the monad induced by , the comparison functor is an isomorphism of categories.
(iii) U reflects isomorphisms, that is, if is an isomorphism then f is an isomorphism.
Proof. Item (i) is an instance of Theorem 2.14. Item (ii), with differences depending on the exact mathematical setting, has appeared in several works on quantitative algebra ([11, Thm 4.13], [1, Thm 2.17], [28, Thm 6.3]). We offer a proof in §3.1. Item (iii) follows from (ii) using Proposition 2.4.
Remark 3.8 The restrictions imposed on (purely functional signature) and (consisting of basic quantitative equations, as opposed to arbitrary Horn implications in the signature ) are used for proving item (ii) of Theorem 3.7. Without appropriate conditions, item (ii) is generally false (cf. Remark 2.15).
As a direct consequence of Theorem 3.7 we have the following.
Corollary 3.9 To every quantitative equational theory , corresponds a monad on , also denoted by , induced by the adjoint pair , such that .
Example 3.10 Consider the quantitative theory of Example 3.6 defining quantitative convex algebras. Recall that, in this example, the base category is (isomorphic to) . The corresponding monad is the Kantorovich Distribution monad, which takes a fuzzy relation and maps it to the fuzzy relation of finite distributions on equipped with the Kantorovich lifting of the fuzzy relation (see [25]). If the base theory is taken to be that of 1-bounded metric spaces (see Example 3.1), the resulting monad is the Kantorovich Distribution monad studied in the first article on quantitative algebras [22].
Remark 3.11 As already mentioned, the definitions presented in this section are inspired by both [11] and [28]. As in [11], the base category is always symmetric monoidal closed and therefore it can be enriched over itself. But as in [28], the resulting monad is in general not enriched over the base category. The latter property holds if contains basic quantitative equations enforcing that every operations satisfies the conditions for being a homomorphism in the base category. See [28] for a detailed discussion.
3.1 Proof of the Monadicity Theorem 3.7(ii)
Let be a quantitative equational theory. Consider the functor
from the category of models of to the base category, that forgets the function symbols in and the Horn implications in . By Theorem 3.7.(i), we know that has a left adjoint . Write for the induced monad on .
We show that is strictly monadic in the sense of [21, §VI.3], namely that the comparison functor is an isomorphism of categories. Similarly as for other variations of quantitative algebras ([11,1]), we apply Beck's (Strict) Monadicity Theorem ([21, Theorem VI.7.1]). We are thus going to prove the following.
Proposition 3.12 The right adjoint creates coequalizers for those parallel pairs in such that has a split coequalizer in .
Recall from [21, §VI.6] that a split coequalizer of a parallel pair is given by morphisms , and such that the diagram below commutes
and moreover both horizontal composites are identities. Note that e is always a coequalizer of f and g. Moreover, split coequalizers are absolute (i.e. preserved by all functors).
The proof of Proposition 3.12 is similar to the proof of the analogous [11, Thm 4.13] and [1, Thm 2.17]. Given a parallel pair in such that the pair has a split coequalizer in , we use the fact is absolute to obtain a (unique) -structure on , say . This follows the usual argument for the purely algebraic case (see, e.g., [3, Remark 3.4(7)]).
In the purely algebraic case, the induced structure on is ensured to satisfy the required equations, since ordinary equations are preserved by homomorphisms. However, the preservation of quantitative equations requires a separate argument (recall that arbitrary Horn sentences are not preserved by homomorphisms). This is provided by the following Lemma 3.13. The proofs of [11, Thm 4.13] and [1, Thm 2.17] rely on similar arguments.
Lemma 3.13 Let be a homomorphism in such that is split epic in : there is a -homomorphism such that is the identity. If the -structure is a model of , , then as well.
Proof. Consider a sentence in , say
where is an atomic formula in and the 's are atomic formulas in (note that if the above sentence is in ). Given such that , we have since is a homomorphism of -structures. Hence since . It follows that since is a homomorphism of -structures, and we are done since is the identity function by assumption.
We now prove Proposition 3.12. Let be a parallel pair in , and assume that the pair has a split coequalizer in , say
where , together with and similarly as in Equation (1). We have to show that creates the coequalizing diagram , i.e. that there exists exactly one and such that and , and moreover that the unique such is a coequalizer of and in ([21, Definition V.1]).
We first equip with a -structure, using that is an absolute coequalizer. Proceeding similarly as in [3, Remark 3.4(7)], we show that there is a unique -structure on such that lifts to a -homomorphism . For each function symbol of arity , since in we have in . Hence, in ,
since and are -homomorphisms. It follows that coequalizes and in Set. But since is an absolute coequalizer, it is preserved by applying the carrier functor to Set and then the -fold product functor on Set. Hence is a coequalizer of and in Set. As a result, there is a unique such that
This yields an interpretation of each function symbol , thus lifting the -structure on to a -structure , with . By construction of , lifts to a homomorphism of -structures with .
This -structure on is unique such that and . This uses the faithfulness of and the fact that is the identity. Given any -structure on and any -homomorphism such that and , for each , we must have, in Set,
while since with U faithful.
Moreover, by Lemma 3.13. We thus have unique and such that and .
It remains to show that is a coequalizer of and in . This follows from easy manipulations, using that is a coequalizer in and that is a homomorphism in . Let in such that . We thus have , and since is a coequalizer of and in , there is a unique in such that .
We show that is a homomorphism of -structures. Given , we have to show that, in Set,
But by Equation (2) above, and since p is a -homomorphism, we have, in Set,
In other words, lifts to a -homomorphism with . Moreover is unique such that since implies , and thus since is faithful.
This concludes the proof of Proposition 3.12.
4 Compact Theories of Quantitative Algebras
The notion of compact theory of quantitative algebras has been introduced in [25]. The mathematical setting of [25] is a special case of that considered in this paper (in Section 3), where:
(i) The base theory (Π, B) is fixed to be that of fuzzy relations, as described in Example 3.1.
(ii) The basic quantitative equations in Q are required to be antecedent complete (see Definition 4.1 below). As we will discuss in Remark 4.2, this is not truly a restriction, but the notion of antecedent complete basic quantitative equation is key for the definition of compactness.
In what follows, we extend the definition of compact theories from [25] to the more general setting of Section 3. The definition coincides with that of [25] when the two restrictions above are adopted.
Recall from Definition 2.22 that, for every , we have a presentation , where consists of one variable for each , and is the set of all atomic -formulas that hold in .
Definition 4.1 [Antecedent Complete Basic Quantitative Equations] A basic quantitative equation
is called antecedent complete (or just “AC”) if , for some .
In other words, in AC basic quantitative equations, the variables are in one-to-one correspondence with the elements of a model in the base category, and the formulas in the antecedent are a complete description of the relations which hold in . Note that both and can be infinite.
Remark 4.2 Alternatively, a basic quantitative equation is AC precisely when
(i) for every -atomic formula , if is a logical consequence of the assumptions under the base theory , then it must be already contained in the assumptions, i.e.:
(ii) and in , there is no formula with distinct variables.
Consequently, for each , one can always find a , consisting only of AC basic quantitative equations, such that is equivalent to , in the sense that . Such is obtained by “completing” (i.e., adding all deducible atomic formulas to) the antecedents of all basic quantitative equations in under the theory , and identifying variables in the quantifications, if is deducible.
Remark 4.3 In [25] and [28], since the base theory is fixed to be that of fuzzy relations (i.e., ), AC basic quantitative equations are written as “ ”, to explicitly indicate that the atomic formulas of the antecedent are exactly those holding true in the fuzzy relation .
In order to introduce the notion of compact quantitative equational theory, from [25], we need the following technical definition.
Definition 4.4 [Finitary Restriction of a Theory] Given a quantitative theory , we define its finitary restriction to be:
where and are the subsets of formulas, in and respectively, that are expressed in ordinary first order logic, i.e., that involve only a finite number of variables and formulas in the antecedent.
Example 4.5 Consider the theory of quantitative convex algebras over fuzzy relations, from Example 3.6. In this case is a proper subset of , obtained by removing all instances of the order completeness axioms (see Example 3.1) which are infinitary. By contrast, , because all basic quantitative equations in are finitary.
We are now ready to formally define compact quantitative theories.
Definition 4.6 [Compact Quantitative Theories] A theory is compact if, for all AC basic quantitative equations of the form , the following holds:
i.e., if is a logical consequence of the theory then it must also be a consequence of the weaker theory (note that the other direction () is always trivially true).
Remark 4.7 Note that, in the definition of compact theory, the conservativity requirement is only relative to AC basic quantitative equations . It may therefore be possible, for a theory , to be compact and that the implication fails for some non-AC basic quantitative equation .
Remark 4.8 By ordinary logical reasoning, the following holds:
with fresh in and , and where free variables in sequences are interpreted as being universally quantified, as customary. Note that while and the index set can be infinite, the right-hand side expresses logical entailment between ordinary first order logic formulas, because all function and relation symbols and have finite arity. Therefore, by the compactness theorem of first order logic, the right-hand side holds if and only if there exists a finite proof of the sequent , necessarily using only a finite subset of the formulas on the left-hand side of the sequent. In [25], this “finite proof” formulation for the compactness of a theory is adopted, whence the name due to the involvement of the compactness theorem of first order logic. It is equivalent to the formulation in Definition 4.6.
Example 4.9 The main result of [25] is that the quantitative equational theory of convex algebras (in Example 3.6) is compact.
5 Main Result
Recall from Definition 4.4 that, for any quantitative theory we have a corresponding subtheory, its finitary restriction . Since and , the category is a full subcategory of and is a full subcategory of (see Theorem 2.14(i)). Denote with and the inclusion functors
Let be the monad arising from the adjunction of Theorem 3.7 and also, as any monad, from the Eilenberg–Moore adjunction (see Proposition 2.1). The two are connected by the comparison functor (see Section 2.1) which, by Theorem 3.7, is an isomorphism of categories. Similarly for the monad . We thus have the following functors involved:

with the following commutations: , , , , by Proposition 2.2, and (i.e., I lifts G) because all four functors are defined as forgetful functors. The last observation has the following consequence.
Proposition 5.1 There exists a unique natural such that .
Proof. The natural transformation has type but, since lifts , its type is equivalently . Therefore, by the universal property of the adjunction , there exists a unique satisfying .
The following is our main result.
Definition 5.2 We say that a monad morphism (see Definition 2.5) is compatible with the inclusion functor if the corresponding canonical functor (see Proposition 2.6) coincides with under the comparison functors, i.e., .
Theorem 5.3 For every quantitative theory , the following are equivalent:
(i) The theory T is compact (see Definition 4.6).
(ii) The natural transformation in Proposition 5.1 is a natural isomorphism.
(iii) There is a natural isomorphism yielding a monad restriction such that (which is essentially unique by Proposition 2.12) is compatible with the inclusion functor .
In particular, from (i) (iii) in Theorem 5.3 we obtain the following corollary.
Corollary 5.4 If the theory T is compact then the monad T is a restriction of along G.
Remark 5.5 Implication (iii) (i) in Theorem 5.3 does not seem to readily imply the converse of the implication in Corollary 5.4. It is indeed a priori conceivable that monad restrictions may exist and yet none of them are compatible with (Proposition 2.12 states that they are all equal up to isomorphism). We do not know if the converse of the implication in Corollary 5.4 holds.
The rest of this paper is devoted to the proof of Theorem 5.3. We prove direction (i) (ii) in Subsection 5.1, direction (ii) (i) in Subsection 5.2, direction (iii) (ii) in Subsection 5.3 and direction (ii) (iii) in Subsection 5.4. Before doing so, we state as propositions the following instances, to the present situation and notation, of previously established facts.
Proposition 5.6 (from Corollary 2.13) T is a monad restriction of along G if, and only if, there exists a functor lifting (i.e., ) and such that the canonical natural transformation (as specified in Proposition 2.7) is a natural isomorphism.
Proposition 5.7 (from Proposition 2.23(i)) For all , let . Then:
(i) is presented by in , and
(ii) (F_{T_f}(GA), (\eta_{GA}^T_f(a) \mid a \in A)) is presented by in .
Proof. The first item is a direct instantiation of the first item in Proposition 2.23 by taking and . For the second item, a similar instantiation formally gives:
but since the inclusion is a forgetful functor (i.e., and are the same -structure), the notation and , and similarly and , coincide. Hence the statement (ii).
Proposition 5.8 (from Proposition 2.23(ii)) For every AC quantitative equation (see Definition 4.1)
(i)
(ii)
Proof. On top of the same argument used in the proof of Proposition 5.7, it is sufficient to observe that quantifying over all and atomic formulas , as in the statement of Proposition 2.23(ii), is equivalent to quantifying over all AC basic quantitative equations (see Definition 4.1).
5.1 Proof of Direction in Theorem 5.3
We need to prove that, for each , the component of the natural transformation of Proposition 5.1 is an isomorphism. Denote with the underlying morphism which satisfies \theta_A \circ \eta_{GA}^T_f = G(\eta_A^T). We are going to prove that is an isomorphism using Lemma 2.25. This, in turn, will imply that is an isomorphism, because reflects isomorphisms (Theorem 3.7(iii)).
To invoke Lemma 2.25, we need the following four observations. The assumption that the theory T is compact is used in Observation 4.
Observation 1. As noted in Proposition 5.1, the natural transformation has, equivalently, type . This means that is a point of the model , for each . Or, equivalently, for each , because is a forgetful functor (i.e., and are the same structures). Therefore we have the following expanded -structure:
Observation 2. The property \theta_A \circ \eta_{GA}^T_f = G(\eta_A^T) means exactly that is a homomorphism of expanded structures, i.e., it preserves all the parameters:
Observation 3. The parameters generates . This is because, by Proposition 5.7(i), the -structure is presented by in and, by Definition 2.19, this implies that generate . But since and are defined as forgetful functors (i.e., and are the same structures and and are the same parameters) we deduce that generate .
Observation 4. By Definition 4.6, the assumption that is compact means that for all AC basic quantitative equations of the form , where for some , it holds that . In fact, since the reverse implication trivially holds (because ), we have:
In particular, by fixing B to be A, and using Proposition 5.8, the assumption implies that
holds for all atomic in the signature . Again noting that and are forgetful functors, we can rewrite the left-hand side and obtain, for all atomic in the signature :
We can now conclude that is an isomorphism by instantiating the statement of Lemma 2.25 as follows: , , , , , , and the list of parameters as . The required assumptions of Lemma 2.25 are satisfied by Observations 1,3 and 4. Therefore which, by Observation 2, is a homomorphism of expanded structures, is the only such one and is an isomorphism.
5.2 Proof of Direction in Theorem 5.3
To prove that the theory is compact (see Definition 4.6) we need to show that for every AC basic quantitative equation of the form , it holds that
(†)
From Definition 4.1 of AC basic quantitative equations, the variables and formulas come from the presentation of some , i.e., , and .
Hence, using Proposition 5.8, we can rewrite as:
Recall that and are defined as forgetful functors, so that and are the same -structure and and the same parameters. Hence we can rewrite the above as:
By assumption (ii), we have a natural isomorphism satisfying . This property means, equivalently, that the component preserves the parameters and therefore it is an isomorphism of expanded structures:
Hence holds.
□
5.3 Proof of Direction in Theorem 5.3
We first establish the following lemma, also used in the proof of direction (ii) (iii) in Subsection 5.4.
Lemma 5.9 Let be a monad morphism (not necessarily an isomorphism) compatible with . Let be the (uniquely determined) natural transformation from Proposition 5.1 satisfying . Then it holds that: .
Proof. The unit compatibility property of the monad morphism (see Definition 2.5) states that:
(Unit compatibility of )
From , by application of Proposition 2.6 we obtain a canonical functor lifting (i.e., ). And in turn, combining Proposition 2.7 and Proposition 2.8, from we obtain a canonical natural transformation such that .
The assumption that is compatible with I is, by Definition 5.2, that .
Let be the natural transformation corresponding to via the comparison functor. Note that, by definition of on morphisms (see Section 2.1) we have that . This implies that the equation holds. By Proposition 5.1, there exists only one such natural transformation. Hence . And therefore .
We now return to the proof of Direction (iii) (ii) in Theorem 5.3. From the assumption, we have a monad morphism which is a natural isomorphism and such that is compatible with . By Lemma 5.9, is the underlying morphism of . Reasoning similarly as in the beginning of §5.1, we get that is a natural isomorphism.
5.4 Proof of Direction in Theorem 5.3
We need to show that there is a monad restriction , i.e. a monad morphism that is a natural isomorphism, such that is compatible with I.
First, observe that it suffices to show that a monad morphism (not necessarily an isomorphism) such that is compatible with exists. Indeed, if such exists, by Lemma 5.9 it is the underlying morphism of . Assumption (ii) is that is a natural isomorphism and this implies that is also a natural isomorphism and therefore is a monad restriction.
To construct the monad morphism compatible with we proceed as follows. Define the functor as the functor , corresponding to via the comparison functors. Since is a lifting of (i.e., ), using Proposition 2.2 we derive that also is a lifting of (i.e., ). Therefore from , using Proposition 2.7 we obtain a canonical monad morphism . Define to be . Proposition 2.8 says that the canonical functor (from Proposition 2.6) induced by is exactly the functor we started with. Therefore is compatible with , because .
6 Conclusions and Future Work
In this work, we have taken the purely logical definition of compact quantitative equational theory of [25], extended to the more general setting of quantitative algebra described in Section 3, and provided a categorical characterisation formulated as Theorem 5.3.
As mentioned in Remark 5.5, we do not know if the reverse of the implication in Corollary 5.4 holds. We leave this as a technical open question for future investigation.
Another interesting direction of future work is towards generalisations. Our notion of compactness (Definition 4.6), expressed as the logical implication ( ), is based on comparing the theory of to its finitary restriction . A more general approach can, potentially, be based on the notion of interpretation of a theory in another theory (cf e.g. [19]). If the quantitative equational theory can be interpreted in a finitary (i.e., only having finite formulas) , then we might define to be compact via the interpretation if where is the interpretation of the basic quantitative equation . This formulation adds more flexibility, still retaining the key fact that validity of judgements is witnessed by finite proofs due to the compactness theorem of first order logic (see Remark 4.8). This generalisation might be developed in the context of Morita equivalence (in the sense of [17, D1.4]).
In another orthogonal direction, one focusing on the general connection between logic and monad restrictions rather than on finite proofs, one could relax the requirement and instead compare to its -ary restriction , defined as expected for any regular cardinal .
References
[1] Adámek, J., Varieties of quantitative algebras and their monads, in: 37th Annual ACM/IEEE Symposium on Logic in Computer Science (LICS'22), ACM (2022). https://doi.org/10.1145/3531130.3532405
[2] Adámek, J., M. Dostál and J. Velebil, Strongly finitary monads for varieties of quantitative algebras, in: 10th Conference on Algebra and Coalgebra in Computer Science (CALCO'23), volume 270 of LIPIcs, pages 10:1–10:14, Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2023). https://doi.org/10.4230/LIPICS.CALCO.2023.10
[3] Adamek, J. and J. Rosicky, Locally Presentable and Accessible Categories, London Mathematical Society Lecture Note Series, Cambridge University Press (1994). https://doi.org/10.1017/CB09780511600579
[4] Bacci, G., G. Bacci, K. G. Larsen and R. Mardare, A complete quantitative deduction system for the bisimilarity distance on markov chains, Log. Methods Comput. Sci. 14 (2018). https://doi.org/10.23638/LMCS-14(4:15)2018
[5] Bacci, G., R. Mardare, P. Panangaden and G. Plotkin, An algebraic theory of markov processes, in: 33rd Annual ACM/IEEE Symposium on Logic in Computer Science (LICS'18), pages 679–688, ACM (2018). https://doi.org/10.1145/3209108.3209177
[6] Bacci, G., R. Mardare, P. Panangaden and G. D. Plotkin, Propositional logics for the lawvere quantale, in: M. Kerjean and P. B. Levy, editors, Proceedings of the 39th Conference on the Mathematical Foundations of Programming Semantics, MFPS XXXIX, Indiana University, Bloomington, IN, USA, June 21-23, 2023, volume 3 of EPTICS, EpiSciences (2023). https://doi.org/10.46298/ENTICS.12292
[7] Bacci, G., R. Mardare, P. Panangaden and G. D. Plotkin, Sum and tensor of quantitative effects, Log. Methods Comput. Sci. 20 (2024). https://doi.org/10.46298/LMCS-20(4:9)2024
[8] Bacci, G., R. Mardare, P. Panangaden and G. D. Plotkin, Quantitative equational logic, J. ACM 73, pages 26:1–26:52 (2026). https://doi.org/10.1145/3818603
[9] Barr, M. and C. Wells, Toposes, triples and theories, Reprints in Theory and Applications of Categories pages 1–288 (2005). Originally published by Springer-Verlag, New York, 1985. http://www.tac.mta.ca/tac/reprints/articles/12/tr12.pdf
[10] D'Angelo, K., S. Gurke, J. M. Kirss, B. König, M. Najafi, W. Rozowski and P. Wild, Behavioural metrics: Compositionality of the kantorovich lifting and an application to up-to techniques, in: R. Majumdar and A. Silva, editors, 35th International Conference on Concurrency Theory, CONCUR 2024, September 9-13, 2024, Calgary, Canada, volume 311 of LIPIcs, pages 20:1–20:19, Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2024). https://doi.org/10.4230/LIPICS.CONCUR.2024.20
[11] Ford, C., S. Milius and L. Schröder, Monads on categories of relational structures, in: F. Gadducci and A. Silva, editors, 9th Conference on Algebra and Coalgebra in Computer Science, CALCO 2021, August 31 to September 3, 2021, Salzburg, Austria, volume 211 of LIPIcs, pages 14:1–14:17, Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2021). https://doi.org/10.4230/LIPICS.CALCO.2021.14
[12] Forster, J., L. Schröder, P. Wild, H. Beohar, S. Gurke, B. König and K. Messing, Quantitative graded semantics and spectra of behavioural metrics, in: J. Endrullis and S. Schmitz, editors, 33rd EACSL Annual Conference on Computer Science Logic, CSL 2025, February 10-14, 2025, Amsterdam, Netherlands, volume 326 of LIPIcs, pages 33:1–33:21, Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2025). https://doi.org/10.4230/LIPICS.CSL.2025.33
[13] Gavazzo, F., Quantitative behavioural reasoning for higher-order effectful programs: Applicative distances, in: Logic in Computer Science, LICS 2018, pages 452–461, ACM (2018). https://doi.org/10.1145/3209108.3209149
[14] Gavazzo, F. and C. D. Florio, Elements of quantitative rewriting, Proc. ACM Program. Lang. 7, pages 1832–1863 (2023). https://doi.org/10.1145/3571256
[15] Goncharov, S., D. Hofmann, P. Nora, L. Schröder and P. Wild, Kantorovich functors and characteristic logics for behavioural distances, in: O. Kupferman and P. Sobocinski, editors, Foundations of Software Science and Computation Structures – 26th International Conference, FoSSaCS 2023, Held as Part of the European Joint Conferences on Theory and Practice of Software, ETAPS 2023, Paris, France, April 22-27, 2023, Proceedings, volume 13992 of LNCS, pages 46–67, Springer (2023). https://doi.org/10.1007/978-3-031-30829-1_3
[16] Hodges, W., Model Theory, volume 42 of Encyclopedia of Mathematics and its Applications, Cambridge University Press (1993). https://doi.org/10.1017/CB09780511551574
[17] Johnstone, P., Sketches of an Elephant: A Topos Theory Compendium, Oxford Logic Guides, Clarendon Press (2002). https://doi.org/https://doi.org/10.1093/oso/9780198515982.001.0001
[18] Jurka, J., S. Milius and H. Urbat, Algebraic reasoning over relational structures, in: V. De Paiva and A. Simpson, editors, Proc. 40th Conference on Mathematical Foundations of Programming Semantics (MFPS), volume 4 of ENTICS, pages 13:1–13:20 (2024). https://doi.org/10.48550/ARXIV.2401.08445
[19] Kamsma, M., Type space functors and interpretations in positive logic, Arch. Math. Logic. 62, pages 1–28 (2023). https://doi.org/https://doi.org/10.1007/s00153-022-00825-7
[20] Lago, U. D., F. Honsell, M. Lenisa and P. Pistone, On quantitative algebraic higher-order theories, in: A. P. Felty, editor, 7th International Conference on Formal Structures for Computation and Deduction, FSCD 2022, August 2-5, 2022, Haifa, Israel, volume 228 of LIPIcs, pages 4:1–4:18, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2022). https://doi.org/10.4230/LIPICS.FSCD.2022.4
[21] Mac Lane, S., Categories for the Working Mathematician, Springer, 2nd edition (1998). https://doi.org/https://doi.org/10.1007/978-1-4757-4721-8
[22] Mardare, R., P. Panangaden and G. D. Plotkin, Quantitative algebraic reasoning, in: M. Grohe, E. Koskinen and N. Shankar, editors, Proceedings of the 31st Annual ACM/IEEE Symposium on Logic in Computer Science, LICS '16, New York, NY, USA, July 5-8, 2016, pages 700–709, ACM (2016). https://doi.org/10.1145/2933575.2934518
[23] Mardare, R., P. Panangaden and G. D. Plotkin, On the axiomatizability of quantitative algebras, in: 32nd Annual ACM/IEEE Symposium on Logic in Computer Science, LICS 2017, Reykjavik, Iceland, June 20-23, 2017, pages 1–12, IEEE Computer Society (2017). https://doi.org/10.1109/LICS.2017.8005102
[24] Milius, S. and H. Urbat, Equational axiomatization of algebras with structure, in: M. Bojańczyk and A. Simpson, editors, Proc. Foundations of Software Science and Computation Structures (FoSSaCS), volume 11425 of Lecture Notes Comput. Sci. (ARCoSS), pages 400–417, Springer (2019). https://doi.org/10.1007/978-3-030-17127-8_23
[25] Mio, M., Compact quantitative theories of convex algebras, Electronic Notes in Theoretical Informatics and Computer Science Volume 5 - Proceedings of MFPS XLI, 15 (2025), ISSN 2969-2431. https://doi.org/10.46298/entics.16876
[26] Mio, M., R. Sarkis and V. Vignudelli, Combining nondeterminism, probability, and termination: Equational and metric reasoning, in: 36th Annual ACM/IEEE Symposium on Logic in Computer Science, LICS 2021, Rome, Italy, June 29 - July 2, 2021, pages 1–14, IEEE (2021). https://doi.org/10.1109/LICS52264.2021.9470717
[27] Mio, M., R. Sarkis and V. Vignudelli, Beyond nonexpansive operations in quantitative algebraic reasoning, in: Proc. 37th Annual ACM/IEEE Symposium on Logic in Computer Science (LICS'22), pages 52:1–52:13, ACM (2022). https://doi.org/10.1145/3531130.3533366
[28] Mio, M., R. Sarkis and V. Vignudelli, Universal quantitative algebra for fuzzy relations and generalised metric spaces, Log. Methods Comput. Sci. 20, pages 19:1–19:56 (2024). https://doi.org/10.46298/LMCS-20(4:19)2024
[29] Mio, M. and V. Vignudelli, Monads and quantitative equational theories for nondeterminism and probability, in: I. Konnov and L. Kovács, editors, 31st International Conference on Concurrency Theory, CONCUR 2020, September 1-4, 2020, Vienna, Austria (Virtual Conference), volume 171 of LIPIcs, pages 28:1–28:18, Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2020). https://doi.org/10.4230/LIPICS.CONCUR.2020.28
[30] Sarkis, R., Lifting Algebraic Reasoning to Generalized Metric Spaces, Phd thesis, ENS de Lyon (2024). Available at https://doi.org/10.5281/zenodo.14001076.
[31] Street, R., The formal theory of monads, Journal of Pure and Applied Algebra 2, pages 149–168 (1972), ISSN 0022-4049. https://doi.org/https://doi.org/10.1016/0022-4049(72)90019-9
[32] Wild, P. and L. Schröder, Characteristic Logics for Behavioural Metrics via Fuzzy Lax Extensions, in: I. Konnov and L. Kovács, editors, 31st International Conference on Concurrency Theory, CONCUR 2020, September 1-4, 2020, Vienna, Austria (Virtual Conference), volume 171 of LIPIcs, pages 27:1–27:23, Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2020). 2007.01033.
https://doi.org/10.4230/LIPIcs.CONCUR.2020.27
[33] Wild, P. and L. Schröder, A quantified coalgebraic van benthem theorem, in: S. Kiefer and C. Tasson, editors, Foundations of Software Science and Computation Structures - 24th International Conference, FOSSACS 2021, Held as Part of the European Joint Conferences on Theory and Practice of Software, ETAPS 2021, Luxembourg City, Luxembourg, March 27 - April 1, 2021, Proceedings, volume 12650 of LNCS, pages 551–571, Springer (2021). https://doi.org/10.1007/978-3-030-71995-1_28