| 1 |
------------------------------------------------------------------------ |
| 2 |
-- The Agda standard library |
| 3 |
-- |
| 4 |
-- Instances of algebraic structures where the carrier is ⊤. In |
| 5 |
-- mathematics, this is usually called 0 (1 in the case of Monoid, Group). |
| 6 |
-- |
| 7 |
-- From monoids up, these are zero-objects – i.e, both the initial |
| 8 |
-- and the terminal object in the relevant category. |
| 9 |
------------------------------------------------------------------------ |
| 10 |
|
| 11 |
{-# OPTIONS --cubical-compatible --safe #-} |
| 12 |
|
| 13 |
open import Level using (Level) |
| 14 |
|
| 15 |
module Algebra.Construct.Terminal {c ℓ : Level} where |
| 16 |
|
| 17 |
open import Algebra.Bundles |
| 18 |
open import Data.Unit.Polymorphic using (⊤) |
| 19 |
open import Relation.Binary.Core using (Rel) |
| 20 |
|
| 21 |
------------------------------------------------------------------------ |
| 22 |
-- Gather all the functionality in one place |
| 23 |
|
| 24 |
module 𝕆ne where |
| 25 |
|
| 26 |
infix 4 _≈_ |
| 27 |
Carrier : Set c |
| 28 |
Carrier = ⊤ |
| 29 |
|
| 30 |
_≈_ : Rel Carrier ℓ |
| 31 |
_ ≈ _ = ⊤ |
| 32 |
|
| 33 |
------------------------------------------------------------------------ |
| 34 |
-- Raw bundles |
| 35 |
|
| 36 |
rawMagma : RawMagma c ℓ |
| 37 |
rawMagma = record { 𝕆ne } |
| 38 |
|
| 39 |
rawMonoid : RawMonoid c ℓ |
| 40 |
rawMonoid = record { 𝕆ne } |
| 41 |
|
| 42 |
rawGroup : RawGroup c ℓ |
| 43 |
rawGroup = record { 𝕆ne } |
| 44 |
|
| 45 |
rawNearSemiring : RawNearSemiring c ℓ |
| 46 |
rawNearSemiring = record { 𝕆ne } |
| 47 |
|
| 48 |
rawSemiring : RawSemiring c ℓ |
| 49 |
rawSemiring = record { 𝕆ne } |
| 50 |
|
| 51 |
rawRing : RawRing c ℓ |
| 52 |
rawRing = record { 𝕆ne } |
| 53 |
|
| 54 |
------------------------------------------------------------------------ |
| 55 |
-- Bundles |
| 56 |
|
| 57 |
magma : Magma c ℓ |
| 58 |
magma = record { 𝕆ne } |
| 59 |
|
| 60 |
semigroup : Semigroup c ℓ |
| 61 |
semigroup = record { 𝕆ne } |
| 62 |
|
| 63 |
band : Band c ℓ |
| 64 |
band = record { 𝕆ne } |
| 65 |
|
| 66 |
commutativeSemigroup : CommutativeSemigroup c ℓ |
| 67 |
commutativeSemigroup = record { 𝕆ne } |
| 68 |
|
| 69 |
monoid : Monoid c ℓ |
| 70 |
monoid = record { 𝕆ne } |
| 71 |
|
| 72 |
commutativeMonoid : CommutativeMonoid c ℓ |
| 73 |
commutativeMonoid = record { 𝕆ne } |
| 74 |
|
| 75 |
idempotentCommutativeMonoid : IdempotentCommutativeMonoid c ℓ |
| 76 |
idempotentCommutativeMonoid = record { 𝕆ne } |
| 77 |
|
| 78 |
group : Group c ℓ |
| 79 |
group = record { 𝕆ne } |
| 80 |
|
| 81 |
abelianGroup : AbelianGroup c ℓ |
| 82 |
abelianGroup = record { 𝕆ne } |
| 83 |
|
| 84 |
nearSemiring : NearSemiring c ℓ |
| 85 |
nearSemiring = record { 𝕆ne } |
| 86 |
|
| 87 |
semiring : Semiring c ℓ |
| 88 |
semiring = record { 𝕆ne } |
| 89 |
|
| 90 |
ring : Ring c ℓ |
| 91 |
ring = record { 𝕆ne } |
| 92 |
|