knead-arithmetic-0.0.0.1: Linear algebra and interpolation using LLVM JIT

Safe HaskellNone

Data.Array.Knead.Arithmetic.Sparse

Synopsis

Documentation

data Dim set dim Source

Constructors

Dim set dim 

Instances

(C set, C dim) => C (Dim set dim) 
(Compose set, Compose dim) => Compose (Dim set dim) 
(C set, C dim) => C (Dim set dim) 
(Compose set, Compose dim) => Compose (Dim set dim) 

sparseSet :: Value val => val (Dim set dim) -> val setSource

sparseDim :: Value val => val (Dim set dim) -> val dimSource

pairFromDim :: Value val => val (Dim set dim) -> val (set, dim)Source

dimFromPair :: Value val => val (set, dim) -> val (Dim set dim)Source

newtype RowMatrix p coll rows set cols a Source

Sparse matrix with a definite number of non-zero entries per row.

Constructors

RowMatrix (Matrix p coll rows (Dim set cols) (Index cols, a)) 

multiplyRowMatrixVector :: (C coll, C rows, C cols, C set, PseudoRing a) => RowMatrix p coll rows set cols a -> Vector p coll cols a -> Vector p coll rows aSource

newtype ColumnMatrix p coll set rows cols a Source

Sparse matrix with a definite number of non-zero entries per column.

Constructors

ColumnMatrix (Matrix p coll (Dim set rows) cols (Index rows, a)) 

multiplyColumnMatrixVector :: (C coll, C set, C rows, C cols, PseudoRing a, C a, Storable a, C rows, Storable rows, C coll, Storable coll, Struct rows ~ rowsStruct, IsSized rowsStruct, Struct coll ~ collStruct, IsSized collStruct) => ColumnMatrix p coll set rows cols a -> Vector p coll cols a -> IOVector p coll rows aSource

multiplyMatrixMatrix :: (C coll, C set0, C set1, C rows, C cols, C glue, PseudoRing a, C a, Storable a, C cols, Storable cols, C rows, Storable rows, C coll, Storable coll, Struct cols ~ colsStruct, IsSized colsStruct, Struct rows ~ rowsStruct, IsSized rowsStruct, Struct coll ~ collStruct, IsSized collStruct) => ColumnMatrix p coll set0 rows glue a -> RowMatrix p coll glue set1 cols a -> IOMatrix p coll rows cols aSource

fillMatrixMatrix :: (C coll, C rows, C cols, C a) => Exp a -> ColumnMatrix p coll set0 rows glue a -> RowMatrix p coll glue set1 cols a -> Array p (coll, (rows, cols)) aSource

transposeColumnMatrix :: (C coll, C set, C rows, C cols) => ColumnMatrix p coll set rows cols a -> RowMatrix p coll cols set rows aSource

sparseRealIndex :: (C coll, C rows, C cols) => Matrix p coll rows cols (i, a) -> Matrix p coll rows cols (Index coll, i)Source

scaleRowRows :: (C coll, C rows, C cols, C set, PseudoRing a) => Vector p coll rows a -> RowMatrix p coll rows set cols a -> RowMatrix p coll rows set cols aSource

scaleRowColumns :: (C coll, C rows, C cols, C set, PseudoRing a) => Vector p coll cols a -> RowMatrix p coll rows set cols a -> RowMatrix p coll rows set cols aSource

mulCell :: PseudoRing a => Exp a -> Exp (i, a) -> Exp (i, a)Source