| Copyright | Guillaume Sabbagh 2021 |
|---|---|
| License | GPL-3 |
| Maintainer | guillaumesabbagh@protonmail.com |
| Stability | experimental |
| Portability | portable |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Diagram.Conversion
Description
Functions to convert all functor types.
Synopsis
- diagramToFinFunctor :: (FiniteCategory c m o, Morphism m o) => Diagram c m o c m o -> FinFunctor c m o
- diagramToPartialFunctor :: (FiniteCategory c m o, Morphism m o) => Diagram c m o c m o -> PartialFunctor c m o
- finFunctorToDiagram :: FinFunctor c m o -> Diagram c m o c m o
- finFunctorToPartialFunctor :: (FiniteCategory c m o, Morphism m o) => FinFunctor c m o -> PartialFunctor c m o
- partialFunctorToDiagram :: (FiniteCategory c m o, Morphism m o, Eq m, Eq o, Show o, Show m) => PartialFunctor c m o -> Maybe (Diagram c m o c m o)
- partialFunctorToFinFunctor :: (FiniteCategory c m o, Morphism m o, Eq m, Eq o, Show o, Show m) => PartialFunctor c m o -> Maybe (FinFunctor c m o)
Diagram to something
diagramToFinFunctor :: (FiniteCategory c m o, Morphism m o) => Diagram c m o c m o -> FinFunctor c m o Source #
Converts a homogeneous Diagram to a FinFunctor.
diagramToPartialFunctor :: (FiniteCategory c m o, Morphism m o) => Diagram c m o c m o -> PartialFunctor c m o Source #
Converts a homogeneous Diagram to a PartialFunctor
FinFunctor to something
finFunctorToDiagram :: FinFunctor c m o -> Diagram c m o c m o Source #
Converts a FinFunctor into a Diagram.
A FinFunctor is a morphism of the FinCat category, it is a homogeneous FinFunctor. This functions casts it to a heterogeneous FinFunctor (i.e. a Diagram).
finFunctorToPartialFunctor :: (FiniteCategory c m o, Morphism m o) => FinFunctor c m o -> PartialFunctor c m o Source #
Converts a total functor to a partial functor.
PartialFunctor to something
partialFunctorToDiagram :: (FiniteCategory c m o, Morphism m o, Eq m, Eq o, Show o, Show m) => PartialFunctor c m o -> Maybe (Diagram c m o c m o) Source #
Try to convert a PartialFunctor into a Diagram if it can (if it is total).
partialFunctorToFinFunctor :: (FiniteCategory c m o, Morphism m o, Eq m, Eq o, Show o, Show m) => PartialFunctor c m o -> Maybe (FinFunctor c m o) Source #
Try to convert a partial functor to a total functor if it is possible.