numerical-0.0.0.0: core package for Numerical Haskell project

Safe HaskellSafe
LanguageHaskell2010

Numerical.World

Synopsis

Documentation

data Native Source #

Every numerical algorithm runs somewhere.

This could be on a CPU, a GPU,

Instances
(Buffer rep el, Layout (Format lay locality rank rep) rank) => PureArray (ImmArray Native rep lay locality rank) rank el Source # 
Instance details

Defined in Numerical.Array.Pure

Associated Types

type PureArrayAddress (ImmArray Native rep lay locality rank) :: Type Source #

Methods

basicShape :: ImmArray Native rep lay locality rank el -> Index rank Source #

basicSparseIndexToAddress :: address ~ PureArrayAddress (ImmArray Native rep lay locality rank) => ImmArray Native rep lay locality rank el -> Index rank -> Maybe address Source #

basicAddressToIndex :: address ~ PureArrayAddress (ImmArray Native rep lay locality rank) => ImmArray Native rep lay locality rank el -> address -> Index rank Source #

basicAddressRange :: address ~ PureArrayAddress (ImmArray Native rep lay locality rank) => ImmArray Native rep lay locality rank el -> Maybe (Range address) Source #

basicNextAddress :: address ~ PureArrayAddress (ImmArray Native rep lay locality rank) => ImmArray Native rep lay locality rank el -> address -> Maybe address Source #

basicNextIndex :: address ~ PureArrayAddress (ImmArray Native rep lay locality rank) => ImmArray Native rep lay locality rank el -> Index rank -> Maybe address -> Maybe (Index rank, address) Source #

basicUnsafeAddressRead :: (Monad m, address ~ PureArrayAddress (ImmArray Native rep lay locality rank)) => ImmArray Native rep lay locality rank el -> address -> m el Source #

basicUnsafeSparseRead :: Monad m => ImmArray Native rep lay locality rank el -> Index rank -> m (Maybe el) Source #

(Buffer rep el, Layout (Format lay locality rank rep) rank) => Array (MArray Native rep lay locality rank) rank el Source # 
Instance details

Defined in Numerical.Array.Mutable

Associated Types

type ArrPure (MArray Native rep lay locality rank) :: Type -> Type Source #

type MArrayAddress (MArray Native rep lay locality rank) :: Type Source #

Methods

basicUnsafeAffineAddressShift :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank st el -> Int -> address -> address Source #

basicUnsafeFreeze :: (PrimMonad m, arr ~ ArrPure (MArray Native rep lay locality rank), MArray Native rep lay locality rank ~ ArrMutable arr) => MArray Native rep lay locality rank (PrimState m) el -> m (arr el) Source #

basicUnsafeThaw :: (PrimMonad m, MArray Native rep lay locality rank ~ ArrMutable arr, arr ~ ArrPure (MArray Native rep lay locality rank)) => arr el -> m (MArray Native rep lay locality rank (PrimState m) el) Source #

basicShape :: MArray Native rep lay locality rank st el -> Index rank Source #

basicCardinality :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank st el -> Range address -> Int Source #

basicSparseIndexToAddress :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank s el -> Index rank -> Maybe address Source #

basicAddressToIndex :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank s el -> address -> Index rank Source #

basicAddressRange :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank st el -> Maybe (Range address) Source #

basicSparseNextAddress :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank st el -> address -> Maybe address Source #

basicSparseNextIndex :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank st el -> Index rank -> Maybe address -> Maybe (Index rank, address) Source #

basicLocalAffineAddressRegion :: address ~ MArrayAddress (MArray Native rep lay locality rank) => MArray Native rep lay locality rank st el -> address -> AffineRange address Source #

basicOverlaps :: MArray Native rep lay locality rank st el -> MArray Native rep lay locality rank st el -> Bool Source #

basicClear :: PrimMonad m => MArray Native rep lay locality rank (PrimState m) el -> m () Source #

basicUnsafeAddressRead :: (PrimMonad m, address ~ MArrayAddress (MArray Native rep lay locality rank)) => MArray Native rep lay locality rank (PrimState m) el -> address -> m el Source #

basicUnsafeAddressWrite :: (PrimMonad m, address ~ MArrayAddress (MArray Native rep lay locality rank)) => MArray Native rep lay locality rank (PrimState m) el -> address -> el -> m () Source #

basicUnsafeSparseRead :: PrimMonad m => MArray Native rep lay locality rank (PrimState m) el -> Index rank -> m (Maybe el) Source #

data ImmArray Native rep lay locality rank el Source # 
Instance details

Defined in Numerical.Array.Pure

data ImmArray Native rep lay locality rank el = ImMutableNativeArray {}
data MArray Native rep lay locality rank st el Source # 
Instance details

Defined in Numerical.Array.Mutable

data MArray Native rep lay locality rank st el = MutableNativeArray {}
type PureArrayAddress (ImmArray Native rep lay locality rank) Source # 
Instance details

Defined in Numerical.Array.Pure

type PureArrayAddress (ImmArray Native rep lay locality rank) = LayoutAddress (Format lay locality rank rep)
type ArrPure (MArray Native rep lay locality rank) Source # 
Instance details

Defined in Numerical.Array.Mutable

type ArrPure (MArray Native rep lay locality rank) = ImmArray Native rep lay locality rank
type MArrayAddress (MArray Native rep lay locality rank) Source # 
Instance details

Defined in Numerical.Array.Mutable

type MArrayAddress (MArray Native rep lay locality rank) = LayoutAddress (Format lay locality rank rep)