|
Dedekind 0.0.0
A structuralist C++23 Module Library
|
Kleene starter: the three-valued truth surface ๐3 as an algebra on a set (the downstream sibling of the Boolean ๐น). More...
#include <functional>import dedekind.algebra:universal;import dedekind.sets;import dedekind.category;
Variables | |
| constexpr auto | dedekind::algebra::๐3 = ๐ธ<Ternary, Boole, Finite>{} |
The canonical Kleene universe ๐3 = ๐ธ<Ternary, Boole, Finite> (the three-valued sibling of ๐น = ๐ธ<bool>). | |
Kleene starter: the three-valued truth surface ๐3 as an algebra on a set (the downstream sibling of the Boolean ๐น).
@partition :kleene
Downstream witness (sibling of :boolean) that Kleene's three-valued truth surface ๐3 = ๐ธ<Ternary> is an algebra on a set: the carrier Ternary is closed under the Kleene meet โง, join โจ and reflection ยฌ. It is a bounded distributive lattice (the De Morgan / Kleene sibling of the Boolean ๐น = ๐ธ<bool>), but not a Boolean algebra: the interior value Unknown is self-negating (ยฌUnknown = Unknown), so ๐3 is uncomplemented.
The species-level statements live upstream in :logic (IsBoundedDeMorganChain / IsBooleanLogic); this partition pins their downstream algebra-on-set counterpart, where the logic's lattice structure meets IsAlgebraOnSet. This is the algebra-on-set portion of #912; the companion criterion — registering Ternary's bounds and order in the :total / :posetal lattice machinery — now lives at the Ternary definition in :logic (so IsDistributiveLattice / IsBoundedLattice and the order stack resolve on the carrier, witnessed in logic_lattice_structure_test.cpp and order_test.cpp).
Wikipedia: Three-valued logic, Kleene algebra (with involution), ลukasiewiczโMoisil algebra.
:logic upstream). This partition is exactly that thesis made concrete for the Kleene system: ๐3 is the abstract algebra of three-valued logic, an IsAlgebraOnSet. [Trans: The algebraic method in logic consists in treating every logical system as a specific type of abstract algebra.]
|
inlineconstexprexport |
The canonical Kleene universe ๐3 = ๐ธ<Ternary, Boole, Finite> (the three-valued sibling of ๐น = ๐ธ<bool>).
The Finite cardinality tag is explicit: Ternary is a three-element carrier, but the ๐ธ primary defaults C to โต_0, which would report this finite universe as countably infinite. Only the cardinality metadata is corrected: the classifier species is Boole either way (a universe over a regular carrier answers in Boole). Mirrors the ๐ธ<bool> = ๐ธ<bool, Boole, Finite> override in :boundaries, but kept local here so the Kleene carrier's cardinality stays a downstream (:algebra) fact rather than being pushed up into :sets.