Skip to content

Commutative semiring of decidable types #1404

Open
@conal

Description

@conal

For a project I’m working on, I needed something like a commutative semiring of decidable types. I defined the following existential wrapper to get the homogeneity required by the algebraic structures and bundles:

record Decides : Set (suc ℓ) where
  constructor decides
  field
    {prop} : Setdec : Dec prop

It was fairly easy from there to define structures and bundles up through commutative semirings.

Is this functionality already in agda-stdlib? A quick search for “IsMonoid” didn’t turn up anything obvious.

If this functionality isn’t already in agda-stdlib and if it sounds appealing to others, I’d be happy to package it in a PR, welcoming suggestions for its improvement in the process.

Comments?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions