# Structural completeness in quasivarieties

Paolo Aglianò
DIISM,
Università di Siena, Italy
<EMAIL_ADDRESS>Alex Citkin
Metropolitan Telecommunications,
New York, USA
<EMAIL_ADDRESS>
###### Abstract

In this paper we study various forms of (hereditary) structural completeness
for quasivarieties of algebras, using mostly algebraic techniques. More
specifically we study relative weakly projective algebras and the way they
interact with structural completeness in quasivarieties. These ideas are then
applied to the study of $C$-structural completeness and $C$-primitivity,
through an algebraic generalization of Prucnal’s substitution. Finally we
study in depth dual i-discriminator quasivarieties in which a particular
instance of Prucnal’s substitution is used to prove that if each fundamental
operation commutes with the i-discriminator, then it is primitive.

##  1 Introduction.

Research in admissibility of (finitary structural inference) rules in
propositional logics is concerned with primarily two problems: given a
propositional logic $\mathsf{L}$, does $\mathsf{L}$ has admissible not
derivable rules? And if it does, what are they (see, e.g.,[60])? The logics in
which all structural admissible rules are derivable are called structurally
complete, and this notion was introduced in [54]. Since a structurally
complete logic cannot have structurally complete extensions (e.g. Medvedev
Logic (see [29]), it is natural to ask whether a logic and all its extensions
are structurally complete; for such logics the term hereditary structural
completeness was coined in [29]. Thus, traditionally, the problem of
structural completeness is formulated in the following way: given a
propositional logic $\mathsf{L}$, is it structurally complete? And if it is,
is it hereditarily structurally complete? And if it is not, which of its
extensions are structurally complete?

The equivalent algebraic semantic of an algebraizable propositional logic is a
quasivariety (see [17]): the formulas are translated into equations and the
rules into quasiequations. In algebraic terms, given a quasivariety
$\mathsf{Q}$, a quasiequation $\Phi$ is admissible in $\mathsf{Q}$ if
$\mathsf{F}_{\mathsf{Q}}(\omega)\models\Phi$, and $\Phi$ is derivable in
$\mathsf{Q}$ if $\mathsf{Q}\models\Phi$. Accordingly, $\mathsf{Q}$ is
structurally complete if $\mathsf{Q}$ does not have admissible not derivable
quasiequations, that is, if $\mathsf{Q}$ is generated by
$\mathsf{F}_{\mathsf{Q}}(\omega)$. And $\mathsf{Q}$ is hereditarily
structurally complete if $\mathsf{Q}$ and all its subquasivarieties are
structurally complete. Because hereditary structural completeness of
$\mathsf{Q}$ is equivalent to all subquasivarieties of $\mathsf{Q}$ being
equational (that is, every subquasivariety of $\mathsf{Q}$ can be defined
relative to $\mathsf{Q}$ by a set of equations), hereditarily structurally
complete quasivarieties also called deductive or primitive (see [13]), and we
use the latter term. It follows that any question about structural
completeness (and its variations, see [8]) of an algebraizable logic can be
solved in purely algebraic terms. On the other hand, given the fact that
structural completeness for quasivarieties does not make any reference to
logic, the concept makes sense also for quasivarieties that are not
quasivarieties of logic.

In [51], Mints observed that any admissible in the intuitionistic
propositional calculus (IPC) rule which does not contain either connectives
$\lor$ or $\to$ is derivable in IPC. In other words, IPC is
$\\{\land,\lor,\neg\\}$\- and $\\{\land,\to,\neg\\}$-structurally complete.
This observation leads to the following problem: given a set of formulas $F$
in the language of logic $\mathsf{L}$, we say that $\mathsf{L}$ is
structurally complete relative to $F$ if every admissible rule whose premises
and conclusion are in $F$, is derivable in $\mathsf{L}$. For instance, one can
take $F$ as a set of all formulas of IPC not containing disjunction and IPC
will be structurally complete relative to such $F$. Moreover, we say that
logic $\mathsf{L}$ is p-structurally complete relative to $F$, if every
admissible rule whose premises (not necessarily conclusions) are in $F$ is
derivable. For instance, IPC is p-structurally complete (and even hereditarily
p-structurally complete) relative to set of all Harrop (or all anti-Harrop)
formulas (see [58]). Another set of formulas relative to which IPC is
p-complete was introduced in [30].

This observation led the second author to introducing a notion of
$C$-structural completeness (see [31]): if $C$ is a subset of the set of
connectives of a propositional logic $\mathsf{L}$, $\mathsf{L}$ is
$C$-structurally complete if every admissible rule containing only connectives
from $C$ is derivable in $\mathsf{L}$. $C$-structural completeness is very
close but not the same as structural completeness of the $C$-fragment of
$\mathsf{L}$. For instance, from Mints’ observation it follows that IPC is
$\\{\to,\neg\\}$-structurally complete, while $\\{\to,\neg\\}$-fragment of IPC
is not (see [28, 31] for details). In some cases $C$-structural completeness
can be extended to structural completeness; for instance, the proof from [51]
holds for any axiomatic extension of IPC, thus it holds for the Dummett
calculus LC = IPC + $((p\to q)\lor(q\to p))$ and because $\lor$ can be
expressed in LC by a formula, LC (and every its extension) is structurally
complete, and this is an alternative proof of hereditary structural
completeness of LC first observed in [36] (the same argument is used to prove
primitivity in [39], Theorem 2.9).

In the algebraic setting, if $\mathsf{Q}$ is a quasivariety and $C$ is a
subset of the set of basic operations, then $\mathsf{Q}$ is $C$-structurally
complete if for every quasiequation $\Phi$ containing operations only from
$C$, ${\textbf{F}}_{\mathsf{Q}}(\omega)\models\Phi$ entails
$\mathsf{Q}\models\Phi$. In other words, if $\Phi$ is refuted in some algebra
from $\mathsf{Q}$, then $\Phi$ must be refuted in
${\textbf{F}}_{\mathsf{Q}}(\omega)$. On the other hand, if $\mathsf{Q}^{C}$ is
a quasivariety generated by all $C$-reducts of algebras from $\mathsf{Q}$,
then $\mathsf{Q}^{C}$ is structurally complete if every quasiequation $\Phi$
is refuted in ${\textbf{F}}_{\mathsf{Q}^{C}}(\omega)$ as long as it is refuted
in some algebra from $\mathsf{Q}^{C}$, or equivalently, in some $C$-reduct of
an algebra from $\mathsf{Q}$. Let us observe that $C$-reduct of
${\textbf{F}}_{\mathsf{Q}}(\omega)$ belongs to $\mathsf{Q}^{C}$ and hence,
structural completeness of $\mathsf{Q}^{C}$ entails $C$-structural
completeness of $\mathsf{Q}$, while the converse does not have to be true.

Admissibility and derivability of quasiequation
$\Phi=\bigwedge_{i\in[1,n]}t_{i}\approx s_{i}\Rightarrow t\approx s$ in a
quasivariety $\mathsf{Q}$ depend on properties of the algebra A finitely
presented by relations $t_{i}\approx s_{i},i\in[1,n]$. Indeed, $\Phi$ is
derivable in $\mathsf{Q}$, that is $\mathsf{Q}\models\Phi$, if and only if the
terms $t$ and $s$ represent the same element of A. And $\Phi$ is admissible in
$\mathsf{Q}$ if and only if none of homomorphic images of A in which $t$ and
$s$ represent distinct elements can be embeddable into
${\textbf{F}}_{\mathsf{Q}}(\omega)$. In particular, if A is subdirectly
irreducible and $t$ and $s$ represent elements from the monolith of A, $\Phi$
is admissible in Q if and only if A is not embeddable in
${\textbf{F}}_{\mathsf{Q}}(\omega)$; in this case, $\Phi$ is a characteristic
rule of A (cf. [29]).

The following simple sufficient condition is often used to demonstrate
$C$-structural completeness: if $C$-reduct of every algebra finitely presented
in $\mathsf{Q}$ can be embedded in the $C$-reduct of
${\textbf{F}}_{\mathsf{Q}}(\omega)$, then $\mathsf{Q}$ is $C$-structurally
complete. Indeed, if a quasiequation $\Phi=\bigwedge_{i\in[1,n]}t_{i}\approx
s_{i}\Rightarrow t\approx s$ whose terms contain operations only from $C$ is
not valid in $\mathsf{Q}$, then there is an algebra
${\textbf{A}}\in\mathsf{Q}$ and a valuation $v$ in A such that
$v(t_{i})=v(s_{i})$ for all $i\in[1,n]$ and $v(t)\neq v(s)$. Thus, $\Phi$ can
be refuted in algebra B finitely presented in $\mathsf{Q}$ and defined by the
relations $t_{i}\approx s_{i},i\in[1,n]$; and if B can be embedded in
${\textbf{F}}_{\mathsf{Q}}(\omega)$ as $C$-subreduct, then $\Phi$ can be
refuted in ${\textbf{F}}_{\mathsf{Q}}(\omega)$ as well.

As an example let us take $\mathsf{Q}$ to be a quasivariety of Heyting
algebras in the signature $\\{\to,\land,\lor,\neg\\}$ and let
$C=\\{\to,\land\\}$ and $C^{\prime}=\\{\land,\lor\\}$ and let us recall that
every finitely presented in $\mathsf{Q}$ algebra is (isomorphic to) a quotient
algebra of some free algebra ${\textbf{F}}_{\mathsf{Q}}(n)$ by a principal
congruence. Let us also recall that for any Heyting algebra A and for every
principal congruence $\varTheta$, each congruence class $a/\varTheta$ contains
a largest and a smallest element. It is a simple exercise to check that the
set of all the largest elements of the $\varTheta$-classes is closed under
$\to$ and $\land$ and hence it forms a $\\{\to,\land\\}$-subreduct of A, while
the set of all smallest elements of the $\varTheta$-classes is closed under
$\land$ and $\lor$ and hence it forms a $\\{\land,\lor\\}$-subreduct of A.
Thus, the $C$\- and $C^{\prime}$-reducts of any quotient algebra by a
principal congruence can be embedded in a $C$\- or $C^{\prime}$-reduct of the
preimage. Therefore the $C$\- and $C^{\prime}$-reducts of every finitely
presented algebra can be embedded in the respective reducts of a free algebra,
which means that $\mathsf{Q}$ is $C$\- and $C^{\prime}$-structurally complete.

The paper is structured in the following way: in Section 2 we give the
necessary definitions and remind the basic facts about quasivarieties. In
Section 3 we study relative weakly projective algebras and primitive
quasivarieties. In particular we give a criterion of primitivity for tame
quasivarieties, that is for quasivarieties in which every finitely generated
algebra is finitely presented. In addition, we prove that every finite
subdirectly irreducible algebra is projective in the quasivariety which it
generates as long as it is weakly projective in it.

Section 4 is dedicated to studying C-structurally complete and C-primitive
quasivarieties. We introduce the notion of u-presentable congruence and we
prove that, for quasivariety $\mathsf{Q}$ to be $C$-structurally complete, it
is sufficient that every compact $\mathsf{Q}$-congruence of
$\mathsf{F}_{\mathsf{Q}}(\omega)$ is u-presentable. We also give an algebraic
generalization of Prucnal’s substitution (see [55]).

In Section 5 we study in depth dual i-discriminator quasivarieties that are
different from the varieties studied in Section 4 but to which one can apply
techniques similar to Prucnal’s substitution. We prove several structure
theorems, connecting them with the theory of if ideals in quasivarieties, and
we show that every relatively congruence distributive dual i-discriminator
variety in which every fundamental operation commutes with the i-discriminator
is primitive.

In Section 6 we discuss some questions arising during our investigations into
the matter of this paper.

##  2 Main definitions.

###  2.1 Class operators, quasivarieties an free algebras.

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 [53] or [21] for a textbook
treatment. We only point out that if $\mathsf{K}$ is a finite set of finite
algebras, then ${\mathbf{P}}_{u}(\mathsf{K})=\mathsf{K}$.

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 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$. 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 absolutely free 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}$.

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

  * (a)

if $\mathsf{K}={\mathbf{H}}{\mathbf{S}}{\mathbf{P}}\mathsf{K}$, then
$\mathsf{K}$ is a variety;

  * (b)

if
$\mathsf{K}={\mathbf{I}}{\mathbf{S}}{\mathbf{P}}{\mathbf{P}}_{u}\mathsf{K}$,
then $\mathsf{K}$ is a quasivariety;

  * (c)

if $\mathsf{K}={\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}\mathsf{K}$, then
$\mathsf{K}$ is a universal class.

Of course we will use the standard abbreviations ${\mathbf{V}}$ for
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}$ and ${\mathbf{Q}}$ for
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}{\mathbf{P}}_{u}$; from the properties of
the operators one can easily deduce that for any class $\mathsf{K}$,
${\mathbf{Q}}(\mathsf{K})\subseteq{\mathbf{V}}(\mathsf{K})$.

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 [27].

######  Theorem 2.1.

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

  1. 1.

$\mathsf{K}$ is a universal class if and only if it is the class of all
algebras in which a given set of universal sentences is valid;

  2. 2.

$\mathsf{K}$ is a quasivariety if and only if it is the class of all algebras
in which a given set of quasiequations is valid;

  3. 3.

$\mathsf{K}$ is a variety if and only if it is the class of all algebras in
which a given set of equations is valid.

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 a class $\mathsf{K}$ contains all the free algebras in
$\mathsf{K}$ if and only if
$\mathsf{K}={\mathbf{I}}{\mathbf{S}}{\mathbf{P}}(\mathsf{K})$; therefore for
any quasivariety $\mathsf{Q}$,
${\textbf{F}}_{\mathsf{Q}}(X)={\textbf{F}}_{{\mathbf{V}}(\mathsf{Q})}(X)$.

###  2.2 Congruences and subdirectly irreducible algebras.

A  congruence on an algebra A is an equivalence relation that is compatible
(in the usual sense) with all the fundamental operations of A. As the
intersection of any family of congruences on A is again a congruence on A, the
mapping sending $X\subseteq A^{2}$ into $\vartheta_{\textbf{A}}(X)$ (the
smallest congruence of A containing $X$) is a closure operator on $A^{2}$ that
can be proved too by algebraic. Thus the congruences of A form an algebraic
lattice which we denote by $\operatorname{Con}({\textbf{A}})$; hence there are
always a largest and smallest congruence in $\operatorname{Con}({\textbf{A}})$
which will be denoted by $1_{\textbf{A}}$ and $0_{\textbf{A}}$. A variety
$\mathsf{V}$ is  congruence distributive if all congruence lattices of
algebras in $\mathsf{V}$ are distributive.

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. An
algebra A is finitely subdirectly irreducible if the same conclusion as above
holds whenever $I$ is finite.

######  Lemma 2.2.

For an algebra A the following are equivalent:

  1. 1.

A is subdirectly irreducible;

  2. 2.

$\operatorname{Con}({\textbf{A}})$ has exactly one minimal congruence
$\mu_{\textbf{A}}>0_{\textbf{A}}$ (which of course it is equivalent to saying
that $0_{\textbf{A}}$ is strictly meet irreducible in
$\operatorname{Con}({\textbf{A}})$);

  3. 3.

there are $a,b\in A$ such that $(a,b)\in\theta$ for all
$\theta\in\operatorname{Con}({\textbf{A}})$, $\theta>0_{\textbf{A}}$.

For any variety $\mathsf{V}$ we denote by $\mathsf{V}_{fsi}$ the class of
finitely subdirectly irreducible members of $\mathsf{V}$; we have the
classical results:

######  Theorem 2.3.

  1. 1.

(Birkhoff [15]) 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}$ and
then ${\mathbf{V}}(\mathsf{V}_{si})=\mathsf{V}$.

  2. 2.

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

###  2.3 Relative congruences

