# Structural and universal completeness
in algebra and logic

Paolo Aglianò  DIISM, Università di Siena, Siena, Italy<EMAIL_ADDRESS>Sara
Ugolini  Artificial Intelligence Research Institute (IIIA), CSIC, Barcelona,
Spain<EMAIL_ADDRESS>
###### Abstract.

In this work we study the notions of structural and universal completeness
both from the algebraic and logical point of view. In particular, we provide
new algebraic characterizations of quasivarieties that are actively and
passively universally complete, and passively structurally complete. We apply
these general results to varieties of bounded lattices and to quasivarieties
related to substructural logics. In particular we show that a substructural
logic satisfying weakening is passively structurally complete if and only if
every classical contradiction is explosive in it. Moreover, we fully
characterize the passive structurally complete varieties of
$\mathsf{MTL}$-algebras, i.e., bounded commutative integral residuated
lattices generated by chains.

##  1\. Introduction

The main aim of this paper is to explore some connections between algebra and
logic; mainly, we try to produce some bridge theorems. A bridge theorem is a
statement connecting logical (and mostly synctactical) features of deductive
systems and properties of classes of algebras; this connection is usually
performed using the tools of general algebra and the rich theory that is
behind it. The main reason behind this kind of exploration is in the further
understanding one can gain by connecting two apparently distant fields. In
this way, we can explore logical properties in purely algebraic terms; at the
same time statements can be imported from logic that have an important and
often new algebraic meaning.

The set of logical problems we want to explore is connected with the concept
of structural completeness of a deductive system, in the different ways it can
be declined. For a deductive system, being structurally complete means that
each of its proper extensions admits new theorems. This notion can be
formalized in a more rigorous way, using the concept of admissible rule. A
rule is admissible in a logic if, whenever there is a substitution making its
premises a theorem, such substitution also makes the conclusion a theorem. A
logic is then structurally complete if all its admissible rules are derivable
in the system. It is well-known that classical logic is structurally complete;
intuitionistic logic is not but it satisfies a weaker although still
interesting notion: it is passively structurally complete. We will see that
this is not just a feature of intuitionism but it can be explained in a much
more general framework, and it is connected to the way the contradictions of
classical logic are treated. In more details, passive structural completeness
means that all rules that do not apply to theorems are derivable. Naturally,
the dual notion of active structural completeness also arises, which instead
isolates the derivability of those rules for which there exists a substitution
making their premises a theorem. The latter notion has been explored in
generality in [35]. Structural completeness and its hereditary version have
been deeply studied in the literature: e.g., in general algebraic terms in
[13], in substructural logics in [68], in fuzzy logics in [29], in
intermediate logics in [30].

A natural extension of this kind of problems is to consider clauses instead of
rules. A clause is a formal pair $\Sigma\Rightarrow\Delta$, where both
$\Sigma$ and $\Delta$ are finite sets of formulas over a suitable language. A
clause is then admissible if a substitution making all the formulas in
$\Sigma$ into theorems makes at least one of the formulas in $\Delta$ a
theorem. Likewise, a clause is derivable if at least one of the formulas in
$\Delta$ is derivable from $\Sigma$. A logic is universally complete if every
admissible clause is derivable in it. It is then also possible to investigate
the situation in which admissible clauses are active or passive in a deductive
system, and thus the corresponding notions of universal completeness.
Universal completeness in connection to admissible clauses has been studied in
[22].

The way in which our bridge theorems will be created exploits the machinery of
the so-called Blok-Pigozzi connection [18]. Without going into details, this
machinery allows us to express purely logical concepts in an algebraic
language. The advantage of doing so is evident: on one hand we can use the
entire wealth of results about classes of algebras and various algebraic
operators. On the other hand, very often by mean of this translation one ends
up with algebraic results that are interesting in their own nature,
irregardless of their logical origin.

While not every logical system admits this translation, many interesting
and/or classical systems do: classical and intuitionistic logic, relevance
logics, substructural logics in general, many-valued logics, many modal logics
and so on. In this framework, one can translate the previously described
notions of structural and universal completeness into properties of the
quasiequational or universal theory of a quasivariety of algebras. In this
setting, we will rephrase the notions of interest not in terms of formulas,
but in terms of equations in a suitable language.

In this manuscript our aim is twofold; on one side we will try to describe in
a complete and organic way (as much as it is possible) the phenomena mentioned
above and the relations among them. In particular, we will recall the existing
results trying to put them in a coherent perspective, which we believe is
currently lacking, and we will provide many examples. On the other side, we
will provide new results and novel characterizations of those notions that are
missing an effective algebraic description. More specifically, we will first
show how the characterization of active structural completeness in [35] can be
extended to describe active universal completeness. Moreover, we will give
algebraic descriptions of the notions of passive universal and structural
completeness and the latter will result in an effective characterization. As a
particularly interesting consequence, we show that a substructural logic
satisfying the weakening rule is passively structurally complete if and only
if every contradiction of classical logic is explosive in it. This generalizes
and explains the passive structural completeness of intuitionistic logic.
Moreover, it entails that all substructural logics (with weakening) with the
Glivenko property with respect to classical logic are passively structurally
complete. Further specializing the general result, we build on it to provide a
clear characterization (and an axiomatization) of the minimal passive
structurally complete logic that is an axiomatic extension of the t-norm based
logic $\mathcal{MTL}$. From the algebraic side, this means that we
characterize the passive structurally complete quasivarieties of bounded
commutative integral residuated lattices generated by chains.

The techniques we will employ in our study are the ones proper of general
algebra. In particular, we will use the understanding of algebraic objects
such as projective and exact algebras. The same objects are known to be
relevant for the algebraic study of unification problems in algebraizable
logics [47]. In fact, we will show how the notion of unifiability of a set of
formulas (or, equivalently, a set of equations) plays a major role in our
results.

The structure of this manuscript is as follows. In the next section we will
discuss the needed preliminary notions. In particular, the Blok-Pigozzi
connection, projective and exact algebras, algebraic unification, and finally,
we define the notions of structural and universal completeness. Section 3 is
devoted to universal completeness, and Section 4 to structural completeness,
both in their various declinations. The last section is devoted to a deeper
understanding of some relevant examples from the realms of algebra and
(algebraic) logic respectively. In particular, in Subsection 5.1 we apply our
results to the variety of (bounded) lattices; finally, in Subsection 5.2, we
prove the aforementioned results and more about substructural logics.

##  2\. Preliminaries

###  2.1. Universal algebra and the Blok-Pigozzi connection

Let $\mathsf{K}$ be a class of algebras; we denote by
${\mathbf{I}},{\mathbf{H}},{\mathbf{P}},{\mathbf{S}},{\mathbf{P}}_{u}$ the
class operators sending $\mathsf{K}$ in the class of all isomorphic copies,
homomorphic images, direct products, subalgebras and ultraproducts of members
of $\mathsf{K}$. The operators can be composed in the obvious way; for
instance ${\mathbf{S}}{\mathbf{P}}(\mathsf{K})$ denotes all algebras that are
embeddable in a direct product of members of $\mathsf{K}$; moreover there are
relations among the classes resulting from applying operators in a specific
orders, for instance
${\mathbf{P}}{\mathbf{S}}(\mathsf{K})\subseteq{\mathbf{S}}{\mathbf{P}}(\mathsf{K})$
and ${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}(\mathsf{K})$ is the largest class we
can obtain composing the operators. We will use all the known relations
without further notice, but the reader can consult [69] or [21] for a textbook
treatment.

If $\rho$ is a type of algebras, an equation is a pair $p,q$ of $\rho$-terms
(i.e. elements of the absolutely free algebra ${\textbf{T}}_{\rho}(\omega)$)
that we write suggestively as $p\approx q$; a universal sentence or clause in
$\rho$ is a formal pair $(\Sigma,\Gamma)$ that we write as
$\Sigma\Rightarrow\Gamma$, where $\Sigma,\Gamma$ are finite sets of equations;
a universal sentence is a quasiequation if $|\Gamma|=1$ and it is is negative
if $\Delta=\emptyset$. Clearly an equation is a quasiequation in which
$\Sigma=\emptyset$.

Given any set of variables $X$, an assignment of $X$ into an algebra $A$ of
type $\rho$ is a function $h$ mapping each variable $x\in X$ to an element of
A, that extends (uniquely) to a homomorphism (that we shall also call $h$)
from the term algebra ${\textbf{T}}_{\rho}(\omega)$ to A. An algebra A
satisfies an equation $p\approx q$ with an assignment $h$ (and we write
${\textbf{A}},h\models p\approx q$) if $h(p)=h(q)$ in A. An equation $p\approx
q$ is valid in A (and we write ${\textbf{A}}\vDash p\approx q$) if for all
assignments $h$ in A, ${\textbf{A}},h\models p\approx q$; if $\Sigma$ is a set
of equations then ${\textbf{A}}\vDash\Sigma$ if ${\textbf{A}}\vDash\sigma$ for
all $\sigma\in\Sigma$. A universal sentence is valid in A (and we write
${\textbf{A}}\vDash\Sigma\Rightarrow\Delta$) if for all assignments $h$ to A,
$h(p)=h(q)$ for all $p\approx q\in\Sigma$ implies that there is an identity
$s\approx t\in\Delta$ with $h(s)=h(t)$; in other words a universal sentence
can be understood as the formula
$\forall\mathbf{x}(\bigwedge\Sigma\rightarrow\bigvee\Delta)$. An equation or a
universal sentence is valid in a class $\mathsf{K}$ if it is valid in all
algebras in $\mathsf{K}$.

A class of algebras is a variety if it is closed under
${\mathbf{H}},{\mathbf{S}}$ and ${\mathbf{P}}$, a quasivariety if it is closed
under ${\mathbf{I}}$,${\mathbf{S}}$,${\mathbf{P}}$ and ${\mathbf{P}}_{u}$ and
a universal class if it is closed under
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}$. The following facts were
essentially discovered by A. Tarski , J. Łòs and A. Lyndon in the pioneering
phase of model theory; for proof of this and similar statements the reader can
consult [26].

######  Lemma 2.1.

Let $\mathsf{K}$ be any class of algebras. Then:

  1. (1)

$\mathsf{K}$ is a universal class if and only if
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}(\mathsf{K})=\mathsf{K}$ if and only
if it is the class of algebras in which a set of universal sentences is valid;

  2. (2)

$\mathsf{K}$ is a quasivariety if and only if
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}{\mathbf{P}}_{u}(\mathsf{K})=\mathsf{K}$
if and only if it is the class of algebras in which a set of quasiequations is
valid;

  3. (3)

$\mathsf{K}$ is a variety if and only if
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}(\mathsf{K})=\mathsf{K}$ if and only if
it is the class of algebras in which a set of equations is valid.

######  Notation 1.

We will often write ${\mathbf{V}}$ for ${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}$
and ${\mathbf{Q}}$ for ${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}{\mathbf{P}}_{u}$.

For the definition of free algebras in a class $\mathsf{K}$ on a set $X$ of
generators, in symbols ${\textbf{F}}_{\mathsf{K}}(X)$, we refer to [21]; we
merely observe that every free algebra on a class $\mathsf{K}$ belongs to
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}(\mathsf{K})$. It follows that every free
algebra in $\mathsf{K}$ is free in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}(\mathsf{K})$ and therefore for any
quasivariety $\mathsf{Q}$,
${\textbf{F}}_{\mathsf{Q}}(X)={\textbf{F}}_{{\mathbf{V}}(\mathsf{Q})}(X)$.

There are two fundamental results that we will be using many times and deserve
a spotlight. Let ${\textbf{B}},({\textbf{A}}_{i})_{i\in I}$ be algebras in the
same signature; we say that B embeds in $\prod_{i\in I}{\textbf{A}}_{i}$ if
${\textbf{B}}\in{\mathbf{I}}{\mathbf{S}}(\prod_{i\in I}{\textbf{A}}_{i})$. Let
$p_{i}$ be the $i$-th projection, or better, the composition of the embedding
and the $i$-th projection, from B to ${\textbf{A}}_{i}$; the embedding is
subdirect if for all $i\in I$, $p_{i}({\textbf{B}})={\textbf{A}}_{i}$ and in
this case we will write

${\textbf{B}}\leq_{sd}\prod_{i\in I}{\textbf{A}}_{i}.$

An algebra B is subdirectly irreducible if it is nontrivial and for any
subdirect embedding

${\textbf{B}}\leq_{sd}\prod_{i\in I}{\textbf{A}}_{i}$

there is an $i\in I$ such that B and ${\textbf{A}}_{i}$ are isomorphic. It can
be shown that A is subdirectly irreducible if and only if the congruence
lattice $\operatorname{Con}({\textbf{A}})$ of A has a unique minimal element
different from the trivial congruence. If $\mathsf{V}$ is a variety we denote
by $\mathsf{V}_{si}$ the class of subdirectly irreducible algebras in
$\mathsf{V}$.

######  Theorem 2.2.

  1. (1)

(Birkhoff [16]) Every algebra can be subdirectly embedded in a product of
subdirectly irreducible algebras. So if ${\textbf{A}}\in\mathsf{V}$, then A
can be subdirectly embedded in a product of members of $\mathsf{V}_{si}$.

  2. (2)

(Jónsson’s Lemma [56]) Suppose that $\mathsf{K}$ is a class of algebras such
that $\mathsf{V}(\mathsf{K})$ is congruence distributive; then
$\mathsf{V}_{si}\subseteq{\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}(\mathsf{K})$.

If $\mathsf{Q}$ is a quasivariety and ${\textbf{A}}\in\mathsf{Q}$, a relative
congruence of A is a congruence $\theta$ such that
${\textbf{A}}/\theta\in\mathsf{Q}$; relative congruences form an algebraic
lattice $\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$. Moreover, for an algebra A
and a set $H\subseteq A\times A$ there exists the least relative congruence
$\theta_{\mathsf{Q}}(H)$ on A containing $H$. When $H=\\{(a,b)\\}$, we just
write $\theta_{\mathsf{Q}}(a,b)$. When $\mathsf{Q}$ is a variety we simplify
the notation by dropping the subscript $\mathsf{Q}$.

For any congruence lattice property $P$ we say that
${\textbf{A}}\in\mathsf{Q}$ is relative $P$ if
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ satisfies $P$. So for instance A is
relative subdirectly irreducible if $\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$
has a unique minimal element; since clearly
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is a meet subsemilattice of
$\operatorname{Con}({\textbf{A}})$, any subdirectly irreducible algebra is
relative subdirectly irreducible for any quasivariety to which it belongs. For
a quasivariety $\mathsf{Q}$ we denote by $\mathsf{Q}_{rsi}$ the class of
relative subdirectly irreducible algebras in $\mathsf{Q}$. We have the
equivalent of Birkhoff’s and Jónsson’s results for quasivarieties:

######  Theorem 2.3.

Let $\mathsf{Q}$ be any quasivariety.

  1. (1)

(Mal’cev [62]) Every ${\textbf{A}}\in\mathsf{Q}$ is subdirectly embeddable in
a product of algebras in $\mathsf{Q}_{rsi}$.

  2. (2)

(Czelakowski-Dziobiak [32]) If $\mathsf{Q}={\mathbf{Q}}(\mathsf{K})$, then
$\mathsf{Q}_{rsi}\subseteq{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}(\mathsf{K})$.

The following fact will be used in the sequel.

######  Lemma 2.4.

Let A be an algebra, such that ${\mathbf{V}}({\textbf{A}})$ is congruence
distributive. Then ${\mathbf{Q}}({\textbf{A}})={\mathbf{V}}({\textbf{A}})$ if
and only if every subdirectly irreducible algebra in
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})$ is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}{\textbf{A}}$.

###### Proof.

Suppose first that ${\mathbf{Q}}({\textbf{A}})={\mathbf{V}}({\textbf{A}})$,
and let A be a subdirectly irreducible algebra in
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})$. Thus A is
subdirectly irreducible in
${\mathbf{V}}({\textbf{A}})={\mathbf{Q}}({\textbf{A}})$, and by Theorem 2.3
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})$.

Conversely assume that every subdirectly irreducible algebra in
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})$ is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}{\textbf{A}}$. Since
${\mathbf{V}}({\textbf{A}})$ is congruence distributive, by Theorem 2.2(2)
every subdirectly irreducible algebra in ${\mathbf{V}}({\textbf{A}})$ is in
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})$, thus in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}{\textbf{A}}$. Now every algebra in
${\mathbf{V}}({\textbf{A}})$ is subdirectly embeddable in a product of
subdirectly irreducible algebras in ${\mathbf{V}}({\textbf{A}})$ (Theorem
2.2(1)). Therefore,
${\mathbf{V}}({\textbf{A}})\subseteq{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})\subseteq{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}{\mathbf{P}}_{u}({\textbf{A}})={\mathbf{Q}}({\textbf{A}})$
and thus equality holds. ∎

In this work we are particularly interested in quasivarieties that are the
equivalent algebraic semantics of a logic in the sense of Blok-Pigozzi [18].
We will spend some time illustrating the machinery of Abstract Algebraic Logic
that establishes a Galois connection between algebraizable logics and
quasivarieties of logic, since it is relevant to understand our results. For
the omitted details we refer the reader to [18, 40].

