Copyright | (C) 2012-2015 Edward Kmett |
---|---|
License | BSD-style (see the file LICENSE) |
Maintainer | Edward Kmett <ekmett@gmail.com> |
Stability | experimental |
Portability | non-portable |
Safe Haskell | Trustworthy |
Language | Haskell2010 |
1-D Vectors
Documentation
A 1-dimensional vector
>>>
pure 1 :: V1 Int
V1 1
>>>
V1 2 + V1 3
V1 5
>>>
V1 2 * V1 3
V1 6
>>>
sum (V1 2)
2
V1 a |
Instances
Representable V1 Source # | |
MonadFix V1 Source # | |
MonadZip V1 Source # | |
Foldable V1 Source # | |
Defined in Linear.V1 fold :: Monoid m => V1 m -> m # foldMap :: Monoid m => (a -> m) -> V1 a -> m # foldMap' :: Monoid m => (a -> m) -> V1 a -> m # foldr :: (a -> b -> b) -> b -> V1 a -> b # foldr' :: (a -> b -> b) -> b -> V1 a -> b # foldl :: (b -> a -> b) -> b -> V1 a -> b # foldl' :: (b -> a -> b) -> b -> V1 a -> b # foldr1 :: (a -> a -> a) -> V1 a -> a # foldl1 :: (a -> a -> a) -> V1 a -> a # elem :: Eq a => a -> V1 a -> Bool # maximum :: Ord a => V1 a -> a # | |
Foldable1 V1 Source # | |
Defined in Linear.V1 fold1 :: Semigroup m => V1 m -> m # foldMap1 :: Semigroup m => (a -> m) -> V1 a -> m # foldMap1' :: Semigroup m => (a -> m) -> V1 a -> m # toNonEmpty :: V1 a -> NonEmpty a # maximum :: Ord a => V1 a -> a # minimum :: Ord a => V1 a -> a # foldrMap1 :: (a -> b) -> (a -> b -> b) -> V1 a -> b # foldlMap1' :: (a -> b) -> (b -> a -> b) -> V1 a -> b # foldlMap1 :: (a -> b) -> (b -> a -> b) -> V1 a -> b # foldrMap1' :: (a -> b) -> (a -> b -> b) -> V1 a -> b # | |
Eq1 V1 Source # | |
Ord1 V1 Source # | |
Read1 V1 Source # | |
Show1 V1 Source # | |
Traversable V1 Source # | |
Applicative V1 Source # | |
Functor V1 Source # | |
Monad V1 Source # | |
Serial1 V1 Source # | |
Defined in Linear.V1 serializeWith :: MonadPut m => (a -> m ()) -> V1 a -> m () # deserializeWith :: MonadGet m => m a -> m (V1 a) # | |
Distributive V1 Source # | |
Hashable1 V1 Source # | |
Affine V1 Source # | |
Metric V1 Source # | |
Trace V1 Source # | |
Finite V1 Source # | |
R1 V1 Source # | |
Additive V1 Source # | |
Defined in Linear.V1 | |
Apply V1 Source # | |
Bind V1 Source # | |
Traversable1 V1 Source # | |
Generic1 V1 Source # | |
Num r => Algebra r (E V1) Source # | |
Num r => Coalgebra r (E V1) Source # | |
Lift a => Lift (V1 a :: Type) Source # | |
Unbox a => Vector Vector (V1 a) Source # | |
Defined in Linear.V1 basicUnsafeFreeze :: Mutable Vector s (V1 a) -> ST s (Vector (V1 a)) # basicUnsafeThaw :: Vector (V1 a) -> ST s (Mutable Vector s (V1 a)) # basicLength :: Vector (V1 a) -> Int # basicUnsafeSlice :: Int -> Int -> Vector (V1 a) -> Vector (V1 a) # basicUnsafeIndexM :: Vector (V1 a) -> Int -> Box (V1 a) # basicUnsafeCopy :: Mutable Vector s (V1 a) -> Vector (V1 a) -> ST s () # | |
Unbox a => MVector MVector (V1 a) Source # | |
Defined in Linear.V1 basicLength :: MVector s (V1 a) -> Int # basicUnsafeSlice :: Int -> Int -> MVector s (V1 a) -> MVector s (V1 a) # basicOverlaps :: MVector s (V1 a) -> MVector s (V1 a) -> Bool # basicUnsafeNew :: Int -> ST s (MVector s (V1 a)) # basicInitialize :: MVector s (V1 a) -> ST s () # basicUnsafeReplicate :: Int -> V1 a -> ST s (MVector s (V1 a)) # basicUnsafeRead :: MVector s (V1 a) -> Int -> ST s (V1 a) # basicUnsafeWrite :: MVector s (V1 a) -> Int -> V1 a -> ST s () # basicClear :: MVector s (V1 a) -> ST s () # basicSet :: MVector s (V1 a) -> V1 a -> ST s () # basicUnsafeCopy :: MVector s (V1 a) -> MVector s (V1 a) -> ST s () # basicUnsafeMove :: MVector s (V1 a) -> MVector s (V1 a) -> ST s () # basicUnsafeGrow :: MVector s (V1 a) -> Int -> ST s (MVector s (V1 a)) # | |
Data a => Data (V1 a) Source # | |
Defined in Linear.V1 gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> V1 a -> c (V1 a) # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (V1 a) # dataTypeOf :: V1 a -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c (V1 a)) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (V1 a)) # gmapT :: (forall b. Data b => b -> b) -> V1 a -> V1 a # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> V1 a -> r # gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> V1 a -> r # gmapQ :: (forall d. Data d => d -> u) -> V1 a -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> V1 a -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> V1 a -> m (V1 a) # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> V1 a -> m (V1 a) # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> V1 a -> m (V1 a) # | |
Storable a => Storable (V1 a) Source # | |
Monoid a => Monoid (V1 a) Source # | |
Semigroup a => Semigroup (V1 a) Source # | |
Bounded a => Bounded (V1 a) Source # | |
Floating a => Floating (V1 a) Source # | |
Generic (V1 a) Source # | |
Ix a => Ix (V1 a) Source # | |
Num a => Num (V1 a) Source # | |
Read a => Read (V1 a) Source # | |
Fractional a => Fractional (V1 a) Source # | |
Show a => Show (V1 a) Source # | |
Binary a => Binary (V1 a) Source # | |
Serial a => Serial (V1 a) Source # | |
Serialize a => Serialize (V1 a) Source # | |
NFData a => NFData (V1 a) Source # | |
Eq a => Eq (V1 a) Source # | |
Ord a => Ord (V1 a) Source # | |
Hashable a => Hashable (V1 a) Source # | |
Ixed (V1 a) Source # | |
Epsilon a => Epsilon (V1 a) Source # | |
Random a => Random (V1 a) Source # | |
Unbox a => Unbox (V1 a) Source # | |
Defined in Linear.V1 | |
FoldableWithIndex (E V1) V1 Source # | |
FunctorWithIndex (E V1) V1 Source # | |
TraversableWithIndex (E V1) V1 Source # | |
Each (V1 a) (V1 b) a b Source # | |
Field1 (V1 a) (V1 b) a b Source # | |
type Rep V1 Source # | |
type Diff V1 Source # | |
Defined in Linear.Affine | |
type Size V1 Source # | |
type Rep1 V1 Source # | |
newtype MVector s (V1 a) Source # | |
type Rep (V1 a) Source # | |
type Index (V1 a) Source # | |
type IxValue (V1 a) Source # | |
newtype Vector (V1 a) Source # | |