If $\mathsf{Q}$ is a quasivariety and ${\textbf{A}}\in\mathsf{Q}$, a
$\mathsf{Q}$-congruence (of A is a congruence $\theta$ such that
${\textbf{A}}/\theta\in\mathsf{Q}$; as the intersection of any family of
$\mathsf{Q}$-congruences of A is a $\mathsf{Q}$-congruence, they form an
algebraic lattice $\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$. If $H\subseteq
A^{2}$ the smallest $\mathsf{Q}$-congruence of A containing $H$ will be
denoted by $\theta_{\mathsf{Q}}(H)$; when $H=\\{(a,b)\\}$, we just write
$\theta_{\mathsf{Q}}(a,b)$. If ${\textbf{A}}\in\mathsf{Q}$ we say that A is
relatively subdirectly irreducible in $\mathsf{Q}$ (or briefly
$\mathsf{Q}$-irreducible) if for any subdirect embedding

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

for which ${\textbf{A}}_{i}\in\mathsf{Q}$ for all $i\in I$, there is an $i\in
I$ such that B and ${\textbf{A}}_{i}$ are isomorphic. The concept of finitely
$\mathsf{Q}$-irreducible is defined in an obvious way.

######  Lemma 2.4.

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

  1. 1.

A is $\mathsf{Q}$-irreducible;

  2. 2.

$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ has exactly one minimal congruence
above $0_{\textbf{A}}$;

  3. 3.

there are $a,b\in A$ such that $(a,b)\in\theta$ for all
$\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$, $\theta>0_{\textbf{A}}$.

The minimal congruence mentioned in Lemma 2.4 is called the
$\mathsf{Q}$-monolith of A. Observe also that, since
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is a meet subsemilattice of
$\operatorname{Con}({\textbf{A}})$, if A is subdirectly irreducible and
${\textbf{A}}\in\mathsf{Q}$, then A is $\mathsf{Q}$-irreducible. If
$\mathsf{Q}$ is any subquasivariety we denote by $\mathsf{Q}_{ir}$ and
$\mathsf{Q}_{fir}$ the classes of $\mathsf{Q}$-irreducible algebras and
finitely $\mathsf{Q}$-irreducible algebras in $\mathsf{Q}$, respectively. We
have the equivalent of Birkhoff’s and Jónsson’s results for quasivarieties:

######  Theorem 2.5.

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

  1. 1.

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

  2. 2.

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

First we observe:

######  Lemma 2.6.

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}})$;
since any subdirectly irreducible algebra B in
${\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})$ is
$\mathsf{Q}({\textbf{A}})$-irreducible by Theorem 2.5
${\textbf{B}}\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.3(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.3(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. ∎

Next:

######  Proposition 2.7.

Let $\mathsf{Q}$ be a quasivariety, ${\textbf{A}}\in\mathsf{Q}$, and
${\textbf{B}}\leq{\textbf{A}}$. Then, there exists a maximal
$\mathsf{Q}$-congruence $\theta$ on A such that

$\displaystyle\theta|_{\textbf{B}}=0_{\textbf{B}}.$

Moreover if B is $\mathsf{Q}$-irreducible, then ${\textbf{A}}/\theta$ is
$\mathsf{Q}$-irreducible.

###### Proof.

Let
$V=\\{\alpha\in\textrm{Con}_{\mathsf{Q}}{\textbf{A}}:\alpha|_{\textbf{B}}=0_{\textbf{B}}\\}$;
since $0_{\textbf{A}}\in V$, $V\neq\varnothing$. Let $C$ be an ascending chain
in $V$, and let $\theta:=\bigvee C$; as
$\mathsf{Con}_{\mathsf{Q}}{\textbf{A}}$ is an algebraic lattice, if for some
$a,b\in{\textbf{B}}$, $a\neq b$ and $(a,b)\in\theta$, then there is an
$\alpha\in C$ such that $(a,b)\in\alpha$, which contradicts $\alpha\in V$. By
Zorn’s Lemma $V$ has a maximal congruence $\theta$.

If B is $\mathsf{Q}$-irreducible, then (by Lemma 2.4(3)) there are two
elements $a,b\in{\textbf{B}}$ such that $(a,b)\in\theta^{\prime}$ for all
$\theta^{\prime}>0_{\textbf{B}}$. Now a relative proper congruence $\alpha$ of
${\textbf{A}}/\theta$ is of the form $\theta^{\prime}/\theta$ for some
$\theta^{\prime}>\theta$. Since $\theta$ is a maximal in $V$ we must have
$(a,b)\in\theta^{\prime}$ and thus
$(a/\theta,b/\theta)\in\theta^{\prime}/\theta$; by Lemma 2.4(3),
${\textbf{A}}/\theta$ is $\mathsf{Q}$-irreducible. ∎

###  2.4 Relatively finitely presented algebras.

Let $\sigma$ be a type and let $\mathsf{K}$ be a class of algebras of type
$\sigma$; let $X$ be a set of variables and $\Sigma$ be a set of equations of
type $\sigma$ in variables from $X$. We say that the pair $(X,\Sigma)$ is  a
$\mathsf{K}$-presentation of ${\textbf{A}}\in\mathsf{K}$ if there exists a
function $\alpha:X\longrightarrow A$ such that

  1. $\bullet$

$\alpha(X)$ generates A and for any $p(x_{1},\dots,x_{n})\approx
q(x_{1},\dots,x_{n})\in\Sigma$,

$p(\alpha(x_{1}),\dots,\alpha(x_{n}))=q(\alpha(x_{1}),\dots,\alpha(x_{n}));$

  2. $\bullet$

if ${\textbf{B}}\in\mathsf{K}$ and $\beta:X\longrightarrow B$ such that for
any $p(x_{1},\dots,x_{n})\approx q(x_{1},\dots,x_{n})\in\Sigma$,
$p(\beta(x_{1}),\dots,\beta(x_{n}))=q(\beta(x_{1}),\dots,\beta(x_{n}))$, then
there exists a homomorphism $f:{\textbf{A}}\longrightarrow{\textbf{B}}$ such
that $f(\alpha(x))=\beta(x)$ for all $x\in X$ (Figure 1).

XAB$\alpha$$\beta$$f$ Figure 1:

Let $F(X,\Sigma)$ be a representation of $\mathsf{Q}$-irreducible algebra A
and let $(p,q)$ any pair of elements generating the $\mathsf{Q}$-monolith of
A. We call the quasiidentity

$\Sigma\Rightarrow p\approx q$

a characteristic quasiidentity of A. We denote it by
$\textrm{ch}({\textbf{A}})$ the set of characteristic quasiidentities of A.

######  Lemma 2.8.

If an algebra ${\textbf{A}}\in\mathsf{Q}$ is $\mathsf{Q}$-irreducible and
$\mathsf{Q}$-finitely presented, then for every algebra
${\textbf{B}}\in\mathsf{Q}$ and for every $\Phi\in\textrm{ch}({\textbf{A}})$
${\textbf{B}}\not\vDash\Phi\iff{\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$.

###### Proof.

The right-to-left implication is obvious since ${\textbf{A}}\not\vDash\Phi$.
Assume then that ${\textbf{B}}\not\vDash\Phi$ and let

$\Phi=\\{p_{i}\approx q_{i}:i\in I\\}\Rightarrow p\approx q.$

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
$p(b_{1},\dots,b_{n})\neq p(b_{1},\dots,b_{n})$. Let $g$ be the homomorphism
extending the assignment $x_{i}\longmapsto b_{i}$; then
$\theta_{\mathsf{Q}}(\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$; but since
the pair $(p,q)$ generates the monolith of A any proper homomorphic image of A
must satisfy $\Phi$. Hence $f({\textbf{A}})\cong{\textbf{A}}$ and thus
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$. ∎

Lemma 2.8 implies that all the characteristic quasiidentities are
interderivable in the Birkhoff’s sense, i.e. they define the same
quasivariety; therefore the choice of $\Sigma,p,q$ does not matter. Therefore,
if $\mathsf{Q}$ is a quasivariety for any $(X,\Sigma)$ there is exactly one
algebra (up to isomorphism) ${\textbf{A}}\in\mathsf{Q}$ that is
$\mathsf{Q}$-presented by $(X,\Sigma)$; we will denote that algebra by
${\textbf{F}}_{\mathsf{Q}}(X,\Sigma)$ and we may assume that $\alpha(X)=X$,
i.e. $\alpha$ is the identity mapping. Note that
${\textbf{F}}_{\mathsf{Q}}(X,\emptyset)={\textbf{F}}_{\mathsf{Q}}(X)$. An
algebra ${\textbf{A}}\in\mathsf{Q}$ is  $\mathsf{Q}$-finitely presented if
${\textbf{A}}\cong{\textbf{F}}_{\mathsf{Q}}(X,\Sigma)$ for some finite sets
$X,\Sigma$.

If $p\approx q$ is an equation and $\Sigma$ is a set of equations in variables
from $X$, then $p\approx q$ is a $\mathsf{K}$-consequence of $\Sigma$ (in
symbols, $\Sigma\vdash_{\mathsf{K}}p\approx q$), if for every
${\textbf{B}}\in\mathsf{K}$ and every map
$\beta:X\longrightarrow{\textbf{B}}$,

${\textbf{B}}\models\beta(\Sigma)\text{ entails
}{\textbf{B}}\models\beta(p)\approx\beta(q).$

######  Theorem 2.9 ([50], Section 5).

Let ${\textbf{A}}\in\mathsf{K}$ be an algebra $\mathsf{K}$-presented by
$(X,\Sigma)$ and map $\alpha:X\longrightarrow{\textbf{A}}$. Then for any terms
$p$ and $q$ in variables from $X$,

$p(\alpha(\vec{x}))=q(\alpha(\vec{x}))\iff\Sigma\vdash_{\mathsf{K}}p(\vec{x})\approx
q(\vec{x}).$

######  Corollary 2.10.

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

  1. 1.

if $\Sigma_{1}$ and $\Sigma_{2}$ are sets of equations in variables from $X$
and $\Sigma_{1}\vdash_{\mathsf{K}}\Sigma_{2}$, then there is a homomorphism of
${\textbf{F}}(X,\Sigma_{1})$ onto ${\textbf{F}}(X,\Sigma_{2})$;

  2. 2.

$(X,\Sigma_{1})$ and $(X,\Sigma_{2})$ $\mathsf{K}$-define the same (up to
isomorphism) algebra if and only if

$\Sigma_{1}\vdash_{\mathsf{K}}\Sigma_{2}\text{ and
}\Sigma_{2}\vdash_{\mathsf{K}}\Sigma_{1}.$

Let $X$ be a set of variables and $\Sigma$ be a set of equations of type
$\sigma$ in variables from $X$; we denote by $\theta_{\mathsf{Q}}(\Sigma)$ the
$\mathsf{Q}$-congruence of ${\textbf{F}}_{\mathsf{Q}}(X)$ generated by all
pairs in $\\{(p,q):p\approx q\in\Sigma\\}$.

######  Lemma 2.11.

Let $\mathsf{Q}$ be a quasivariety, $X$ a set of variables and $\Sigma$ a set
of equations in variables from $X$; if $p\approx q$ is an equation in
variables from $X$ then the following are equivalent:

  1. 1.

${\textbf{F}}_{\mathsf{Q}}(X,\Sigma)\vDash p\approx q$;

  2. 2.

$\Sigma\vdash_{\mathsf{Q}}p\approx q$;

  3. 3.

$(p,q)\in\theta_{\mathsf{Q}}(\Sigma)$.

######  Theorem 2.12.

Let $\mathsf{Q}$ be a quasivariety. For any ${\textbf{A}}\in\mathsf{Q}$ the
following are equivalent:

  1. 1.

A is finitely $\mathsf{Q}$-presented by $(X,\Sigma)$;

  2. 2.

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

###### Proof.

It is enough to prove that
${\textbf{F}}_{\mathsf{Q}}(X,\Sigma)\cong{\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$.
Take $\beta$ to be the map sending $x\longmapsto
x/\theta_{\mathsf{Q}}(\Sigma)$; then for all $p\approx q\in\Sigma$

$p(\beta(\vec{x}))=\beta(p(\vec{x})=p(\vec{x})/\theta_{\mathsf{Q}}(\Sigma)=\dots=q(\beta(\vec{x}));$

Hence by definition there is a homomorphism
$f:{\textbf{F}}_{\mathsf{Q}}(X,\Sigma)\longrightarrow{\textbf{F}}_{\mathsf{Q}}(\Sigma)/\theta_{\mathsf{Q}}(\Sigma)$
with $f(x)=\beta(x)$ (where we have taken $\alpha=id_{X}$). Since
$\\{\beta(x):x\in X\\}$ generates
${\textbf{F}}_{\mathsf{Q}}(X)/\theta_{\mathsf{Q}}(\Sigma)$, $f$ is onto (see
Figure 2).

X${\textbf{F}}_{\mathsf{Q}}(X,\Sigma)$${\textbf{F}}_{\mathsf{Q}}/\theta_{\mathsf{Q}}(\Sigma)$$id_{X}$$\beta$$f$
Figure 2:

Let now $u,v\in{\textbf{F}}_{\mathsf{Q}}(X,\Sigma)$ with $f(u)=f(v)$; as $X$
generates the algebra, there are terms $s,t$ and $x_{1},\dots,x_{k}\in X$ with
$u=s(x_{1},\dots,x_{k})$ and $v=t(x_{1},\dots,x_{k})$. Hence
$s(\varphi(\vec{x}))=s(\varphi(\vec{y}))$ i.e.
$s(\vec{x})/\theta_{\mathsf{Q}}(\Sigma)=t(\vec{x})/\theta_{\mathsf{Q}}(\Sigma)$,
i.e. $(s,t)\in\theta_{\mathsf{Q}}(\Sigma)$. By Lemma 2.11,
${\textbf{F}}_{\mathsf{Q}}(X,\Sigma)\vDash s\approx t$ and thus
$u=s(\vec{x})=t(\vec{x})=v$. Thus $f$ is injective and the conclusion holds.

∎

Let $\mathsf{Q}$ be a quasivariety and ${\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}})\\}.$

######  Lemma 2.13.

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

  1. 1.

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

  2. 2.

if ${\textbf{A}}\in\mathsf{Q}$ is $\mathsf{Q}$-irreducible and
$\mathsf{Q}$-finitely presented, then $[\mathsf{Q}:{\textbf{A}}]$ is a
quasivariety.

Moreover if $\mathsf{Q}$ is locally finite then the converse implications in
(1) and (2) 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
precisely, if $|A|=n$, $\Psi$ is the conjunction of the diagram of A (which is
a conjunction of universal sentences that describe the operation tables of A)
and $\bigwedge_{i,j\leq n,i\neq j}\neg(x_{i}\approx x_{j})$. Now it is well-
known (and easy to check) that $\Psi$ defines the universal class $\mathsf{U}$
of algebras of the given type that do not contain A as a subalgebra. Therefore
$[\mathsf{Q};{\textbf{A}}]=\mathsf{Q}\cap\mathsf{U}$; as the intersection of
two universal classes is an universal class, it follows that
$[\mathsf{Q}:{\textbf{A}}]$ is universal.

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 the Łò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 therefore a universal class.

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 $\mathsf{Q}$-irreducible and finitely presented,
i.e.
${\textbf{A}}\cong{\textbf{F}}_{\mathsf{Q}}(\mathbf{x})/\theta_{\mathsf{Q}}(\Sigma)$.
If $\Phi$ is a characteristic quasiidentity of A then by Lemma 2.8 we get at
once that
$[\mathsf{Q}:{\textbf{A}}]=\\{{\textbf{B}}\in\mathsf{Q}:{\textbf{B}}\vDash\Phi\\}$
and this of course implies that $[\mathsf{Q}:{\textbf{A}}]$ is a quasivariety.

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 $\mathsf{Q}$-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}})$, so
that $|A|\leq|B|$; on the other hand
${\textbf{B}}\in{\mathbf{H}}({\textbf{A}})$, so $|B|\leq|A|$. Since everything
is finite we have ${\textbf{A}}={\textbf{B}}_{i}$ and A is
$\mathsf{Q}$-irreducible. ∎

In quasivarieties, finitely presented algebras sometimes behave as finite
algebras.

######  Corollary 2.14.

Let $\mathsf{Q}={\mathbf{Q}}(\mathsf{K})$ and let ${\textbf{A}}\in\mathsf{Q}$
be $\mathsf{Q}$-irreducible and $\mathsf{Q}$-finitely presented; then
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}(\mathsf{K})$.

###### Proof.

If ${\textbf{A}}\in\mathsf{Q}$ is $\mathsf{Q}$-irreducible and
$\mathsf{Q}$-finitely presented, and $\Phi$ is a characteristic quasiidentity
of A, then, as $\Phi$ fails in A it must fail for some
${\textbf{B}}\in\mathsf{K}$. It follows that
${\textbf{B}}\notin[\mathsf{Q}:{\textbf{A}}]$ which by definition implies
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})\subseteq{\mathbf{I}}{\mathbf{S}}(\mathsf{K})$.
∎

##  3 Relatively weakly projective algebras and primitive quasivarieties.

###  3.1 Structurally complete quasivarieties.

A quasivariety $\mathsf{Q}$ is  structurally complete if any proper
subquasivariety of $\mathsf{Q}$ generates a proper subvariety of
${\mathbf{H}}(\mathsf{Q})$. The proof of the following can be found in several
papers (see for instance [13], [22] and [8]).

######  Theorem 3.1.

(see also [13], [22]) For a quasivariety $\mathsf{Q}$ the following are
equivalent:

  1. 1.

$\mathsf{Q}$ is structurally complete;

  2. 2.

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

  3. 3.

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

  4. 4.

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

  5. 5.

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

For any quasivariety $\mathsf{Q}$, we define the  structural core of
$\mathsf{Q}$ as the smallest $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$ such
that ${\mathbf{H}}(\mathsf{Q})={\mathbf{H}}(\mathsf{Q}^{\prime})$. The
structural core of a quasivariety always exists:

######  Corollary 3.2.

