variety (universal algebra)
A variety is a kind of algebra, defined not by a single example but by a list of laws everything in it must obey. ‘All groups’ is a variety; ‘all commutative rings’ is a variety; ‘all lattices’ is a variety. The unifying idea is that membership is decided purely by satisfying equations, so the class is closed in pleasant ways and carries a rich uniform theory.
Formally, fix a signature Σ and a set E of identities over Σ. The variety V = Mod(E) is the class of all Σ-algebras satisfying every identity in E. Such a class is called equational, and a class is a variety precisely when it equals Mod(E) for some E. Within a variety one always has free algebras on any set of generators, and every algebra is a quotient of a free one, so the variety is completely determined by its free objects.
Beware the unfortunate name collision: ‘variety’ here is the universal-algebra notion (an equational class), totally distinct from an algebraic variety in algebraic geometry (a zero set of polynomials). The two share only the word. The deep structural fact about varieties in our sense is Birkhoff's HSP theorem, which characterizes them by closure under homomorphic images, subalgebras and products.
Groups, abelian groups, rings, lattices, distributive lattices and Boolean algebras are all varieties; fields are not, because no set of identities defines them.
Equational definability is the dividing line between a variety and a merely elementary class.
The variety of all groups, of abelian groups, and of trivial (one-element) groups form a chain of sub-varieties; abelian groups are cut out by the extra identity x·y ≈ y·x.