This article includes a list of references, but its sources remain unclear because it has insufficient inline citations. (May 2009) (Learn how and when to remove this template message)

A lattice is an abstract structure studied in the mathematical subdisciplines of order theory and abstract algebra. It consists of a partially ordered set in which every two elements have a unique supremum (also called a least upper bound or join) and a unique infimum (also called a greatest lower bound or meet). An example is given by the natural numbers, partially ordered by divisibility, for which the unique supremum is the least common multiple and the unique infimum is the greatest common divisor.
Lattices can also be characterized as algebraic structures satisfying certain axiomatic identities. Since the two definitions are equivalent, lattice theory draws on both order theory and universal algebra. Semilattices include lattices, which in turn include Heyting and Boolean algebras. These "latticelike" structures all admit ordertheoretic as well as algebraic descriptions.
If
A partially ordered set
It follows by an induction argument that every nonempty finite subset of a lattice has a least upper bound and a greatest lower bound. With additional assumptions, further conclusions may be possible; see Completeness (order theory) for more discussion of this subject. That article also discusses how one may rephrase the above definition in terms of the existence of suitable Galois connections between related partially ordered sets  an approach of special interest for the category theoretic approach to lattices, and for formal concept analysis.
A bounded lattice is a lattice that additionally has a greatest element 1 and a least element 0, which satisfy
The greatest and least element is also called the maximum and minimum, or the top and bottom element, and denoted by ? and ?, respectively. Every lattice can be converted into a bounded lattice by adding an artificial greatest and least element, and every nonempty finite lattice is bounded, by taking the join (resp., meet) of all elements, denoted by (resp.) where .
A partially ordered set is a bounded lattice if and only if every finite set of elements (including the empty set) has a join and a meet. For every element x of a poset it is trivially true (it is a vacuous truth) that and , and therefore every element of a poset is both an upper bound and a lower bound of the empty set. This implies that the join of an empty set is the least element , and the meet of the empty set is the greatest element . This is consistent with the associativity and commutativity of meet and join: the join of a union of finite sets is equal to the join of the joins of the sets, and dually, the meet of a union of finite sets is equal to the meet of the meets of the sets, i.e., for finite subsets A and B of a poset L,
and
hold. Taking B to be the empty set,
and
which is consistent with the fact that .
A lattice element y is said to cover another element x, if , but there does not exist a z such that . Here, means and .
A lattice
Given a subset of a lattice, , meet and join restrict to partial functions  they are undefined if their value is not in the subset H. The resulting structure on H is called a partial lattice. In addition to this extrinsic definition as a subset of some other algebraic structure (a lattice), a partial lattice can also be intrinsically defined as a set with two partial binary operations satisfying certain axioms.^{[1]}
An algebraic structure , consisting of a set L and two binary operations ?, and ?, on L is a lattice if the following axiomatic identities hold for all elements a, b, c of L.



