Logic, Sets and Infinity

Partial Orders and Hasse Diagrams

Learn what makes a relation a partial order, draw clean Hasse diagrams, and read off maxima, chains, antichains and bounds.

Key takeaways

  • A partial order is a relation that is reflexive, antisymmetric and transitive.
  • A Hasse diagram shows only covering pairs and places the larger element higher, so arrows and loops are unnecessary.
  • Maximal elements have nothing above them, while a maximum is above everything and may not exist.
  • Chains are sets of mutually comparable elements, antichains are sets of mutually incomparable ones, and the two are tightly linked.

A partial order is a way of ranking things in which some pairs may simply not be comparable. A Hasse diagram draws such an order as dots and upward lines, keeping only the links you cannot deduce from others.

Numbers on a line are totally ordered: of any two, one comes first. Tasks in a project, subsets of a set and divisors of a number are different, since two of them can be unrelated. This article shows how to recognize that situation, draw it and extract information from the picture.

The three rules

Let ≤ be a relation on a set P. It is a partial order when, for all elements a, b and c, the following hold.

  1. Reflexive. a ≤ a.
  2. Antisymmetric. If a ≤ b and b ≤ a, then a = b.
  3. Transitive. If a ≤ b and b ≤ c, then a ≤ c.

A set with a partial order is often called a poset. If every two elements are comparable, meaning a ≤ b or b ≤ a, the order is total, also called linear. The symbol ≤ here stands for whatever relation you are studying, not necessarily "less than or equal to".

Relation Partial order? Why
≤ on the real numbers Yes, and total Any two reals compare
"divides" on positive integers Yes 4 and 6 do not compare
⊆ on the subsets of a set Yes {a} and {b} do not compare
"divides" on all integers No 2 and −2 divide each other but differ
< on the real numbers No, it is a strict order It is not reflexive
"is a friend of" No, in general Not transitive

The failure on the integers is instructive. A relation that is reflexive and transitive but not antisymmetric is called a preorder. You can repair it by grouping mutually related items, an application of equivalence relations.

Covering and the Hasse diagram

Say b covers a if a is strictly below b and nothing lies strictly between them. In a finite poset, the whole order can be rebuilt from the covering pairs: a ≤ b exactly when you can climb from a to b through covers, or when a = b.

A Hasse diagram, named after the German mathematician Helmut Hasse, uses that fact. To draw one:

  1. List all the elements.
  2. Find every covering pair.
  3. Place each element above everything it covers.
  4. Join covering pairs with a line. No arrowheads are needed because direction is "up".

Loops (from reflexivity) and shortcut lines (from transitivity) are omitted. Horizontal lines are not allowed, since neither end would be higher.

Worked example: divisors of 12

The divisors of 12 are 1, 2, 3, 4, 6 and 12, ordered by divisibility. Check each possible pair for something in between.

covers:  1–2   1–3
         2–4   2–6   3–6
         4–12  6–12
not a cover:  1–4  (2 lies between)
not a cover:  2–12 (4 and 6 lie between)

Draw 1 at the bottom, 2 and 3 above it, 4 and 6 above those, and 12 at the top. The diagram has seven lines. You can read divisibility straight off it: 3 divides 12 because there is an upward path 3, 6, 12. There is no upward path from 3 to 4, so 3 does not divide 4.

Divisors of 12 from top to bottom
12 Covers 4 and 6 4 and 6 4 covers 2, while 6 covers 2 and 3 2 and 3 Both cover 1, and neither divides the other 1 Divides every number in the set 12 Covers 4 and 6 4 and 6 4 covers 2, while 6 covers 2 and 3 2 and 3 Both cover 1, and neither divides the other 1 Divides every number in the set

The subsets of {a, b, c} under ⊆ give another classic picture. It has eight dots in four levels, with sizes 1, 3, 3 and 1, and twelve lines, one for each way of adding a single element. It looks like a cube standing on a corner. Compare it with power sets in general.

A second example: ordering pairs

Orders often arise from comparing several features at once. Say a hypothetical shopper rates laptops by two scores, speed and battery life, each from 1 to 3. Declare (a, b) ≤ (c, d) when a ≤ c and b ≤ d. This is called the product order.

It is reflexive, antisymmetric and transitive because each coordinate is. It is not total: (3, 1) and (1, 3) cannot be compared, since each wins on one feature.

(1,1) ≤ (2,1) ≤ (2,3) ≤ (3,3)     a chain
(3,1), (2,2), (1,3)               an antichain

The Hasse diagram of all nine pairs is a tilted 3 by 3 grid. Each point is covered by the points one step higher in exactly one coordinate, which gives twelve lines.

