/caterwaul/Rig/Type

Copy path to clipboard

This is what is often called a “semiring”, but here we follow the convention described in https://ncatlab.org/nlab/show/rig, reserving “semiring” for a rig without multiplicative unit.

Source

{-|
This is what is often called a “semiring”, but here we follow the convention
described in https://ncatlab.org/nlab/show/rig, reserving “semiring” for a rig
without multiplicative unit.
-}
let kCat = ../Category/Cat/semigroupal

let vObject = Type

in λ(object : Kind) →
λ(cat : ../Category/Monoidal/Kind kCat vObject object) →
λ(m : object) →
{ additive : ../Monoid/Commutative/Type object cat m
, multiplicative : ../Monoid/Type object cat m
}