By a _logic_ $\mathcal{L}$ in what follows we mean a substitution invariant
consequence relation $\vdash$ on the set of terms
${\textbf{T}}_{\rho}(\omega)$ (also called _algebra of formulas_) of some
algebraic language $\rho$. In loose terms, to establish the algebraizability
of a logic $\mathcal{L}$ with respect to a quasivariety of algebras
$\mathsf{Q}_{\mathcal{L}}$ over the same language $\rho$, one needs a finite
set of one-variable equations

$\tau(x)=\\{\delta_{i}(x)\approx\varepsilon_{i}(x):i=1,\dots,n\\}$

over terms of type $\rho$ and a finite set of formulas of $\mathcal{L}$ in two
variables

$\Delta(x,y)=\\{\varphi_{1}(x,y),\dots,\varphi_{m}(x,y)\\}$

that allow to transform equations, quasiequations and universal sentences in
$\mathsf{Q}_{\mathcal{L}}$ into formulas, rules and clauses of $\mathcal{L}$;
moreover this transformation must respect both the consequence relation of the
logic and the semantical consequence of the quasivariety. More precisely, for
all sets of formulas $\Gamma$ of $\mathcal{L}$ and formulas
$\varphi\in{\textbf{T}}_{\rho}(\omega)$

$\Gamma\vdash_{\mathcal{L}}\varphi\quad\text{iff}\quad\tau(\Gamma)\vDash_{\mathsf{Q}_{\mathcal{L}}}\tau(\varphi)$

where $\tau(\Gamma)$ is a shorthand for $\\{\tau(\gamma):\gamma\in\Gamma\\}$,
and also

$(x\approx y)\Dashv\vDash_{\mathsf{Q}_{\mathcal{L}}}\tau(\Delta(x,y)).$

A quasivariety $\mathsf{Q}$ is a quasivariety of logic if it is the equivalent
algebraic semantics for some logic $\mathcal{L}_{\mathsf{Q}}$; the Galois
connection between algebraizable logics and quasivarieties of logic is given
by

$\mathcal{L}_{\mathsf{Q}_{\mathcal{L}}}=\mathcal{L}\qquad\qquad\mathsf{Q}_{\mathcal{L}_{\mathsf{Q}}}=\mathsf{Q}.$

Not every quasivariety is a quasivariety of logic; for instance no idempotent
quasivariety, such as any quasivariety of lattices, can be a quasivariety of
logics. Nonetheless quasivarieties of logic are plentiful. In fact any ideal
determined variety is such, as well as any quasivariety coming from a
congruential variety with normal ideals (see [9] for details). Moreover, every
quasivariety is categorically equivalent to a quasivariety of logic [65]. This
means that if an algebraic concept is expressible through notions that are
invariant under categorical equivalence, and it holds for a quasivariety
$\mathsf{Q}$, then it holds for its categorically equivalent quasivariety of
logic $\mathsf{Q}^{\prime}$; and hence in can be transformed into a logical
concept in $\mathcal{L}_{\mathsf{Q}^{\prime}}$ using the Blok-Pigozzi
connection.

######  Definition 2.5.

If $\mathsf{Q}$ is any quasivariety, with an abuse of notation, we will denote
by $\mathcal{L}_{\mathsf{Q}}$ a logic whose equivalent algebraic semantics is
categorically equivalent to $\mathsf{Q}$.

The following result hints at what kind of properties can be transferred by
categorical equivalence.

######  Theorem 2.6 ([12]).

Let $\mathsf{K}$ be a class closed under subalgebras and direct products; If
$\mathsf{K}$ is categorically equivalent to a quasivariety $\mathsf{Q}$, then
$\mathsf{K}$ is a quasivariety.

Suppose now that $\mathsf{Q}$ and $\mathsf{R}$ are quasivarieties and suppose
that $F:\mathsf{Q}\longrightarrow\mathsf{R}$ is a functor between the two
algebraic categories witnessing the categorical equivalence. Now, $F$
preserves all the so-called categorical properties, i.e., those notions that
can be expressed as properties of morphisms. In particular, embeddings are
mapped to embeddings (since in algebraic categories they are exactly the
categorical monomorphisms), surjective homomorphisms are mapped to surjective
homomorphisms (since they correspond to regular epimorphisms in the
categories). Moreover, we observe that direct products are preserved as well,
since they can be expressed via families of surjective homomorphisms (see e.g.
[21]). Therefore, if $\mathsf{Q}^{\prime}$ is a subquasivariety of
$\mathsf{Q}$, then the restriction of $F$ to $\mathsf{Q}^{\prime}$ witnesses a
categorical equivalence between $\mathsf{Q}^{\prime}$ and

$\mathsf{R}^{\prime}=\\{{\textbf{B}}\in\mathsf{R}:{\textbf{B}}=F({\textbf{A}})\
\text{for some ${\textbf{A}}\in\mathsf{Q}^{\prime}$}\\}.$

It follows from Theorem 2.6 that $\mathsf{R}^{\prime}$ is a subquasivariety of
$\mathsf{R}$, and that $\mathsf{R}^{\prime}$ is a variety whenever
$\mathsf{Q}^{\prime}$ is such. Given a quasivariety $\mathsf{Q}$, we denote by
$\Lambda_{q}(\mathsf{Q})$ the lattice of subquasivarieties of $\mathsf{Q}$.
Hence the correspondence sending
$\mathsf{Q}^{\prime}\longmapsto\mathsf{R}^{\prime}$ is a lattice isomorphism
between $\Lambda_{q}(\mathsf{Q})$ in $\Lambda_{q}(\mathsf{R})$ that preserves
all the categorical properties. Moreover, we observe that, since ultraproducts
in an algebraic category admit a categorical definition which turns out to be
equivalent to the algebraic one (see for instance [37]), the functor $F$ also
map universal subclasses to universal subclasses; more precisely,
$\mathsf{U}\subseteq\mathsf{Q}$ is a universal class if and only if
$F(\mathsf{U})\subseteq\mathsf{R}$ is a universal class.