For any quasivariety $\mathsf{Q}$,
${\mathbf{Q}}(\mathsf{F}_{\mathsf{Q}}(\omega))$ is structurally complete and
it is the structural core of $\mathsf{Q}$.

###### Proof.

${\mathbf{Q}}(\mathsf{F}_{\mathsf{Q}}(\omega))$ is structurally complete by
Theorem 3.1; if $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$ is such that
${\mathbf{H}}(\mathsf{Q}^{\prime})={\mathbf{H}}(\mathsf{Q})$, then clearly
${\textbf{F}}_{\mathsf{Q}}(\omega)\in\mathsf{Q}^{\prime}$ from which the
thesis follows. ∎

It follows at once that a quasivariety $\mathsf{Q}$ is structurally complete
if and only if it coincides with its structural core. As a consequence the
structurally complete subvarieties of a quasivariety $\mathsf{Q}$ are exactly
those that coincide with the structural cores of $\mathsf{Q}^{\prime}$ for
some $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$; even more, since
${\mathbf{H}}(\mathsf{Q})$ is a variety, the structurally complete
subquasivarieties of a variety $\mathsf{V}$ are exactly the structural cores
of $\mathsf{V}^{\prime}$ for some subvariety $\mathsf{V}^{\prime}$ of
$\mathsf{V}$. This observation is particularly useful when the free countably
generated algebra in $\mathsf{V}$ has a reasonable description; it has been
exploited in [40] (for Wajsberg algebras), [1] and [6] (for Wajsberg algebras
and hoops).

If $\mathsf{Q}$ is a quasivariety an algebra A is  $\mathsf{Q}$-exact if
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$.
Here are some sufficient conditions for structural completeness.

######  Lemma 3.3.

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

  1. 1.

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

  2. 2.

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

  3. 3.

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

  4. 4.

every finitely generated $\mathsf{Q}$-irreducible algebra in $\mathsf{Q}$ is
$\mathsf{Q}$-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
Theorem 3.1 . The other points follow from (1) since $\mathsf{Q}$ is generated
as a quasivariety by all the classes in (2), (3) and (4) (for (3) a proof is
in [41], Proposition 2.2.18).

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. ∎

If $\mathsf{Q}$ is locally finite then we get an equivalent condition.

######  Theorem 3.4.

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

  1. 1.

$\mathsf{Q}$ is structurally complete;

  2. 2.

every finite $\mathsf{Q}$-irreducible is $\mathsf{Q}$-exact.

###### Proof.

(1) implies (2) (regardless of local finiteness) by By Corollary 2.14 and
Theorem 3.1. If we assume (2), we observe that every locally finite
quasivariety is generated as a quasivariety by its finite algebras (as every
finitely generated algebra is finite); since they are all in
${\mathbf{I}}{\mathbf{S}}({\textbf{F}}_{\mathsf{Q}}(\omega))$, we conclude
that $\mathsf{Q}={\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$, i.e.
$\mathsf{Q}$ is structurally complete. ∎

###  3.2 Primitive quasivarieties.

Let $\mathsf{Q}$ be a quasivariety and $\mathsf{K}\subseteq\mathsf{Q}$; we say
that $\mathsf{K}$ is  equational relative to $\mathsf{Q}$ if
$\mathsf{K}={\mathbf{V}}(\mathsf{K})\cap\mathsf{Q}$. Clearly if
$\mathsf{Q},\mathsf{Q}^{\prime}$ are quasivarieties with
$\mathsf{Q}^{\prime}\subseteq Q$ then $\mathsf{Q}^{\prime}$ is  equational
relative to $\mathsf{Q}$ if and only if
$\mathsf{Q}^{\prime}={\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$; this
implies that $\mathsf{Q}^{\prime}$ is axiomatizable modulo $\mathsf{Q}$ by a
set of equations.

######  Lemma 3.5.

Let $\mathsf{Q}^{\prime}$ be equational relative to $\mathsf{Q}$. Then:

  1. 1.

for every ${\textbf{A}}\in\mathsf{Q}^{\prime}$,
$\textrm{Con}_{\mathsf{Q}^{\prime}}({\textbf{A}})=\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$;

  2. 2.

$Q^{\prime}_{ir}=\mathsf{Q}_{ir}\cap\mathsf{Q}^{\prime}$.

In particular if all the $\mathsf{Q}$-congruence lattices of algebras in
$\mathsf{Q}$ satisfy some lattice equation, then the same is true for all the
$\mathsf{Q}^{\prime}$-congruence lattices of algebras in any equational
subquasivariety of $\mathsf{Q}$.

A quasivariety $\mathsf{Q}$ is  primitive if every subquasivariety of
$\mathsf{Q}$ is equational in $\mathsf{Q}$; an algebra A is  weakly
$\mathsf{Q}$-primitive [13] if for any algebra ${\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}})$.

######  Theorem 3.6.

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.

every $\mathsf{Q}$-irreducible ${\textbf{A}}\in\mathsf{Q}$ is weakly
$\mathsf{Q}$-primitive.

###### 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 3.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 3.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.5 and (3) holds.

Conversely, assume (3) and let $\mathsf{Q}^{\prime}$ be a subquasivariety of
$\mathsf{Q}$. Let
${\textbf{B}}\in{\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$; then B is
subdirectly embeddable in $\prod_{i\in I}{\textbf{A}}_{i}$ where
${\textbf{A}}_{i}$ is $\mathsf{Q}$-irreducible. Now for any $i$
${\textbf{A}}_{i}\in{\mathbf{H}}({\textbf{B}})$, so
${\textbf{A}}_{i}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{B}})$.
As ${\textbf{B}}\in{\mathbf{H}}(\mathsf{Q}^{\prime})$, there is a
${\textbf{C}}\in Q^{\prime}$ with ${\textbf{B}}\in{\mathbf{H}}({\textbf{C}})$
and thus
${\textbf{A}}_{i}\in{\mathbf{H}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{C}})$.
So there is a
${\textbf{D}}_{i}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{C}})\subseteq\mathsf{Q}^{\prime}$
with ${\textbf{A}}_{i}\in{\mathbf{H}}({\textbf{D}}_{i})$. So
${\textbf{A}}_{i}\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{D}}_{i})\subseteq\mathsf{Q}^{\prime}$
for all $i\in I$; this implies ${\textbf{B}}\in Q^{\prime}$,
$\mathsf{Q}^{\prime}={\mathbf{H}}(\mathsf{Q}^{\prime})\cap\mathsf{Q}$ and
$\mathsf{Q}$ is primitive. ∎

We observe that the equivalence of (1) and (3) entails Theorem 2.12 from [13].
If instead of a quasivariety we consider a variety we get a little
improvement.

######  Corollary 3.7.

For a variety $\mathsf{V}$ the following are equivalent:

  1. 1.

$\mathsf{V}$ is primitive;

  2. 2.

every subquasivariety of $\mathsf{V}$ is a variety;

  3. 3.

$\mathsf{V}$ is structurally complete and every proper subvariety of
$\mathsf{V}$ is primitive.

###### Proof.

Trivially (1) and (2) are equivalent and imply (3). Assume then (3) and let
$\mathsf{Q}$ be a subquasivariety of $\mathsf{V}$; if $\mathsf{Q}=\mathsf{V}$
then it is a variety. Otherwise ${\mathbf{H}}(\mathsf{Q})$ must be a proper
subvariety of $\mathsf{V}$, so it is primitive; hence $\mathsf{Q}$ is a
variety and (2) follows. ∎

We will see later that the hypothesis of structural completeness for
$\mathsf{V}$ cannot be removed: there are varieties such that every proper
subvariety is primitive but fail to be structurally complete. To get more
information we need some definitions: let A be an algebra and $\mathsf{K}$ a
class of algebras of the same type as A. We say that:

  1. $\bullet$

A is  projective in $\mathsf{K}$ if for all ${\textbf{B}}\in\mathsf{K}$ if
$f:{\textbf{B}}\longrightarrow{\textbf{A}}$ is a surjective epimorphism, then
there is an embedding $g:{\textbf{A}}\longrightarrow{\textbf{B}}$ with
$gf=id_{\textbf{A}}$;

  2. $\bullet$

A is  weakly $\mathsf{K}$-projective if for all ${\textbf{B}}\in\mathsf{K}$ if
${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$, then
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$.

It is clear that if A is projective in $\mathsf{K}$, then A is weakly
$\mathsf{K}$-projective.

######  Lemma 3.8.

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

  1. 1.

A is weakly $\mathsf{Q}$-projective;

  2. 2.

$[\mathsf{Q}:{\textbf{A}}]$ is closed under ${\mathbf{H}}$.

###### Proof.

Assume (1), and 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
$\mathsf{Q}$-projective; 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}}$. Assume now (2); we show that A is weakly
$\mathsf{Q}$-projective. 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
$\mathsf{Q}$-projective. ∎

######  Corollary 3.9.

Let $\mathsf{Q}$ be a quasivariety; if A is $\mathsf{Q}$-irreducible and
$\mathsf{Q}$-finitely presented then the following are equivalent:

  1. 1.

A is weakly $\mathsf{Q}$-projective;

  2. 2.

$[\mathsf{Q}:{\textbf{A}}]$ is $\mathsf{Q}$-equational;

  3. 3.

$[\mathsf{Q}:{\textbf{A}}]$ is a variety.

###### Proof.

If (1) holds then $[\mathsf{Q}:\mathsf{A}]$ is a quasivariety by Lemma 2.13
and it is closed under ${\mathbf{H}}$ by Lemma 3.8; therefore it is a variety
and (3) holds. Clearly (3) implies (2), so let’s assume (2) i.e.
$[\mathsf{Q}:{\textbf{A}}]={\mathbf{H}}([\mathsf{Q}:{\textbf{A}}])\cap\mathsf{Q}$.
Let ${\textbf{B}}\in\mathsf{Q}$ with
${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$; if
${\textbf{A}}\notin{\mathbf{S}}({\textbf{B}})$, then
${\textbf{B}}\in[\mathsf{Q}:{\textbf{A}}]$ and thus
${\textbf{A}}\in{\mathbf{H}}([\mathsf{Q}:{\textbf{A}}])$. As
${\textbf{A}}\in\mathsf{Q}$ we get ${\textbf{A}}\in[\mathsf{Q}:{\textbf{A}}]$,
a contradiction; so ${\textbf{A}}\in{\mathbf{S}}({\textbf{B}})$ and therefore
it is weakly $\mathsf{Q}$-projective. ∎

Again Corollary 3.9 entails Lemma 5.1.23 from [41]; also we get at once that
if $\mathsf{Q}$ is primitive, then every finitely $\mathsf{Q}$-presented
$\mathsf{Q}$-irreducible algebra in $\mathsf{Q}$ must be weakly
$\mathsf{Q}$-projective. The converse however does not seem to be true in
general; it is however when we restrict to locally finite quasivarieties
(Theorem 3.10 below).

A class $\mathsf{K}$ of algebras is  tame if every finitely generated algebra
in $\mathsf{K}$ is $\mathsf{K}$-finitely presented. Note that the concept has
content: any class $\mathsf{K}$ of algebras of finite type which is locally
finite in the usual sense (i.e. every finitely generated algebra in
$\mathsf{K}$ is finite) is tame since in that case the class of finite
algebras, the class of finitely generated and the class of finitely presented
algebras coincide. Tame classes of algebras have been studied mainly in groups
(better, in algebras in which groups are interpretable): for instance
nilpotent groups are tame, so Abelian groups are tame (and it is an example of
a tame non locally finite variety).

The next result is implicit in [41] (Section 5.1) for locally finite
quasivarieties (for a self-contained proof the reader can look at [8], Theorem
4.11); tameness is weaker than local finiteness but the same proof goes
through with minimal changes.

######  Theorem 3.10.

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

  1. 1.

$\mathsf{Q}$ is primitive;

  2. 2.

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

  3. 3.

every finitely generated $\mathsf{Q}$-irreducible ${\textbf{A}}\in\mathsf{Q}$
is weakly $\mathsf{Q}$-projective;

  4. 4.

every finitely generated $\mathsf{Q}$-irreducible ${\textbf{A}}\in\mathsf{Q}$
is weakly $\mathsf{Q}_{fg}$-projective, where $\mathsf{Q}_{fg}$ is the class
of finitely generated algebras in $\mathsf{Q}$.

We observe that (4) implies (1) even in the absence of tameness; so we get:

######  Corollary 3.11.

Let $\mathsf{Q}$ be a quasivariety; if every finitely generated
$\mathsf{Q}$-irreducible algebra is weakly $\mathsf{Q}$-projective (or even
weakly $\mathsf{Q}_{fg}$-projective) then $\mathsf{Q}$ is primitive.

From the fact that any locally finite variety is tame we get:

######  Corollary 3.12.

Let $\mathsf{Q}$ be a quasivariety such that every finite
${\textbf{A}}\in\mathsf{Q}$ is weakly $\mathsf{Q}$-projective. Then every
locally finite subquasivariety of $\mathsf{Q}$ is primitive.

We have another characterization of weak $\mathsf{Q}$-projectivity that gives
rise to an interesting class of examples.

######  Lemma 3.13.

Let $\mathsf{K}$ be any class of algebras. Then the following are equivalent:

  1. 1.

every algebra in $\mathsf{K}$ is weakly $\mathsf{K}$-projective;

  2. 2.

for all ${\textbf{A}}\in\mathsf{K}$ and for any
$\theta\in\textrm{Con}_{\mathsf{K}}({\textbf{A}})$ there is and endomorphism
$f$ of A with $\theta=\textrm{ker}(f)$.

Moreover every algebra in $\mathsf{K}$ is projective in $\mathsf{K}$ if and
only if $f$ in (2) can always taken to be idempotent.

###### Proof.

Assume (1) and let ${\textbf{B}}\in\mathsf{K}$ and
$\theta\in\textrm{Con}_{\mathsf{K}}({\textbf{B}})$; then
${\textbf{A}}={\textbf{B}}/\theta\in\mathsf{K}$ and
${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$. By (1),
${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$; if $f$ is the
canonical epimorphism and $g$ is the embedding, then $gf$ is and endomorphism
of A whose kernel is equal to $\theta$. Moreover if B is projective, then $gf$
is the identity and so it is idempotent.

Conversely assume (2) let ${\textbf{A}}\in\mathsf{K}$ such that
${\textbf{A}}\in{\mathbf{H}}({\textbf{B}})$ for some
${\textbf{B}}\in\mathsf{K}$. Then ${\textbf{A}}\cong{\textbf{B}}/\theta$ for
some $\theta\in\textrm{Con}_{\mathsf{K}}({\textbf{B}})$ and there is an
endomorphism $f$ of B with $\textrm{ker}(f)=\theta$. If
$f({\textbf{B}})={\textbf{C}}$ then

${\textbf{A}}\cong{\textbf{B}}/\theta\cong{\textbf{B}}/\textrm{ker}(f)\cong{\textbf{C}}\leq{\textbf{B}}.$

So ${\textbf{A}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$ and it is weakly
$\mathsf{K}$-projective. If $f$ is idempotent then for all $b\in B$,
$(b,f(b))\in\textrm{ker}(f)$; if $g:{\textbf{B}}\longrightarrow{\textbf{A}}$
is the canonical epimorphism then $g(b)=g(f(b))$. If
$h:{\textbf{C}}\longrightarrow{\textbf{A}}$ is the isomorphism, then $h$ is a
monomorphism from A to B. If $a\in A$ and $b\in B$ with $g(b)=a$ then

$g(h(a))=g(f(b))=g(b)=a.$

We have just proved that A is a retract of B, so A is projective in
$\mathsf{K}$. ∎

Since every locally finite variety is tame from Theorem 3.10 we get:

######  Corollary 3.14.

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

  1. 1.

every finite algebra in $\mathsf{Q}$ is weakly $\mathsf{Q}_{fin}$-projective,
where $\mathsf{Q}_{fin}$ is the class of finite algebras in $\mathsf{Q}$;

  2. 2.

every locally finite subquasivariety of $\mathsf{Q}$ is primitive.

Finally we observe that many of the known examples above have the property
that every $\mathsf{Q}$-finitely presented $\mathsf{Q}$-irreducible algebra is
projective in $\mathsf{Q}$, which is an (apparently) stronger condition than
the one requested by Theorem 3.10. This is because it seems plausible that
being projective in a quasivariety $\mathsf{Q}$ is a strictly stronger concept
that being weakly $\mathsf{Q}$-projective (and indeed it is, see Example 3.17
below). However:

######  Theorem 3.15.

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 $\mathsf{Q}$-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.5(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}})$. ∎

We close this section with several examples

######  Example 3.16.

(Fragments of Heyting algebras) An early example of an application of Lemma
3.13 is in the seminal papers [55], [56] and [57]. Remember that for any
Hilbert algebra A and $a,b,c\in A$

$a\rightarrow(b\rightarrow c)=(a\rightarrow b)\rightarrow(a\rightarrow c).$

Let now A be a finite Hilbert algebra,
$\theta\in\operatorname{Con}({\textbf{A}})$ and $F=1/\theta$ the filter
associated with $\theta$. Since A is finite, so is $F$ and hence we may assume
that $F=\\{a_{1},\dots,a_{n}\\}$; define

$\varphi(x)=a_{1}\rightarrow(a_{2}\rightarrow\dots\rightarrow(a_{n}\rightarrow
x)).$

Then clearly $\varphi$ is an endomorphism of A; moreover if $\varphi(b)=1$
then

$a_{1}\rightarrow(a_{2}\rightarrow\dots\rightarrow(a_{n}\rightarrow b))=1$

and since $a_{1},\dots,a_{n}\in F$ we get by modus ponens that $b\in F$. Hence
$\textrm{Ker}(\varphi)\subseteq F$; on the other hand $\textrm{Ker}(\varphi)$
is a filter and for any $i\leq n$

$\displaystyle\varphi(a_{i})$
$\displaystyle=a_{1}\rightarrow(a_{2}\rightarrow\dots\rightarrow(a_{n}\rightarrow
a_{i}))$ $\displaystyle\geq
a_{1}\rightarrow(a_{2}\rightarrow\dots\rightarrow(a_{n-1}\rightarrow a_{i}))$
$\displaystyle\quad\vdots$ $\displaystyle\geq
a_{1}\rightarrow(a_{2}\rightarrow\dots\rightarrow(a_{i}\rightarrow a_{i}))=1$

so $a_{1}\in\textrm{Ker}(\varphi)$ for $i\leq n$. Hence
$F=\textrm{Ker}(\varphi)$ and every finite Hilbert algebra is projective
(since $\varphi$ is clearly idempotent) in the class of finite Hilbert
algebras. It follows that any locally finite subvariety of Hilbert algebras is
primitive; but Hilbert algebras themselves are locally finite [35] so any
variety of Hilbert algebras is primitive (and so are their prelinear versions,
i.e. varieties of Gödel BCK-algebras)). All this follows of course also from
Prucnal’s results ([56], [57]).

The ${\rightarrow,\wedge}$ fragment (i.e. Brouwerian semilattices) is easier
since $(\rightarrow,\wedge)$ form a residuated pair. Let A be a Brouwerian
semilattice, then for all $a,b,c\in A$

$a\rightarrow(b\wedge c)=(a\rightarrow b)\wedge(a\rightarrow c).$

But Brouwerian semilattices are locally finite [47], so every the variety of
Brouwerian semilattices is primitive (and so is its prelinear version, i.e.
varieties of Gödel hoops [5]).

If we add the join (i.e. we have Brouwerian lattices), then we run into
problems since we can no longer prove that the map we want to define is an
endomorphism. However in [33] the second author proved that there are two
Brouwerian lattices, called ${\textbf{S}}_{1}$ and ${\textbf{S}}_{2}$ such
that, for any variety $\mathsf{V}$ of Brouwerian lattices

  1. $\bullet$

if ${\textbf{S}}_{1}\notin\mathsf{V}$, then $\mathsf{V}$ is locally finite;

  2. $\bullet$

if ${\textbf{S}}_{1},{\textbf{S}}_{2}\notin\mathsf{V}$, then every finite
Brouwerian lattice in $\mathsf{V}$ is projective in $\mathsf{V}_{fin}$;

  3. $\bullet$

if either ${\textbf{S}}_{1}\in\mathsf{V}$ or ${\textbf{S}}_{2}\in\mathsf{V}$,
then $\mathsf{V}$ is not primitive.

It follows that a variety of Brouwerian lattices is primitive if and only if
it does not contain ${\textbf{S}}_{1}$ and ${\textbf{S}}_{2}$; moreover all
such varieties are locally finite.

Primitive subvarieties of Heyting algebras have been totally characterized in
[32]. Other applications of Lemma 3.13 to (fragments of) commutative
residuated lattices can be found in [7]; a more general theory encompassing
these results is in Section 4.2 below.∎

######  Example 3.17.

The only examples we know of a algebras that are $\mathsf{Q}$-weakly
projective but not projective appeared very recently. A modal algebra is a
Boolean algebra with a modal operator $\Box$, that we take as a fundamental
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 [65] and the bibliography therein). A modal algebra is a K4-algebra
if it satisfies $\Box x\leq\Box\Box x$; in [59] V.V. Rybakov classified all
the primitive varieties of K4-algebras. However very recently [26] J. Carr
discovered a mistake in Rybakov’s proof; in his description some varieties are
missing. Upon reading the thesis the first author of this paper suggested that
this probably depended on the fact that these varieties contained a weakly
projective algebra that is not projective. And J. Carr proved exactly that
(private communication): all the varieties missed by Rybakov contain a weakly
projective algebra that is not projective.∎

