{-# OPTIONS --cubical-compatible --safe #-}
open import Level using (Level)
module Algebra.Morphism.Construct.Terminal {c β : Level} where
open import Algebra.Bundles.Raw
using (RawMagma; RawMonoid; RawGroup; RawNearSemiring; RawSemiring; RawRing)
open import Algebra.Morphism.Structures
open import Data.Product.Base using (_,_)
open import Function.Definitions using (StrictlySurjective)
import Relation.Binary.Morphism.Definitions as Rel
open import Relation.Binary.Morphism.Structures
open import Algebra.Construct.Terminal {c} {β}
private
variable
a βa : Level
A : Set a
one : A β πne.Carrier
one _ = _
strictlySurjective : A β StrictlySurjective πne._β_ one
strictlySurjective x _ = x , _
isMagmaHomomorphism : (M : RawMagma a βa) β
IsMagmaHomomorphism M rawMagma one
isMagmaHomomorphism M = record
{ isRelHomomorphism = record { cong = _ }
; homo = _
}
isMonoidHomomorphism : (M : RawMonoid a βa) β
IsMonoidHomomorphism M rawMonoid one
isMonoidHomomorphism M = record
{ isMagmaHomomorphism = isMagmaHomomorphism (RawMonoid.rawMagma M)
; Ξ΅-homo = _
}
isGroupHomomorphism : (G : RawGroup a βa) β
IsGroupHomomorphism G rawGroup one
isGroupHomomorphism G = record
{ isMonoidHomomorphism = isMonoidHomomorphism (RawGroup.rawMonoid G)
; β»ΒΉ-homo = Ξ» _ β _
}
isNearSemiringHomomorphism : (N : RawNearSemiring a βa) β
IsNearSemiringHomomorphism N rawNearSemiring one
isNearSemiringHomomorphism N = record
{ +-isMonoidHomomorphism = isMonoidHomomorphism (RawNearSemiring.+-rawMonoid N)
; *-homo = Ξ» _ _ β _
}
isSemiringHomomorphism : (S : RawSemiring a βa) β
IsSemiringHomomorphism S rawSemiring one
isSemiringHomomorphism S = record
{ isNearSemiringHomomorphism = isNearSemiringHomomorphism (RawSemiring.rawNearSemiring S)
; 1#-homo = _
}
isRingHomomorphism : (R : RawRing a βa) β IsRingHomomorphism R rawRing one
isRingHomomorphism R = record
{ isSemiringHomomorphism = isSemiringHomomorphism (RawRing.rawSemiring R)
; -βΏhomo = Ξ» _ β _
}