In any collection of score pairs, the maximal ones are those for which no other pair is at least as good on both counts and better on one. Economists and engineers call this set the Pareto frontier. The order will not choose among those models for you, because choosing requires a decision about how much speed is worth against battery life.

A different rule, comparing speed first and using battery only to break ties, is the lexicographic order. It is total, like alphabetical order in a dictionary.

Top, bottom, maximal and minimal

These terms are easy to mix up.

  • A maximum (greatest element) is above every element.
  • A maximal element has nothing strictly above it.
  • A minimum is below every element.
  • A minimal element has nothing strictly below it.

Take the set {2, 3, 4, 6} under divisibility. Both 4 and 6 are maximal, and both 2 and 3 are minimal. There is no maximum and no minimum. Add 12 to the set and it becomes the maximum. Add 1 and it becomes the minimum.

A maximum, when it exists, is the only maximal element in a finite poset. In infinite posets, maximal elements may not exist at all, and proving that they do is the job of Zorn's lemma.

Bounds and lattices

An upper bound of two elements is something above both. The least upper bound, or join, is an upper bound below all the others. The greatest lower bound, or meet, is defined the same way from below.

Among the divisors of 12, the join of 4 and 6 is 12 and their meet is 2. In general, for divisibility the join is the least common multiple and the meet is the greatest common divisor, which you can compute with the Euclidean algorithm. For subsets, join is union and meet is intersection.

A poset in which every two elements have both a join and a meet is a lattice. The set {2, 3, 4, 6} is not one, since 4 and 6 have no upper bound inside it.

Chains and antichains

A chain is a set of elements that are pairwise comparable, such as 1, 2, 4, 12. An antichain is a set in which no two distinct elements are comparable, such as {4, 6}.

How few chains can cover all of the divisors of 12? Two are enough: {1, 2, 4} and {3, 6, 12}. One chain cannot do it, because 4 and 6 can never share a chain. Dilworth's theorem says this always works out: in a finite poset, the minimum number of chains covering it equals the size of the largest antichain.

The mirror statement, Mirsky's theorem, says that the minimum number of antichains covering a finite poset equals the number of elements in its longest chain. Here the longest chain has four elements, and the antichains {1}, {2, 3}, {4, 6} and {12} do the job.

For the subsets of an n-element set, Sperner's theorem gives the largest antichain: the binomial coefficient "n choose ⌊n/2⌋", where ⌊n/2⌋ is n/2 rounded down. For n = 4 that is 6, the number of two-element subsets.

Putting a partial order in a line

A linear extension lists all elements so that whenever a ≤ b, a appears no later than b. In computing this is called a topological sort, and it is how you order tasks that depend on each other.

For the divisors of 12, 1 must come first and 12 last. The valid middle orders of 2, 3, 4 and 6 are:

2, 3, 4, 6
2, 3, 6, 4
2, 4, 3, 6
3, 2, 4, 6
3, 2, 6, 4

So there are five linear extensions. To produce one for any finite poset, repeatedly pick a minimal element of what remains, write it down and remove it. The idea reappears in critical path scheduling.

When are two orders the same?

Two posets are isomorphic if there is a bijection between them that preserves the order in both directions. Their Hasse diagrams then have the same shape, with only the labels changed.

The divisors of 30, which is 2 × 3 × 5, form a copy of the subsets of {a, b, c}. Match 2 with a, 3 with b and 5 with c, and send each divisor to the set of primes it uses. So 1 goes to the empty set, 10 goes to {a, c} and 30 goes to the whole set. One divisor divides another exactly when the matching set is contained in the other.

The divisors of 12 are different, because the prime 2 appears twice. Their diagram is a 3 by 2 grid: the exponent of 2 runs through 0, 1, 2 and the exponent of 3 through 0, 1. In general the divisor diagram of a number depends only on the exponents in its prime factorization. So 12, 18, 20 and 45 all produce the same picture.

Common errors

  • Drawing a line between two elements that already have a path through a third.
  • Reading height as order. Two dots at different heights are comparable only if an upward path joins them.
  • Treating two maximal elements as equal because they sit at the same level.
  • Assuming a poset has a top. Check it.
Chains versus antichains
Chain Every pair is comparable Lies along an upward route Example: 1, 2, 4, 12 Antichain No pair is comparable Often spreads across a level Example: 4 and 6 VS Chain Every pair is comparable Lies along an upward route Example: 1, 2, 4, 12 Antichain No pair is comparable Often spreads across a level Example: 4 and 6

Written for 4Mathematics with AI writing tools and not reviewed line by line by a person. Check anything you rely on against a textbook or primary source. Report an error.

Keep reading

All 41 articles in Logic, Sets and Infinity →

Latest news on this topic