######  Example 3.18.

The first example of a locally finite variety that is structurally complete
but not primitive, appeared in the seminal paper [13]. The idea is to find a
finite algebra A such that A is projective in ${\mathbf{Q}}({\textbf{A}})$ (so
that ${\mathbf{Q}}({\textbf{A}})$ is structurally complete by Lemma 3.3) but
such that ${\mathbf{Q}}({\textbf{A}})$ contains a totally non projective
algebra in the sense of [32]. In [13] Bergman observed that the Fano lattice F
has exactly those characteristics; the Fano lattice is the lattice of
subspaces of $(\mathbb{Z}_{2})^{3}$ seen as a vector space on $\mathbb{Z}_{2}$
and it is displayed in Figure 3.

Figure 3: The Fano lattice

Now F is projective in ${\mathbf{V}}({\textbf{F}})$ [42], hence in
${\mathbf{Q}}({\textbf{F}})$, but F has a subalgebra that is totally non
projective. Therefore ${\mathbf{Q}}({\textbf{F}})$ is a locally finite
structurally complete quasivariety of lattices that is not primitive.

The second author in [32] used the same technique to show that there is a
variety of Heyting algebras (which is the equivalent algebraic semantics of
Medvedev’s Logic) that is structurally complete but not primitive; more
examples of structurally complete not primitive subvarieties of this variety
can be found in [61]. Various examples of structurally complete non primitive
quasivarieties of Wajsberg algebras and Wajsberg hoops appear in [1] and [6].∎

######  Example 3.19.

(Quasivarieties of abelian groups and modules) Since abelian groups are tame
we can deal only with finitely generated abelian groups; the Fundamental
Theorem states that a finitely generated abelian group is isomorphic to the
direct product (direct sum really, but since there are only finitely many
summands it is the same) of a finite power of $\mathbb{Z}$ and finitely many
finite cyclic groups. This implies at once that:

  1. $\bullet$

the variety of abelian groups is ${\mathbf{V}}(\mathbb{Z})$ (since all
finitely generated abelian groups belong to ${\mathbf{V}}(\mathbb{Z})$);

  2. $\bullet$

a subquasivariety of abelian groups is proper if and only if it does not
contain $\mathbb{Z}$;

  3. $\bullet$

every proper subvariety is finitely generated by finitely many cyclic groups.

Let’s justify the last argument; if $\mathsf{V}$ is locally finite let F be
the 1-generated free algebra in $\mathsf{V}$; then F is finite and cyclic and
every cyclic group in $\mathsf{V}$ is a homomorphic image of F. As F is finite
there are only finitely many of them and, by the Fundamental Theorem, they
generate all the finitely generated groups in $\mathsf{V}$. Thus $\mathsf{V}$
is generated by them and thus it is finitely generated. Hence every proper
subvariety of the variety of abelian groups is locally finite.

Moreover any locally finite variety of abelian groups is primitive; in fact
every finite subdirectly irreducible abelian group is cyclic of order $p^{n}$
for some prime $p$. If $\mathsf{V}$ is a locally finite variety of abelian
groups, let ${\textbf{A}}\in\mathsf{V}$ and let
$f:{\textbf{A}}\longrightarrow\mathbb{Z}_{p^{n}}$ be a onto homomorphism; if
$b$ is generator of $\mathbb{Z}_{p^{n}}$ then any $a\in f^{-1}(b)$ generates
in A a finite cyclic group C of which $\mathbb{Z}_{p^{n}}$ is a homomorphic
image. But it is well-known that homomorphic images and subalgebras of a
cyclic group coincide so really
$\mathbb{Z}_{p^{n}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{C}})$. Hence
$\mathbb{Z}_{p^{n}}\in{\mathbf{I}}{\mathbf{S}}({\textbf{B}})$ and it is weakly
projective in $\mathsf{V}$. By Theorem 3.10 $\mathsf{V}$ is primitive.

Now observe that $\mathbb{Z}$ is torsion-free so it satisfies all the quasi
equations

$nx\approx 0\qquad\Longrightarrow\qquad x\approx 0.$ ($\varepsilon_{n}$)

Hence ${\mathbf{Q}}(\mathbb{Z})$ satisfies the same quasiequations and it is a
proper subquasivariety; but of course ${\mathbf{H}}({\mathbf{Q}}(\mathbb{Z}))$
is the entire variety of abelian groups, and so the variety of abelian groups
cannot be structurally complete. So abelian groups form a variety in which
every proper subvariety is primitive but the variety fails to be structurally
complete. To close the circle we observe that also ${\mathbf{Q}}(\mathbb{Z})$
is primitive since it is an atom in the lattice of subquasivarieties of
abelian groups. To prove that, let $\mathsf{Q}$ be a proper subquasivariety of
$\mathsf{Q}(\mathbb{Z})$; then $\mathbb{Z}\notin\mathsf{Q}$. If $\mathsf{Q}$
is nontrivial then it contains finitely generated nontrivial algebras and each
of them is a direct product of cyclic groups; since any factor of a direct
product is also a subalgebra $\mathsf{Q}$ must contain at least a finite
cyclic group. But any finite cyclic group does not satisfy $\varepsilon_{n}$
for some (really infinitely many) $n$; thus $\mathsf{Q}$ must be trivial and
${\mathbf{Q}}(\mathbb{Z})$ is an atom in the lattices of subquasivarieties.
Therefore it is primitive.

Finally there are no other primitive subquasivarieties of the variety of
abelian groups, other the ones we described. First observe that the only
locally finite primitive subquasivarieties are the locally finite
subvarieties. If $\mathsf{Q}$ is a primitive proper subquasivariety of abelian
groups that is not locally finite, then $\mathbb{Z}\in\mathsf{Q}$ so
${\mathbf{Q}}(\mathbb{Z})\subseteq\mathsf{Q}$; since $\mathsf{Q}$ is primitive
it is structurally complete and thus every proper subquasivariety of
$\mathsf{Q}$ must generate a proper subvariety of abelian groups (Theorem 3.1)
. But ${\mathbf{Q}}(\mathbb{Z})$ generates the entire variety of abelian
groups so it cannot be proper; hence ${\mathbf{Q}}(\mathbb{Z})=\mathsf{Q}$.

Now an abelian group is a module over $\mathbb{Z}$ seen as a principal ideal
domain and not surprising most of what we said has been generalized to modules
over a PID [12] and (at some cost) even to modules over a Dedekind domain
[44]. In general, if $\mathsf{M}_{\textbf{R}}$ is the variety of modules over
a Dedekind domain R, the primitive subquasivarieties of
$\mathsf{M}_{\textbf{R}}$ are exactly the locally finite varieties and
${\mathbf{Q}}({\textbf{R}})$ (regarded as an R-module over itself).∎

##  4 More on structural completeness

###  4.1 $C$-completeness

The concept of $C$-completeness has been introduced by the second author in
[31]. Let $A$ be any set; a clone of operations on $A$ is a set of operations
on $A$ that contains all the projections and it is closed under composition
(whenever possible). As the intersection of any family of clones is still a
clone, it makes sense to talk about clone generation (that is of course a
closure operator). If A is any algebra, then the term clone of A, denoted by
$\textrm{Clo}({\textbf{A}})$ is the clone on $A$ generated by all the
fundamental operations.

Let now $\mathsf{Q}$ be a quasivariety; then the terms in the language of
$\mathsf{Q}$ can be seen as operations on ${\textbf{F}}_{\mathsf{Q}}(\omega)$,
and the set of all terms is just the clone of all derived operations on
${\textbf{F}}_{\mathsf{Q}}(\omega)$, i.e. the clone on
${\textbf{F}}_{\mathsf{Q}}(\omega)$ generated by all the fundamental
operations. We will refer to it as the term clone of $\mathsf{Q}$ and we will
denote it by $\textrm{Clo}(\mathsf{Q})$. Let $C$ be a subclone of
$\textrm{Clo}(\mathsf{Q})$; a $C$-quasiequation is a quasiequation containing
only operations from $C$. We say that $\mathsf{Q}$ is $C$-structurally
complete if for every $C$-quasiequation $\Phi$, if
${\textbf{F}}_{\mathsf{Q}}(\omega)\vDash\Phi$, then $\mathsf{Q}\vDash\Phi$. A
quasivariety is $C$-primitive if all its subquasivarieties are
$C$-structurally complete. Observe that if $C^{\prime}$ is a subclone of $C$
and $\mathsf{Q}$ is $C$-structurally complete ($C$ primitive), then
$\mathsf{Q}$ is $C^{\prime}$-structurally complete ($C^{\prime}$-primitive).
Observe also that if $T$ is a set of generators for $C$, it is easy to check
that $\mathsf{Q}$ is $C$-structurally complete if and only if for every
quasiequation $\Phi$ containing only operations from $T$,
${\textbf{F}}_{\mathsf{Q}}(\omega)\vDash\Phi$ entails $\mathsf{Q}\vDash\Phi$.
Therefore if $T$ is a set of terms that generates $C$ we may talk about
$T$-structural completeness and $T$-primitivity, meaning the corresponding
concept for the clone generated by $T$. If $C$ is the entire term clone of
$\mathsf{Q}$ then $C$-structural completeness is the usual structural
completeness.

Let $\mathsf{Q}$ be a quasivariety and let $C$ a subclone of the term clone of
$\mathsf{Q}$. Let $\mathsf{Q}^{C}$ be the class of all $C$-subreducts of
algebras in $\mathsf{Q}$; then it is easily seen that $\mathsf{Q}^{C}$ is a
quasivariety in which all the $C$-quasiequation holding in $\mathsf{Q}$ are
valid. So if $\mathsf{Q}^{C}$ is structurally complete or primitive, then
$\mathsf{Q}$ is $C$-structurally complete or $C$-primitive. For instance if
$\mathsf{H}$ is the variety of Heyting algebras, then its
$\\{\wedge,\rightarrow\\}$-subreducts form the variety of Brouwerian
semilattices, that is (as we have already observed) primitive; thus
$\mathsf{H}$ is $\\{\wedge,\rightarrow\\}$-primitive.

The converse however fails to hold; the variety $\mathsf{H}$ of Heyting
algebras is $\\{\rightarrow,\neg\\}$-structurally complete [51] but the
quasivariety of its $\\{\rightarrow,\neg\\}$-subreducts is not structurally
complete [28]. The problem is that there is a
$\\{\rightarrow,\neg\\}$-quasiequation that is valid in the in
${\textbf{F}}_{\mathsf{H}^{\\{\rightarrow,\neg\\}}}(\omega)$ but it is not
valid in ${\textbf{F}}_{\mathsf{H}}(\omega)$.

###  4.2  u-presentability and Prucnal terms

Let A be any algebra, $\theta\in\textrm{Con}({\textbf{A}})$ and let $C$ be a
subclone of $\textrm{Clo}({\textbf{A}})$; by ${\textbf{A}}^{C}$ we denote the
algebra whose universe is $A$ and whose fundamental operations are those in
$C$. We say that $\theta$ is u-presentable relative to $C$ if there is a set
$\Delta\subseteq\textrm{Con}({\textbf{A}})$ such that

  1. 1.

$\theta=\bigcup\Delta$;

  2. 2.

$\Delta$ is closed under finite joins;

  3. 3.

${\textbf{A}}^{C}/\delta\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}}^{C})$
for all $\delta\in\Delta$.

In this case $\Delta$ is called a u-presentation of $\theta$ relative to $C$.

######  Theorem 4.1.

Let A be an algebra, $\theta\in\operatorname{Con}({\textbf{A}})$ and $C$ a
subclone of $\textrm{Clo}({\textbf{A}})$; then the following are equivalent:

  1. 1.

$\theta$ is u-presentable relative to $C$;

  2. 2.

${\textbf{A}}^{C}/\theta\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}}^{C})$.

###### Proof.

Obviously (2) implies (1). Let then
$\mathsf{U}={\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}}^{C})$ and
let $\Delta$ be a u-presentation of $\theta$ relative to $C$. For any
$\delta\in\Delta_{\theta}$, let
$L_{\delta}\\{\varepsilon\in\Delta:\delta\leq\varepsilon\\}$. By the
definition of u-presentability if $\delta,\delta^{\prime}\in\Delta$, then
$\delta\vee\delta^{\prime}\in\Delta$, hence $\\{L_{\delta}:\delta\in\Delta\\}$
has the finite intersection property. Therefore there exists an ultrafilter
$U$ on $\Delta$ such that $L_{\delta}\in U$ for all $\delta\in\Delta$.