The following two identities are also usually regarded as axioms, even though they follow from the two absorption laws taken together.^{[note 1]}
These axioms assert that both and are semilattices. The absorption laws, the only axioms above in which both meet and join appear, distinguish a lattice from an arbitrary pair of semilattices and assure that the two semilattices interact appropriately. In particular, each semilattice is the dual of the other.
A bounded lattice is an algebraic structure of the form such that is a lattice, 0 (the lattice's bottom) is the identity element for the join operation ?, and 1 (the lattice's top) is the identity element for the meet operation ?.
See semilattice for further details.
Lattices have some connections to the family of grouplike algebraic structures. Because meet and join both commute and associate, a lattice can be viewed as consisting of two commutative semigroups having the same domain. For a bounded lattice, these semigroups are in fact commutative monoids. The absorption law is the only defining identity that is peculiar to lattice theory.
By commutativity and associativity one can think of join and meet as binary operations that are defined on nonempty finite sets, rather than on elements. In a bounded lattice the empty join and the empty meet can also be defined (as 0 and 1, respectively). This makes bounded lattices somewhat more natural than general lattices, and many authors require all lattices to be bounded.
The algebraic interpretation of lattices plays an essential role in universal algebra.
An ordertheoretic lattice gives rise to the two binary operations ? and ?. Since the commutative, associative and absorption laws can easily be verified for these operations, they make into a lattice in the algebraic sense.
The converse is also true. Given an algebraically defined lattice , one can define a partial order L by setting
for all elements a and b from L. The laws of absorption ensure that both definitions are equivalent:
a = a ? b implies b = b ? (b ? a) = (a ? b) ? b = a ? b
and dually for the other direction.
One can now check that the relation
Since the two definitions of a lattice are equivalent, one may freely invoke aspects of either definition in any way that suits the purpose at hand.
Further examples of lattices are given for each of the additional properties discussed below.
Most partial ordered sets are not lattices, including the following.
The appropriate notion of a morphism between two lattices flows easily from the above algebraic definition. Given two lattices and , a lattice homomorphism from L to M is a function such that for all :
Thus f is a homomorphism of the two underlying semilattices. When lattices with more structure are considered, the morphisms should "respect" the extra structure, too. In particular, a boundedlattice homomorphism (usually called just "lattice homomorphism") f between two bounded lattices L and M should also have the following property:
In the ordertheoretic formulation, these conditions just state that a homomorphism of lattices is a function preserving binary meets and joins. For bounded lattices, preservation of least and greatest elements is just preservation of join and meet of the empty set.
Any homomorphism of lattices is necessarily monotone with respect to the associated ordering relation; see preservation of limits. The converse is not true: monotonicity by no means implies the required preservation of meets and joins (see pic.9), although an orderpreserving bijection is a homomorphism if its inverse is also orderpreserving.
Given the standard definition of isomorphisms as invertible morphisms, a lattice isomorphism is just a bijective lattice homomorphism. Similarly, a lattice endomorphism is a lattice homomorphism from a lattice to itself, and a lattice automorphism is a bijective lattice endomorphism. Lattices and their homomorphisms form a category.
A sublattice of a lattice L is a nonempty subset of L that is a lattice with the same meet and join operations as L. That is, if L is a lattice and is a subset of L such that for every pair of elements a, b in M both and are in M, then M is a sublattice of L.^{[2]}
A sublattice M of a lattice L is a convex sublattice of L, if and x, y in M implies that z belongs to M, for all elements x, y, z in L.
We now introduce a number of important properties that lead to interesting special classes of lattices. One, boundedness, has already been discussed.
A poset is called a complete lattice if all its subsets have both a join and a meet. In particular, every complete lattice is a bounded lattice. While bounded lattice homomorphisms in general preserve only finite joins and meets, complete lattice homomorphisms are required to preserve arbitrary joins and meets.
Every poset that is a complete semilattice is also a complete lattice. Related to this result is the interesting phenomenon that there are various competing notions of homomorphism for this class of posets, depending on whether they are seen as complete lattices, complete joinsemilattices, complete meetsemilattices, or as joincomplete or meetcomplete lattices.
Note that "partial lattice" is not the opposite of "complete lattice"  rather, "partial lattice", "lattice", and "complete lattice" are increasingly restrictive definitions.
A conditionally complete lattice is a lattice in which every nonempty subset that has an upper bound has a join (i.e., a least upper bound). Such lattices provide the most direct generalization of the completeness axiom of the real numbers. A conditionally complete lattice is either a complete lattice, or a complete lattice without its maximum element 1, its minimum element 0, or both.
Since lattices come with two binary operations, it is natural to ask whether one of them distributes over the other, i.e. whether one or the other of the following dual laws holds for every three elements a, b, c of L:
A lattice that satisfies the first or, equivalently (as it turns out), the second axiom, is called a distributive lattice. The only nondistributive lattices with fewer than 6 elements are called M_{3} and N_{5};^{[3]} they are shown in picture 10 and 11, respectively. A lattice is distributive if and only if it doesn't have a sublattice isomorphic to M_{3} or N_{5}.^{[4]} Each distributive lattice is isomorphic to a lattice of sets (with union and intersection as join and meet, respectively).^{[5]}
For an overview of stronger notions of distributivity which are appropriate for complete lattices and which are used to define more special classes of lattices such as frames and completely distributive lattices, see distributivity in order theory.
For some applications the distributivity condition is too strong, and the following weaker property is often useful. A lattice is modular if, for all elements a, b, c of L, the following identity holds.
This condition is equivalent to the following axiom.
A lattice is modular if and only if it doesn't have a sublattice isomorphic to N_{5} (shown in pic.11).^{[4]} Besides distributive lattices, examples of modular lattices are the lattice of twosided ideals of a ring, the lattice of submodules of a module, and the lattice of normal subgroups of a group. The set of firstorder terms with the ordering "is more specific than" is a nonmodular lattice used in automated reasoning.
A finite lattice is modular if and only if it is both upper and lower semimodular. For a graded lattice, (upper) semimodularity is equivalent to the following condition on the rank function r:
Another equivalent (for graded lattices) condition is Birkhoff's condition:
A lattice is called lower semimodular if its dual is semimodular. For finite lattices this means that the previous conditions hold with ? and ? exchanged, "covers" exchanged with "is covered by", and inequalities reversed.^{[6]}
In domain theory, it is natural to seek to approximate the elements in a partial order by "much simpler" elements. This leads to the class of continuous posets, consisting of posets where every element can be obtained as the supremum of a directed set of elements that are waybelow the element. If one can additionally restrict these to the compact elements of a poset for obtaining these directed sets, then the poset is even algebraic. Both concepts can be applied to lattices as follows:
Both of these classes have interesting properties. For example, continuous lattices can be characterized as algebraic structures (with infinitary operations) satisfying certain identities. While such a characterization is not known for algebraic lattices, they can be described "syntactically" via Scott information systems.
Let L be a bounded lattice with greatest element 1 and least element 0. Two elements x and y of L are complements of each other if and only if:
In general, some elements of a bounded lattice might not have a complement, and others might have more than one complement. For example, the set {0, ½, 1} with its usual ordering is a bounded lattice, and ½ does not have a complement. In the bounded lattice N_{5}, the element a has two complements, viz. b and c (see Pic.11).
In the case the complement is unique, we write and equivalently, . A bounded lattice for which every element has a complement is called a complemented lattice. The corresponding unary operation over L, called complementation, introduces an analogue of logical negation into lattice theory. The complement is not necessarily unique, nor does it have a special status among all possible unary operations over L. A complemented lattice that is also distributive is a Boolean algebra. For a distributive lattice, the complement of x, when it exists, is unique.
Heyting algebras are an example of distributive lattices where some members might be lacking complements. Every element x of a Heyting algebra has, on the other hand, a pseudocomplement, also denoted ¬x. The pseudocomplement is the greatest element y such that . If the pseudocomplement of every element of a Heyting algebra is in fact a complement, then the Heyting algebra is in fact a Boolean algebra.
A chain from x_{0} to x_{n} is a set , where . The length of this chain is n, or one less than its number of elements. A chain is maximal if x_{i} covers x_{i1} for all .
If for any pair, x and y, where , all maximal chains from x to y have the same length, then the lattice is said to satisfy the JordanDedekind chain condition.
Any set X may be used to generate the free semilattice FX. The free semilattice is defined to consist of all of the finite subsets of X, with the semilattice operation given by ordinary set union. The free semilattice has the universal property. For the free lattice over a set X, Whitman gave a construction based on polynomials over Xs members.^{[7]}^{[8]}
We now define some ordertheoretic notions of importance to lattice theory. In the following, let x be an element of some lattice L. If L has a bottom element 0, is sometimes required. x is called:
Let L have a bottom element 0. An element x of L is an atom if and there exists no element y of L such that . Then L is called:
The notions of ideals and the dual notion of filters refer to particular kinds of subsets of a partially ordered set, and are therefore important for lattice theory. Details can be found in the respective entries.
This article is in a list format that may be better presented using prose. (March 2017)

Note that in many applications the sets are only partial lattices: not every pair of elements has a meet or join.
Monographs available free online:
Elementary texts recommended for those with limited mathematical maturity:
The standard contemporary introductory text, somewhat harder than the above:
Advanced monographs:
On free lattices:
On the history of lattice theory:
On applications of lattice theory: