Data.LinearMap
 Stability experimental Maintainer conal@conal.net
Description
Linear maps
Synopsis
class VectorSpace a s => LMapDom a s | a -> s where
 data :-* a :: * -> * lapply :: VectorSpace b s => (a :-* b) -> a -> b linear :: (a -> b) -> a :-* b
inL :: (LMapDom c s, VectorSpace b s', LMapDom a s') => ((a -> b) -> c -> d) -> (a :-* b) -> c :-* d
inL2 :: (LMapDom c s, VectorSpace b s', LMapDom a s', LMapDom e s, VectorSpace d s) => ((a -> b) -> (c -> d) -> e -> f) -> (a :-* b) -> (c :-* d) -> e :-* f
inL3 :: (LMapDom a s, VectorSpace b s, VectorSpace f s, LMapDom p s, LMapDom c s', VectorSpace d s', LMapDom e s) => ((a -> b) -> (c -> d) -> (e -> f) -> p -> q) -> (a :-* b) -> (c :-* d) -> (e :-* f) -> p :-* q
linearK :: LMapDom a s => (a -> b) -> (b -> c) -> a :-* c
(.*) :: (VectorSpace c s, LMapDom b s, LMapDom a s) => (b :-* c) -> (a :-* b) -> a :-* c
pureL :: LMapDom a s => b -> a :-* b
(<\$>*) :: (LMapDom a s, VectorSpace b s) => (b -> c) -> (a :-* b) -> a :-* c
liftL2 :: (LMapDom a s, VectorSpace b s, VectorSpace c s, VectorSpace d s) => (b -> c -> d) -> (a :-* b) -> (a :-* c) -> a :-* d
liftL3 :: (LMapDom a s, VectorSpace b s, VectorSpace c s, VectorSpace d s, VectorSpace e s) => (b -> c -> d -> e) -> (a :-* b) -> (a :-* c) -> (a :-* d) -> a :-* e
idL :: LMapDom a s => a :-* a
Documentation
 class VectorSpace a s => LMapDom a s | a -> s where Source
Domain of a linear map.
Associated Types
 data :-* a :: * -> * Source
 Linear map type
Methods
 lapply :: VectorSpace b s => (a :-* b) -> a -> b Source
Linear map as function
 linear :: (a -> b) -> a :-* b Source
Function (assumed linear) as linear map.
Instances
 LMapDom Double Double LMapDom Float Float LMapDom u s => LMapDom (Vector2 u) s (LMapDom a s, LMapDom b s) => LMapDom ((,) a b) s (LMapDom a s, LMapDom b s, LMapDom c s) => LMapDom ((,,) a b c) s
 inL :: (LMapDom c s, VectorSpace b s', LMapDom a s') => ((a -> b) -> c -> d) -> (a :-* b) -> c :-* d Source
Transform a linear map by transforming a linear function.
 inL2 :: (LMapDom c s, VectorSpace b s', LMapDom a s', LMapDom e s, VectorSpace d s) => ((a -> b) -> (c -> d) -> e -> f) -> (a :-* b) -> (c :-* d) -> e :-* f Source
Transform a linear maps by transforming linear functions.
 inL3 :: (LMapDom a s, VectorSpace b s, VectorSpace f s, LMapDom p s, LMapDom c s', VectorSpace d s', LMapDom e s) => ((a -> b) -> (c -> d) -> (e -> f) -> p -> q) -> (a :-* b) -> (c :-* d) -> (e :-* f) -> p :-* q Source
Transform a linear maps by transforming linear functions.
 linearK :: LMapDom a s => (a -> b) -> (b -> c) -> a :-* c Source
Convenience function for linear definitions. Both functions are assumed linear.
 (.*) :: (VectorSpace c s, LMapDom b s, LMapDom a s) => (b :-* c) -> (a :-* b) -> a :-* c Source
Compose linear maps
 pureL :: LMapDom a s => b -> a :-* b Source
Constant value as a linear map
 (<\$>*) :: (LMapDom a s, VectorSpace b s) => (b -> c) -> (a :-* b) -> a :-* c Source
Map a linear function over a linear map.
 liftL2 :: (LMapDom a s, VectorSpace b s, VectorSpace c s, VectorSpace d s) => (b -> c -> d) -> (a :-* b) -> (a :-* c) -> a :-* d Source
Apply a linear binary function over linear maps.
 liftL3 :: (LMapDom a s, VectorSpace b s, VectorSpace c s, VectorSpace d s, VectorSpace e s) => (b -> c -> d -> e) -> (a :-* b) -> (a :-* c) -> (a :-* d) -> a :-* e Source
Apply a linear ternary function over linear maps.
 idL :: LMapDom a s => a :-* a Source
Identity linear map