Consider the map

$f:a\longmapsto(a/\delta)_{\delta\in\Delta}/U;$

this is clearly a homomorphism from ${\textbf{A}}^{C}$ to
$\prod_{d\in\Delta}{\textbf{A}}^{C}/\delta$. We claim that
$\textrm{ker}(f)=\theta$. In fact if
$(a/\delta)_{\delta\in\Delta}/U=(b/\delta)_{\delta\in\Delta}/U$, then
$\\{\delta:a/\delta=\beta/\delta\\}\in U$. If $(a,b)\notin\theta$ then, as
$\theta=\bigcup\Delta$, $(a,b)\notin\delta$ for all $\delta\in J$; this
implies that $\\{\delta:a/\delta=\beta/\delta\\}=\emptyset$ which contradicts
the fact that $U$ is an ultrafilter. Hence $(a,b)\in\theta$ and
$\theta=\textrm{ker}(f)$.

Conversely assume that $(a,b)\in\theta$; then $(a,b)\in\delta^{\prime}$ for
some $\delta^{\prime}\in\Delta$. It follows that $(a,b)\in\varepsilon$ for all
$\varepsilon\in L_{\delta^{\prime}}$ and thus

$L_{\delta^{\prime}}\subseteq\\{\delta:a/\delta=b/\delta\\}.$

As $U$ extends $\\{L_{\delta}:\delta\in J\\}$, the right hand side of the
above inclusion belongs to $U$, which means that $(a/\delta)_{\delta\in
J}/U=(b/\delta)_{\delta\in J}/U$ as wished. Therefore
${\textbf{A}}^{C}/\delta\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}}^{C})$.
∎

######  Corollary 4.2.

For any algebra A and $C\subseteq\textrm{Clo}({\textbf{A}})$ the following are
equivalent:

  1. 1.

every congruence of A is u-presentable relative to $C$;

  2. 2.

every compact congruence of A is $u$-presentable relative to $C$.

###### Proof.

(1) trivially implies (2). Let $\theta\in\operatorname{Con}({\textbf{A}})$ and
let
$\Delta_{\theta}=\\{\delta\in\operatorname{Con}({\textbf{A}}):\delta\leq\theta,\
\text{$\delta$ compact}\\}$. Then $\Delta_{\theta}$ is closed under finite
joins an $\bigcup\Delta_{\theta}=\theta$. Moreover by Theorem 4.1,
${\textbf{A}}^{C}/\delta\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}}^{C})$
for all $\delta\in\Delta_{\theta}$. Therefore $\theta$ is u-presentable
relative to $C$. ∎

Now we can connect u-presentability and structural completeness, but first we
need a lemma.

######  Lemma 4.3.

Let $\mathsf{Q}$ be a quasivariety and let

$\Phi:=\bigwedge_{i=1}^{n}r_{i}(\mathbf{x})\approx
s_{i}(\mathbf{x})\Rightarrow r(\mathbf{x})\approx s(\mathbf{x})$

be a quasiequation. Then $\mathsf{Q}\vDash\Phi$ if and only if
${\textbf{A}}\vDash\Phi$ where A is an algebra in $\mathsf{Q}$ finitely
presented by the relations $r_{i}(\mathbf{x})\approx s_{i}(\mathbf{x})$,
$i=1,\dots,n$.

###### Proof.

The left-to-right implication is trivial. Suppose that
${\textbf{A}}\vDash\Phi$ and assume by way of contradiction that there is
${\textbf{B}}\in\mathsf{Q}$ with ${\textbf{B}}\not\vDash\Phi$. Then there are
$b_{1},\dots,b_{n}\in B$ such that

$r_{i}(b_{1},\dots,b_{n})=s_{i}(b_{1},\dots,b_{n})\quad\text{ for all $i$}$

but $r(b_{1},\dots,b_{n})\neq s(b_{1},\dots,b_{n})$.

As A is finitely presented and generated by $a_{1},\dots,a_{n}$ we can extend
the map $f:a_{i}\longmapsto b_{i}$ to a homomorphism
$f:{\textbf{A}}\longrightarrow{\textbf{B}}$. By assumption,
${\textbf{A}}\vDash\Phi$ and thus $r(a_{1},\dots,a_{n})=s(a_{1},\dots,a_{n})$.
Therefore

$\displaystyle r(b_{1},\dots,b_{n})$
$\displaystyle=r(f(a_{1}),\dots,f(a_{n}))$
$\displaystyle=f(r(a_{1},\dots,a_{n}))=f(s(a_{1},\dots,a_{n}))$
$\displaystyle=s(f(a_{1}),\dots,f(a_{n}))=s(b_{1},\dots,b_{n}).$

So ${\textbf{B}}\vDash\Phi$, a clear contradiction. ∎

######  Corollary 4.4.

Let $\mathsf{Q}$ be a quasivariety and $\Phi$ be a quasiequation. Then
$\mathsf{Q}\vDash\Phi$ if and only if for every compact
$\mathsf{Q}$-congruence $\theta$ of ${\textbf{F}}_{\mathsf{Q}}(\omega)$ we
have ${\textbf{F}}_{\mathsf{Q}}(\omega)/\theta\vDash\Phi$.

######  Theorem 4.5.

Let $\mathsf{Q}$ be a quasivariety, ${\textbf{A}}\in\mathsf{Q}$ and $C$ a
clone of operations of $\mathsf{Q}$; if every compact congruence of
${\textbf{F}}_{\mathsf{Q}}(\omega)$ is u-presentable relative to $C$, then
$\mathsf{Q}$ is $C$-structurally complete.

###### Proof.

Let $\Phi$ be a $C$-quasiequation and suppose that $\mathsf{Q}\not\vDash\Phi$;
then by Corollary 4.4 there exists a compact $\mathsf{Q}$-congruence $\theta$
of ${\textbf{F}}_{\mathsf{Q}}(\omega)$ such that
${\textbf{F}}_{\mathsf{Q}}(\omega)/\theta\not\vDash\Phi$. Since $\theta$ is
u-presentable relative to $C$, ${\textbf{F}}^{C}_{\mathsf{Q}}/\theta$ embeds
in an ultrapower of ${\textbf{F}}^{C}_{\mathsf{Q}}(\omega)$ and so
${\textbf{F}}^{C}_{\mathsf{Q}}(\omega)\not\vDash\Phi$. As $\Phi$ is a
$C$-quasiequation ${\textbf{F}}_{\mathsf{Q}}(\omega)\not\vDash\Phi$, hence the
thesis holds. ∎

Given a quasivariety $\mathsf{Q}$ and a countably generated algebra
${\textbf{A}}\in\mathsf{Q}$, it is well-known that there is an epimorphism
$\varphi$ from $\textrm{Clo}({\textbf{F}}_{\mathsf{Q}}(\omega))$ to
$\textrm{Clo}({\textbf{A}})$ (regarded as algebras in the type of
$\mathsf{Q}$). If $C\subseteq\textrm{Clo}({\textbf{F}}_{\mathsf{Q}}(\omega))$
we say that A is u-presentable relative to $C$ if it is u-presentable relative
to $\varphi(C)$.

######  Corollary 4.6.

Let $\mathsf{Q}$ be a quasivariety, ${\textbf{A}}\in\mathsf{Q}$ and $C$ a
clone of operations of $\mathsf{Q}$; if every compact $\mathsf{Q}$-congruence
of every countably generated algebra in $\mathsf{Q}$ is u-presentable with
respect to $C$, then $\mathsf{Q}$ is $C$-primitive.

###### Proof.

It is enough to observe that if $\mathsf{Q}^{\prime}\subseteq\mathsf{Q}$, then
${\textbf{F}}_{\mathsf{Q}^{\prime}}(\omega)$ is a countably generated algebra
in $\mathsf{Q}$. ∎

It is interesting to observe that if $C$ is the entire term clone of
$\mathsf{Q}$, then we obtain a new necessary and sufficient condition.

######  Theorem 4.7.

A quasivariety $\mathsf{Q}$ is structurally complete if and only if every
completely meet irreducible congruence
$\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$ is
u-presentable.

###### Proof.

If $\mathsf{Q}$ is structurally complete, then
$\mathsf{Q}={\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$ and therefore
every $\mathsf{Q}$-irreducible algebra is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.
It follows that every completely meet irreducible congruence of
${\textbf{F}}_{\mathsf{Q}}(\omega)$ is u-presentable.

Conversely if (2) holds then, by Theorem 4.1, if $\theta$ is a completely meet
irreducible congruence of ${\textbf{F}}_{\mathsf{Q}}(\omega)$ then
${\textbf{F}}_{\mathsf{Q}}(\omega)/\theta\in{\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$.
Every $\mathsf{Q}$-irreducible algebra A is embeddable in an ultraproduct of
finitely generated subalgebras and each one of them is a subdirect product of
finitely generated $\mathsf{Q}$-irreducible algebras that are necessarily
equal to ${\textbf{F}}_{\mathsf{Q}}(\omega)/\delta$ for some completely meet
irreducible congruence of ${\textbf{F}}_{\mathsf{Q}}(\omega)$. Then each one
of them is in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{F}}_{\mathsf{Q}}(\omega))$
and so does A, since it is $\mathsf{Q}$-irreducible. It follows that
$\mathsf{Q}={\mathbf{Q}}({\textbf{F}}_{\mathsf{Q}}(\omega))$ and hence
$\mathsf{Q}$ is structurally complete. ∎

######  Corollary 4.8.

A quasivariety $\mathsf{Q}$ is primitive if and only if for every countably
generated ${\textbf{A}}\in\mathsf{Q}$ every completely meet irreducible
$\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is u-presentable.

Sometimes $u$-presentability is expressible directly via term operations. Let
A be any algebra, $C$ a subclone of the clone of all term operations on A, $T$
a set of generators for $C$ and ${\textbf{A}}^{T}$ the reduct of A to $T$; we
say that A has the Prucnal property relative to $C$ if for all
$n\in\mathbb{N}$ there is a term
$t_{n}(x_{1},\dots,x_{n},y_{1},\dots,y_{n},z)$ such that for any compact
$\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$,
$\theta=\bigvee_{i=1}^{n}\vartheta^{\mathsf{Q}}_{\textbf{A}}(a_{i},b_{i})$

  1. 1.

the map $\sigma_{n}:c\longmapsto t_{n}(a_{1},\dots,a_{n},b_{1},\dots,b_{n},c)$
is an endomorphism of ${\textbf{A}}^{T}$;

  2. 2.

$\textrm{ker}(\sigma_{n})=\theta$.

In this case the terms $\sigma_{n}$ are called the Prucnal terms relative to
$C$ and the endomorphisms $\sigma_{n}$ are called the Prucnal
$C$-endomorphisms. If $C$ is the entire clone of derived operations on A, then
we will drop the decoration $C$.

######  Theorem 4.9.

Let $\mathsf{Q}$ be a quasivariety and let $C$ a clone of term operations of
$\mathsf{Q}$. If ${\textbf{F}}_{\mathsf{Q}}(\omega)$ has the Prucnal property
relative to $C$, then $\mathsf{Q}$ is $C$-structurally complete.

###### Proof.

By Corollary 4.4 it is enough to show that every compact congruence of
${\textbf{F}}_{\mathsf{Q}}(\omega)$ is u-presentable relative to $C$. So let
$\theta$ be such a congruence; then from the definition of Prucnal terms and a
straightforward application of the Third Homomorphism Theorem it follows that
${\textbf{F}}^{C}_{\mathsf{Q}}(\omega)/\theta\in{\mathbf{I}}{\mathbf{S}}({\textbf{F}}^{C}_{\mathsf{Q}}(\omega)$.
This implies that $\theta$ is $u$-presentable. ∎

######  Corollary 4.10.

Let $\mathsf{Q}$ be a quasivariety and let $C$ a clone of term operations of
$\mathsf{Q}$. If every countably generated algebra in $\mathsf{Q}$ has the
Prucnal property relative to $C$, then $\mathsf{Q}$ is $C$-primitive.

A quasivariety $\mathsf{Q}$ has the principal Prucnal property relative to
$C$, if there is a term $t(x,y,z)$ that is a Prucnal term for principal
congruences, relative to $C$, i.e. for all ${\textbf{A}}\in\mathsf{Q}$ and for
all $a,b,\in{\textbf{A}}$

  1. 1.

the map $\sigma:c\longmapsto t(a,b,c)$ is an endomorphism of
${\textbf{A}}^{C}$;

  2. 2.

$\textrm{ker}(\sigma)=\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)$.

We will show that for any quasivariety the principal Prucnal property
(relative to $C$) implies the Prucnal property (relative to $C$). To this aim
we need several lemmas.

######  Lemma 4.11.

[34] Let $\mathsf{Q}$ be a quasivariety and ${\textbf{A}}\in\mathsf{Q}$; if
$\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ and $a,b\in A$ then
$(\theta\vee\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b))/\theta=\vartheta_{{\textbf{A}}/\theta}(a/\theta,b/\theta)$.

For the following lemma, in order to avoid clutter we use a special notation;
first we will denote a sequence $a_{1},\dots,a_{n}\in A$ by $\mathbf{a}^{n}$.
Next if $\theta\in\operatorname{Con}({\textbf{A}})$ we will write
$\bar{{\textbf{A}}}$ for ${\textbf{A}}/\theta$, $\overline{a}$ for $a/\theta$
and $\overline{\mathbf{a}}^{n}$for $\overline{a}_{1},\dots,\overline{a}_{n}$.

######  Lemma 4.12.

Let $\mathsf{Q}$ be a quasivariety, ${\textbf{A}}\in\mathsf{Q}$ and
$a_{1},\dots,a_{n},b_{1},\dots,b_{n}\in A$. If
$\overline{x}=x/\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{n},b_{n})$,
$\bar{{\textbf{A}}}={\textbf{A}}/\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{n},b_{n})$
and $c,d\in A$ then

$\displaystyle(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{1},b_{1})\vee\dots\vee\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{n},b_{n})\quad\text{if
and only if}$
$\displaystyle(\overline{c},\overline{d})\in\vartheta_{\bar{{\textbf{A}}}}^{\mathsf{Q}}({\overline{a}}_{1},{\overline{b}}_{1})\vee\dots\vee\vartheta_{\bar{{\textbf{A}}}}^{\mathsf{Q}}({\overline{a}}_{n-1},{\overline{b}}_{n-1}).$

###### Proof.

The proof is by induction, using Lemma 4.11 both in the base step and the
induction step. ∎

Let $\mathsf{Q}$ be a quasivariety with a principal Prucnal term relative to
$C$, say $t(x,y,z)$. We define for $n\geq 1$

$\displaystyle t_{1}(x_{1},y_{1},z):=t(x_{1},y_{1},z)$ $\displaystyle
t_{n+1}=t_{n}(x_{1},\dots,x_{n},y_{1},\dots,y_{n},t(x_{n},y_{n},z)).$

######  Lemma 4.13.

Let $\mathsf{Q}$ be a quasivariety with principal Prucnal term $t(x,y,z)$
relative to $C$, ${\textbf{A}}\in\mathsf{Q}$ and $a,b,c,d\in A$. Then

$\displaystyle(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{1},b_{1})\vee\dots\vee\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{n},b_{n})\quad\text{if
and only if}$ $\displaystyle
t_{n}({\mathbf{a}}^{n},{\mathbf{b}}^{n},c)=t_{n}({\mathbf{a}}^{n},{\mathbf{b}}^{n},d).$

###### Proof.

We induct on $n\geq 1$; the case $n=1$ comes straight from the definition of
principal Prucnal term. Suppose then that the conclusion holds for any
positive integer less than $n$. Then

$\displaystyle(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{1},b_{1})\vee\dots\vee\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{n},b_{n})\quad\text{if
and only if}$
$\displaystyle(\overline{c},\overline{d})\in\vartheta_{\bar{{\textbf{A}}}}^{\mathsf{Q}}({\overline{a}}_{1},{\overline{b}}_{1})\vee\dots\vee\vartheta_{\bar{{\textbf{A}}}}^{\mathsf{Q}}({\overline{a}}_{n-1},{\overline{b}}_{n-1})\quad\text{if
and only if}$ $\displaystyle
t_{n-1}(\overline{\mathbf{a}}^{n-1},\overline{\mathbf{b}}{}^{n-1},\overline{c})=t_{n-1}(\overline{\mathbf{a}}^{n-1},\overline{\mathbf{b}}{}^{n-1},\overline{d})\quad\text{if
and only if}$ $\displaystyle
t_{n-1}(\overline{a}^{n-1},\overline{b}^{n-1},\overline{d})d\quad\mathrel{\vartheta_{\textbf{A}}^{\mathsf{Q}}(a_{n},b_{n})}\quad
t_{n-1}(\overline{a}^{n-1},\overline{b}^{n-1},d)\quad\text{if and only if}$
$\displaystyle
t(a_{n},b_{n},t_{n-1}(\overline{a}^{n-1},\overline{b}^{n-1},c))=t(a_{n},b_{n},t_{n-1}(\overline{a}^{n-1},\overline{b}^{n-1},d))\quad\text{if
and only if}$ $\displaystyle
t_{n}({\mathbf{a}}^{n},{\mathbf{b}}^{n},c)=t_{n}({\mathbf{a}}^{n},{\mathbf{b}}^{n},d).$

