Finite relation algebras as tables of atoms #
A finite relation algebra is the complex algebra of its atom structure, which is given by finitely
much data: the number of atoms, the converse of each, which of them lie below the identity, and
the triples (a, b, c) with c ≤ a;b. An AtomTable records these as numbers and lists of
numbers, so that finite relation algebras become the instances of decision problems in the sense
of Mathlib's ComputablePred and many-one reducibility.
A table need not describe an atom structure: the lists may be malformed. AtomTable.Presents
relates a table to the atom structure it describes, of which there is at most one, and that
structure need not satisfy the laws (LawfulAtomStructure), associativity among them.
Main definitions #
Cslib.RelationAlgebra.AtomTable: tables, coded as tuples(size, conv, id, cycles).Cslib.RelationAlgebra.AtomTable.Presents: a table presents an atom structure onFin size.Cslib.RelationAlgebra.AtomTable.IsRepresentable: a table presents a lawful atom structure whose complex algebra is representable.
Main results #
Cslib.RelationAlgebra.AtomTable.Presents.unique: a table presents at most one atom structure.Cslib.RelationAlgebra.AtomTable.exists_presents_equiv: every finite relation algebra is isomorphic to the complex algebra of an atom structure presented by a table.
A table presents at most one atom structure.
The table presents a lawful atom structure whose complex algebra is representable. This is the representation problem for finite relation algebras as a predicate on tables; a table that presents no atom structure, or one violating the laws, is a no-instance.
Every finite relation algebra is isomorphic to the complex algebra of an atom structure that
some table presents. Isomorphic relation algebras are both representable or both not
(Cslib.RelationAlgebraEquiv.representable_iff; for finite ones in different universes, by
Cslib.RelationAlgebra.Representation.representable), so tables cover the representation problem
for finite relation algebras.