linear-0.7: Linear Algebra

Portabilitynon-portable
Stabilityexperimental
MaintainerEdward Kmett <ekmett@gmail.com>
Safe HaskellSafe-Inferred

Linear.Core

Description

Corepresentable functors as vector spaces

Synopsis

Documentation

class Functor f => Core f whereSource

A Functor f is corepresentable if it is isomorphic to (x -> a) for some x. Nearly all such functors can be represented by choosing x to be the set of lenses that are polymorphic in the contents of the Functor, that is to say x = Rep f is a valid choice of x for (nearly) every Representable Functor.

Methods

core :: ((forall g x. Functor g => (x -> g x) -> f x -> g (f x)) -> a) -> f aSource