∎

We observe that Lemma 4.13 is a generalization of Theorem 2.6 in [18].

######  Corollary 4.14.

If a quasivariety $\mathsf{Q}$ has a principal Prucnal term relative to $C$,
then it has the Prucnal property relative to $C$.

###### Proof.

The terms $t_{n},n\geq 1$ clearly satisfy the first condition for Prucnal
terms, as iterated compositions of $t$. By Lemma 4.13 they also satisfy the
second. ∎

###  4.3 The relative TD-term

Here we will consider a special principal Prucnal term. Let $\mathsf{Q}$ be a
quasivariety; a relative TD-term for $\mathsf{Q}$ is a ternary term $t(x,y,z)$
such that

  1. $\bullet$

$\mathsf{Q}\vDash t(x,x,z)$;

  2. $\bullet$

if $(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)$ then
$t(a,b,c)=t(a,b,d)$.

Let $\mathsf{Q}$ be a quasivariety with a relative TD-term $t(x,y,z)$ and $q$
a $k$-term of $\mathsf{Q}$; we say that $q$ commutes with $t$ if for all
${\textbf{A}}\in\mathsf{Q}$ and $a,b,c_{1},\dots,c_{k}\in A$

$t(a,b,q(c_{1},\dots,c_{k}))=q(t(a,b,c_{1}),\dots,t(a,b,c_{k})).$

######  Theorem 4.15.

If $t(x,y,z)$ is a relative TD-term for $\mathsf{Q}$, then $t$ is a principal
Prucnal term relative to any clone $C$ of operations that commute with
$t(x,y,z)$.

###### Proof.

Let ${\textbf{A}}\in\mathsf{Q}$ and let $a,b\in A$ and consider the mapping

$z\longmapsto t(a,b,z).$

If $q\in C$ and $c_{1},\dots,c_{k}\in A$, then

$t(a,b,q(c_{1},\dots,c_{k}))=q(t(a,b,c_{1}),\dots,t(a,b,c_{k})),$

so the mapping is an endomorphism of ${\textbf{A}}^{C}$.

Now if $(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)$ then
$t(a,b,c)=t(a,b,d)$ by definition; conversely if $t(a,b,c)=t(a,b,d)$ then

$c=t(a,a,c)\mathrel{\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)}t(a,b,c)=t(a,b,d)\mathrel{\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)}t(a,a,d)=d.$

∎

######  Corollary 4.16.

Let $\mathsf{Q}$ be a quasivariety with a relative TD-term $t(x,y,z)$. Then
for all nontrivial ${\textbf{A}}\in\mathsf{Q}$, A has the Prucnal property for
A, relative to any clone $C$ of operations that commute with the relative TD-
term.

######  Corollary 4.17.

Let $\mathsf{Q}$ be a quasivariety with a relative TD-term; then $\mathsf{Q}$
is $C$-primitive for any clone $C$ of terms that commute with the relative TD-
term.

The notion of relative TD-term generalizes to quasivarieties the notion of TD-
term in [18] and the results in this section generalizes to quasivarieties the
results in [31]. Some of the others results in [18] can be generalized to
quasivarieties with a relative TD-term.

A quasivariety has definable principal relative congruences (DPRC) if there is
a first order formula $\Phi(x,y,z,w)$ in the language of of $\mathsf{Q}$ such
that for all A in $\mathsf{Q}$ and for all $a,b,c,d\in{\textbf{A}}$

$(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\quad\text{if and only
if}\quad{\textbf{A}}\vDash\Phi(a,b,c,d).$

A quasivariety has equationally definable principal relative congruences
(EDPRC) if $\Phi$ can be taken as a finite conjunction of equations. A
quasivariety $\mathsf{Q}$ has the relative congruence extension property
(RCEP) if for any ${\textbf{A}}\in\mathsf{Q}$ and any subalgebra B of A, if
$\varphi\in\textrm{Con}_{\mathsf{Q}}({\textbf{B}})$ there is a
$\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ with $\varphi=\theta\cap
B^{2}$.

######  Theorem 4.18.

If $\mathsf{Q}$ has a relative TD-term $t(x,y,z)$ then

  1. 1.

for all ${\textbf{A}}\in\mathsf{Q}$ the lattice
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is dually relatively
pseudocomplemented;

  2. 2.

$\mathsf{Q}$ has EDPRC: for any ${\textbf{A}}\in\mathsf{Q}$ and $a,b,c,d\in
A$, $(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)$ if and only if
$t(a,b,c)=t(a,b,d)$;

  3. 3.

$\mathsf{Q}$ has the RCEP ;

  4. 4.

the $\mathsf{Q}$-congruences of any ${\textbf{A}}\in\mathsf{Q}$ 3-permute.

The proofs are easily patterned after the corresponding proofs in [18].

##  5 Other primitive quasivarieties

###  5.1 Congruence intersection terms

There are quasivarieties not necessarily having Prucnal terms to which some of
the techniques in the previous sections can be applied (at a cost). We will
say that a quasivariety has the relative principal intersection property
(RPIP) if there are quaternary terms $p,q$ in the type of $\mathsf{Q}$ such
that for any ${\textbf{A}}\in\mathsf{Q}$

$\vartheta^{\mathsf{Q}}_{\textbf{A}}(a,b)\cap\vartheta^{\mathsf{Q}}(c,d)=\vartheta_{\textbf{A}}^{\mathsf{Q}}(p(a,b,c,d),q(a,b,c,d)).$

The RPIP for varieties was introduced by K. Baker in [11] and studied
extensively in [2]. We observe that if
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is distributive, then (as any
complete distributive lattice) it is pseudocomplemented: in particular if
${\textbf{A}}\in\mathsf{Q}$, then for any
$\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ there is a
$\theta^{*}\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ such that

$\theta^{*}=\bigvee\\{\varphi\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}}):\theta\wedge\varphi=0_{\textbf{A}}\\}.$

In particular, if $\textrm{MI}^{\mathsf{Q}}_{\textbf{A}}$ is the set of meet
irreducible elements in $\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ and $a,b\in
A$, then

$(\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b))^{*}=\bigwedge\\{\varphi\in\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}:(a,b)\notin\varphi\\}.$

From now on we will denote by $\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)$ the
pseudocomplement of $\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)$ in
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$.

######  Theorem 5.1.

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

  1. 1.

$\mathsf{Q}$ has the RPIP;

  2. 2.

$\mathsf{Q}$ is relative congruence distributive and there are terms $p,q$
such that for all $\mathsf{Q}$-irreducible ${\textbf{A}}\in\mathsf{Q}$ and
$a,b,c,d\in A$

$p(a,b,c,d)=q(a,b,c,d)\quad\text{if and only if}\quad\text{$a=b$ or $c=d$}.$

  3. 3.

$\mathsf{Q}$ is relative congruence distributive and there are terms $p,q$
such that for all ${\textbf{A}}\in\mathsf{Q}$ and $a,b\in A$

$\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)=\\{(c,d):p(a,b,c,d)=q(a,b,c,d)\\}.$

###### Proof.

Observe that any quasivariety with the RPIP is relatively congruence
distributive, by Proposition 1.2 in [34]. Let’s assume (1), i.e. $\mathsf{Q}$
has the RPIP witnessed by $p,q$; let ${\textbf{A}}\in\mathsf{Q}$, $a,b\in A$
and

$\alpha=\\{(c,d):p(a,b,c,d)=q(a,b,c,d)\\}.$

Then we have

$\displaystyle(c,d)\in\alpha\quad\text{if and only if}$ $\displaystyle
p(a,b,c,d)=q(a,b,c,d)\quad\text{if and only if}$
$\displaystyle\vartheta_{\textbf{A}}\mathsf{Q}(a,b)\cap\vartheta_{\textbf{A}}^{\mathsf{Q}}(c,d)=0_{\textbf{A}}\quad\text{if
and only if}$
$\displaystyle\vartheta_{\textbf{A}}^{\mathsf{Q}}(c,d)\leq\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)\quad\text{if
and only if}$ $\displaystyle(c,d)\in\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)$

so $\alpha=\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)$ and (1) implies (3).

Next assume (3) and let A be a $\mathsf{Q}$-irreducible algebra in
$\mathsf{Q}$. Then

$\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)=\left\\{\begin{array}[]{ll}1_{\textbf{A}},&\hbox{if
$a=b$;}\\\ 0_{\textbf{A}},&\hbox{if $a\neq b$.}\end{array}\right.$

Suppose that $p(a,b,c,d)=q(a,b,c,d)$ with $a\neq b$; then
$(c,d)\in\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)$ and thus $c=d$. Conversely, if
$a=b$ then $\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)=1_{\textbf{A}}$ so
$p(a,b,c,d)=q(a,b,c,d)$ for all $c,d$; if $c=d$ then
$(c,d)\in\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)$ and so again
$p(a,b,c,d)=q(a,b,c,d)$. Therefore (3) implies (2).

Finally assume (2). We will make use of the following fact whose proof can be
found in [34]: for any $\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ and
$a,b\in A$,
$(\theta\vee\theta^{\mathsf{Q}}_{\textbf{A}}(a,b))/\theta=\vartheta^{\mathsf{Q}}_{{\textbf{A}}/\theta}(a/\theta,b/\theta)$.
Let then $a,b,c,d\in A$; we must prove that

$\vartheta^{\mathsf{Q}}_{\textbf{A}}(a,b)\cap\vartheta^{\mathsf{Q}}(c,d)=\vartheta_{\textbf{A}}^{\mathsf{Q}}(p(a,b,c,d),q(a,b,c,d)).$

Since $\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is an algebraic lattice, every
element is a meet of completely meet irreducible elements. So to prove (1), it
is enough to show that, if $\varphi$ is completely meet irreducible in
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ then

$\vartheta^{\mathsf{Q}}_{\textbf{A}}(a,b)\cap\vartheta^{\mathsf{Q}}(c,d)\leq\varphi\quad\text{if
and only
if}\quad\vartheta_{\textbf{A}}^{\mathsf{Q}}(p(a,b,c,d),q(a,b,c,d))\leq\varphi.$

So suppose that
$\vartheta^{\mathsf{Q}}_{\textbf{A}}(a,b)\cap\vartheta^{\mathsf{Q}}(c,d)\leq\varphi$;
as $\varphi$ is completely meet irreducible and
$\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is distributive, $\varphi$ is join
prime, so either $\vartheta^{\mathsf{Q}}_{\textbf{A}}(a,b)\leq\varphi$ or
$\vartheta^{\mathsf{Q}}(c,d)\leq\varphi$. Then in ${\textbf{A}}/\varphi$ we
have

$\displaystyle\vartheta^{\mathsf{Q}}_{{\textbf{A}}/\varphi}(a/\theta,b/\varphi)$
$\displaystyle\cap\vartheta^{\mathsf{Q}}_{{\textbf{A}}/\theta}(c/\varphi,d/\varphi)$
$\displaystyle=(\varphi\vee\theta^{\mathsf{Q}}_{\textbf{A}}(a,b))/\varphi\cap(\varphi\vee\theta^{\mathsf{Q}}_{\textbf{A}}(a,b))/\varphi$
$\displaystyle=\varphi/\varphi=0_{{\textbf{A}}/\varphi}.$

Since ${\textbf{A}}/\varphi$ is $\mathsf{Q}$-irreducible
$p(a,b,c,d)/\varphi=q(a,b,c,d)/\varphi$ which implies

$\vartheta_{\textbf{A}}^{\mathsf{Q}}(p(a,b,c,d),q(a,b,c,d))\leq\varphi.$

Conversely if
$\vartheta_{\textbf{A}}^{\mathsf{Q}}(p(a,b,c,d),q(a,b,c,d))\leq\varphi$, then

$\displaystyle\vartheta_{{\textbf{A}}/\varphi}^{\mathsf{Q}}(p(a,b,c,d)/$
$\displaystyle\varphi,q(a,b,c,d)/\varphi)$
$\displaystyle=(\varphi\vee\vartheta_{\textbf{A}}^{\mathsf{Q}}(p(a,b,c,d),q(a,b,c,d)))/\varphi=\varphi/\varphi=0_{{\textbf{A}}/\varphi}$

so, since ${\textbf{A}}/\varphi$ is $\mathsf{Q}$-irreducible, either
$(a,b)\in\varphi$ or $(c,d)\in\varphi$, which implies
$\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\cap\vartheta_{\textbf{A}}^{\mathsf{Q}}(c,d)\leq\varphi$
as wished. So (3) implies (1) and the proof is finished. ∎

Let $\mathsf{Q}$ be a quasivariety with the RPIP (and hence relative
congruence distributive), ${\textbf{A}}\in\mathsf{Q}$ and let L be the lattice
of compact $\mathsf{Q}$-congruences of A plus eventually $1_{\textbf{A}}$.
Then one can define a topology on $\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}$
which is equivalent to the Priestley duality on the lattice of ideals L (see
[25], Proposition 3.10). More precisely the topology is defined by the subbase
$\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}(a,b)=\\{\theta\in\textrm{MI}_{\textbf{A}}:(a,b)\notin\theta\\}$,
for $a,b\in A$. It follows that $\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}$ is
compact in that topology which in turn implies (see Lemma 2.1 in [63]):

######  Lemma 5.2.

Let $\mathsf{Q}$ be a quasivariety with the RPIP and
${\textbf{A}}\in\mathsf{Q}$; then if
$\bigwedge\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}(a,b)\leq\gamma$, where
$\gamma\in\textrm{MI}^{\mathsf{Q}}_{\textbf{A}}$, then there exists a
$\theta\in\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}(a,b)$ with $\theta\leq\gamma$.

######  Theorem 5.3.

Let $\mathsf{Q}$ be a quasivariety with the RPIP such that every finitely
$\mathsf{Q}$-irreducible algebra in $\mathsf{Q}$ is $\mathsf{Q}$-simple. Then
the following hold.

  1. 1.

For any ${\textbf{A}}\in\mathsf{Q}$ and $a,b\in A$,
$\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)$ and
$\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)$ are complements; therefore the meet of
two coprincipal $\mathsf{Q}$-congruences of A is coprincipal.

  2. 2.

If $\theta\in\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$ is such that
${\textbf{A}}/\theta$ is $\mathsf{Q}$-simple, then

$\bigcup\\{\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b):\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)\leq\theta\\}=\theta.$

###### Proof.

By hypothesis every element of $\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}$ is a
maximal element in in $\textrm{Con}_{\mathsf{Q}}({\textbf{A}})$. Let
$\gamma\geq\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)$ with
$\gamma\in\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}$; then

$\bigwedge\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}(a,b)=\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)\leq\gamma$

so by Lemma 5.2 there is a nontop
$\theta\in\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}(a,b)$ with $\theta\leq\gamma$.
By maximality of $\theta$ we must have $\theta=\gamma$ and thus
$(a,b)\notin\gamma$.

Now suppose that
$\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\vee\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)\neq
1_{\textbf{A}}$; then there must be a maximal congruence $\gamma$ with
$\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\vee\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)\leq\gamma$;
as $\gamma\in\textrm{MI}_{\textbf{A}}^{\mathsf{Q}}$ and
$\gamma\geq\gamma_{\textbf{A}}(a,b)$ we must have $(a,b)\notin\gamma$, a clear
contradiction. So
$\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\vee\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)=1_{\textbf{A}}$
and the first part of the thesis follows.

That the meet of two coprincipal $\mathsf{Q}$-congruences of A is coprincipal
comes straight from the properties of complemented elements in a distributive
lattice and this concludes the proof of (1).

For (2) we will show that for all
$\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\leq\theta$ we have
$\gamma_{\textbf{A}}^{\mathsf{Q}}(a,b)\leq\theta$. As
$\bigcup\\{\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b):\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\leq\theta\\}=\theta$
the conclusion will follow.

If $\vartheta_{\textbf{A}}(a,b)\leq\theta$ then
$\vartheta_{\textbf{A}}(a,b)\vee\gamma_{\textbf{A}}(a,b)=1_{\textbf{A}}$ and,
since $\theta$ is covered by $1_{\textbf{A}}$ there exists
$(c,d)\in\gamma_{\textbf{A}}(a,b)$ with $(c,d)\notin\theta$. Now
$\vartheta_{\textbf{A}}(c,d)\leq\gamma_{\textbf{A}}(a,b)$ so
$\vartheta_{\textbf{A}}(a,b)\leq\gamma_{\textbf{A}}(c,d)$; moreover
$\vartheta_{\textbf{A}}(c,d)\cap\gamma_{\textbf{A}}(c,d)=0_{\textbf{A}}\leq\theta$
and, as $\theta$ is meet prime (since it is meet irreducible and
$\textrm{Con}_{\mathsf{Q}}A$ is distributive), we must have
$\gamma{\textbf{A}}(c,d)\leq\theta$. ∎

