| Copyright | (c) Erich Gut |
|---|---|
| License | BSD3 |
| Maintainer | zerich.gut@gmail.com |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
OAlg.Data.Dualisable
Description
data admitting a kind of duality.
Synopsis
- type family Dual (x :: k) :: k
- class Dualisable x where
- fromDual' :: Dualisable x => p x -> Dual x -> x
- class Reflexive x where
- fromBidual' :: Reflexive x => p x -> Dual (Dual x) -> x
- class Transposable x where
- transpose :: x -> x
- data Site
- data Side
- data Direction
Dual
type family Dual (x :: k) :: k Source #
the assigned dual kind.
Instances
Dualisable
class Dualisable x where Source #
admitting a duality.
Property Let x be Dualisable, than holds: toDual is a bijection
with its inverse fromDual.
Instances
fromDual' :: Dualisable x => p x -> Dual x -> x Source #
Reflexive
class Reflexive x where Source #
admitting reflection.
Property Let x be Reflexive, than holds:
toBidualis a bijection with its inversefromBidual.
fromBidual' :: Reflexive x => p x -> Dual (Dual x) -> x Source #
fromBidual enriched with a parameterized type p which serves as a proxy -
e.g. Proxy or Id will serve - and will not be evaluated.
It serves for the type checker to pick the right fromBidual.
Transposable
class Transposable x where Source #
transposable types..
Property Let x be a Transposable, then holds:
For all x in x holds: .transpose (transpose x) == x
Instances
| Transposable Direction Source # | |
| Transposable Side Source # | |
| Transposable Site Source # | |
| Transposable N Source # | |
| Transposable Q Source # | |
| Transposable Z Source # | |
| (Distributive x, TransposableDistributive x) => Transposable (Matrix x) Source # | |
| (Galoisian x, TransposableDistributive x) => Transposable (GL2 x) Source # | |
| TransposableMultiplicative c => Transposable (Inv c) Source # | |
| Transposable (Orientation p) Source # | |
Defined in OAlg.Structure.Oriented.Definition Methods transpose :: Orientation p -> Orientation p Source # | |
| (Transposable x, Ord n) => Transposable (Entries n n x) Source # | |
Site
Side
Direction
concept of the directions LeftToRight and RightToLeft.
Constructors
| LeftToRight | |
| RightToLeft |
Instances
| Bounded Direction Source # | |
| Enum Direction Source # | |
Defined in OAlg.Data.Dualisable Methods succ :: Direction -> Direction # pred :: Direction -> Direction # fromEnum :: Direction -> Int # enumFrom :: Direction -> [Direction] # enumFromThen :: Direction -> Direction -> [Direction] # enumFromTo :: Direction -> Direction -> [Direction] # enumFromThenTo :: Direction -> Direction -> Direction -> [Direction] # | |
| Show Direction Source # | |
| Eq Direction Source # | |
| Ord Direction Source # | |
| Transposable Direction Source # | |
| type Dual 'LeftToRight Source # | |
Defined in OAlg.Data.Dualisable | |
| type Dual 'RightToLeft Source # | |
Defined in OAlg.Data.Dualisable | |