# product(Poset,Poset) -- computes the product of two posets

## Synopsis

• Function: product
• Usage:
R = product(P, Q)
R = P * Q
• Inputs:
• P, an instance of the type Poset,
• Q, an instance of the type Poset,
• Outputs:
• R, an instance of the type Poset, the Cartesian product of $P$ and $Q$

## Description

The Cartesian product of the posets $P$ and $Q$ is the new poset whose ground set is the Cartesian product of the ground sets of $P$ and $Q$ and with partial order given by $(a,b) \leq (c,d)$ if and only if $a \leq c$ and $b \leq d$.

 i1 : product(chain 3, poset {{a,b},{b,c}}) o1 = Relation Matrix: | 1 1 1 1 1 1 1 1 1 | | 0 1 1 0 1 1 0 1 1 | | 0 0 1 0 0 1 0 0 1 | | 0 0 0 1 1 1 1 1 1 | | 0 0 0 0 1 1 0 1 1 | | 0 0 0 0 0 1 0 0 1 | | 0 0 0 0 0 0 1 1 1 | | 0 0 0 0 0 0 0 1 1 | | 0 0 0 0 0 0 0 0 1 | o1 : Poset

The product of $n$ chains of length $2$ is isomorphic to the boolean lattice on $n$ elements. These are also isomorphic to the divisor lattice on the product of $n$ distinct primes.

 i2 : B = booleanLattice 4; i3 : B == product(4, i -> chain 2) o3 = true