###  5.2 Dual i-discriminator varieties

In the late 1990’s K. Baker and the second author collaborated for some time
([2], [3]; while writing the second paper an interest arose about various
kinds of dual discriminator functions and produced an unpublished (and very
rough) manuscript [4], that had a very limited circulation at the time (but
some of the results have been rediscovered in [14]). In this section we
improve on those results and we show how they connect to the problems we are
considering.

The dual i-discriminator function on a set $A$ is a ternary function
$p(x,y,z)$ such that for any $a,b,c\in A$

$\displaystyle a\neq b\quad\text{implies}\quad p(a,b,c)=c$ $\displaystyle
p(a,a,b)=p(a,a,c)$ $\displaystyle p(a,a,a)=p(p(a,a,a),p(a,a,a),p(a,a,a)).$

If we write $\pi(x)=p(x,x,x)$, this definition becomes:

$\pi(\pi(a))=\pi(a)\quad\text{and}\quad p(a,b,c)=\begin{cases}\pi(a)&\text{if
$a=b$}\\\ c&\text{if $a\neq b$}\end{cases}.$

In case $\pi(x)$ is the identity, then the dual i-discriminator function is
just the dual discriminator function described in [38]. We first observe the
following easy fact:

######  Lemma 5.4.

If A is an algebra and $p(x,y,z)$ is a dual i-discriminator term for A, then A
is simple.

###### Proof.

If $\theta\in\operatorname{Con}({\textbf{A}})$ and there are $(a,b)\in\theta$
with $a\neq b$, then for all $c,d\in A$

$c=p(a,b,c)\mathrel{\theta}p(a,a,c)=p(a,a,d)\mathrel{\theta}p(a,b,d)=d.$

Therefore $\theta=1_{\textbf{A}}$ and A is simple. ∎

A quasivariety $\mathsf{Q}$ is a dual i-discriminator quasivariety if there is
term $p(x,y,z)$ that is the dual i-discriminator on every
$\mathsf{Q}$-irreducible algebra in $\mathsf{Q}$. Observe that, by Lemma 5.4,
if $\mathsf{Q}$ is a dual i-discriminator variety, then every
$\mathsf{Q}$-irreducible algebra in $\mathsf{Q}$ is simple; so $\mathsf{Q}$ is
semisimple in the absolute sense.

Dual i-discriminator varieties share many properties with dual discriminator
varieties in the sense of [38]. However there are dual i-discriminator
quasivarieties that are not dual discriminator quasivarieties (see Example
5.19 below). First we want to show that every dual i-discriminator
quasivariety is relative congruence distributive. In order to do that first we
show:

######  Theorem 5.5.

Let $\mathsf{K}$ be a class of similar algebras with a term $p(x,y,z)$ that is
the dual i-discriminator on each member of $\mathsf{K}$. Then
${\mathbf{V}}(\mathsf{K})$ is congruence distributive and in fact satisfies
Jónsson’s condition $\Delta_{3}$.

###### Proof.

We must produce four ternary terms $t_{0},t_{1},t_{2},t_{3}$ such that
$t_{0}(x,y,z)\approx z$, $t_{3}(x,y,z)\approx z$ and moreover

  1. 1.

$t_{i}(x,y,x)\approx x$ for $i=1,3$,

  2. 2.

$t_{1}(x,x,z)\approx x$,

  3. 3.

$t_{2}(x,x,z)\approx z$,

  4. 4.

$t_{1}(x,z,z)\approx t_{2}(x,z,z)$

all hold in ${\mathbf{V}}(\mathsf{K})$. Let

$t_{1}(x,y,z)=p(p(x,y,z),y,x)\qquad\qquad t_{2}(x,y,z)=p(p(x,y,y),z,z).$

Since conditions 1.–4. are equational, it is enough to show that they hold for
each member of $\mathsf{K}$. Accordingly, let ${\textbf{A}}\in\mathsf{K}$ and
let $a,b,c\in A$. Then $t_{1}(a,b,a)=p(p(a,b,a),b,a)$. If $a\neq b$, then
$p(p(a,b,a),b,a)=p(a,b,a)=a$. If $a=b$ then $p(p(a,b,a),b,a)=p(\pi(a),a,a)=a$,
whether or not $\pi(a)=a$. An identical argument shows that $t_{2}(a,b,a)=a$,
thus proving 1.

Next, $t_{1}(a,a,c)=p(p(a,a,c),a,a)=p(\pi(a),a,a)=a$ as above. On the other
hand $t_{2}(a,a,c)=p(p(a,a,a),c,c)=p(\pi(a),c,c)$, which is equal to $c$ if
$\pi(a)\neq c$, or to $\pi\pi(a)=\pi(a)=c$ if $\pi(a)=c$. This proves 2. and
3.

Finally we have to show that $t_{1}(a,c,c)=t_{2}(a,c,c)$. If $a=c$, both sides
reduce to $p(p(a,a,a),a,a)$. If $a\neq c$ we have

$\displaystyle t_{1}(a,c,c)=p(p(a,c,c),c,a)=p(c,c,a)=\pi(c)$ $\displaystyle
t_{2}(a,c,c)=p(p(a,c,c),c,c)=p(c,c,c)=\pi(c).$

This proves 4. and therefore ${\mathbf{V}}(\mathsf{K})$ is congruence
distributive. ∎

Next:

######  Lemma 5.6.

Let $\mathsf{K}$ be a class of similar algebras with a term $p(x,y,z)$ that is
the dual i-discriminator on each member of $\mathsf{K}$. Then
$\mathsf{Q}={\mathbf{Q}}(\mathsf{K})$ is a dual i-discriminator variety with
dual i-discriminator term $p(x,y,z)$. Moreover $p(x,y,z)$ is a dual
i-discriminator term for any finitely $\mathsf{Q}$-irreducible algebra in
$\mathsf{Q}$.

###### Proof.

Since the second claim clearly implies the first we will prove that one. By
Theorem 2.5 all the finitely $\mathsf{Q}$-irreducible members of $\mathsf{Q}$
lie in ${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}(\mathsf{K})$. Since being a
dual i-discriminator function can be expressed by the universal sentence

$\forall x,y,z[p(x,x,y)\approx p(x,x,z)]\wedge[\neg(x\approx y)\rightarrow
p(x,y,z)\approx\pi(z)],$

$p(x,y,z)$ is a dual i-discriminator on each member of
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}(\mathsf{K})$. This concludes the
proof. ∎

######  Theorem 5.7.

Every dual i-discriminator quasivariety is relative congruence distributive.

###### Proof.

Let $\mathsf{Q}$ be a dual i-discriminator variety; then by Lemma 5.6
${\mathbf{V}}(\mathsf{Q})$ is congruence distributive. Now in [37] (Corollary
2.4) the author showed that a subquasivariety $\mathsf{R}$ of a congruence
distributive variety is relative congruence distributive if and only if any
finitely $\mathsf{R}$-irreducible algebra in $\mathsf{R}$ is finitely
subdirectly irreducible in the absolute sense.

But by Lemma 5.6 every finitely $\mathsf{Q}$-irreducible algebra has
$p(x,y,z)$ as a dual i-discriminator term, so it is simple; hence it is
finitely subdirectly irreducible in the absolute sense. Therefore $\mathsf{Q}$
is relatively congruence distributive. ∎

######  Remark 5.8.

Let $\mathsf{V}$ be a dual i-discriminator variety with witness term
$p(x,y,z)$. Which subquasivarieties of $\mathsf{V}$ are dual i-discriminator
with the same term? In general not all of them; however let $\mathsf{V}_{fsi}$
be the class of finitely subdirectly irreducible (i.e. simple) algebras in
$\mathsf{V}$. Then ${\mathbf{Q}}(\mathsf{K})$ is a dual i-discriminator
quasivariety with witness term $p(x,y,z)$ if and only if
$\mathsf{K}\subseteq\mathsf{V}_{fsi}$, so apparently we have a recipe to
construct many dual i-discriminator quasivarieties. However it is an immediate
consequence of Proposition 2.5 in [37] that if $\mathsf{V}$ is locally finite,
then each of those subquasivarieties is really a variety.

Dual i-discriminator variety have a special kind of RPIP; we say that a
quasivariety $\mathsf{Q}$ has the relative ternary principal intersection
property (RTPIP for short) if there is a ternary term $p(x,y,z)$ such that

$\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\cap\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)=\vartheta_{\textbf{A}}^{\mathsf{Q}}(p(a,b,c),p(a,b,d)).$

######  Lemma 5.9.

Every dual i-discriminator variety $\mathsf{Q}$ has the RTPIP.

###### Proof.

Let A be a $\mathsf{Q}$-irreducible algebra in $\mathsf{Q}$ and let
$a,b,c,d\in A$. Then $p(x,y,z)$ is the dual i-discriminator function on $A$
therefore

$p(a,b,c)=p(a,b,d)\quad\text{if and only if}\quad\text{$a=b$ or $c=d$}.$

As $\mathsf{Q}$ is relatively congruence distributive, Theorem 5.1 yields the
conclusion. ∎

The concept of having the RTPIP and being a dual i-discriminator quasivariety
coincide for finitely generated quasivarieties.

######  Theorem 5.10.

A finitely generated quasivariety has the RTPIP if and only if it is a dual
i-discriminator quasivariety.

###### Proof.

Any dual i-discriminator variety has the RTPIP by Lemma 5.9. Suppose
$\mathsf{Q}$ has the RTPIP, witness $p(x,y,z)$; then it is relative congruence
distributive by Theorem 5.1.

Moreover, since it is finitely generated, it has only finitely many
$\mathsf{Q}$-irreducible algebras, all of them finite. Let then A one of them
and let $a,b\in A$ with $a\neq b$; then by Theorem 5.1 the function
$z\longmapsto t(a,b,z)$ is one-to one on $A$ and hence it is a permutation.
The order of this permutation divides $n!$, where $n$ is the largest among the
cardinalities of $\mathsf{Q}$-irreducible algebras and the $n$-th power of
this permutation is the identity.

Define inductively a sequence of terms $p_{k}(x,y,z)$ for $k=0,1,2,\dots,n-1$
by

$p_{0}(x,y,z)=z\qquad\qquad p_{k+1}(x,y,z)=p(x,y,p_{k}(x,y,z)).$

Then each $t_{k}$ for $1\leq k\leq n$ witnesses the RTPIP for $\mathsf{V}$ and
moreover $t_{n}$ has the property that in each $\mathsf{Q}$-irreducible member
of $\mathsf{Q}$, $a\neq b$ implies $t_{n}(a,b,c)=c$. However, the unary term
$\tau(x)=p_{n}(x,x,x)$ is not necessarily idempotent, so further modifications
are needed.

For any $\mathsf{Q}$-irreducible algebra ${\textbf{A}}\in\mathsf{Q}$ there
exist $l_{\textbf{A}},m_{\textbf{A}}>0$ such that
$\tau^{l_{\textbf{A}}+m_{\textbf{A}}}=\tau^{l_{\textbf{A}}}$ on A. Let $L$ be
a positive integer such that for any $\mathsf{Q}$-irreducible
${\textbf{A}}\in\mathsf{V}$, $L$ is both a multiple of $m_{\textbf{A}}$ and
greater than $l_{\textbf{A}}$; since there are only finitely many
$\mathsf{Q}$-irreducible algebras in $\mathsf{Q}$ we can take $L$ to be the
product of all $l_{\textbf{A}}$ and $m_{\textbf{A}}$. Then on each
$\mathsf{Q}$-irreducible member we have $\tau^{2L}=\tau^{L}$, so the term
$\pi(x)=\tau^{L}(x)$ is idempotent.

Now we must construct a dual idempotent discriminator term of which $\pi(x)$
is the diagonal. Define terms $q_{i}(x,y,z)$ for $i=0,1,2,\dots,L$ by

$q_{0}(x,y,z)=z\qquad\qquad
q_{k+1}(x,y,z)=p_{n}(q_{k}(x,y,x),q_{k}(x,y,y),q_{k}(x,y,z)).$

Set $d=q_{L}$. Then $p(x,x,x)=\pi(x)$ as desired, while $d$ retains the
properties of $p_{n}(x,y,z)$. Hence $p(x,y,z)$ is a dual i-discriminator term
for $\mathsf{Q}$. ∎

######  Corollary 5.11.

Let $\mathsf{Q}$ be a quasivariety with the RTPIP; if A is a finite algebra in
$\mathsf{Q}$, then every ${\mathbf{Q}}({\textbf{A}})$ is dual i-discriminator
variety.

Observe that Corollary 5.11 is a handy tool for testing the RTPIP for a
quasivariety. For instance, since a Heyting algebra is subdirectly irreducible
if and only if the top element is completely join irreducible, Heyting
algebras have the RPIP with $q_{1}(x,y,z,w):=(x\leftrightarrow
y)\vee(z\leftrightarrow w)$ and $q_{2}(x,y,z,w)\approx 1$. However the only
simple Heyting algebra is the two element one, so the only variety of Heyting
algebra with the RTPIP is the variety of Boolean algebras.

###  5.3 Filtrality

Let ${\textbf{A}}\leq_{sd}\prod_{i\in I}{\textbf{A}}_{i}$; a congruence
$\theta\in\operatorname{Con}({\textbf{A}})$ is filtral if there is a filter
$F$ on $I$ such that

$\theta=\\{(a,b):\\{i:a_{i}=b_{i}\\}\in F\\}.$

A quasivariety $\mathsf{Q}$ is relatively filtral if, whenever A is
subdirectly embeddable in a product of $\mathsf{Q}$-irreducible algebras, then
every $\mathsf{Q}$-congruence of A is filtral.

######  Theorem 5.12.

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

  1. 1.

$\mathsf{Q}$ has EDPRC if and only if it has DPRC and the RCEP;

  2. 2.

$\mathsf{Q}$ is relatively filtral if and only if $\mathsf{Q}$ has EDPRC and
every $\mathsf{Q}$-irreducible algebra is $\mathsf{Q}$-simple.

######  Lemma 5.13.

If $\mathsf{Q}$ is a dual i-discriminator variety, with witness term
$p(x,y,z)$, then $\mathsf{Q}$ has DPRC and the CEP. In fact if
${\textbf{A}}\in\mathsf{Q}$ and $a,b,c,d\in A$ then

$(c,d)\in\vartheta_{\textbf{A}}^{\mathsf{Q}}(a,b)\quad\text{if and only
if}\quad\forall u[p(c,d,u)=p(c,d,p(a,b,u))].$

###### Proof.

By Lemma 5.4 and Theorem 5.3, $\vartheta^{\mathsf{Q}}_{\textbf{A}}(a,b)$ and
$\gamma^{\mathsf{Q}}_{\textbf{A}}(a,b)$ are complements, thus

$\vartheta^{\mathsf{Q}}_{\textbf{A}}(c,d)\leq\vartheta^{\mathsf{Q}}_{\textbf{A}}(a,b)\qquad\text{if
and only
if}\qquad\gamma^{\mathsf{Q}}_{\textbf{A}}(a,b)\leq\gamma^{\mathsf{Q}}_{\textbf{A}}(c,d).$

By the definition of $\gamma^{\mathsf{Q}}_{\textbf{A}}(a,b)$ the latter is
equivalent to

$\forall u,v\ \ p(a,b,u)=p(a,b,v)\quad\Longrightarrow\quad p(c,d,u)=p(c,d,v).$
(1)

Now assume the latter and let $v=p(a,b,u)$. Since the equation

$p(x,y,p(x,y,z))\approx p(x,y,z)$

holds in $\mathsf{Q}$ we get

$p(a,b,u)=p(a,b,p(a,b,u))=p(a,b,v);$

therefore

$p(c,d,u)=p(c,d,v)=p(c,d,p(a,b,u)).$

Conversely, if for all $u$, $p(c,d,u)=p(c,d,p(a,b,u))$ and
$p(a,b,u)=p(a,b,v)$, then

$p(c,d,u)=p(c,d,p(a,b,u))=p(c,d,p(a,b,v))=p(c,d,v).$

Therefore that $\mathsf{Q}$ has DPRC. Also observe that the formula defining
principal $\mathsf{Q}$-congruences in $\mathsf{Q}$ is universal and so it is
preserved by subalgebras. Hence if ${\textbf{A}}\in\mathsf{Q}$ any principal
$\mathsf{Q}$-congruence of a subalgebra B of A extends to a principal
$\mathsf{Q}$-congruence of A. This is enough to guarantee the RCEP [19]. ∎

######  Corollary 5.14.

