Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell98 |
Synopsis
- data Permutation sh
- newtype Shape sh = Shape sh
- newtype Element sh = Element CInt
- size :: Permutation sh -> sh
- identity :: C sh => sh -> Permutation sh
- data Inversion
- fromPivots :: C sh => Inversion -> Vector (Shape sh) (Element sh) -> Permutation sh
- toPivots :: C sh => Inversion -> Permutation sh -> Vector (Shape sh) (Element sh)
- toMatrix :: (C sh, Floating a) => Permutation sh -> Square sh a
- data Sign
- determinant :: C sh => Permutation sh -> Sign
- numberFromSign :: Floating a => Sign -> a
- transpose :: C sh => Permutation sh -> Permutation sh
- inversionFromTransposition :: Transposition -> Inversion
- multiply :: (C sh, Eq sh) => Permutation sh -> Permutation sh -> Permutation sh
- apply :: (Measure meas, C vert, C horiz, C height, Eq height, C width, Floating a) => Inversion -> Permutation height -> Full meas vert horiz height width a -> Full meas vert horiz height width a
Documentation
data Permutation sh Source #
Instances
(C sh, Show sh) => Show (Permutation sh) Source # | |
Defined in Numeric.LAPACK.Permutation.Private showsPrec :: Int -> Permutation sh -> ShowS # show :: Permutation sh -> String # showList :: [Permutation sh] -> ShowS # | |
(C sh, Eq sh) => Eq (Permutation sh) Source # | |
Defined in Numeric.LAPACK.Permutation.Private (==) :: Permutation sh -> Permutation sh -> Bool # (/=) :: Permutation sh -> Permutation sh -> Bool # | |
C sh => Format (Permutation sh) Source # | |
Defined in Numeric.LAPACK.Format |
Shape sh |
Instances
Functor Shape Source # | |
Show sh => Show (Shape sh) Source # | |
C sh => C (Shape sh) Source # | |
Defined in Numeric.LAPACK.Permutation.Private | |
C sh => Indexed (Shape sh) Source # | |
Defined in Numeric.LAPACK.Permutation.Private indices :: Shape sh -> [Index (Shape sh)] # offset :: Shape sh -> Index (Shape sh) -> Int # uncheckedOffset :: Shape sh -> Index (Shape sh) -> Int # unifiedOffset :: Checking check => Shape sh -> Index (Shape sh) -> Result check Int # inBounds :: Shape sh -> Index (Shape sh) -> Bool # sizeOffset :: Shape sh -> (Int, Index (Shape sh) -> Int) # uncheckedSizeOffset :: Shape sh -> (Int, Index (Shape sh) -> Int) # unifiedSizeOffset :: Checking check => Shape sh -> (Int, Index (Shape sh) -> Result check Int) # | |
C sh => InvIndexed (Shape sh) Source # | |
Eq sh => Eq (Shape sh) Source # | |
type Index (Shape sh) Source # | |
Defined in Numeric.LAPACK.Permutation.Private |
Instances
Storable (Element sh) Source # | |
Defined in Numeric.LAPACK.Permutation.Private | |
Show (Element sh) Source # | |
Eq (Element sh) Source # | |
size :: Permutation sh -> sh Source #
identity :: C sh => sh -> Permutation sh Source #
Instances
Monoid Inversion | |
Semigroup Inversion | |
Bounded Inversion | |
Enum Inversion | |
Defined in Numeric.Netlib.Modifier succ :: Inversion -> Inversion # pred :: Inversion -> Inversion # fromEnum :: Inversion -> Int # enumFrom :: Inversion -> [Inversion] # enumFromThen :: Inversion -> Inversion -> [Inversion] # enumFromTo :: Inversion -> Inversion -> [Inversion] # enumFromThenTo :: Inversion -> Inversion -> Inversion -> [Inversion] # | |
Show Inversion | |
Eq Inversion | |
fromPivots :: C sh => Inversion -> Vector (Shape sh) (Element sh) -> Permutation sh Source #
QC.forAll QC.arbitraryBoundedEnum $ \inv -> QC.forAll (QC.arbitrary >>= genPivots) $ \xs -> xs == Perm.toPivots inv (Perm.fromPivots inv xs)
determinant :: C sh => Permutation sh -> Sign Source #
QC.forAll genPerm2 $ \(p0,p1) -> determinant (multiply p0 p1) == determinant p0 <> determinant p1
numberFromSign :: Floating a => Sign -> a Source #
numberFromSign s == (-1)^fromEnum s
transpose :: C sh => Permutation sh -> Permutation sh Source #
QC.forAll genPerm2 $ \(p0,p1) -> transpose (multiply p0 p1) == multiply (transpose p1) (transpose p0)
multiply :: (C sh, Eq sh) => Permutation sh -> Permutation sh -> Permutation sh Source #