Let us show an example of how we can use these correspondences, that is also a
preview of what we will see in the coming sections; if $\mathsf{Q}$ is a
quasivariety, a subquasivariety $\mathsf{Q}^{\prime}$ is equational in
$\mathsf{Q}$ if
$\mathsf{Q}^{\prime}={\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$. A
quasivariety is primitive if every subquasivariety of $\mathsf{Q}$ is
equational in $\mathsf{Q}$. It is clear from the discussion above that this
concept is preserved by categorical equivalence and that the lattice
isomorphism described above sends primitive subquasivarieties in primitive
subquasivarieties.

###  2.2. Projectivity, weak projectivity and exactness

We now introduce the algebraic notions that will be the key tools for our
investigation: projective, weakly projective, exact, and finitely presented
algebras.

######  Definition 2.7.

Given a class $\mathsf{K}$ of algebras, an algebra ${\textbf{A}}\in\mathsf{K}$
is projective in $\mathsf{K}$ if for all
${\textbf{B}},{\textbf{C}}\in\mathsf{K}$, any homomorphism
$h:{\textbf{A}}\longmapsto{\textbf{C}}$, and any surjective homomorphism
$g:{\textbf{B}}\longmapsto{\textbf{C}}$, there is a homomorphism
$f:{\textbf{A}}\longmapsto{\textbf{B}}$ such that $h=gf$.

ACB $h$$f$$g$

Determining the projective algebras in a class is usually a challenging
problem, especially in a general setting. If however $\mathsf{K}$ contains all
the free algebras on $\mathsf{K}$ (in particular, if $\mathsf{K}$ is a
quasivariety), projectivity admits a simpler formulation. We call an algebra B
a retract of an algebra A if there is a homomorphism
$g:{\textbf{A}}\longmapsto{\textbf{B}}$ and a homomorphism
$f:{\textbf{B}}\longmapsto{\textbf{A}}$ with $gf=\textrm{id}_{\textbf{B}}$
(and thus, necessarily, $f$ is injective and $g$ is surjective). The following
theorem was proved first by Whitman for lattices [75] but it is well-known to
hold for any class of algebras.

######  Theorem 2.8.

Let $\mathsf{Q}$ be a quasivariety. Then the following are equivalent:

  1. (1)

A is projective in $\mathsf{Q}$;

  2. (2)

A is a retract of a free algebra in $\mathsf{Q}$.

  3. (3)

A is a retract of a projective algebra in $\mathsf{Q}$.

In particular every free algebra in $\mathsf{Q}$ is projective in
$\mathsf{Q}$.

######  Definition 2.9.

Given a quasivariety $\mathsf{Q}$ we say that an algebra is finitely presented
in $\mathsf{Q}$ if there exists a finite set $X$ and a finite set $H$ of pairs
of terms over $X$ such that
${\textbf{A}}\cong{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(H)$.

The proof of the following theorem is standard (but see [47]).

######  Theorem 2.10.

For a finitely presented algebra ${\textbf{A}}\in\mathsf{Q}$ the following are
equivalent:

  1. (1)

A is projective in $\mathsf{Q}$;

  2. (2)

A is projective in the class of all finitely presented algebras in
$\mathsf{Q}$;

  3. (3)

A is a retract of a finitely generated free algebra in $\mathsf{Q}$.

As a consequence we stress that if $\mathsf{Q}$ is a quasivariety and
$\mathsf{V}={\mathbf{V}}(\mathsf{Q})$ then all the algebras that are
projective in $\mathsf{Q}$ are also projective in $\mathsf{V}$ (and vice
versa). Moreover, all the finitely generated projective algebras in
$\mathsf{Q}$ lie inside ${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

######  Definition 2.11.

An algebra A is weakly projective in an algebra B if
${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$ implies
${\textbf{A}}\in{\mathbf{S}}({\textbf{B}})$; an algebra is _weakly projective
in a class $\mathsf{K}$_ if it is weakly projective in any algebra
${\textbf{B}}\in\mathsf{K}$.

######  Definition 2.12.

If $\mathsf{Q}$ is a quasivariety of algebras and ${\textbf{A}}\in\mathsf{Q}$,
let $G_{\textbf{A}}$ be the set of generators of A; A is exact in $\mathsf{Q}$
if it is weakly projective in some ${\textbf{F}}_{\mathsf{Q}}(X)$ with
$|X|\geq|G_{\textbf{A}}|$.

Clearly any projective algebra in $\mathsf{Q}$ is weakly projective in
$\mathsf{Q}$ and any weakly projective algebra in $\mathsf{Q}$ is exact in
$\mathsf{Q}$.

Observe also the following consequence of the definition.

######  Lemma 2.13.

Let $\mathsf{Q}$ be a quasivariety and let A be a finitely generated algebra
in $\mathsf{Q}$; then the following are equivalent:

  1. (1)

A is exact in $\mathsf{Q}$;

  2. (2)

${\textbf{A}}\in{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

Therefore for finitely generated algebras our definition of exactness
coincides with the one in [23]. We close this subsection with a couple of
results connecting projectivity and weak projectivity.

######  Proposition 2.14.

Let A be a finite subdirectly irreducible algebra; if A is weakly projective
in ${\mathbf{Q}}({\textbf{A}})$, then it is projective in
${\mathbf{Q}}({\textbf{A}})$.

###### Proof.

Let $\mathsf{Q}={\mathbf{Q}}({\textbf{A}})$; since A is finite, $\mathsf{Q}$
is locally finite. Let F be a finitely generated (hence finite) free algebra
in $\mathsf{Q}$ such that ${\textbf{A}}\in{\mathbf{H}}({\textbf{F}})$; since A
is weakly projective, A is embeddable in F and without loss of generality we
may assume that ${\textbf{A}}\leq{\textbf{F}}$. Consider the set

$V=\\{\alpha\in\textrm{Con}_{\mathsf{Q}}({\textbf{F}}):\alpha\cap
A^{2}=0_{\textbf{A}}\\},$

where we denote by $0_{{\textbf{A}}}$ the minimal congruence of A. It is easy
to see that $V$ is an inductive poset so we may apply Zorn’s Lemma to find a
maximal congruence $\theta\in V$. Clearly $a\longmapsto a/\theta$ is an
embedding of A into ${\textbf{F}}/\theta$. We claim that ${\textbf{F}}/\theta$
is relative subdirectly irreducible and to prove so, since everything is
finite, it is enough to show that $\theta$ is meet irreducible in
$\textrm{Con}_{\mathsf{Q}}({\textbf{F}})$; so let
$\alpha,\beta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ such that
$\alpha\wedge\beta=\theta$. Then

$0_{\textbf{A}}=\theta\cap A^{2}=(\alpha\wedge\beta)\cap A^{2}=(\alpha\cap
A^{2})\wedge(\beta\cap A^{2});$

But A is subdirectly irreducible, so $0_{A}$ is meet irreducible in
$\textrm{Con}({\textbf{A}})$; hence either $\alpha\cap A^{2}=0_{\textbf{A}}$
or $\beta\cap A^{2}=0_{\textbf{A}}$, so either $\alpha\in V$ or $\beta\in V$.
Since $\theta$ is maximal in $V$, either $\alpha=\theta$ or $\beta=\theta$,
which proves that ${\textbf{F}}/\theta$ is relative subdirectly irreducible.
Therefore, by Theorem 2.3(2),
${\textbf{F}}/\theta\in{\mathbf{I}}{\mathbf{S}}({\textbf{A}})$; since
${\textbf{F}}/\theta$ and A are both finite and each one is embeddable in the
other, they are in fact isomorphic. Thus ${\textbf{A}}\leq{\textbf{F}}$, and
there is a homomorphism from F onto A that maps each $a\in A$ to itself. This
shows that A is a retract of F, and therefore A is projective in
${\mathbf{Q}}({\textbf{A}})$. ∎

For varieties we have to add the hypothesis of congruence distributivity,
since the use of Theorem 2.2(2) is paramount; for the very similar proof see
[53, Theorem 9].

######  Proposition 2.15.

Let A be a finite subdirectly irreducible algebra such that
${\mathbf{V}}({\textbf{A}})$ is congruence distributive; if A is weakly
projective in ${\mathbf{V}}({\textbf{A}})$, then it is projective in
${\mathbf{V}}({\textbf{A}})$.

We observe that in algebraic categories projectivity is a property preserved
by categorical equivalence and the same holds for weak projectivity and
exactness. Finally by [42] being finitely presented and being finitely
generated are also categorical properties preserved by equivalences.

###  2.3. Algebraic unification

The main objects of our study, i.e., the notions of universal and structural
completeness, are closely related to unification problems. The classical
syntactic unification problem given two term $s,t$ finds a unifier for them;
that is, a uniform replacement of the variables occurring in $s$ and $t$ by
other terms that makes $s$ and $t$ identical. When the latter syntactical
identity is replaced by equality modulo a given equational theory $E$, one
speaks of $E$-unification. S. Ghilardi [47] proved that there is a completely
algebraic way of studying ($E$-)unification problems in varieties of logic,
which makes use of finitely presented and projective algebras and thus is
invariant under categorical equivalence.

Let us discuss Ghilardi’s idea in some detail showing how it can be applied to
quasivarieties. If $\mathsf{Q}$ is a quasivariety and $\Sigma$ is a finite set
of equations in the variables $X=\\{x_{1},\dots,x_{n}\\}$ by a substitution
$\sigma$ we mean an assignment from $X$ to
${\textbf{F}}_{\mathsf{Q}}(\omega)$, extending to a homomorphism from
${\textbf{F}}_{\mathsf{Q}}(X)$ to ${\textbf{F}}_{\mathsf{Q}}(\omega)$.

######  Definition 2.16.

A unification problem for a quasivariety $\mathsf{Q}$ is a finite set of
identities $\Sigma$ in the language of $\mathsf{Q}$; $\Sigma$ is unifiable in
$\mathsf{Q}$ if there is a substitution $\sigma$ such that
$\mathsf{Q}\vDash\sigma(\Sigma)$, i.e.

$\mathsf{Q}\vDash p(\sigma(x_{1}),\dots,\sigma(x_{n}))\approx
q(\sigma(x_{1}),\dots,\sigma(x_{n}))$

for all $p\approx q\in\Sigma$. The substitution $\sigma$ is called a unifier
for $\Sigma$.

Observe that $\Sigma$ is unifiable in $\mathsf{Q}$ if and only if it is
unifiable in ${\mathbf{V}}(\mathsf{Q})$. Let us now present the algebraic
approach, where a unification problem can be represented by a finitely
presented algebra in $\mathsf{Q}$.

######  Definition 2.17.

If A is in $\mathsf{Q}$, a unifier for A is a homomorphism
$u:{\textbf{A}}\longrightarrow{\textbf{P}}$ where P is a projective algebra in
$\mathsf{Q}$; we say that an algebra is unifiable in $\mathsf{Q}$ if at least
one such homomorphism exists. A quasivariety $\mathsf{Q}$ is unifiable if
every finitely presented algebra in $\mathsf{Q}$ is unifiable.

######  Notation 2.

When we write ${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$,
$\theta_{\mathsf{Q}}(\Sigma)$ is the relative congruence generated in
${\textbf{F}}_{\mathsf{Q}}(X)$ by the set $\\{(p,q):p\approx q\in\Sigma\\}$.

The following summarizes the needed results of [47] applied to quasivarieties.

######  Theorem 2.18.

Let $\mathsf{Q}$ be a quasivariety, and let $\Sigma$ be a finite set of
equations in the language of $\mathsf{Q}$ with variables in a (finite) set
$X$; then:

  1. (1)

if $\Sigma$ is unifiable via
$\sigma:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}(Y)$ then
$u_{\sigma}:{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\to{\textbf{F}}_{\mathsf{Q}}(Y)$
defined by

$u_{\sigma}(t/\theta_{\mathsf{Q}}(\Sigma))=\sigma(t)$

is a unifier for ${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$;

  2. (2)

conversely let
${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$. If
there is a unifier $u:{\textbf{A}}\to{\textbf{P}}$, where P is projective and
a retract of ${\textbf{F}}_{\mathsf{Q}}(Y)$ witnessed by an embedding
$i:{\textbf{P}}\to{\textbf{F}}_{\mathsf{Q}}(Y)$, the substitution

$\sigma_{u}:x\longmapsto i(u(x/\theta_{\mathsf{Q}}(\Sigma)))$

is a unifier for $\Sigma$ in $\mathsf{Q}$.

###### Proof.

For the first claim, consider
$\sigma:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}(Y)$ and the
natural epimorphism
$\pi_{\Sigma}:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$.
Since $\theta_{\mathsf{Q}}(\Sigma)$ is the least congruence of
${\textbf{F}}_{\mathsf{Q}}(X)$ containing the set of pairs
$S=\\{(p,q):p\approx q\in\Sigma\\}$, and given that $S\subseteq\ker(\sigma)$,
by the Second Homomorphism Theorem we can close the following diagram with
exactly the homomorphism $u_{\sigma}$:

${\textbf{F}}_{\mathsf{Q}}(X)$${\textbf{F}}_{\mathsf{Q}}(Y)$${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$$\sigma$$u_{\sigma}$$\pi_{\Sigma}$

The second claim is easily seen, since $\sigma_{u}$ is defined by a
composition of homomorphism and as above the set of pairs $S=\\{(p,q):p\approx
q\in\Sigma\\}$ is contained in its kernel, which yields that $\sigma_{u}$ is a
unifier for $\Sigma$ in $\mathsf{Q}$. ∎

######  Corollary 2.19.

A finite set of identities $\Sigma$ is unifiable in $\mathsf{Q}$ if and only
if the finitely presented algebra
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is unifiable in
$\mathsf{Q}$.

The following observation shows how to characterize unifiability in
quasivarieties.

######  Definition 2.20.

For a quasivariety $\mathsf{Q}$, we let ${\textbf{F}}_{\mathsf{Q}}$ be the
smallest free algebra, i.e. ${\textbf{F}}_{\mathsf{Q}}(\emptyset)$ (if there
are constant operations) or else ${\textbf{F}}_{\mathsf{Q}}(x)$.

We have the following :

######  Lemma 2.21.

Let $\mathsf{Q}$ be a quasivariety and let ${\textbf{A}}\in\mathsf{Q}$. Then
the following are equivalent:

  1. (1)

A is unifiable in $\mathsf{Q}$;

  2. (2)

there is a homomorphism from A to ${\textbf{F}}_{\mathsf{Q}}$.

###### Proof.

Note that (2) trivially implies (1), since ${\textbf{F}}_{\mathsf{Q}}$ is
projective. Vice versa, if A is unifiable, there is a homomorphism from A to
some projective algebra P. Since P is a retract of some free algebra in
$\mathsf{Q}$, and ${\textbf{F}}_{\mathsf{Q}}$ is a homomorphic image of every
free algebra in $\mathsf{Q}$, the claim follows. ∎

The above lemma implies for instance that if ${\textbf{F}}_{\mathsf{Q}}$ is
trivial, then $\mathsf{Q}$ is unifiable since every algebra admits a
homomorphism onto a trivial algebra. Hence, examples of unifiable algebras
include lattices, groups, lattice-ordered abelian groups, residuated lattices.
On the other hand, both bounded lattices and bounded residuated lattices
(explored in Subsection 5.1 and 5.2 respectively) are unifiable if and only if
they admit a homomorphism onto the algebra (over the appropriate signature)
with two elements $0$ and $1$.

We observe in passing that if
${\textbf{A}}\cong{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}$ is
finitely presented unifiable algebra in $\mathsf{Q}$, witnessed by a unifier
$u:{\textbf{A}}\longrightarrow{\textbf{P}}$, then $u$ can be split into a
homomorphism onto its image $u({\textbf{A}})$, and an embedding from
$u({\textbf{A}})$ to P. By the Third Homomorphism Theorem there is a
$\theta^{\prime}\in\textrm{Con}({\textbf{F}}_{\mathsf{Q}}(X))$ corresponding
to the kernel of the onto homomorphism $u:{\textbf{A}}\longrightarrow
u({\textbf{A}})$, $\theta^{\prime}\geq\theta$, such that
${\textbf{F}}_{\mathsf{V}}(X)/\theta^{\prime}$ embeds in P; note that
$\theta^{\prime}\in\textrm{Con}_{\mathsf{Q}}({\textbf{F}}_{\mathsf{Q}}(X))$,
since ${\textbf{P}}\in\mathsf{Q}$. The diagram in Figure 1 shows that indeed
${\textbf{F}}_{\mathsf{V}}(X)/\theta^{\prime}$ is exact.

${\textbf{F}}_{\mathsf{V}}(X)/\theta$${\textbf{F}}_{\mathsf{V}}(X)/\theta^{\prime}$P${\textbf{F}}_{\mathsf{V}}(\omega)$
Figure 1.

Let us now introduce the usual notion of order among unifiers. Given two
unifiers $u_{1},u_{2}$ for A we say that $u_{1}$ is less general then $u_{2}$
(and we write $u_{1}\preceq u_{2}$), if there is a homomorphism $h$ that makes
the following diagram commute.

A${\textbf{P}}_{2}$${\textbf{P}}_{1}$$u_{2}$$u_{1}$$h$

Clearly $\preceq$ is a preordering and so the equivalence classes of the
associated equivalence relation (i.e. the unifiers that are equally general)
form a poset $U_{\textbf{A}}$; using the maximal sets of that poset it is
possible to define a hierarchy of unification types (see [47]). In particular,
the unification type is _unitary_ if there is one maximal element, that is
called the most general unifier or mgu.

######  Definition 2.22.

We say that a quasivariety $\mathsf{Q}$ has projective unifiers if every
finitely presented unifiable algebra in $\mathsf{Q}$ is projective, and that
it has exact unifiers if every finitely presented unifiable algebra in
$\mathsf{Q}$ is exact.

If $\mathsf{Q}$ has projective unifiers, then (from the algebraic perspective)
the identity map is a unifier, and it is also the most general unifier. Next
we have a lemma whose proof is straightforward (modulo Lemma 2.21).

######  Lemma 2.23.

Let $\mathsf{Q}$ be a quasivariety; then the following are equivalent:

  1. (1)

$\mathsf{Q}$ has projective (exact) unifiers;

  2. (2)

for any finitely presented ${\textbf{A}}\in\mathsf{Q}$, A has
${\textbf{F}}_{\mathsf{Q}}$ as a homomorphic image if and only if A is
projective (exact).

If $\mathsf{Q}$ is locally finite, then we have a necessary and sufficient
condition.

######  Lemma 2.24.

Let $\mathsf{Q}$ be a locally finite quasivariety of finite type, then the
following are equivalent:

  1. (1)

$\mathsf{Q}$ has projective unifiers;

  2. (2)

every finite unifiable algebra in $\mathsf{Q}$ is projective in the class of
finite algebras in $\mathsf{Q}$.

###### Proof.

(1) implies (2) is obvious. Assume (2), let A be unifiable and finite and let
${\textbf{B}}\in\mathsf{Q}$ such that
$f:{\textbf{B}}\longrightarrow{\textbf{A}}$ is a onto homomorphism. Let
$a_{1},\dots,a_{n}$ be the generators of A and let $b_{1},\dots,b_{n}\in B$
with $f(b_{i})=a_{i}$ for $i=1\ldots n$; if ${\textbf{B}}^{\prime}$ is the
subalgebra generated by $b_{1},\dots,b_{n}$ then $f$ restricted to
${\textbf{B}}^{\prime}$ is onto. Clearly ${\textbf{B}}^{\prime}$ is finite.
Hence by hypothesis there exists a $g:{\textbf{A}}\longrightarrow{\textbf{B}}$
such that $fg$ is the identity on A. This shows that A is projective in B and
hence in $\mathsf{Q}$. Thus (1) holds. ∎

Having exact unifiers is weaker than having projective unifiers:

######  Example 2.25.

The variety $\mathsf{D}$ of distributive lattices is unifiable since it has no
constants and it is idempotent; hence its least free algebra is trivial. But
$\mathsf{D}$ does note have projective unifiers: a distributive lattice is
projective if and only if the meet of join irreducible elements is again join
irreducible [11], so there are finite non projective distributive lattices.
However every finitely presented (i.e. finite) distributive lattice is exact
[22].

######  Example 2.26.

A different example is the variety of $\mathsf{ST}$ of Stone algebras; a Stone
algebra is a pseudocomplemented bounded distributive lattice in the signature
$(\land,\lor,*,0,1)$ such that $x^{*}\lor x^{**}\approx 1$ holds. A Stone
algebra is unifiable if and only if is has a homomorphism into the two element
Boolean algebra if and only if it is nontrivial. While there are nontrivial
Stone algebras that are not projective, any nontrivial Stone algebra is exact
([22, Lemma 17]). Hence $\mathsf{ST}$ has exact unifiers.

Moreover, there are examples of varieties having a most general unifier that
do not have projective unifiers.

######  Example 2.27.

From the results in [48], the variety $\mathsf{SH}$ of Stonean Heyting
algebras (that is, Heyting algebras such that $\neg x\lor\neg\neg x\approx 1$
holds) is such that every unifiable algebra ${\textbf{A}}\in\mathsf{SH}$ has a
most general unifier. However, $\mathsf{SH}$ does not have projective
unifiers. The algebra ${\textbf{F}}_{\mathsf{SH}}(x,y,z)/\theta$, where
$\theta$ is the congruence generated by the pair $(\neg x\rightarrow(y\vee
z),1)$, is unifiable but not projective. We observe that Ghilardi’s argument
relies heavily on some properties of Heyting algebras and uses Kripke models,
making it difficult to generalize.

Trivial examples show that having projective or exact unifiers is not
inherited in general by subvarieties (see for instance [35, Example 7.2]). The
following lemma (that we extract from [35, Lemma 5.4]) gives a sufficient
condition for having projective unifiers. We write a detailed proof for the
reader’s convenience.

######  Lemma 2.28 ([35]).

Let $\mathsf{Q}$ be a quasivariety and let $\mathsf{Q}^{\prime}$ be a
subquasivariety of $\mathsf{Q}$ such that if
${\textbf{B}}={\textbf{F}}_{\mathsf{Q}^{\prime}}(X)/\theta_{\mathsf{Q}^{\prime}}(\Sigma)$
is finitely presented and unifiable in $\mathsf{Q}^{\prime}$, then
${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is
unifiable in $\mathsf{Q}$. If $\mathsf{Q}$ has projective unifiers then
$\mathsf{Q}^{\prime}$ has projective unifiers.

###### Proof.

It is an easy exercise in general algebra to show that if
$\Theta=\bigcap\\{\theta\in\textrm{Con}({\textbf{F}}_{\mathsf{Q}}(X)):{\textbf{F}}_{\mathsf{Q}}(X)/\theta\in\mathsf{Q}^{\prime}\\}$
then

${\textbf{F}}_{\mathsf{Q}^{\prime}}(X)/\theta_{\mathsf{Q}^{\prime}}(\Sigma)\cong{\textbf{F}}_{\mathsf{Q}}(X)/(\theta_{\mathsf{Q}}(\Sigma)\vee\Theta).$

It follows that B is a homomorphic image of A via the natural surjection

$p:a/\theta_{\mathsf{Q}}(\Sigma)\longmapsto
a/(\theta_{\mathsf{Q}}(\Sigma)\vee\Theta)$

composed with the isomorphism. Moreover if
$f:{\textbf{A}}\longrightarrow{\textbf{C}}$ is a homomorphism and
${\textbf{C}}\in\mathsf{Q}^{\prime}$, then
$\textrm{ker}(p)\leq\textrm{ker}(f)$ and by the Second Homomorphism Theorem
there is a $f^{\prime}:{\textbf{B}}\longrightarrow{\textbf{C}}$ with
$f^{\prime}p=f$.

Now let
${\textbf{B}}={\textbf{F}}_{\mathsf{Q}^{\prime}}/\theta_{\mathsf{Q}^{\prime}}(\Sigma)$
be finitely presented and unifiable and let
${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$; then
A is finitely presented and unifiable as well, so, since $\mathsf{Q}$ has
projective unifiers, A is projective in $\mathsf{Q}$. We now show that B is
projective. Suppose there are algebras
${\textbf{C}},{\textbf{D}}\in\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$ and
homomorphisms $h:{\textbf{B}}\to{\textbf{D}},g:{\textbf{C}}\to{\textbf{D}}$
with $g$ surjective. Then, there is a homomorphism
$hp:{\textbf{A}}\to{\textbf{D}}$, and since A is projective by the definition
of projectivity there is a homomorphism $f:{\textbf{A}}\to{\textbf{C}}$ such
that $gf=hp$. Factoring $f$ as above, there is $f^{\prime}$ such that
$f^{\prime}p=f$. Therefore since $gf^{\prime}p=gf=hp$ and $p$ is surjective,
we get that $gf^{\prime}=h$ which means that B is projective in
$\mathsf{Q}^{\prime}$. ∎

We will see later in Section 3.2 (Example 3.29) that Lemma 2.28 does not hold
with “projective unifiers” replaced by “exact unifiers”. We can build on the
previous lemma and obtain the following.

######  Lemma 2.29.

Suppose that $\mathsf{Q}$ is a quasivariety such that
${\textbf{F}}_{\mathsf{Q}}={\textbf{F}}_{\mathsf{Q}^{\prime}}$ for all
$\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$. If $\mathsf{Q}$ has projective
unifiers, then every subquasivariety $\mathsf{Q}^{\prime}$ has projective
unifiers.

###### Proof.

Let $\mathsf{Q}^{\prime}$ be a subquasivariety of $\mathsf{Q}$, let
${\textbf{B}}={\textbf{F}}_{\mathsf{Q}^{\prime}}(X)/\theta(\Sigma)$ be
finitely presented and unifiable in $\mathsf{Q}^{\prime}$ and let
${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta(\Sigma)$. Then B is a
homomorphic image of A and, since B is unifiable there is a homomorphism from
B to ${\textbf{F}}_{\mathsf{Q}^{\prime}}={\textbf{F}}_{\mathsf{Q}}$. Hence A
is unifiable as well; hence the hypothesis of Lemma 2.28 are satisfied, and so
$\mathsf{Q}^{\prime}$ has projective unifiers. ∎

We close this subsection with a corollary appearing also in [35] that is
useful to some examples we will explore in what follows. We reproduce the easy
proof for the reader’s convenience.

######  Corollary 2.30.

Let $\mathsf{Q}$ be a quasivariety and let
${\mathbf{V}}(\mathsf{Q})=\mathsf{V}$; if $\mathsf{V}$ has exact (projective)
unifiers, then so does $\mathsf{Q}$.

###### Proof.

First recall that $\mathsf{Q}$ and $\mathsf{V}$ have the same free algebras.
Let ${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{V}}(\Sigma)$
and ${\textbf{B}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$;
if B is unifiable then, as B is a homomorphic image of A via the epimorphism
$p$ described in the proof of Lemma 2.28, A is unifiable as well hence it is
exact. Therefore there is an embedding
$u:{\textbf{A}}\longrightarrow{\textbf{F}}_{\mathsf{Q}}(\omega)$; then by (the
proof of) Lemma 2.28 there is a
$g:{\textbf{B}}\longrightarrow{\textbf{F}}_{\mathsf{Q}}(\omega)$ with $gp=u$.
Since $u$ is injective, so is $p$ and hence A and B are isomorphic. This
proves the thesis. ∎

###  2.4. Structural and universal completeness

We now introduce the main notions of interest of this work, that is,
structural and universal completeness.

Let $\mathcal{L}$ be a logic with consequence relation $\vdash$. We call
clause of $\mathcal{L}$ an ordered pair $(\Sigma,\Gamma)$ where
$\Sigma,\Gamma$ are finite sets of formulas. We usually write a clause as
$\Sigma\Rightarrow\Gamma$. A rule is a clause $\Sigma\Rightarrow\Gamma$ where
$\Gamma=\\{\gamma\\}$. A rule is admissible in a logic if, when added to its
calculus, it does not produce new theorems. More precisely:

######  Definition 2.31.

A clause $\Sigma\Rightarrow\Delta$ is admissible in a logic $\mathcal{L}$ if
every substitution making all the formulas in $\Sigma$ a theorem, also makes
at least one of the formulas in $\Delta$ a theorem.

Moreover, we say that a clause $\Sigma\Rightarrow\Delta$ is derivable in a
logic $\mathcal{L}$ if $\Sigma\vdash\delta$ for some $\delta\in\Delta$. An
admissible clause is not necessarily derivable; a popular example is Harrop’s
rule for intuitionistic logic

$\\{\neg p\rightarrow(q\vee r)\\}\ \Rightarrow\ \\{(\neg p\rightarrow
q)\vee(\neg p\rightarrow r)\\}$

which is admissible but not derivable.

######  Definition 2.32.

Let $\mathcal{L}$ be a logic. A clause $\Sigma\Rightarrow\Gamma$ is passive in
$\mathsf{Q}$ if there is no substitution making the premises $\Sigma$ a
theorem of $\mathcal{L}$; a clause is active otherwise. Finally, a clause
$\Sigma\Rightarrow\Delta$ is negative if $\Delta=\emptyset$.

We observe that every admissible negative clause is necessarily passive.

######  Definition 2.33.

A logic is said to be

  1. $\bullet$

universally complete if every admissible clause is derivable;

  2. $\bullet$

structurally complete if every admissible rule is derivable;

  3. $\bullet$

actively universally complete if every active admissible clause is derivable;

  4. $\bullet$

actively structurally complete if every active admissible rule is
derivable111Logics with this property have been more often called almost
structurally complete but here we follow A. Citkin’s advice (see [35, footnote
2, page 8]).

  5. $\bullet$

passively universally complete if every passive admissible clause is
derivable;

  6. $\bullet$

passively structurally complete if every passive admissible rule is derivable;

  7. $\bullet$

non negatively universally complete if every non negative admissible clause is
derivable.

Modulo algebraizability, one obtains the corresponding notions for a
quasivariety. In particular, we can express admissibility and derivability of
clauses in $\mathcal{L}_{\mathsf{Q}}$ using the (quasi)equational logic of
$\mathsf{Q}$; this is because the Blok-Pigozzi Galois connection transforms
(sets of) formulas in $\mathcal{L}_{\mathsf{Q}}$ into (sets of) equations in
$\mathsf{Q}$ in a uniform way. The obtained notions make sense for
quasivarieties that do not necessarily correspond to a logic.

######  Definition 2.34.

Let $\mathsf{Q}$ be a quasivariety. A universal sentence
$\Sigma\Rightarrow\Delta$ is admissible in $\mathsf{Q}$ if every substitution
unifying all the identities in $\Sigma$ also unifies at least one of the
identities in $\Delta$. A universal sentence is passive if there is no
substitution unifying its premises, active otherwise. $\mathsf{Q}$ is
(active/passive) universally/structurally complete  if every (active/passive)
admissible universal sentence/quasiequation is valid in $\mathsf{Q}$.

If $P$ is one of those properties, then we say that a logic (or a
quasivariety) is hereditarily $P$ if the logic (or the quasivariety) and all
its extensions have the property $P$. Some of these properties are well-known
to be distinct: for instance classical logic is non-negative universally
complete but not universally complete, while intuitionistic logic is not
structurally complete (thanks to Harrop’s example) but it is passively
structurally complete (as reported by Wronski in 2005, see [29]). The
following is a consequence of algebraizability.

######  Theorem 2.35.

Let $\mathsf{Q}$ be a quasivariety of logic, $\Sigma,\Delta$ sets of equations
in the language of $\mathsf{Q}$ and $\Sigma^{\prime},\Delta^{\prime}$ the
corresponding sets of formulas in $\mathcal{L}_{\mathsf{Q}}$. Then:

  1. (1)

$\Sigma^{\prime}\Rightarrow\Delta^{\prime}$ is admissible in
$\mathcal{L}_{\mathsf{Q}}$ if and only if $\Sigma\Rightarrow\Delta$ is
admissible in $\mathsf{Q}$;

  2. (2)

$\Sigma^{\prime}\Rightarrow\Delta^{\prime}$ is derivable in
$\mathcal{L}_{\mathsf{Q}}$ if and only if
$\mathsf{Q}\vDash\Sigma\Rightarrow\Delta$.

Moreover, by Corollary 2.19 we get the following.

######  Proposition 2.36.

Let $\mathsf{Q}$ be a quasivariety of logic, $\Sigma,\Delta$ sets of equations
in the language of $\mathsf{Q}$ and $\Sigma^{\prime},\Delta^{\prime}$ the
corresponding sets of formulas in $\mathcal{L}_{\mathsf{Q}}$. Then:

  1. (1)

$\Sigma^{\prime}\Rightarrow\Delta^{\prime}$ is active in
$\mathcal{L}_{\mathsf{Q}}$ if and only if
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is unifiable in
$\mathsf{Q}$;

  2. (2)

$\Sigma^{\prime}\Rightarrow\Delta^{\prime}$ is passive in
$\mathcal{L}_{\mathsf{Q}}$ if and only if
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is not unifiable in
$\mathsf{Q}$.

The next lemma (also derivable from [22, Theorem 2]) characterizes
admissibility of universal sentences.

######  Lemma 2.37.

Let $\mathsf{Q}$ be any quasivariety, let $\Sigma\Rightarrow\Delta$ be a
clause in the language of $\mathsf{Q}$ and let
$\mathsf{U}_{\Sigma\Rightarrow\Delta}=\\{{\textbf{A}}\in\mathsf{Q}:{\textbf{A}}\vDash\Sigma\Rightarrow\Delta\\}$.
Then the following are equivalent:

  1. (1)

$\Sigma\Rightarrow\Delta$ is admissible in $\mathsf{Q}$;

  2. (2)

${\textbf{F}}_{\mathsf{Q}}(\omega)\vDash\Sigma\Rightarrow\Delta$;

  3. (3)

${\mathbf{H}}(\mathsf{Q})={\mathbf{H}}(\mathsf{U}_{\Sigma\Rightarrow\Delta})$.

###### Proof.

The equivalence between (1) and (2) follows directly from the definition of
admissibility. Assume now
${\textbf{F}}_{\mathsf{Q}}(\omega)\vDash\Sigma\Rightarrow\Delta$, then
${\textbf{F}}_{\mathsf{Q}}(\omega)\in\mathsf{U}_{\Sigma\Rightarrow\Delta}$.
Clearly
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))\subseteq{\mathbf{H}}(\mathsf{U}_{\Sigma\Rightarrow\Delta})\subseteq{\mathbf{H}}(\mathsf{Q})$.
Now every algebra is embeddable in an ultraproduct of its finitely generated
subalgebras and every finitely generated algebra is a homomorphic image of
${\textbf{F}}_{\mathsf{Q}}(\omega)$. Therefore if ${\textbf{A}}\in\mathsf{Q}$,
then
${\textbf{A}}\in{\mathbf{S}}{\mathbf{P}}_{u}{\mathbf{H}}({\textbf{F}}_{\mathsf{Q}}(\omega))\subseteq{\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.
So
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))={\mathbf{H}}(\mathsf{Q})$
and thus (3) holds.

Conversely assume (3). Since
${\textbf{F}}_{\mathsf{Q}}(\omega)\in{\mathbf{H}}(\mathsf{Q})={\mathbf{H}}(\mathsf{U}_{\Sigma\Rightarrow\Delta})$,
there is ${\textbf{A}}\in\mathsf{U}_{\Sigma\Rightarrow\Delta}$ such that
${\textbf{F}}_{\mathsf{Q}}(\omega)\in{\mathbf{H}}({\textbf{A}})$. Since
${\textbf{F}}_{\mathsf{Q}}(\omega)$ is projective in $\mathsf{Q}$, it follows
that
${\textbf{F}}_{\mathsf{Q}}(\omega)\in{\mathbf{S}}({\textbf{A}})\subseteq{\mathbf{S}}(\mathsf{U}_{\Sigma\Rightarrow\Delta})\subseteq\mathsf{U}_{\Sigma\Rightarrow\Delta}$.
Therefore, ${\textbf{F}}_{\mathsf{Q}}(\omega)\models\Sigma\Rightarrow\Delta$
and (2) holds. ∎

To conclude the preliminaries, we present the following lemma which will be
particularly useful in our proofs.

######  Lemma 2.38.

Let $\mathsf{Q}$ be a quasivariety, and $\Sigma,\Delta$ be finite sets of
equations over variables in a finite set $X$. The following are equivalent:

  1. (1)

$\mathsf{Q}\models\Sigma\Rightarrow\Delta$;

  2. (2)

${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\models\Sigma\Rightarrow\Delta$;

  3. (3)

there is $p\approx q\in\Delta$ such that
$p/\theta_{\mathsf{Q}}(\Sigma)=q/\theta_{\mathsf{Q}}(\Sigma)$ in
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$.

###### Proof.

It is clear that (1) implies (2) and (2) implies (3). We now show that (3)
implies (1).

Let ${\textbf{A}}\in\mathsf{Q}$. If there is no assignment of the variables in
$X$ to A that models $\Sigma$, then
${\textbf{A}}\models\Sigma\Rightarrow\Delta$. Otherwise, suppose there is an
assignment $h$ such that ${\textbf{A}},h\models\Sigma$. Then, since
$\theta_{\mathsf{Q}}(\Sigma)$ is the smallest relative congruence of
${\textbf{F}}_{\mathsf{Q}}(X)$ containing the set of pairs
$S=\\{(p,q):p\approx q\in\Sigma\\}$, by the Second Homomorphism Theorem we can
close the following diagram:

${\textbf{F}}_{\mathsf{Q}}(X)$A${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$$h$$f$$\pi_{\Sigma}$

That is, there is a homomorphism
$f:{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\to{\textbf{A}}$
such that $h=f\pi_{\Sigma}$, where $\pi_{\Sigma}$ is the natural epimorphism
from ${\textbf{F}}_{\mathsf{Q}}(X)$ to
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$. Now by (3) there
is at least an identity $p\approx q\in\Delta$ such that
$(p,q)\in\ker(\pi_{\Sigma})$. Since $h=f\pi_{\Sigma}$, $(p,q)\in\ker(h)$,
which means that ${\textbf{A}},h\models p\approx q$ and therefore
${\textbf{A}}\models\Sigma\Rightarrow\Delta$. Since A is an arbitrary algebra
of $\mathsf{Q}$ this shows that $\mathsf{Q}\models\Sigma\Rightarrow\Delta$. ∎

##  3\. Universal completeness

In this section we study from the algebraic perspective the notion of
universal completeness and its variations: active, nonnegative, passive
universal completeness, together with their hereditary versions. That is, we
shall see which algebraic properties correspond to the notions coming from the
logical perspective (detailed in the preliminaries Subsection 2.4). For each
notion, we will present a characterization theorem and some examples. While
the characterizations of active and passive universal completeness (to the
best of our knowledge) are fully original, we build on existing ones for the
other notions, presenting some new results and a coherent presentation in our
framework.

###  3.1. Universal quasivarieties

We start with universal completeness. The following expands [22, Proposition
6].

######  Theorem 3.1.

For any quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is universally complete;

  2. (2)

for every universal class $\mathsf{U}\subseteq\mathsf{Q}$,
${\mathbf{H}}(\mathsf{U})={\mathbf{H}}(\mathsf{Q})$ implies
$\mathsf{U}=\mathsf{Q}$.

  3. (3)

$\mathsf{Q}={\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$;

  4. (4)

every finitely presented algebra in $\mathsf{Q}$ is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

###### Proof.

(2) implies (1) via Lemma 2.35. We show that (1) implies (2). Let
$\mathsf{U}\subseteq\mathsf{Q}$ be a universal class such that
${\mathbf{H}}(\mathsf{U})={\mathbf{H}}(\mathsf{Q})$ and suppose that
$\mathsf{U}\vDash\Sigma\Rightarrow\Delta$; then

${\mathbf{H}}(\mathsf{Q})={\mathbf{H}}(\mathsf{U})\subseteq{\mathbf{H}}(\mathsf{U}_{\Sigma\Rightarrow\Delta})\subseteq{\mathbf{H}}(\mathsf{Q}).$

So
${\mathbf{H}}(\mathsf{U}_{\Sigma\Rightarrow\Delta})={\mathbf{H}}(\mathsf{Q})$
and by Lemma 2.35 $\Sigma\Rightarrow\Delta$ is admissible in $\mathsf{Q}$. By
(1), $\mathsf{Q}\vDash\Sigma\Rightarrow\Delta$; therefore $\mathsf{U}$ and
$\mathsf{Q}$ are two universal classes in which exactly the same clauses are
valid, thus they are equal. Hence (2) holds, and thus (2) and (1) are
equivalent.

(1) implies (3) follows by Lemma 2.35. Moreover, (3) clearly implies (4). We
now show that (4) implies (1), which completes the proof. Consider a universal
sentence $\Sigma\Rightarrow\Delta$ that is admissible in $\mathsf{Q}$, or
equivalently (by Lemma 2.35), such that
${\textbf{F}}_{\mathsf{Q}}(\omega)\models\Sigma\Rightarrow\Delta$. The
finitely presented algebra
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$
by (4), and thus
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\models\Sigma\Rightarrow\Delta$.
By Lemma 2.38, $\mathsf{Q}\models\Sigma\Rightarrow\Delta$ and thus
$\mathsf{Q}$ is universally complete. ∎

By algebraizability, and since the property of being universal (for the
discussion in Subsection 2.1) is preserved by categorical equivalence, we get
at once:

######  Corollary 3.2.

For a quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is universally complete;

  2. (2)

$\mathcal{L}_{\mathsf{Q}}$ is universally complete.

The following theorem and lemma show a sufficient and a necessary condition
respectively for a quasivariety to be universally complete.

######  Theorem 3.3.

If every finitely presented algebra in $\mathsf{Q}$ is exact then $\mathsf{Q}$
is universally complete.

###### Proof.

If every finitely presented algebra in $\mathsf{Q}$ is exact, it is in
${\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$, and thus also
in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.
The claim then follows from Theorem 3.1. ∎

######  Theorem 3.4.

If $\mathsf{Q}$ is universally complete, then $\mathsf{Q}$ is unifiable.

###### Proof.

Suppose by counterpositive that there is a finite set of identities $\Sigma$
that is not unifiable in $\mathsf{Q}$. Then $\Sigma\Rightarrow\emptyset$ is
(passively) admissible but not derivable; indeed it does not hold in the
trivial algebra. This implies that $\mathsf{Q}$ is not universally complete,
and the claim is proved. ∎

Since projectivity implies exactness, we observe the following immediate
consequence of Theorem 3.3.

######  Corollary 3.5.

If every finitely presented algebra in $\mathsf{Q}$ is projective then
$\mathsf{Q}$ is universally complete.

For locally finite varieties there is a stronger result, observed in [22].

######  Lemma 3.6.

[22] Let $\mathsf{Q}$ be a locally finite quasivariety; then
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$
if and only if every finite subalgebra B of A is in
${\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

######  Theorem 3.7 ([22]).

Let $\mathsf{Q}$ be a locally finite variety of finite type. Then $\mathsf{Q}$
is universally complete if and only if $\mathsf{Q}$ is unifiable and has exact
unifiers.

###### Proof.

Suppose that $\mathsf{Q}$ is universally complete; then, by Theorem 3.4,
$\mathsf{Q}$ is unifiable. Since it is universally complete, every finite
algebra in $\mathsf{Q}$ is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$,
hence in ${\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$ (by
Lemma 3.6). Thus every finite unifiable algebra in $\mathsf{Q}$ is exact and
$\mathsf{Q}$ has exact unifiers. The converse claim follows from Theorem 3.3.
∎

######  Remark 3.8.

We observe that Theorem 3.4 limits greatly the examples of universally
complete quasivarieties. In particular, in quasivarieties with finite type the
trivial algebra is finitely presented, and thus if $\mathsf{Q}$ is universally
complete, it must be unifiable. This means that a quasivariety with more than
one constant in its finite type cannot be universally complete if there are
nontrivial models where the constants are distinct; similarly if there is only
one constant, then it must generate the trivial algebra in nontrivial models,
or equivalently, in ${\textbf{F}}_{\mathsf{Q}}$. If there are no constants,
then ${\textbf{F}}_{\mathsf{Q}}={\textbf{F}}_{\mathsf{Q}}(x)$ and, in order to
be able to embed the trivial algebra, there has to be an idempotent term.

Let us now discuss some different examples of universally complete
(quasi)varieties.

######  Example 3.9.

Let us consider lattice-ordered abelian groups (or abelian $\ell$-groups for
short). These are algebras ${\textbf{G}}=(G,\land,\lor,\cdot,^{-1},1)$ where
$(G,\cdot,^{-1},1)$ is an abelian group, $(G,\land,\lor)$ is a lattice, and
the group operation distributes over the lattice operations. Every finitely
presented abelian $\ell$-groups is projective [15]; thus, the variety of
abelian $\ell$-groups is universally complete by Corollary 3.5.

The same holds for the variety of _negative cones_ of abelian $\ell$-groups.
Given an $\ell$-group G, the set of elements $G^{-}=\\{x\in G:x\leq 1\\}$ can
be seen as a residuated lattice (see Section 5.2)
${\textbf{G}}^{-}=(G^{-},\cdot,\to,\land,\lor,1)$ where $(\cdot,\land,\lor,1)$
are inherited by the group and $x\to y=x^{-1}\cdot y\land 1$. The algebraic
category of negative cones of abelian $\ell$-groups is equivalent to the one
of abelian $\ell$-groups [46], thus every finitely presented algebra is
projective and the variety of negative cones of $\ell$-groups
$\mathsf{L}\mathsf{G}^{-}$ is universally complete. Observe that in all these
cases the unique constant $1$ is absorbing w.r.t. any basic operation, and it
generates the trivial algebra.

######  Example 3.10.

Hoops are a particular variety of residuated monoids related to logic which
were defined in an unpublished manuscript by Büchi and Owens, inspired by the
work of Bosbach on partially ordered monoids (see [17] for details on the
theory of hoops). Hoops have a constant which is absorbing w.r.t. any basic
operation; hence the least free algebra is trivial in any variety of hoops and
any variety of hoops is unifiable. In [8] it was shown that every finite hoop
is projective in the class of finite hoops which via Lemma 2.24 entails that
every locally finite variety of hoops has projective unifiers. Since any
locally finite quasivariety is contained in a locally finite variety, every
locally finite quasivariety of hoops is universally complete. The same holds
in the variety of $\rightarrow$-subreducts of hoops, usually denoted by
$\mathsf{HBCK}$; again locally finite varieties of $\mathsf{HBCK}$-algebras
have projective unifiers [8] and hence they are universally complete. For a
non-locally finite example, we say that a hoop is cancellative if the
underlying monoid is cancellative; cancellative hoops form a variety
$\mathsf{C}$ that is categorically equivalent to the one of abelian
$\ell$-groups [17]. Hence $\mathsf{C}$ is a non locally finite variety of
hoops which is universally complete.

The classes of algebras in the above examples all have projective unifiers.
However:

######  Example 3.11.

In lattices there are no constants but any variety of lattices is idempotent;
hence the least free algebra is trivial and every lattice is unifiable. Every
finite distributive lattice is exact [22] and distributive lattices are
locally finite, so distributive lattices are universally complete by Theorem
3.7. Moreover, as we have already observed in Example 2.25, distributive
lattices do not have projective unifiers.

We now consider the hereditary version of universal completeness.

######  Definition 3.12.

A quasivariety $\mathsf{Q}$ is primitive universal if all its
subquasivarieties are universally complete.

All the above examples of universally complete varieties are primitive
universal and this is not entirely coincidental. Distributive lattices are
trivially primitive universal, since they do not have any trivial
subquasivariety. For all the other examples, we have a general result.

######  Theorem 3.13.

Let $\mathsf{Q}$ be a quasivariety with projective unifiers and such that
${\textbf{F}}_{\mathsf{Q}}$ is trivial; then $\mathsf{Q}$ is primitive
universal.

###### Proof.

Observe that for any subquasivariety $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$,
${\textbf{F}}_{\mathsf{Q}^{\prime}}$ is trivial as well. Hence every algebra
in $\mathsf{Q}$ is unifiable in any subvariety to which it belongs. Let
${\textbf{B}}^{\prime}={\textbf{F}}_{\mathsf{Q}^{\prime}}(X)/\theta_{\mathsf{Q}^{\prime}}(\Sigma)$
be finitely presented in $\mathsf{Q}^{\prime}$; then
${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is
finitely presented in $\mathsf{Q}$ and thus it is projective in $\mathsf{Q}$.
But then Lemma 2.28 applies and B is projective; thus $\mathsf{Q}^{\prime}$
has projective unifiers and thus it is universally complete by Corollary 3.5.
∎

Is the same conclusion true if we replace “projective unifiers” with
“unifiable, locally finite with exact unifiers”? We do not know, but we know
that we cannot use an improved version of Lemma 2.28 since it cannot be
improved to account for exact unifiers (see Example 3.29).

###  3.2. Non-negative and active universal quasivarieties

The situation in which universal completeness fails due only to the trivial
algebras has been first investigated in [22]; the following expands [22,
Proposition 8].

######  Theorem 3.14.

For a quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is non-negative universally complete;

  2. (2)

every admissible universal sentence is valid in $\mathsf{Q}^{+}$;

  3. (3)

every nontrivial algebra is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

  4. (4)

every nontrivial finitely presented algebra is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

###### Proof.

The equivalence of the first three points is in [22, Proposition 8], and (3)
clearly implies (4). Assume now that (4) holds, we show (1). Let
$\Sigma\Rightarrow\Delta$ be a non-negative admissible universal sentence with
variables in a finite set $X$, we show that
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\models\Sigma\Rightarrow\Delta$.
If ${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is trivial, then
it models $\Sigma\Rightarrow\Delta$ (given that $\Delta$ is not $\emptyset$).
Suppose now that ${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is
nontrivial, then it is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$
by hypothesis and then it models $\Sigma\Rightarrow\Delta$ since the latter is
admissible, and thus
${\textbf{F}}_{\mathsf{Q}}(\omega)\models\Sigma\Rightarrow\Delta$ by Lemma
2.35. By Lemma 2.38, $\mathsf{Q}$ models $\Sigma\Rightarrow\Delta$ and (1)
holds. ∎

Moreover:

######  Theorem 3.15.

For a quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is non-negative universally complete;

  2. (2)

$\mathcal{L}_{\mathsf{Q}}$ is non-negative universally complete.

###### Proof.

In a categorical equivalence between quasivarieties trivial algebras are
mapped to trivial algebras, since the latter can be characterized as the
algebras that are a homomorphic image of every algebra in a quasivariety. Thus
nontrivial finitely presented algebras are mapped to nontrivial finitely
presented algebras, and the result follows from the usual arguments. ∎

We can also obtain an analogue of Theorem 3.3.

######  Theorem 3.16.

If every nontrivial finitely presented algebra in $\mathsf{Q}$ is exact (or
projective), then $\mathsf{Q}$ is non-negative universally complete.

###### Proof.

If every nontrivial finitely presented algebra is exact (or projective), then
it is in ${\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$, and
therefore in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.
The claim then follows from Theorem 3.14. ∎

Analogously to the case of universal completeness, we get a stronger result
for locally finite quasivarieties.

######  Theorem 3.17.

Let $\mathsf{Q}$ be a locally finite quasivariety. Then $\mathsf{Q}$ is non-
negative universally complete if and only if every nontrivial finitely
presented algebra is exact.

###### Proof.

Suppose that $\mathsf{Q}$ is locally finite and there is a finite nontrivial
algebra ${\textbf{A}}\in\mathsf{Q}$ that is not exact. Then
${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$
and thus, by Lemma 3.6,
${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.
Therefore $\mathsf{Q}$ cannot be non-negative universally complete by Theorem
3.14. The other direction follows from Theorem 3.16. ∎

######  Example 3.18.

Boolean algebras are an example of a non-negative universally complete variety
that is not universally complete. It is easily seen that every nontrivial
finite Boolean algebra is exact (indeed, projective), which shows that Boolean
algebras are non-negative universally complete by Theorem 3.17. However, there
are negative admissible clauses: e.g., the ones with premises given by the
presentation of the trivial algebra, which is finitely presented but not
unifiable. Thus Boolean algebras are not universally complete.

######  Example 3.19.

Stone algebras are a different example; in [22] the authors proved, using the
duality between Stone algebras and particular Priestley spaces, that every
finite nontrivial Stone algebra is exact; hence Stone algebras are non-
negative universally complete.

We now move on to describe active universal completeness from the algebraic
perspective.

######  Theorem 3.20.

Let $\mathsf{Q}$ be a quasivariety. The following are equivalent:

  1. (1)

$\mathsf{Q}$ is active universally complete;

  2. (2)

every unifiable algebra in $\mathsf{Q}$ is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$;

  3. (3)

every finitely presented and unifiable algebra in $\mathsf{Q}$ is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$;

  4. (4)

every universal sentence admissible in $\mathsf{Q}$ is satisfied by all
finitely presented unifiable algebras in $\mathsf{Q}$;

  5. (5)

for every ${\textbf{A}}\in\mathsf{Q}$,
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

###### Proof.

We start by showing that (1) implies (2). Assume (1), and let
$\Sigma\Rightarrow\Delta$ be such that
${\textbf{F}}_{\mathsf{Q}}(\omega)\models\Sigma\Rightarrow\Delta$;
equivalently, by Lemma 2.35, $\Sigma\Rightarrow\Delta$ is an admissible
universal sentence in $\mathsf{Q}$. If $\Sigma$ is unifiable, by hypothesis
$\Sigma\Rightarrow\Delta$ is valid in $\mathsf{Q}$. Suppose now that $\Sigma$
has variables in a finite set $X$ and it is not unifiable, that is, via
Corollary 2.19 there is no homomorphism from
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ to
${\textbf{F}}_{\mathsf{Q}}$. Let A be a unifiable algebra in $\mathsf{Q}$; we
argue that there is no assignment of the variables in $\Sigma$ that validates
$\Sigma$ in A. Indeed otherwise the following diagram would commute and
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ would be unifiable,
yielding a contradiction.

${\textbf{F}}_{\mathsf{Q}}(X)$A${\textbf{F}}_{\mathsf{Q}}$${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$

Therefore, $\Sigma\Rightarrow\Delta$ is vacuously satisfied in A, which is any
unifiable algebra in $\mathsf{Q}$, thus (2) holds. Now, clearly (2) implies
(3), and (3) and (4) are equivalent by the definitions.

Let us show that (4) implies (1). Let $\Sigma\Rightarrow\Delta$ be an active
admissible universal sentence in $\mathsf{Q}$ with variables in a finite set
$X$; we want to show that it is also valid in $\mathsf{Q}$. Since by
hypothesis $\Sigma\Rightarrow\Delta$ is active admissible, $\Sigma$ is
unifiable, and therefore so is
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ by Corollary 2.19.
Then by (4),
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\models\Sigma\Rightarrow\Delta$,
which implies that $\mathsf{Q}\models\Sigma\Rightarrow\Delta$ by Lemma 2.38.
Therefore the first four points are equivalent.

Finally, we show that (1) implies (5) and (5) implies (2), which completes the
proof. We start with (1) $\Rightarrow$ (5). Let ${\textbf{A}}\in\mathsf{Q}$,
and consider a clause $\Sigma\Rightarrow\Delta$ valid in
${\textbf{F}}_{\mathsf{Q}}(\omega)$. We show that
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}(\omega)\models\Sigma\Rightarrow\Delta$.
Now, if $\mathsf{Q}\models\Sigma\Rightarrow\Delta$, in particular
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}(\omega)\models\Sigma\Rightarrow\Delta$.
Suppose that $\mathsf{Q}\not\vDash\Sigma\Rightarrow\Delta$. Since $\mathsf{Q}$
is active universally complete, $\Sigma\Rightarrow\Delta$ must be a passive
rule, thus $\Sigma$ is not unifiable. Equivalently, there is no assignment $h$
of the variables in $\Sigma$ such that
${\textbf{F}}_{\mathsf{Q}},h\models\Sigma$. Thus, there is also no assignment
$h^{\prime}$ of the variables in $\Sigma$ such that
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}},h^{\prime}\models\Sigma$, thus
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}(\omega)\models\Sigma\Rightarrow\Delta$.

It is left to prove (5) $\Rightarrow$ (2). Let A be a unifiable algebra in
$\mathsf{Q}$, then there is a homomorphism
$h:{\textbf{A}}\to{\textbf{F}}_{\mathsf{Q}}$ (Lemma 2.21). Consider the map
$h^{\prime}:{\textbf{A}}\to{\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}$ be
defined as $h^{\prime}(a)=(a,h(a))$. Clearly, $h^{\prime}$ is an embedding of
A into
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$
(by (5)). Thus also
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$,
which completes the proof. ∎

We observe that the previous characterization extends to universal sentences
some of the results in [35] about active structural completeness. We also get
the usual result.

######  Theorem 3.21.

For a quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is active universally complete;

  2. (2)

$\mathcal{L}_{\mathsf{Q}}$ is active universally complete.

###### Proof.

The result follows from the fact that embeddings, ultraproducts, being
finitely presented and unifiable, are all categorical notions and thus
preserved by categorical equivalence. ∎

Moreover, we have the following lemma whose proof is the same as the one of
Theorems 3.3 and 3.7.

######  Theorem 3.22.

If $\mathsf{Q}$ has exact (or projective) unifiers, then $\mathsf{Q}$ is
active universally complete. If $\mathsf{Q}$ is also locally finite then it is
active universally complete if and only if it has exact unifiers.

######  Example 3.23.

A discriminator on a set $A$ is a ternary operation $t$ on $A$ defined by

$t(a,b,c)=\left\\{\begin{array}[]{ll}a,&\hbox{if $a\neq b$;}\\\ c,&\hbox{if
$a=b$.}\end{array}\right.$

A variety $\mathsf{V}$ is a discriminator variety [70] if there is a ternary
term that is the discriminator on all the subdirectly irreducible members of
$\mathsf{V}$. Discriminator varieties have many strong properties: for
instance they are congruence permutable and congruence distributive.

In [20, Theorem 3.1] it has been essentially shown that discriminator
varieties have projective unifiers, and therefore they are all active
universally complete by Theorem 3.22.

######  Example 3.24.

We now see some examples within the algebraic semantics of many-valued logics;
in [8] it has been shown that in any locally finite variety of bounded hoops
or $\mathsf{BL}$-algebras (the equivalent algebraic semantics of Hájek Basic
Logic [51]), the finite unifiable algebras are exactly the finite projective
algebras. It follows that any of such varieties has projective unifiers and
hence it is active universally complete. This holds also for any locally
finite quasivariety of bounded hoops or $\mathsf{BL}$-algebras, or their
reducts, i.e., bounded $\mathsf{HBCK}$-algebras.

In contrast with the case of (unbounded) hoops, not all of them are non-
negative universally complete, as we will now discuss. Let us call chain a
totally orderef algebra. Every finite BL-chain is an ordinal sum of finite
Wajsberg hoops, the first of which is an MV-algebra [4]. No finite MV-chain
different from the 2-element Boolean algebra 2 is unifiable (they are all
simple and the least free algebra is 2), and thus not exact. It follows by
basic facts about ordinal sums that if a locally finite quasivariety
$\mathsf{Q}$ of BL-algebras contains a chain whose first component is
different from 2, $\mathsf{Q}$ is not non-negative universally complete. The
same holds, mutatis mutandis, for bounded hoops and bounded
$\mathsf{HBCK}$-algebras. In Section 5.2 we shall see a different class of
(discriminator) varieties coming from many-valued logics that are active
universally complete.

######  Definition 3.25.

We call a quasivariety $\mathsf{Q}$ active primitive universal if every
subquasivariety of $\mathsf{Q}$ is active universally complete.

It is evident from the characterization theorem of active universally complete
quasivarieties that a variety $\mathsf{Q}$ is active primitive universal if
and only if $\mathcal{L}_{\mathsf{Q}}$ is hereditarily active universally
complete. We have the following fact:

######  Theorem 3.26.

Suppose that $\mathsf{Q}$ is a quasivariety such that
${\textbf{F}}_{\mathsf{Q}}={\textbf{F}}_{\mathsf{Q}^{\prime}}$ for all
$\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$. If $\mathsf{Q}$ has projective
unifiers then it is active primitive universal.

###### Proof.

The proof follows from Theorem 3.22 and Lemma 2.29. ∎

All varieties in Example 3.24 satisfy the hypotheses of Theorem 3.26 (as the
reader can easily check). For discriminator varieties all the examples of
lattice-based varieties in Section 5.2 of this paper (but see also [20] or
[31] for more examples) have the same property; hence they are all active
primitive universal.

Now, a variety is q-minimal if it does not have any proper nontrivial
subquasivariety; so a q-minimal variety is necessarily equationally complete.
We have this result by Bergman and McKenzie:

######  Theorem 3.27.

[14] A locally finite equationally complete variety is q-minimal if and only
if it has exactly one subdirectly irreducible algebra that is embeddable in
any nontrivial member of the variety. Moreover, this is always the case if the
variety is congruence modular.

It follows immediately that every active universally complete q-minimal
variety is active primitive universal.

######  Example 3.28.

Discriminator varieties are active universally complete as seen in example
3.23. Now, given a finitely generated discriminator variety $\mathsf{V}$, it
is generated by a finite algebra A having a discriminator term on it, also
called a quasi-primal algebra. By [74] $\mathsf{V}$ is equationally complete
and, since it is congruence modular, it is q-minimal; hence $\mathsf{V}$ is
active primitive universal.

Finally, we observe that Lemma 2.29 cannot be improved to “having exact
unifiers” and the counterexample is given by De Morgan lattices; we will see
below that they form an active universally complete variety that is not active
primitive universal.

######  Example 3.29.

A De Morgan lattice is a distributive lattice with a unary operation $\neg$
which is involutive and satisfies the De Morgan Laws. It is well-known that
the variety $\mathsf{DM}$ of De Morgan lattices is locally finite and has
exactly two proper non trivial subvarieties, i.e. the variety $\mathsf{BLa}$
of Boolean lattices (axiomatized by $x\leq y\vee\neg y$) and the variety
$\mathsf{KL}$ of Kleene lattices (axiomatized by $x\wedge\neg x\leq y\vee\neg
y$). It is easily seen that all these nontrivial varieties have the same one-
generated free algebra whose universe is $\\{x,\neg x,x\vee\neg x,x\wedge\neg
x\\}$. It follows that all the subquasivarieties of De Morgan lattices have
the same least free algebra and $\mathsf{DM}$ satisfies the hypotheses of
Theorem 3.26. Admissibility in De Morgan lattices has been investigated in
[64] and [22]. Now for a finite algebra ${\textbf{A}}\in\mathsf{DM}$ the
following are equivalent:

  1. (1)

A is unifiable;

  2. (2)

the universal sentence $\\{x\approx\neg x\\}\Rightarrow\emptyset$ is valid in
A;

  3. (3)

${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{DM}}(\omega))$.

The equivalence of (2) and (3) has been proved in [22, Lemma 28], while (3)
implies (1) trivially. If we assume that (2) does not hold for A, then there
is an $a\in A$ with $\neg a=a$; so if
$f:{\textbf{A}}\longrightarrow{\textbf{F}}_{\mathsf{DM}}(x)$ is a homomorphism
and $f(a)=\varphi$, then $\varphi=\neg\varphi$. But there is no element in
${\textbf{F}}_{\mathsf{DM}}(x)$ with that property, so A cannot be unifiable.
This concludes the proof of the equivalence of the three statements.

Therefore $\mathsf{DM}$ has exact unifiers and thus it is active universally
complete by Theorem 3.22. Now consider the subvariety of $\mathsf{DM}$ of
Kleene lattices. In [22] it is shown that the universal sentence

$\Phi:=\\{x\leq\neg x,x\wedge\neg y\leq\neg x\vee y\\}\Rightarrow\neg y\leq y$

is admissible in $\mathsf{KL}$. It is also active, as the reader can easily
check that the substitution $x\longmapsto z\land\neg z$, $y\longmapsto\neg z$
unifies the premises of $\Phi$. However it fails in the three element Kleene
lattice ${\textbf{K}}_{3}$ in Figure 2, with the assignment $x=a$, $y=\neg a$;
hence $\mathsf{KL}$ is not active universally complete. So $\mathsf{DM}$ is a
variety that is active universally complete but not active primitive
universal.

$\neg b=b$$\neg a$$a$ Figure 2. The lattice ${\textbf{K}}_{3}$

Note that in $\mathsf{KL}$ there must be a finite unifiable algebra that is
not exact (since $\mathsf{KL}$ cannot have exact unifiers). Now a finite
Kleene lattice A is exact if and only if both $\\{x\approx\neg
x\\}\Rightarrow\emptyset$ and $\Phi$ are valid in A [22, Lemma 38]. Let
${\textbf{A}}={\textbf{K}}_{3}\times\mathbf{2}$; the reader can easily check
that A is unifiable in $\mathsf{KL}$ (since it satisfies $\\{x\approx\neg
x\\}\Rightarrow\emptyset$ and hence it is unifiable in $\mathsf{DM}$) but does
not satisfy $\Phi$. This shows (as promised) that Lemma 2.28 cannot be
improved.

###  3.3. Passive universal quasivarieties

We will now see that passive universal completeness in a quasivariety
corresponds to an algebraic notion we have already introduced: unifiability.
Moreover, we shall see that it corresponds to the apparently weaker notion of
negative universal completeness, that is, every (passive) admissible negative
universal sentence is derivable. We recall that a quasivariety $\mathsf{Q}$ is
unifiable if every finitely presented algebra in $\mathsf{Q}$ is unifiable.

######  Theorem 3.30.

For every quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is passive universally complete;

  2. (2)

$\mathsf{Q}$ is negative universally complete;

  3. (3)

$\mathsf{Q}$ is unifiable.

###### Proof.

Assume (1) and let $\Sigma\Rightarrow\emptyset$ be a negative admissible
universal sentence; then it is necessarily passive, since there is no
substitution that unifies $\emptyset$. Thus, by (1),
$\Sigma\Rightarrow\emptyset$ is valid in $\mathsf{Q}$.

Assume now (2), we prove that it implies (3) by contrapositive. Suppose that
$\mathsf{Q}$ is not unifiable, that is, there exists a finite set of
identities $\Sigma$ that is not unifiable. Then the negative universal
sentence $\Sigma\Rightarrow\emptyset$ is (passively) admissible, but it is not
derivable (in particular, it fails in the trivial algebra).

Finally, if (3) holds, then (1) trivially holds, since if every set of
identities is unifiable there is no passive admissible clause. ∎

In some cases, we can improve the previous result.

######  Lemma 3.31.

Let $\mathsf{Q}$ be a quasivariety such that
${\mathbf{I}}({\textbf{F}}_{\mathsf{Q}})={\mathbf{I}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}})$,
then the following are equivalent.

  1. (1)

$\mathsf{Q}$ is unifiable;

  2. (2)

every algebra in $\mathsf{Q}$ is unifiable.

###### Proof.

We prove the nontrivial direction by contraposition. Consider an arbitrary
algebra ${\textbf{A}}\in\mathsf{Q}$ and assume that it is not unifiable;
without loss of generality we let
${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta$ for some set $X$ and some
relative congruence $\theta$. Since A is not unifiable, there is no assignment
$h:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}$ such that
${\textbf{F}}_{\mathsf{Q}},h\models\Sigma_{\theta}$, where
$\Sigma_{\theta}=\\{t\approx u:(t,u)\in\theta\\}$. Equivalently, iff
${\textbf{F}}_{\mathsf{Q}}\models\Sigma_{\theta}\Rightarrow\emptyset$. Now,
the equational consequence relation relative to a class of algebras
$\mathsf{K}$ is finitary if and only if $\mathsf{K}$ is closed under
ultraproducts (see for instance [71]); thus by hypothesis the equational
consequence relation relative to ${\textbf{F}}_{\mathsf{Q}}$ is finitary, and
we obtain that
${\textbf{F}}_{\mathsf{Q}}\models\Sigma^{\prime}_{\theta}\Rightarrow\emptyset$,
for $\Sigma^{\prime}_{\theta}$ some finite subset of $\Sigma_{\theta}$. That
is, $\Sigma^{\prime}$ is finite and not unifiable, thus $\mathsf{Q}$ is not
unifiable and the proof is complete. ∎

Observe that if a quasivariety $\mathsf{Q}$ is such that
${\textbf{F}}_{\mathsf{Q}}$ is finite, it satisfies the hypothesis of the
previous lemma.

######  Corollary 3.32.

Let $\mathsf{Q}$ be a quasivariety such that
${\mathbf{I}}({\textbf{F}}_{\mathsf{Q}})={\mathbf{I}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}})$,
then the following are equivalent.

  1. (1)

$\mathsf{Q}$ is passive universally complete;

  2. (2)

$\mathsf{Q}$ is negative universally complete;

  3. (3)

$\mathsf{Q}$ is unifiable;

  4. (4)

every algebra in $\mathsf{Q}$ is unifiable.

Since unifiability is preserved by categorical equivalence, we get the
following.

######  Corollary 3.33.

A quasivariety $\mathsf{Q}$ is passive universally complete if and only if
$\mathcal{L}_{\mathsf{Q}}$ is passive universally complete.

##  4\. Structural completeness

In this section we investigate the algebraic counterparts of structural
completeness and its variations. The main new results are about the
characterization of passive structurally complete quasivarieties; moreover, we
also show a characterization of primitive quasivarieties grounding on the
results in [50].

###  4.1. Structural quasivarieties

The bridge theorems for structural completeness have been first established by
Bergman [13]. We present the proof for the sake of the reader, expanding with
point (6).

######  Theorem 4.1 ([13]).

For a quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is structurally complete;

  2. (2)

$\mathsf{Q}={\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$;

  3. (3)

no proper subquasivariety of $\mathsf{Q}$ generates a proper subvariety of
${\mathbf{H}}(\mathsf{Q})$;

  4. (4)

for all $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$ if
${\mathbf{H}}(\mathsf{Q}^{\prime})={\mathbf{H}}(\mathsf{Q})$, then
$\mathsf{Q}=\mathsf{Q}^{\prime}$;

  5. (5)

for all ${\textbf{A}}\in\mathsf{Q}$ if
${\mathbf{V}}({\textbf{A}})={\mathbf{H}}(\mathsf{Q})$, then
${\mathbf{Q}}({\textbf{A}})=\mathsf{Q}$;

  6. (6)

every finitely presented algebra in $\mathsf{Q}$ is in
${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

###### Proof.

First, (1) is equivalent to (2) via Lemma 2.35. The implications (3)
$\Leftrightarrow$ (4) $\Rightarrow$ (5) $\Rightarrow$ (2) are straightforward.
(2) implies (4) since if $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$ and
${\mathbf{H}}(\mathsf{Q}^{\prime})={\mathbf{H}}(\mathsf{Q})$, we get that
${\textbf{F}}_{\mathsf{Q}^{\prime}}(\omega)={\textbf{F}}_{{\mathbf{H}}(\mathsf{Q}^{\prime})}(\omega)={\textbf{F}}_{{\mathbf{H}}(\mathsf{Q})}(\omega)={\textbf{F}}_{\mathsf{Q}}(\omega)$;
thus
$\mathsf{Q}={\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))={\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}^{\prime}(\omega))\subseteq\mathsf{Q}^{\prime}$
and then equality holds. Thus the first five points are equivalent; Finally,
clearly (2) implies (6), and (6) implies (2) since a quasivariety is generated
by its finitely presented algebras ([50, Proposition 2.1.18]). ∎

######  Corollary 4.2.

A variety $\mathsf{V}$ is structurally complete if and only if every proper
subquasivariety of $\mathsf{V}$ generates a proper subvariety; therefore if A
is such that ${\mathbf{V}}({\textbf{A}})$ is structurally complete, then
${\mathbf{V}}({\textbf{A}})={\mathbf{Q}}({\textbf{A}})$.

Since the definition of structural completeness is invariant under categorical
equivalence we get also:

######  Corollary 4.3.

Let $\mathsf{Q}$ be a quasivariety; then $\mathsf{Q}$ is structurally complete
if and only if $\mathcal{L}_{\mathsf{Q}}$ is structurally complete.

Let us extract some sufficient conditions for structural completeness.

######  Lemma 4.4.

Let $\mathsf{Q}$ be a quasivariety; if

  1. (1)

every ${\textbf{A}}\in\mathsf{K}$ is exact in
$\mathsf{Q}={\mathbf{Q}}(\mathsf{K})$, or

  2. (2)

every finitely generated algebra in $\mathsf{Q}$ is exact, or

  3. (3)

every finitely presented algebra in $\mathsf{Q}$ is exact, or

  4. (4)

every finitely generated relative subdirectly irreducible in $\mathsf{Q}$ is
exact,

then $\mathsf{Q}$ is structurally complete. Moreover if every
${\textbf{A}}\in\mathsf{K}$ is exact in ${\mathbf{V}}(\mathsf{K})$ and every
subdirectly irreducible member of ${\mathbf{V}}(\mathsf{K})$ is in
${\mathbf{I}}{\mathbf{S}}(\mathsf{K})$, then ${\mathbf{V}}(\mathsf{K})$ is
structurally complete.

###### Proof.

If each algebra in $\mathsf{K}$ is exact in
$\mathsf{Q}={\mathbf{Q}}(\mathsf{K})$, then
$\mathsf{K}\subseteq{\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$;
therefore
$\mathsf{Q}={\mathbf{Q}}(\mathsf{K})\subseteq{\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$
and thus equality holds. Hence $\mathsf{Q}$ is structurally complete by the
characterization theorem. The other points follow.

For the last claim, every subdirectly irreducible member of
${\mathbf{V}}(\mathsf{K})$ lies in ${\mathbf{I}}{\mathbf{S}}(\mathsf{K})$ and
thus is exact in ${\mathbf{V}}(\mathsf{K})$. Since any variety is generated as
a quasivariety by its subdirectly irreducible members,
${\mathbf{V}}(\mathsf{K})$ is structurally complete. ∎

We observe that none of the previous conditions is necessary. For locally
finite quasivarieties we have a necessary and sufficient condition for
structural completeness because of the following:

######  Lemma 4.5 ([22]).

Let $\mathsf{Q}$ be a locally finite quasivariety and A a finite algebra in
$\mathsf{Q}$. Then
${\textbf{A}}\in{\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$ if and only
if
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

The following theorem improves [22, Corollary 11].

######  Theorem 4.6.

For a locally finite quasivariety $\mathsf{Q}$ of finite type the following
are equivalent:

  1. (1)

$\mathsf{Q}$ is structurally complete;

  2. (2)

each finite algebra in $\mathsf{Q}$ is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}({\textbf{F}}_{\mathsf{Q}}(\omega))$;

  3. (3)

every finite relative subdirectly irreducible in $\mathsf{Q}$ is exact.

###### Proof.

Assume (1); then each finite algebra in $\mathsf{Q}$ is in
${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$ and thus, by Lemma 4.5, is
in ${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}({\textbf{F}}_{\mathsf{Q}}(\omega))$
and (2) holds. If (2) holds and A is finite relative subdirectly irreducible,
then it is in ${\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$,
i.e. it is exact. Finally if (3) holds, then $\mathsf{Q}$ is structurally
complete by Lemma 4.4. ∎

###  4.2. Primitive quasivarieties

We now consider the hereditary notion of structural completeness.

######  Definition 4.7.

A class of algebras $\mathsf{K}$ in a quasivariety $\mathsf{Q}$ is equational
relative to $\mathsf{Q}$ if
$\mathsf{K}={\mathbf{V}}(\mathsf{K})\cap\mathsf{Q}$. In particular, a
subquasivariety $\mathsf{Q}^{\prime}$ of $\mathsf{Q}$ is equational relative
to $\mathsf{Q}$ if
$\mathsf{Q}^{\prime}={\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$; a
quasivariety $\mathsf{Q}$ is primitive if every subquasivariety of
$\mathsf{Q}$ is equational relative to $\mathsf{Q}$.

Clearly primitivity is downward hereditary and a variety $\mathsf{V}$ is
primitive if and only if every subquasivariety of $\mathsf{V}$ is a variety.
We can show the following.

######  Theorem 4.8.

For a quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is primitive;

  2. (2)

every subquasivariety of $\mathsf{Q}$ is structurally complete;

  3. (3)

for all subdirectly irreducible ${\textbf{A}}\in{\mathbf{H}}(\mathsf{Q})$ and
for any ${\textbf{B}}\in\mathsf{Q}$, if
${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$, then
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{B}})$.

###### Proof.

We first show the equivalence between (1) and (2). Suppose that $\mathsf{Q}$
is primitive and let $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$; if
$\mathsf{Q}^{\prime\prime}\subseteq\mathsf{Q}^{\prime}$ and
${\mathbf{H}}(\mathsf{Q}^{\prime\prime})={\mathbf{H}}(\mathsf{Q}^{\prime})$
then

$\mathsf{Q}^{\prime}={\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}={\mathbf{H}}(\mathsf{Q}^{\prime\prime})\cap\mathsf{Q}=\mathsf{Q}^{\prime\prime}$

so $\mathsf{Q}^{\prime}$ is structurally complete by Theorem 4.1.

Conversely assume (2), let $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$ and let
$\mathsf{Q}^{\prime\prime}={\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$
(it is clearly a quasivariety); then
${\mathbf{H}}(\mathsf{Q}^{\prime\prime})={\mathbf{H}}(\mathsf{Q}^{\prime})$
and thus $\mathsf{Q}^{\prime\prime}=\mathsf{Q}^{\prime}$, again using the
characterization of Theorem 4.1. So $\mathsf{Q}^{\prime}$ is equational in
$\mathsf{Q}$ and $\mathsf{Q}$ is primitive.

Assume (1) again, and let ${\textbf{A}},{\textbf{B}}\in\mathsf{Q}$ with A
subdirectly irreducible and ${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$. Since
$\mathsf{Q}$ is primitive we have

${\mathbf{Q}}({\textbf{B}})={\mathbf{H}}({\mathbf{Q}}({\textbf{B}}))\cap\mathsf{Q}$

and hence ${\textbf{A}}\in{\mathbf{Q}}({\textbf{B}})$. Since A is subdirectly
irreducible,
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{B}})$ by
Theorem 2.3 and (3) holds.

Conversely, assume (3) and let $\mathsf{Q}^{\prime}$ be a subquasivariety of
$\mathsf{Q}$; if
${\textbf{B}}\in{\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$, observe that
${\textbf{B}}\in{\mathbf{H}}(\mathsf{Q})$ and hence
${\textbf{B}}\leq_{sd}\prod{\textbf{A}}_{i}$ where the ${\textbf{A}}_{i}$ are
subdirectly irreducible in
${\mathbf{H}}(\mathsf{Q})\cap{\mathbf{H}}(\mathsf{Q}^{\prime})$. Then for all
$i$ there is ${\textbf{B}}_{i}\in\mathsf{Q}^{\prime}$ such that
${\textbf{A}}_{i}\in{\mathbf{H}}({\textbf{B}}_{i})$ and hence by hypothesis
${\textbf{A}}_{i}\in{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{B}}_{i})$ and so
${\textbf{A}}_{i}\in\mathsf{Q}^{\prime}$ for all $i$. Therefore
${\textbf{B}}\in\mathsf{Q}^{\prime}$, so
${\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}=\mathsf{Q}^{\prime}$ and
$\mathsf{Q}^{\prime}$ is equational in $\mathsf{Q}$. Therefore $\mathsf{Q}$ is
primitive and (1) holds. ∎

As commented in the preliminary section (Subsection 2.1), primitivity is
preserved under categorical equivalence, and therefore:

######  Corollary 4.9.

A quasivariety is primitive if and only if $\mathcal{L}_{\mathsf{Q}}$ is
hereditarily structurally complete.

We will see how Theorem 4.8 can be improved in the locally finite case. Let
$\mathsf{Q}$ be a quasivariety and let ${\textbf{A}}\in\mathsf{Q}$; we define

$[\mathsf{Q}:{\textbf{A}}]=\\{{\textbf{B}}\in\mathsf{Q}:{\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{B}})\\}.$

The following lemma describes some properties of $[\mathsf{Q}:{\textbf{A}}]$;
the proofs are quite standard with the exception of point (3). As a matter of
fact a proof of the forward implication of (3) appears in [50, Corollary
2.1.17]. However the proof is somewhat buried into generality and it is not
easy to follow; so we felt that a suitable translation would make it easier
for the readers.

######  Lemma 4.10.

Let $\mathsf{Q}$ be a quasivariety; then

  1. (1)

if ${\textbf{A}}\in\mathsf{Q}$ is finite and $\mathsf{Q}$ has finite type,
then $[\mathsf{Q}:{\textbf{A}}]$ is a universal class;

  2. (2)

if A is relative subdirectly irreducible and finitely presented, then
$[\mathsf{Q}:{\textbf{A}}]$ is a quasivariety;

  3. (3)

A is weakly projective in $\mathsf{Q}$ if and only if
$[\mathsf{Q}:{\textbf{A}}]$ is closed under ${\mathbf{H}}$ if and only if
$[\mathsf{Q}:{\textbf{A}}]$ is equational relative to $\mathsf{Q}$;

  4. (4)

if A is relative subdirectly irreducible, finitely presented and weakly
projective in $\mathsf{Q}$, then $[\mathsf{Q}:{\textbf{A}}]$ is a variety.

Moreover if $\mathsf{Q}$ is locally finite of finite type, the converse
implications in (1),(2) and (4) hold.

###### Proof.

For (1), if A is finite, then there is a first order universal sentence $\Psi$
such that, for all ${\textbf{B}}\in\mathsf{Q}$, ${\textbf{B}}\vDash\Psi$ if
and only if ${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$. More in
detail, if $|A|=n$,

$\Psi:=\exists x_{1}\ldots\exists x_{n}(\&\\{x_{i}\neq x_{j}:i,j\leq n,i\neq
j\\}\,\,\&\,\,{\textbf{D}}({\textbf{A}})),$

where ${\textbf{D}}({\textbf{A}})$ is the diagram of A, that is, a conjunction
of universal sentences that describe the operation tables of A (identifying
each element of A with a different $x_{i}$), and $\&$ is first order logic
conjunction.

Consider
${\textbf{B}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}([\mathsf{Q}:{\textbf{A}}])$,
we show that ${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$; if
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$, then
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}([\mathsf{Q}:{\textbf{A}}])$.
Hence there exists a family $({\textbf{A}}_{i})_{i\in
I}\subseteq[\mathsf{Q}:{\textbf{A}}]$ and an ultrafilter $U$ on $I$ such that
${\textbf{C}}=\Pi_{i\in I}{\textbf{A}}/U$ and
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{C}})$. So
${\textbf{C}}\vDash\Psi$; but then by Łòs Lemma there is a (necessarily
nonempty) set of indexes $I^{\prime}\in U$ such that $\Psi$ is valid in each
${\textbf{A}}_{i}$ with $i\in I^{\prime}$, which is clearly a contradiction,
since each ${\textbf{A}}_{i}\in[\mathsf{Q}:{\textbf{A}}]$. Thus
${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$ and
${\textbf{B}}\in[\mathsf{Q}:{\textbf{A}}]$ and therefore
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}([\mathsf{Q}:{\textbf{A}}])=[\mathsf{Q}:{\textbf{A}}]$
which is a universal class by Lemma 2.1

Conversely let $\mathsf{Q}$ be locally finite of finite type; every algebra in
$\mathsf{Q}$ is embeddable in an ultraproduct of its finitely generated (i.e.
finite) subalgebras, say
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}(\\{{\textbf{B}}_{i}:i\in
I\\})$. If A is not finite, then
${\textbf{A}}\notin{\mathbf{S}}({\textbf{B}}_{i})$ for all $i$, so
${\textbf{B}}_{i}\in[\mathsf{Q}:{\textbf{A}}]$ for all $i$. Since
$[\mathsf{Q}:{\textbf{A}}]$ is universal, we would have that
${\textbf{A}}\in[\mathsf{Q}:{\textbf{A}}]$, a clear contradiction. So
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}}_{i})$ for some $i$ and
hence it is finite.

For (2), suppose that A is relative subdirectly irreducible and finitely
presented, i.e.
${\textbf{A}}\cong{\textbf{F}}_{\mathsf{Q}}(\mathbf{x})/\theta(\Sigma)$ where
$\mathbf{x}=(x_{1},\dots,x_{n})$ and $\Sigma=\\{p_{i}(\mathbf{x})\approx
q_{i}(\mathbf{x}):i=1,\dots,m\\}$. We set $a_{i}=x_{i}/\theta(\Sigma)$; since
A is relative subdirectly irreducible, it has a relative monolith $\mu$, i.e.
a minimal non trivial relative congruence. Since $\mu$ is minimal, there are
$c,d\in A$ such that $\mu$ is the relative congruence generated by the pair
$(c,d)$. Now let $t_{c},t_{d}$ terms in
${\textbf{F}}_{\mathsf{Q}}(\mathbf{x})$ such that $t_{c}(a_{1},\dots,a_{n})=c$
and $t_{d}(a_{1},\dots,a_{n})=d$ and let $\Phi$ be the quasiequation

$\bigwedge_{i=1}^{m}p_{i}(\mathbf{x})\approx q_{i}(\mathbf{x})\
\longrightarrow\ t_{c}(\mathbf{x})\approx t_{d}(\mathbf{x}).$

Then ${\textbf{A}}\not\vDash\Phi$; moreover if ${\textbf{C}}\in\mathsf{Q}$ is
a homomorphic image of A which is not isomorphic with A, then
${\textbf{C}}\vDash\Phi$. We claim that
$[\mathsf{Q}:{\textbf{A}}]=\\{{\textbf{B}}\in\mathsf{Q}:{\textbf{B}}\vDash\Phi\\}$
and since $\Phi$ is a quasiequation this implies that
$[\mathsf{Q}:{\textbf{A}}]$ is a quasivariety. Clearly if
${\textbf{B}}\vDash\Phi$, then
${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$; conversely assume
that ${\textbf{B}}\not\vDash\Phi$. Then there are $b_{1},\dots,b_{n}\in B$
such that $p_{i}(b_{1},\dots,b_{n})=q_{i}(b_{1},\dots,b_{n})$ but
$t_{c}(b_{1},\dots,b_{n})\neq t_{d}(b_{1},\dots,b_{n})$. Let $g$ be the
homomorphism extending the assignment $x_{i}\longmapsto b_{i}$; then
$\theta(\Sigma)\subseteq\textrm{ker}(g)$ so by the Second Homomorphism Theorem
there is a homomorphism $f:{\textbf{A}}\longrightarrow{\textbf{B}}$ such that
$f(a_{i})=b_{i}$. Observe that $f({\textbf{A}})\in\mathsf{Q}$ (since it is a
subalgebra of ${\textbf{B}}\in\mathsf{Q}$) and
$f({\textbf{A}})\not\vDash\Phi$, so by what we said above
$f({\textbf{A}})\cong{\textbf{A}}$; this clearly implies
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$, so
${\textbf{B}}\notin[\mathsf{Q}:{\textbf{A}}]$ as wished.

For the converse, let $\mathsf{Q}$ be locally finite of finite type; by (1) A
is finite. Suppose that ${\textbf{A}}\leq_{sd}\prod_{i\in I}{\textbf{B}}_{i}$
where each ${\textbf{B}}_{i}$ is relative subdirectly irreducible in
$\mathsf{Q}$. Since A is finite, each ${\textbf{B}}_{i}$ can be taken to be
finite; if ${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{B}}_{i})$ for
all $i$, then ${\textbf{B}}_{i}\in[\mathsf{Q}:{\textbf{A}}]$ for all $i$ and
hence, being $[\mathsf{Q}:{\textbf{A}}]$ a quasivariety we have
${\textbf{A}}\in[\mathsf{Q}:{\textbf{A}}]$ which is impossible. Hence there is
an $i$ such that ${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}}_{i})$,
so that $|A|\leq|B_{i}|$; on the other hand
${\textbf{B}}\in{\mathbf{H}}({\textbf{A}})$, so $|B|\leq|A|$. Since everything
is finite we have ${\textbf{A}}\cong{\textbf{B}}_{i}$ and then A is relative
subdirectly irreducible.

For the first forward direction of (3), suppose that
${\textbf{B}}\in{\mathbf{H}}([\mathsf{Q}:{\textbf{A}}])$. If
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$, then
${\textbf{A}}\in{\mathbf{S}}{\mathbf{H}}([\mathsf{Q}:{\textbf{A}}])\subseteq{\mathbf{H}}{\mathbf{S}}([\mathsf{Q}:{\textbf{A}}])$.
Now $[\mathsf{Q}:{\textbf{A}}]\subseteq\mathsf{Q}$ and A is weakly projective
in $\mathsf{Q}$; so ${\textbf{A}}\in{\mathbf{S}}([\mathsf{Q}:{\textbf{A}}])$
which is impossible. It follows that
${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$ and
${\textbf{B}}\in[\mathsf{Q}:{\textbf{A}}]$; thus $[\mathsf{Q}:{\textbf{A}}]$
is closed under ${\mathbf{H}}$. For the second forward direction, it is easy
to see that if $[\mathsf{Q}:{\textbf{A}}]$ is closed under ${\mathbf{H}}$ then
$[\mathsf{Q}:{\textbf{A}}]$ is equational relative to $\mathsf{Q}$. Assume now
that $[\mathsf{Q}:{\textbf{A}}]$ is closed under ${\mathbf{H}}$, we show that
A is weakly projective in $\mathsf{Q}$. Suppose that
${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$ for some
${\textbf{B}}\in\mathsf{Q}$; if
${\textbf{A}}\notin{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$, then
${\textbf{B}}\in[\mathsf{Q}:{\textbf{A}}]$ and, since
$[\mathsf{Q}:{\textbf{A}}]$ is closed under ${\mathbf{H}}$,
${\textbf{A}}\in[\mathsf{Q}:{\textbf{A}}]$, again a contradiction. Hence
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$ and A is weakly
projective in $\mathsf{Q}$. A completely analogous proof shows that if
$[\mathsf{Q}:{\textbf{A}}]$ is equational relative to $\mathsf{Q}$ then A is
weakly projective, which completes the proof of (3).

(4) follows directly from (1), (2) and (3). ∎

Thus if A is relative subdirectly irreducible and finitely presented, then
$[\mathsf{Q}:{\textbf{A}}]$ is a quasivariety; this is the key to prove the
following result, appearing in [50, Proposition 5.1.24]. We present a self-
contained proof for the sake of the reader.

######  Theorem 4.11 ([50]).

If $\mathsf{Q}$ is a locally finite quasivariety of finite type, then the
following are equivalent.

  1. (1)

$\mathsf{Q}$ is primitive;

  2. (2)

for all finite relative subdirectly irreducible ${\textbf{A}}\in\mathsf{Q}$,
$[\mathsf{Q}:{\textbf{A}}]$ is equational relative to $\mathsf{Q}$;

  3. (3)

every finite relative subdirectly irreducible ${\textbf{A}}\in\mathsf{Q}$ is
weakly projective in $\mathsf{Q}$;

  4. (4)

every finite relative subdirectly irreducible ${\textbf{A}}\in\mathsf{Q}$ is
weakly projective in the class of finite algebras in $\mathsf{Q}$.

###### Proof.

(2) and (3) are equivalent by Lemma 4.10, and (3) and (4) are equivalent in
locally finite quasivarieties.

Now, (1) implies (2) by Lemma 4.10, since if A is a finite relative
subdirectly irreducible algebra then $[\mathsf{Q}:{\textbf{A}}]$ is a
quasivariety, and if $\mathsf{Q}$ is primitive every subquasivariety is
equational relative to $\mathsf{Q}$ by definition.

Finally, assume (3) and let $\mathsf{Q}^{\prime}$ be a subquasivariety of
$\mathsf{Q}$; consider a finite algebra
${\textbf{B}}\in{\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$, then B is a
subdirect product of finite relative subdirectly irreducible algebras in
$\mathsf{Q}$, that is, ${\textbf{B}}\leq_{sd}\prod_{i\in I}{\textbf{A}}_{i}$
where each ${\textbf{A}}_{i}$ is finite relative subdirectly irreducible in
$\mathsf{Q}$, and thus it is also weakly projective in $\mathsf{Q}$ by
hypothesis. Since ${\textbf{B}}\in{\mathbf{H}}(\mathsf{Q}^{\prime})$, there is
${\textbf{A}}\in\mathsf{Q}^{\prime}$ such that
${\textbf{B}}\in{\mathbf{H}}({\textbf{A}})$. But then for each $i\in I$,
${\textbf{A}}_{i}\in{\mathbf{H}}({\textbf{A}})$; since each ${\textbf{A}}_{i}$
is weakly projective in $\mathsf{Q}$, it is also isomorphic to a subalgebra of
A. Thus,
${\textbf{B}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}({\textbf{A}})\subseteq\mathsf{Q}^{\prime}$,
and therefore
$\mathsf{Q}^{\prime}={\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$, which
means that $\mathsf{Q}$ is primitive and (1) holds. ∎

Most results in the literature are about structurally complete and primitive
varieties of algebras and the reason is quite obvious; first the two concepts
are easier to formulate for varieties. Secondly being subdirectly irreducible
is an absolute concept (every subdirectly irreducible algebra is relative
subdirectly irreducible in any quasivariety to which it belongs) while being
relative subdirectly irreducible depends on the subquasivariety we are
considering. Of course when a quasivariety is generated by a “simple” class
(e.g. by finitely many finite algebras), then Theorem 2.3(2) gives a simple
solution, but in general describing the relative subdirectly irreducible
algebras in a quasivariety is not an easy task.

Now, it is clear that if $\mathsf{Q}$ is non-negative universally complete,
then it is structurally complete. Finding examples of (quasi)varieties that
are structurally complete but not primitive is not easy; one idea is to find a
finite algebra A such that A satisfies the hypotheses of Lemma 4.4, but
${\mathbf{V}}({\textbf{A}})$ contains some strict (i.e. not a variety)
subquasivariety. We will see an example of this in Section 5.1. Let us now
show some different kinds of examples of primitive (quasi)varieties.

######  Example 4.12.

The variety of bounded distributive lattices is primitive (as we will discuss
in Section 5.1), since it is equationally complete and congruence modular and
so is q-minimal by Theorem 3.27.

It is well-known (and easy to check) that the variety of distributive lattices
is a dual discriminator variety; a dual discriminator on a set $A$ is a
ternary operation $d$ on $A$ defined by

$d(a,b,c)=\left\\{\begin{array}[]{ll}c,&\hbox{if $a\neq b$;}\\\ a,&\hbox{if
$a=b$.}\end{array}\right.$

A variety $\mathsf{V}$ is a dual discriminator variety [41] if there is a
ternary term that is the dual discriminator on all the subdirectly irreducible
members of $\mathsf{V}$. Dual discriminator varieties, as opposed to
discriminator varieties, do not necessarily have projective unifiers. However,
recently in [24] the authors have extended the results in [14] (such as
Theorem 3.27) in two directions: every minimal dual discriminator variety is
q-minimal, hence primitive and, if the variety is also idempotent, then
minimality can be dropped and the variety is primitive. This last fact gives
raise to different examples of primitive varieties.

######  Example 4.13.

A weakly associative lattice is an algebra $\langle A,\vee,\wedge\rangle$
where $\vee$ and $\wedge$ are idempotent, commutative and satisfy the
absorption laws but (as the name reveals) only a weak form of associativity.
In [41] the authors proved that there is a largest dual discriminator variety
$\mathsf{U}$ of weakly associative lattices; since weakly associative lattices
are idempotent, $\mathsf{U}$ is the largest primitive variety of weakly
associative lattices.

######  Example 4.14.

The pure dual discriminator variety $\mathsf{D}$ (see [41, Theorem 3.2]) is a
variety with a single ternary operation $d(x,y,z)$ satisfying

$\displaystyle d(x,y,y)\approx y$ $\displaystyle d(x,y,x)\approx x$
$\displaystyle d(x,x,y)\approx x$ $\displaystyle d(x,y,d(x,y,z))\approx
d(x,y,z)$ $\displaystyle d(u,v,d(x,y,z))\approx d(d(u,v,x),d(u,v,y),d(u,v,z))$

which is enough to prove that $\mathsf{D}$ is a dual discriminator variety.
Since $d$ is idempotent $\mathsf{D}$ is an idempotent dual discriminator
variety and so it is primitive.

A different example is given by the following.

######  Example 4.15.

A modal algebra is a Boolean algebra with a modal operator $\Box$, that we
take as a basic unary operation, satisfying $\Box 1\approx 1$ and
$\Box(x\wedge y)\approx\Box x\wedge\Box y$; there is an extensive literature
on modal algebras (see for instance [77] and the bibliography therein). A
modal algebra is a K4-algebra if it satisfies $\Box x\leq\Box\Box x$; in [72]
V.V. Rybakov classified all the primitive varieties of K4-algebras. However
very recently [25] Carr discovered a mistake in Rybakov’s proof; namely
Rybakov in his description missed some varieties that all have the properties
of containing a unifiable weakly projective algebra that is not projective. So
any of such varieties, though primitive, does not have projective unifiers.

We now present some examples from (quasi)varieties that are the equivalent
algebraic semantics of (fragments) of many-valued logics; in particular, of
infinite-valued Łukasiewicz logic.

######  Example 4.16.

Wajsberg algebras are the equivalent algebraic semantics of infinite-valued
Łukasiewicz logic in the signature of bounded commutative residuated lattices
$(\cdot,\to,\land,\lor,0,1)$ and they are term-equivalent to the better known
MV-algebras [27]; Wajsberg hoops are their $0$-free subreducts. About these
algebras there are some recent results [1]. In summary:

  1. $\bullet$

the only primitive variety of Wajsberg algebras is the variety of Boolean
algebras, that is also non-negative universally complete, and it is the only
non-negative universally complete variety of Wajsberg algebras;

  2. $\bullet$

there are nontrivial primitive quasivarieties of Wajsberg algebras;

  3. $\bullet$

a proper variety of Wajsberg hoops is structurally complete if and only if it
is primitive if and only if every subdirectly irreducible is either finite or
perfect.

The third point above clearly implies that the variety of Wajsberg hoops is
not primitive. Considering varieties of $\rightarrow$-subreducts, the
$\rightarrow$-subreducts of Wajsberg hoops is a subvariety of
$\mathsf{BCK}$-algebras usually denoted by $\mathsf{LBCK}$; every locally
finite subvariety of $\mathsf{LBCK}$-algebras is a variety of
$\mathsf{HBCK}$-algebras, so it is universally complete. However:

  1. $\bullet$

the only non locally finite subvariety is the entire variety $\mathsf{LBCK}$
[59];

  2. $\bullet$

$\mathsf{LBCK}$ it is generated as a quasivariety by its finite chains [2];

  3. $\bullet$

every infinite chain contains all the finite chains as subalgebras [59];

  4. $\bullet$

so if $\mathsf{Q}$ is a quasivariety which contains only finitely many chains,
then ${\mathbf{V}}(\mathsf{Q})$ is locally finite, hence universally complete
and so $\mathsf{Q}={\mathbf{V}}(\mathsf{Q})$;

  5. $\bullet$

otherwise $\mathsf{Q}$ contains infinitely many chains and so
${\mathbf{V}}(\mathsf{Q})=\mathsf{Q}=\mathsf{LBCK}$.

Hence every subquasivariety of $\mathsf{LBCK}$ is a variety and
$\mathsf{LBCK}$ is primitive. The status of non locally finite varieties of
basic hoops and basic algebras is still unclear (except for the cases we
mentioned) and it is under investigation.

###  4.3. Active structurally complete quasivarieties

The problem of active structural completeness has been tackled in [35]; it is
an extensive and profound paper touching many aspects and there is no need to
reproduce it here. We will only state the definition, the main result, and we
will display an example.

######  Theorem 4.17 ([35]).

For a quasivariety $\mathsf{Q}$ the following are equivalent:

  1. (1)

$\mathsf{Q}$ is active structurally complete;

  2. (2)

every unifiable algebra of $\mathsf{Q}$ is in
${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$;

  3. (3)

every finitely presented unifiable algebra in $\mathsf{Q}$ is in
${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$;

  4. (4)

every admissible quasiequation in $\mathsf{Q}$ is valid in all the finitely
presented unifiable algebras in $\mathsf{Q}$;

  5. (5)

for every ${\textbf{A}}\in\mathsf{Q}$,
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}\in{\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

  6. (6)

for every ${\textbf{A}}\in\mathsf{Q}_{rsi}$,
${\textbf{A}}\times{\textbf{F}}_{\mathsf{Q}}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.

Given that, we have as usual:

######  Corollary 4.18.

A quasivariety $\mathsf{Q}$ is active structurally completeif and only if
$\mathcal{L}_{\mathsf{Q}}$ is actively structurally complete.

######  Example 4.19.

An $S4$-algebra is a $K4$-algebra satisfying $\Box x\leq x$; if we define
$\Diamond x:=\neg\Box\neg x$, then a monadic algebra is an $S4$-algebras
satisfying $\Diamond x\leq\Box\Diamond x$. Now let A, B be the monadic algebra
and the $S4$-algebra in Figure 3 and let
$\mathsf{V}={\mathbf{V}}({\textbf{A}})$ and
$\mathsf{W}={\mathbf{V}}({\textbf{B}})$.

$0=\Box 0=\Box a=\Box b$$1=\Box 1$$b$$a$A$0=\Box 0=\Box c$$b=\Box b=\Box
a^{\prime}$$a=\Box a=\Box b^{\prime}$$c$$b^{\prime}$$a^{\prime}$$\Box
c^{\prime}$$c^{\prime}$B Figure 3. A and B

Let $\mathsf{U}=\mathsf{V}\vee\mathsf{W}$ (the varietal join); from [35,
Section 8] one can deduce that:

  1. $\bullet$

every finitely generated algebra in $\mathsf{U}$ is isomorphic to the direct
product of an algebra in $\mathsf{V}$ and one in $\mathsf{W}$, hence
$\mathsf{U}$ is locally finite;

  2. $\bullet$

$\mathsf{U}$ is active structurally complete but not structurally complete;

  3. $\bullet$

$\mathsf{U}$ does not have exact unifiers.

Since $\mathsf{U}$ is locally finite, by Theorem 3.22, it cannot be active
universally complete; so $\mathsf{U}$ is an example of a variety that is
active structurally complete but not active universally complete.

###  4.4. Passive quasivarieties

Passive structurally complete quasivarieties have been studied in [66] in
relation to the joint embedding property, while here we take a different path.
We start with the following observation.

######  Proposition 4.20.

A quasivariety $\mathsf{Q}$ is passive structurally complete if and only if
every non-negative passive admissible universal sentence is derivable in
$\mathsf{Q}$.

###### Proof.

For the non-trivial direction, suppose $\mathsf{Q}$ is passive structurally
complete, and let $\Sigma\Rightarrow\Delta$ be a non-negative
($\Delta\neq\emptyset$) passive admissible universal sentence. This means that
$\Sigma$ is not unifiable, and thus, each quasiequation
$\Sigma\Rightarrow\delta$, for any $\delta\in\Delta$, is passive admissible.
By hypothesis, each such $\Sigma\Rightarrow\delta$ is valid in $\mathsf{Q}$,
thus so is $\Sigma\Rightarrow\Delta$ and the conclusion holds. ∎

It is clear that a key concept to study passive clauses is understanding the
unifiability of the premises. In order to do so, we introduce the following
notion.

######  Definition 4.21.

We say that a finite set of identities $\Sigma$ is trivializing in a class of
algebras $\mathsf{K}$ if the quasiequation $\Sigma\Rightarrow(x\approx y)$ is
valid in $\mathsf{K}$, where the variables $x,y$ do not appear in $\Sigma$.

Notice that such a quasiequation $\Sigma\Rightarrow(x\approx y)$ is valid in
an algebra A if and only if either A is trivial, or there is no assignment of
the variables of $\Sigma$ in A that makes $\Sigma$ valid in A.

######  Lemma 4.22.

Let $\mathsf{Q}$ be a quasivariety, and let $\Sigma$ be a finite set of
equations in its language. The following are equivalent:

  1. (1)

$\Sigma$ is not unifiable in $\mathsf{Q}$;

  2. (2)

${\textbf{F}}_{\mathsf{Q}}$ is nontrivial and $\Sigma$ is trivializing in
${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}})$;

  3. (3)

${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$.

###### Proof.

It is easy to see that (2) and (3) are equivalent, modulo the fact that a set
of identities is trivializing in ${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}})$ if
and only if it is trivializing in ${\textbf{F}}_{\mathsf{Q}}$.

Let us now assume that the identities in $\Sigma$ are on a (finite) set of
variables $X$. Then, given Lemma 2.21, $\Sigma$ is not unifiable in
$\mathsf{Q}$ if and only if there is no homomorphism
$h:{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\to{\textbf{F}}_{\mathsf{Q}}$.
We show that the latter holds if and only if there is no homomorphism
$k:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}$ such that
$k(t)=k(u)$ for each $t\approx u\in\Sigma$. Indeed, for the non-trivial
direction, suppose that there is a homomorphism
$k:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}$ with the above
property. Then the following diagram commutes, i.e., there is a homomorphism
$h:{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)\to{\textbf{F}}_{\mathsf{Q}}$:

${\textbf{F}}_{\mathsf{Q}}(X)$${\textbf{F}}_{\mathsf{Q}}$${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$$k$$h$$\pi$

Notice that there is no homomorphism
$k:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}$ such that
$k(t)=k(u)$ for each $t\approx u\in\Sigma$ if and only if there is no
assignment of variables in $X$ validating $\Sigma$ in
${\textbf{F}}_{\mathsf{Q}}$. The latter is equivalent to
${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$. ∎

We are now ready to prove the characterization theorem.

######  Theorem 4.23.

Let $\mathsf{Q}$ be a quasivariety, then the following are equivalent.

  1. (1)

$\mathsf{Q}$ is passive structurally complete;

  2. (2)

${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$ implies $\Sigma$
is trivializing in $\mathsf{Q}$;

  3. (3)

either ${\textbf{F}}_{\mathsf{Q}}$ is trivial, or $\Sigma$ is trivializing in
${\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}})$ implies $\Sigma$ is trivializing in
$\mathsf{Q}$;

  4. (4)

every nontrivial finitely presented algebra is unifiable.

###### Proof.

We first show that (1) and (2) are equivalent. By definition, $\mathsf{Q}$ is
passive structurally complete if and only if each quasiidentity
$\Sigma\Rightarrow\delta$ where $\Sigma$ is not unifiable in $\mathsf{Q}$ is
valid in $\mathsf{Q}$. That is, $\Sigma$ not unifiable in $\mathsf{Q}$ implies
$\mathsf{Q}\models\Sigma\Rightarrow\delta$, for all identities $\delta$. By
Proposition 4.22, the latter is equivalent to:
${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$ implies
$\mathsf{Q}\models\Sigma\Rightarrow\delta$, for all identities $\delta$. From
this it follows the particular case where $\delta=\\{x\approx y\\}$, with
$x,y$ not appearing in $\Sigma$. In turn, if
${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$ implies
$\mathsf{Q}\models\Sigma\Rightarrow(x\approx y)$, then clearly
$\mathsf{Q}\models\Sigma\Rightarrow\delta$ for any $\delta$, and thus (1)
$\Leftrightarrow$ (2).

Now, (2) and (3) are equivalent by Lemma 4.22, thus the first three points are
equivalent. Let us now assume (2) and prove (4). We consider a nontrivial
finitely presented algebra in $\mathsf{Q}$,
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$. If it is not
unifiable, by Lemma 4.22
${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$. By (2) this
implies that $\Sigma$ is trivializing in $\mathsf{Q}$, that is,
$\mathsf{Q}\models\Sigma\Rightarrow(x\approx y)$ (with $x,y$ new variables).
This clearly implies that
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$ is trivial, a
contradiction. Thus ${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$
is unifiable and (4) holds.

Finally, we prove that (4) implies (1). Suppose $\Sigma\Rightarrow\delta$ is a
passive quasiequation over variables in $X$, that is, $\Sigma$ is not
unifiable in $\mathsf{Q}$. By Lemma 4.22
${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$. Let $x,y$ be
variables not in $X$, and consider the finitely presented algebra
${\textbf{F}}_{\mathsf{Q}}(X^{\prime})/\theta_{\mathsf{Q}}(\Sigma)$, where
$X^{\prime}=X\cup\\{x,y\\}$ and suppose by way of contradiction that it is not
trivial. By (4) it is unifiable, that is, there is a homomorphism
$h:{\textbf{F}}_{\mathsf{Q}}(X^{\prime})/\theta_{\mathsf{Q}}(\Sigma)\to{\textbf{F}}_{\mathsf{Q}}$.
Then, considering the natural epimorphism
$\pi_{\Sigma}:{\textbf{F}}_{\mathsf{Q}}(X^{\prime})\to{\textbf{F}}_{\mathsf{Q}}(X^{\prime})/\theta_{\mathsf{Q}}(\Sigma)$,
the composition $h\pi_{\Sigma}$ is an assignment from $X^{\prime}$ to
${\textbf{F}}_{\mathsf{Q}}$ satisfying $\Sigma$; but
${\textbf{F}}_{\mathsf{Q}}\models\Sigma\Rightarrow\emptyset$, a contradiction.
Thus ${\textbf{F}}_{\mathsf{Q}}(X^{\prime})/\theta_{\mathsf{Q}}(\Sigma)$ is
trivial, and therefore
$x/\theta_{\mathsf{Q}}(\Sigma)=y/\theta_{\mathsf{Q}}(\Sigma)$. By Lemma 2.38
$\mathsf{Q}\models\Sigma\Rightarrow(x\approx y)$, and thus
$\mathsf{Q}\models\Sigma\Rightarrow\delta$ and (1) holds. ∎

Analogously to the case of passive universal completeness, if the smallest
free algebra is isomorphic to all its ultraproducts we can improve the
previous result.

######  Lemma 4.24.

Let $\mathsf{Q}$ be a quasivariety such that
${\mathbf{I}}({\textbf{F}}_{\mathsf{Q}})={\mathbf{I}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}})$,
then the following are equivalent.

  1. (1)

every nontrivial finitely presented algebra in $\mathsf{Q}$ is unifiable;

  2. (2)

every nontrivial algebra in $\mathsf{Q}$ is unifiable.

###### Proof.

The proof is analogous to the one of Lemma 3.31; we prove the nontrivial
direction by contraposition. Consider an arbitrary algebra
${\textbf{A}}={\textbf{F}}_{\mathsf{Q}}(X)/\theta\in\mathsf{Q}$ and assume
that it is not unifiable. Then there is no assignment
$h:{\textbf{F}}_{\mathsf{Q}}(X)\to{\textbf{F}}_{\mathsf{Q}}$ such that
${\textbf{F}}_{\mathsf{Q}},h\models\Sigma_{\theta}$, where
$\Sigma_{\theta}=\\{t\approx u:(t,u)\in\theta\\}$. Equivalently, iff
${\textbf{F}}_{\mathsf{Q}}\models\Sigma_{\theta}\Rightarrow\emptyset$. Now,
the equational consequence relation relative to ${\textbf{F}}_{\mathsf{Q}}$ is
finitary (since all ultraproducts of ${\textbf{F}}_{\mathsf{Q}}$ are
isomorphic to ${\textbf{F}}_{\mathsf{Q}}$); thus we obtain that
${\textbf{F}}_{\mathsf{Q}}\models\Sigma^{\prime}_{\theta}\Rightarrow\emptyset$,
for $\Sigma^{\prime}_{\theta}$ some finite subset of $\Sigma_{\theta}$. But
${\textbf{F}}_{\mathsf{Q}}(X)/\theta\not\vDash\Sigma^{\prime}_{\theta}\Rightarrow(x\approx
y)$ (with $x,y\notin X$), since it is nontrivial, which contradicts (2) of