Every dual i-discriminator quasivariety is relatively filtral.

We will close this section with some examples.

######  Example 5.15.

There are filtral varieties without the RTPIP, which shows that the
implication in Corollary 5.14 cannot be reversed.

A de Morgan algebra is an algebra $\langle
A,\vee,\wedge,\overline{\phantom{a}},0,1\rangle$ in which the
$\\{\wedge,\vee,0,1\\}$-reduct is a bounded distributive lattice and moreover

$\overline{x\vee y}=\overline{x}\wedge\overline{y}\qquad\overline{x\wedge
y}=\overline{x}\vee\overline{y}\qquad\overline{\overline{x}}=x.$

The only subdirectly irreducible de Morgan algebras are shown in Figure 4 (see
[46]) and they are all simple; moreover the variety $\mathsf{M}$ of de Morgan
algebras has EDPC [16] and hence it is filtral.

$0=\overline{1}$$1=\overline{0}$$0=\overline{1}$$a=\overline{a}$$1=\overline{0}$$0=\overline{1}$$a=\overline{b}$$b=\overline{a}$$1=\overline{0}$${\textbf{M}}_{2}$${\textbf{M}}_{3}$${\textbf{M}}_{4}$
Figure 4: Simple de Morgan algebras

The variety $\mathsf{K}$ of Kleene algebras is the variety generated by
${\textbf{M}}_{3}$ and we will show that $\mathsf{K}$ does not have the TPIP.
From now on, let us denote $\vee$ and $\wedge$ by $+$ and juxtaposition, in
order to take advantage of the familiar linear algebra notation. By using the
fact that the operation $x\mapsto\bar{x}$ is a dual automorphism, we may write
any unary polynomial function $p(x)$ of ${\textbf{A}}\in\mathsf{M}$ in the
form $p(x)=\alpha x\bar{x}+\beta x+\gamma\bar{x}+\delta$ for
$\alpha,\beta,\gamma,\delta\in A$.

Claim. Let $p(x)$ be a unary polynomial on ${\textbf{M}}_{3}$; then either
$p(x)$ has a constant Boolean value ($0$ or $1$) or else $p(a)=a$. Hence if
$p(x)$ is one-to-one on ${\textbf{M}}_{3}$, then either $p(x)=x$ or
$p(x)=\bar{x}$; in particular $p(x)$ takes Boolean elements ($0$ and $1$) to
Boolean elements.

To prove this claim, observe that

$p(a)=\alpha a\bar{a}+\beta
a+\gamma\bar{a}+\delta=(\alpha+\beta+\gamma)a+\delta$

for some $\alpha,\beta,\gamma,\delta\in{\textbf{M}}_{3}$. If $\delta=1$, then
$p(x)$ is constantly $1$; if $\delta=a$, then $p(x)$ is constantly $a$.
Finally if $\delta=0$, then $p(x)$ is constantly $0$ if
$\alpha+\beta+\gamma=0$ and otherwise $p(a)=a$. For the second assertion of
the claim, note that $p(a)=a$ and, since $p(x)$ is one-to-one, it must take
$0,a,1$ either to $0,a,1$ or $1,a,0$. ∎

Now suppose that $\mathsf{K}$ has the RTPIP with ternary intersection term
$t(x,y,z)$. Then the polynomial $p(z)=t(0,a,z)$ is one-to-one on
${\textbf{M}}_{3}$ and hence by the Claim $p(0)=t(0,a,0)$ is Boolean, i.e. $0$
or $1$. Now consider the polynomial $q(y)=t(0,y,0)$; since $q(a)=t(0,a,0)\neq
a$, then $q(y)$ is constant giving $t(0,0,0)=q(0)=q(1)=t(0,1,0)$. Similarly,
$t(0,0,1)=t(0,1,1)$. Since $q^{\prime}(z)=t(0,0,z)$ is assumed to be constant
we also have $t(0,0,0)=t(0,0,1)$. Putting these facts together we get

$t(0,1,0)=t(0,0,0)=t(0,0,1)=t(0,1,1),$

which contradicts the assumption that $t(x,y,z)$ is a ternary intersection
term.∎

######  Remark 5.16.

The variety $\mathsf{K}$ of Kleene algebras does have the RPIP, with witness
terms $q_{1}(x,y,z,w)=h(x,y)+h(z,w)$, where $h(x,y)=x\bar{x}y\bar{y}$, and
$q_{2}(x,y,z,w)=q_{1}(x,y,z,w)+(x+y)(\bar{x}+\bar{y})(z+w)(\bar{z}+\bar{w})$.
To see this first observe that the only subdirectly irreducibles in
$\mathsf{K}$ are ${\textbf{M}}_{3}$ and the two-element Boolean algebra
${\textbf{M}}_{2}$. However, since ${\textbf{M}}_{2}$ is a subalgebra of
${\textbf{M}}_{3}$ it is enough to consider the latter. We have hence to show
that for any $r,s,u,v\in{\textbf{M}}_{3}$

$p(r,s,u,v)=q(r,s,u,v)\qquad\text{if and only if}\qquad r=s\quad\text{or}\quad
u=v.$ (P)

First observe that

$h(r,s)=\begin{cases}0\quad\text{if $(r,s)\neq(a,a)$}\\\
a\qquad\text{otherwise}\end{cases}.$

Suppose then that either $(r,s)=(a,a)$ or $(u,v)=(a,a)$ in (P). Then
$p(r,s,u,v)=a=q(u,v,r,s)$, since the summands in the definition of $q$ have
values $a$ and at most $a$.

Otherwise, $h(r,s)=h(u,v)=0$ so (P) becomes

$0=(r+s)(\bar{r}+\bar{s})(u+v)(\bar{u}+\bar{v});$

since $0$ is meet irreducible this occurs when some factor is $0$. But this
happens exactly when $r=s$ or $u=v$, which is precisely what (P) asserts.

It can be shown that the variety $\mathsf{M}$ of de Morgan algebras does not
have the RPIP. We will not prove it but we observe that the above reasoning
fails in $\mathsf{M}$: in ${\textbf{M}}_{4}$, (P) is contradicted by

$p(0,a,0,b)=0=q(0,a,0,b).$

######  Example 5.17.

There are also quasivarieties with the RTPIP that fail to be filtral, showing
that finite generation cannot be removed from the hypotheses of Corollary
5.11. Let
${\textbf{A}}=\langle\mathbb{R},+,-,\cdot,0,\vee,\wedge,\sigma\rangle$, where
$\sigma$ is the unary operation given by $\sigma(r)=\sqrt{|r|}$ for
$r\in\mathbb{R}$. Thus A is a lattice ordered ring with an additional
operation $\sigma$ and it is easy to check that in
${\mathbf{V}}({\textbf{A}})$ the congruences are determined by the
$\sigma$-ideals, i.e. the convex ring ideals such that $a-b\in I$ implies
$\sigma(a)-\sigma(b)\in I$.

Let now $\mathsf{Q}={\mathbf{Q}}({\textbf{A}})$ and $t(x,y,z)=(x-y)z$; to
prove that $t(x,y,z)$ witnesses the RTPIP for $\mathsf{Q}$ it is enough to
show that every algebra in
${\mathbf{I}}{\mathbf{S}}{\mathbf{P}}_{u}({\textbf{A}})$ is an integral
domain, regarded as a ring (because of Theorems 2.5 and 5.1). But this is
obvious, since A is an integral domain and we can express “integral domain”
via a universal sentence.

To show that $\mathsf{Q}$ is not relatively filtral we observe first that in a
relative filtral quasivariety $\mathsf{R}$, if an algebra
${\textbf{B}}\in\mathsf{R}$ is such that
$\textrm{Con}_{\mathsf{R}}({\textbf{B}})$ is totally ordered, then B is
$\mathsf{R}$-simple. Indeed, since $\mathsf{R}$-irreducible algebras are
$\mathsf{R}$-simple, every strictly meet irreducible $\mathsf{R}$-congruence
of B is a coatom in $\textrm{Con}_{\mathsf{R}}({\textbf{B}})$ and since
$\textrm{Con}_{\mathsf{R}}({\textbf{B}})$ is totally ordered there can be only
one coatom. But $0_{\textbf{B}}\in\textrm{Con}_{\mathsf{R}}({\textbf{B}})$ and
it is the meet of strictly meet irreducible congruences so it is itself a
coatom and thus B is $\mathsf{R}$-simple.

We will produce an algebra in $\mathsf{Q}$ with a totally ordered lattice of
$\mathsf{Q}$-congruences that it is not simple. Let ${\textbf{A}}^{*}$ be any
ultraproduct of A; then the universe of ${\textbf{A}}^{*}$ is a nonstandard
model $\mathbb{R}^{*}$ of the reals and since ${\textbf{A}}^{*}$ is totally
ordered, then $\textrm{Con}_{\mathsf{Q}}({\textbf{A}}^{*})$ is totally
ordered. Let $F$ be all the elements of $\mathbb{R}^{*}$ that are not
infinite; it is trivial to check that $F$ is the universe of a subalgebra F of
${\textbf{A}}^{*}$. We claim that if $I$ is the set of infinitesimals in $F$
is a $\sigma$-ideal of F; this happens because the continuity of $\sigma$ as a
real-valued function ensures that if $a$ and $b$ are infinitely close in $F$,
then so are $\sigma(a)$ and $\sigma(b)$. Let $\theta_{I}$ be the congruence
associated to $I$; then $\theta_{I}$ collapses all the infinitesimals to $0$,
so ${\textbf{F}}/\theta_{I}\cong{\textbf{A}}$ and
$\theta_{I}\in\textrm{Con}_{\mathsf{Q}}({\textbf{F}})$. As $\theta_{I}$ is
neither the largest or the smallest $\mathsf{Q}$-congruence of F we have
proved out claim.∎

###  5.4 Fixedpoint discriminator quasivarieties

In this section we will explore an important subclass of dual i-discriminator
quasivarieties. A pointed quasivariety $\mathsf{Q}$ (and from now on we will
denote constant by $0$) is a fixedpoint discriminator quasivariety if there is
a ternary term $d(x,y,z)$ such that, for any $\mathsf{Q}$-irreducible algebra
${\textbf{A}}\in\mathsf{Q}$ and for any $a,b,c\in A$

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

######  Theorem 5.18.

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

  1. 1.

$\mathsf{Q}$ is a fixedpoint discriminator variety;

  2. 2.

$\mathsf{Q}$ is a dual i-discriminator variety with dual i-discriminator term
$p(x,y,z)$ satisfying $p(x,x,x)\approx 0$.

###### Proof.

Assume (1) and let $p(x,y,z)=d(0,d(x,y,z),z)$; then for any
${\textbf{A}}\in\mathsf{Q}_{ir}$ and $a,b,c\in A$

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

Then $p(a,a,a)=0$ and (2) holds.

Conversely assume (2) and let $d(x,y,z)=p(z,p(x,y,z),z)$. Let
${\textbf{A}}\in\mathsf{Q}_{ir}$ and $a,b,c\in A$; then if $a=b$

$d(a,a,c)=p(c,p(a,a,c),c)=p(c,0,c)=c$

and if $a\neq b$

$d(a,b,c)=p(c,p(a,b,c),c)=p(c,c,c)=0.$

Therefore $d(x,y,z)$ is a fixedpoint discriminator for $\mathsf{Q}$. ∎

######  Example 5.19.

(Implication algebras) An implication algebra is an algebra with a single
binary operation $\rightarrow$ axiomatized by

$\displaystyle(x\rightarrow y)\rightarrow x\approx x$
$\displaystyle(x\rightarrow y)\rightarrow y\approx(y\rightarrow x)\rightarrow
x$ $\displaystyle x\rightarrow(y\rightarrow z)\approx
y\rightarrow(x\rightarrow z).$

Equivalently it is an $\rightarrow$-subreduct of a Boolean algebra. The only
subdirectly irreducible implication algebra is the simple algebra
$\langle\\{0,1\\},\rightarrow\rangle$, where $\rightarrow$ is the Boolean
implication. A dual i-discriminator on $\langle\\{0,1\\},\rightarrow\rangle$
with respect to $1$ is

$p(x,y,z)=[(x\rightarrow y)\rightarrow((y\rightarrow x)\rightarrow
z)]\rightarrow z.$

and of course $p(x,x,x)=1$. So the variety of implication algebras is a
fixedpoint discriminator variety by Theorem 5.18. Implication algebras are not
congruence permutable [52], hence they are not a discriminator variety.
Moreover one shows by induction that, for any ternary term $t(x,y,z)$, at
least one of $t(0,0,1)$, $t(0,1,0)$, $t(1,0,0)$ evaluates to $1$ in
$\langle\\{0,1\\},\rightarrow\rangle$ [16]. Hence the variety of implication
algebras is not a dual discriminator variety.∎

######  Remark 5.20.

In [18] the term fixedpoint discriminator variety refers to a slightly
different concept. The fixedpoint discriminator function on a set $A$ is a
ternary function $t(x,y,z)$ with the property that there is a $t_{A}\in A$
(called the discriminating element) such that for any $a,b,c\in A$

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

A fixedpoint discriminator variety in the sense of [18] is a variety having a
fixedpoint discriminator function on each subdirectly irreducible algebra.

Let us show that the concepts differ. Let
${\textbf{Q}}=\langle\\{0,1\\},q\rangle$; we regard Q as a term reduct of the
two-element Boolean algebra, where

$q(x,y,z)=x\wedge((y\wedge z)\vee(y^{\prime}\wedge z^{\prime})).$

By Theorem 2.3, Q is the unique subdirectly irreducible member of
${\mathbf{V}}({\textbf{Q}})$ and for any $a,b,c\in Q$

$q(a,b,c)=\begin{cases}a&\text{if $b=c$}\\\ 0&\text{if $b\neq
c$.}\end{cases}.$

Thus $t(x,y,z)=q(z,x,y)$ is a fixedpoint discriminator function for Q with
discriminating element $0$ and ${\mathbf{V}}({\textbf{Q}})$ is a fixedpoint
discriminator variety in the sense of [18]. It is easily seen that
${\mathbf{V}}({\textbf{Q}})$ has the RPIP witnessed by

$q_{1}(x,y,z,w)=q(x,y,q(x,z,w))\qquad q_{2}(x,y,z,w)=q(y,x,q(y,z,w)).$

However ${\mathbf{V}}({\textbf{Q}})$ does not have the RTPIP ([3] Proposition
2.6) so it cannot be a fixedpoint discriminator variety.

The problem is that the discriminating element $0$ of Q above is not induced
by any constant term of the variety. If we add it to type i.e., we consider
${\mathbf{V}}(\langle\\{0,1\\},q,0\rangle)$, then this variety is termwise
equivalent to the variety of implication algebras.

This is not a coincidence; it is easily seen that a pointed (quasi)variety is
a fixedpoint discriminator variety if and only if it is a fixedpoint
discriminator variety in the sense of [18] in which the discriminating element
is a constant. However the latter is quite a mouthful, so we will stick to our
name.

A fixedpoint discriminator variety is not merely a variety with a constant
arbitrarily designated: there is no ternary term that is the fixedpoint
discriminator with constant $0$ or $1$ in the variety of bounded distributive
lattices (which is a dual discriminator variety). Rather we will see that
“local” properties near $0$ in a member of a fixedpoint discriminator variety
determine its “global” properties.

For classical pointed structures, like groups, rings or Boolean algebras, one
often deals with subsets (like normal subgroups, ideals or filters) that have
two properties:

  1. $\bullet$

they are the congruence blocks of some constant;

  2. $\bullet$

they are definable by certain “closure” properties.

For instance a subset $I$ of a commutative ring R is an ideal if and only if
$r\in R$ and $a\in I$ implies $ra\in I$. Using the classical description of
terms in commutative rings, $I$ is an ideal of R if and only if for any term
$t(x_{1},\dots,x_{m},y_{1},\dots,y_{n})$ in the language of rings such that

$t(x_{1},\dots,x_{m},0,\dots,0)\approx 0,$ ($**$)

then for any $r_{1},\dots,r_{m}\in R$ and $a_{1},\dots,a_{n}\in I$,

$t(r_{0},\dots,r_{m},a_{1},\dots,a_{n})\in I.$

It is a classical theorem in ring theory that it is sufficient to check the
above for the terms $y_{1}-y_{2}$ and $x_{1}y_{1}$.

Let now $\mathsf{K}$ be any class of algebras whose type contains a $0$. A
term $p(x_{1},\dots,x_{m},y_{1},\dots,y_{n})$ is a $\mathsf{K}$-ideal term in
$\vec{y}$ [62] if the identity $p(\vec{x},0,\dots,0)\approx 0$ holds in
$\mathsf{K}$. A nonempty subset $I$ of ${\textbf{A}}\in\mathsf{K}$ is a
$\mathsf{K}$-ideal of A if for any $\mathsf{K}$-ideal term
$p(\vec{x},\vec{y})$, for $\vec{a}\in A$ and $\vec{b}\in I$,