{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE GADTs #-}
module Numeric.LAPACK.Matrix.Shape (
module Numeric.LAPACK.Matrix.Shape,
Layout.Order(..),
Layout.flipOrder,
Omni.height,
Omni.width,
Omni.extent,
Omni.squareSize,
Omni.order,
Omni.TriDiag,
Omni.DiagSingleton(..),
Omni.Property,
Omni.PowerStrip,
Omni.PowerStripSingleton(..),
Omni.powerStripSingleton,
Omni.Strip,
Omni.StripSingleton(..),
Omni.stripSingleton,
Arbitrary,
Unit,
LayoutPriv.Filled,
LayoutPriv.Empty,
Bands,
Layout.addOffDiagonals,
Layout.Packing,
Layout.Packed,
Layout.Unpacked,
) where
import qualified Numeric.LAPACK.Matrix.Shape.Omni as Omni
import qualified Numeric.LAPACK.Matrix.Layout.Private as LayoutPriv
import qualified Numeric.LAPACK.Matrix.Layout as Layout
import Numeric.LAPACK.Matrix.Shape.Omni (Omni(..), Arbitrary, Unit)
import Numeric.LAPACK.Matrix.Layout.Private
(Bands, UnaryProxy, Empty, Filled, Order, Packed, Unpacked)
import Numeric.LAPACK.Matrix.Extent.Private (Small, Big, Shape, Size)
import qualified Data.Array.Comfort.Shape as Shape
import qualified Type.Data.Num.Unary.Literal as TypeNum
import qualified Type.Data.Num.Unary as Unary
import Type.Base.Proxy (Proxy(Proxy))
type Full = Omni Unpacked Arbitrary Filled Filled
type General = Full Size Big Big
general :: Order -> height -> width -> General height width
general :: Order -> height -> width -> General height width
general Order
order height
height width
width =
Full Size Big Big height width -> General height width
forall property lower upper meas vert horiz height width.
(Property property, Strip lower, Strip upper) =>
Full meas vert horiz height width
-> Omni Unpacked property lower upper meas vert horiz height width
Full (Full Size Big Big height width -> General height width)
-> Full Size Big Big height width -> General height width
forall a b. (a -> b) -> a -> b
$ Order -> height -> width -> Full Size Big Big height width
forall height width.
Order -> height -> width -> General height width
Layout.general Order
order height
height width
width
type Tall = Full Size Big Small
tall ::
(Shape.C height, Shape.C width) =>
Order -> height -> width -> Tall height width
tall :: Order -> height -> width -> Tall height width
tall Order
order height
height width
width =
Full Size Big Small height width -> Tall height width
forall property lower upper meas vert horiz height width.
(Property property, Strip lower, Strip upper) =>
Full meas vert horiz height width
-> Omni Unpacked property lower upper meas vert horiz height width
Full (Full Size Big Small height width -> Tall height width)
-> Full Size Big Small height width -> Tall height width
forall a b. (a -> b) -> a -> b
$ Order -> height -> width -> Full Size Big Small height width
forall height width.
(C height, C width) =>
Order -> height -> width -> Tall height width
Layout.tall Order
order height
height width
width
type Wide = Full Size Small Big
wide ::
(Shape.C height, Shape.C width) =>
Order -> height -> width -> Wide height width
wide :: Order -> height -> width -> Wide height width
wide Order
order height
height width
width =
Full Size Small Big height width -> Wide height width
forall property lower upper meas vert horiz height width.
(Property property, Strip lower, Strip upper) =>
Full meas vert horiz height width
-> Omni Unpacked property lower upper meas vert horiz height width
Full (Full Size Small Big height width -> Wide height width)
-> Full Size Small Big height width -> Wide height width
forall a b. (a -> b) -> a -> b
$ Order -> height -> width -> Full Size Small Big height width
forall height width.
(C height, C width) =>
Order -> height -> width -> Wide height width
Layout.wide Order
order height
height width
width
type LiberalSquare = Full Size Small Small
liberalSquare ::
(Shape.C height, Shape.C width) =>
Order -> height -> width -> LiberalSquare height width
liberalSquare :: Order -> height -> width -> LiberalSquare height width
liberalSquare Order
order height
height width
width =
Full Size Small Small height width -> LiberalSquare height width
forall property lower upper meas vert horiz height width.
(Property property, Strip lower, Strip upper) =>
Full meas vert horiz height width
-> Omni Unpacked property lower upper meas vert horiz height width
Full (Full Size Small Small height width -> LiberalSquare height width)
-> Full Size Small Small height width -> LiberalSquare height width
forall a b. (a -> b) -> a -> b
$ Order -> height -> width -> Full Size Small Small height width
forall height width.
(C height, C width) =>
Order -> height -> width -> LiberalSquare height width
Layout.liberalSquare Order
order height
height width
width
type Square sh = Full Shape Small Small sh sh
square :: (Shape.C sh) => Order -> sh -> Square sh
square :: Order -> sh -> Square sh
square Order
order sh
sh = Full Shape Small Small sh sh -> Square sh
forall property lower upper meas vert horiz height width.
(Property property, Strip lower, Strip upper) =>
Full meas vert horiz height width
-> Omni Unpacked property lower upper meas vert horiz height width
Full (Full Shape Small Small sh sh -> Square sh)
-> Full Shape Small Small sh sh -> Square sh
forall a b. (a -> b) -> a -> b
$ Order -> sh -> Full Shape Small Small sh sh
forall sh. Order -> sh -> Square sh
Layout.square Order
order sh
sh
type Quadratic pack property lower upper size =
QuadraticMeas pack property lower upper Shape size size
type QuadraticMeas pack property lower upper meas height width =
Omni pack property lower upper meas Small Small height width
type Hermitian size =
Quadratic Packed Omni.HermitianUnknownDefiniteness Filled Filled size
hermitian :: Order -> sh -> Hermitian sh
hermitian :: Order -> sh -> Hermitian sh
hermitian Order
order sh
size = Hermitian sh -> Hermitian sh
forall neg zero sub size.
(C neg, C zero, C sub) =>
Hermitian size
-> Omni
Packed
(Hermitian neg zero sub)
Filled
Filled
Shape
Small
Small
size
size
Hermitian (Hermitian sh -> Hermitian sh) -> Hermitian sh -> Hermitian sh
forall a b. (a -> b) -> a -> b
$ Order -> sh -> Hermitian sh
forall size. Order -> size -> Hermitian size
Layout.hermitian Order
order sh
size
type Diagonal size = Quadratic Packed Arbitrary Empty Empty size
diagonal :: Order -> size -> Diagonal size
diagonal :: Order -> size -> Diagonal size
diagonal Order
order size
size =
Banded Zero Zero Shape Small Small size size -> Diagonal size
forall sub super meas vert horiz height width.
(Natural sub, Natural super) =>
Banded sub super meas vert horiz height width
-> Omni
Packed
Arbitrary
(Bands sub)
(Bands super)
meas
vert
horiz
height
width
Banded (Banded Zero Zero Shape Small Small size size -> Diagonal size)
-> Banded Zero Zero Shape Small Small size size -> Diagonal size
forall a b. (a -> b) -> a -> b
$
(UnaryProxy Zero, UnaryProxy Zero)
-> Order -> size -> Banded Zero Zero Shape Small Small size size
forall sub super size.
(UnaryProxy sub, UnaryProxy super)
-> Order -> size -> BandedSquare sub super size
Layout.bandedSquare
(Proxy Zero -> UnaryProxy Zero
forall n. Proxy n -> Proxy (Un n)
Unary.unary Proxy Zero
Unary.zero, Proxy Zero -> UnaryProxy Zero
forall n. Proxy n -> Proxy (Un n)
Unary.unary Proxy Zero
Unary.zero) Order
order size
size
type Identity size = Quadratic Packed Unit Empty Empty size
identity :: Order -> size -> Identity size
identity :: Order -> size -> Identity size
identity Order
order size
size =
BandedSquare Zero Zero size -> Identity size
forall sub super size.
(BandedTriangular sub super, BandedTriangular super sub) =>
BandedSquare sub super size
-> Omni
Packed Unit (Bands sub) (Bands super) Shape Small Small size size
UnitBandedTriangular (BandedSquare Zero Zero size -> Identity size)
-> BandedSquare Zero Zero size -> Identity size
forall a b. (a -> b) -> a -> b
$
(UnaryProxy Zero, UnaryProxy Zero)
-> Order -> size -> BandedSquare Zero Zero size
forall sub super size.
(UnaryProxy sub, UnaryProxy super)
-> Order -> size -> BandedSquare sub super size
Layout.bandedSquare
(Proxy Zero -> UnaryProxy Zero
forall n. Proxy n -> Proxy (Un n)
Unary.unary Proxy Zero
Unary.zero, Proxy Zero -> UnaryProxy Zero
forall n. Proxy n -> Proxy (Un n)
Unary.unary Proxy Zero
Unary.zero) Order
order size
size
type UpLo lo up = (UpLoC lo up, UpLoC up lo)
class (DiagUpLoC lo up) => UpLoC lo up where
switchUpLo :: f Empty Filled -> f Filled Empty -> f lo up
instance UpLoC Empty Filled where switchUpLo :: f Empty Filled -> f Filled Empty -> f Empty Filled
switchUpLo f Empty Filled
f f Filled Empty
_ = f Empty Filled
f
instance UpLoC Filled Empty where switchUpLo :: f Empty Filled -> f Filled Empty -> f Filled Empty
switchUpLo f Empty Filled
_ f Filled Empty
f = f Filled Empty
f
type DiagUpLo lo up = (DiagUpLoC lo up, DiagUpLoC up lo)
class (Omni.PowerStrip lo, Omni.PowerStrip up) => DiagUpLoC lo up where
switchDiagUpLo ::
f Empty Empty -> f Empty Filled -> f Filled Empty -> f lo up
instance DiagUpLoC Empty Empty where switchDiagUpLo :: f Empty Empty -> f Empty Filled -> f Filled Empty -> f Empty Empty
switchDiagUpLo f Empty Empty
f f Empty Filled
_ f Filled Empty
_ = f Empty Empty
f
instance DiagUpLoC Empty Filled where switchDiagUpLo :: f Empty Empty -> f Empty Filled -> f Filled Empty -> f Empty Filled
switchDiagUpLo f Empty Empty
_ f Empty Filled
f f Filled Empty
_ = f Empty Filled
f
instance DiagUpLoC Filled Empty where switchDiagUpLo :: f Empty Empty -> f Empty Filled -> f Filled Empty -> f Filled Empty
switchDiagUpLo f Empty Empty
_ f Empty Filled
_ f Filled Empty
f = f Filled Empty
f
data UpLoSingleton lo up where
Lower :: UpLoSingleton Filled Empty
Upper :: UpLoSingleton Empty Filled
autoUplo :: (UpLo lo up) => UpLoSingleton lo up
autoUplo :: UpLoSingleton lo up
autoUplo = UpLoSingleton Empty Filled
-> UpLoSingleton Filled Empty -> UpLoSingleton lo up
forall lo up (f :: * -> * -> *).
UpLoC lo up =>
f Empty Filled -> f Filled Empty -> f lo up
switchUpLo UpLoSingleton Empty Filled
Upper UpLoSingleton Filled Empty
Lower
type Triangular lo diag up size = Quadratic Packed diag lo up size
triangular ::
(DiagUpLo lo up, Omni.TriDiag diag) =>
Order -> size -> Triangular lo diag up size
triangular :: Order -> size -> Triangular lo diag up size
triangular Order
order size
size =
GenTriangularDiag lo up size Any diag -> Triangular lo diag up size
forall lo up size a diag.
GenTriangularDiag lo up size a diag -> Triangular lo diag up size
runGenTriangularDiag (GenTriangularDiag lo up size Any diag
-> Triangular lo diag up size)
-> GenTriangularDiag lo up size Any diag
-> Triangular lo diag up size
forall a b. (a -> b) -> a -> b
$
GenTriangularDiag lo up size Any Unit
-> GenTriangularDiag lo up size Any Arbitrary
-> GenTriangularDiag lo up size Any diag
forall diag (f :: * -> *).
TriDiag diag =>
f Unit -> f Arbitrary -> f diag
Omni.switchTriDiag
(Triangular lo Unit up size -> GenTriangularDiag lo up size Any Unit
forall lo up size a diag.
Triangular lo diag up size -> GenTriangularDiag lo up size a diag
GenTriangularDiag (Triangular lo Unit up size
-> GenTriangularDiag lo up size Any Unit)
-> Triangular lo Unit up size
-> GenTriangularDiag lo up size Any Unit
forall a b. (a -> b) -> a -> b
$ Order -> size -> Triangular lo Unit up size
forall lo up size.
DiagUpLo lo up =>
Order -> size -> Triangular lo Unit up size
unitTriangular Order
order size
size)
(Triangular lo Arbitrary up size
-> GenTriangularDiag lo up size Any Arbitrary
forall lo up size a diag.
Triangular lo diag up size -> GenTriangularDiag lo up size a diag
GenTriangularDiag (Triangular lo Arbitrary up size
-> GenTriangularDiag lo up size Any Arbitrary)
-> Triangular lo Arbitrary up size
-> GenTriangularDiag lo up size Any Arbitrary
forall a b. (a -> b) -> a -> b
$ Order -> size -> Triangular lo Arbitrary up size
forall lo up size.
DiagUpLo lo up =>
Order -> size -> Triangular lo Arbitrary up size
arbitraryTriangular Order
order size
size)
unitTriangular ::
(DiagUpLo lo up) =>
Order -> size -> Triangular lo Unit up size
unitTriangular :: Order -> size -> Triangular lo Unit up size
unitTriangular Order
order size
size =
GenTriangularLoUp Unit size Any lo up -> Triangular lo Unit up size
forall diag size a lo up.
GenTriangularLoUp diag size a lo up -> Triangular lo diag up size
runGenTriangularLoUp (GenTriangularLoUp Unit size Any lo up
-> Triangular lo Unit up size)
-> GenTriangularLoUp Unit size Any lo up
-> Triangular lo Unit up size
forall a b. (a -> b) -> a -> b
$
GenTriangularLoUp Unit size Any Empty Empty
-> GenTriangularLoUp Unit size Any Empty Filled
-> GenTriangularLoUp Unit size Any Filled Empty
-> GenTriangularLoUp Unit size Any lo up
forall lo up (f :: * -> * -> *).
DiagUpLoC lo up =>
f Empty Empty -> f Empty Filled -> f Filled Empty -> f lo up
switchDiagUpLo
(Triangular Empty Unit Empty size
-> GenTriangularLoUp Unit size Any Empty Empty
forall diag size a lo up.
Triangular lo diag up size -> GenTriangularLoUp diag size a lo up
GenTriangularLoUp (Triangular Empty Unit Empty size
-> GenTriangularLoUp Unit size Any Empty Empty)
-> Triangular Empty Unit Empty size
-> GenTriangularLoUp Unit size Any Empty Empty
forall a b. (a -> b) -> a -> b
$ Order -> size -> Triangular Empty Unit Empty size
forall size. Order -> size -> Identity size
identity Order
order size
size)
(Triangular Empty Unit Filled size
-> GenTriangularLoUp Unit size Any Empty Filled
forall diag size a lo up.
Triangular lo diag up size -> GenTriangularLoUp diag size a lo up
GenTriangularLoUp (Triangular Empty Unit Filled size
-> GenTriangularLoUp Unit size Any Empty Filled)
-> Triangular Empty Unit Filled size
-> GenTriangularLoUp Unit size Any Empty Filled
forall a b. (a -> b) -> a -> b
$ UpperTriangular size -> Triangular Empty Unit Filled size
forall diag size.
TriDiag diag =>
UpperTriangular size
-> Omni Packed diag Empty Filled Shape Small Small size size
UpperTriangular (UpperTriangular size -> Triangular Empty Unit Filled size)
-> UpperTriangular size -> Triangular Empty Unit Filled size
forall a b. (a -> b) -> a -> b
$
Order -> size -> UpperTriangular size
forall size. Order -> size -> UpperTriangular size
Layout.upperTriangular Order
order size
size)
(Triangular Filled Unit Empty size
-> GenTriangularLoUp Unit size Any Filled Empty
forall diag size a lo up.
Triangular lo diag up size -> GenTriangularLoUp diag size a lo up
GenTriangularLoUp (Triangular Filled Unit Empty size
-> GenTriangularLoUp Unit size Any Filled Empty)
-> Triangular Filled Unit Empty size
-> GenTriangularLoUp Unit size Any Filled Empty
forall a b. (a -> b) -> a -> b
$ LowerTriangular size -> Triangular Filled Unit Empty size
forall diag size.
TriDiag diag =>
LowerTriangular size
-> Omni Packed diag Filled Empty Shape Small Small size size
LowerTriangular (LowerTriangular size -> Triangular Filled Unit Empty size)
-> LowerTriangular size -> Triangular Filled Unit Empty size
forall a b. (a -> b) -> a -> b
$
Order -> size -> LowerTriangular size
forall size. Order -> size -> LowerTriangular size
Layout.lowerTriangular Order
order size
size)
arbitraryTriangular ::
(DiagUpLo lo up) =>
Order -> size -> Triangular lo Arbitrary up size
arbitraryTriangular :: Order -> size -> Triangular lo Arbitrary up size
arbitraryTriangular Order
order size
size =
GenTriangularLoUp Arbitrary size Any lo up
-> Triangular lo Arbitrary up size
forall diag size a lo up.
GenTriangularLoUp diag size a lo up -> Triangular lo diag up size
runGenTriangularLoUp (GenTriangularLoUp Arbitrary size Any lo up
-> Triangular lo Arbitrary up size)
-> GenTriangularLoUp Arbitrary size Any lo up
-> Triangular lo Arbitrary up size
forall a b. (a -> b) -> a -> b
$
GenTriangularLoUp Arbitrary size Any Empty Empty
-> GenTriangularLoUp Arbitrary size Any Empty Filled
-> GenTriangularLoUp Arbitrary size Any Filled Empty
-> GenTriangularLoUp Arbitrary size Any lo up
forall lo up (f :: * -> * -> *).
DiagUpLoC lo up =>
f Empty Empty -> f Empty Filled -> f Filled Empty -> f lo up
switchDiagUpLo
(Triangular Empty Arbitrary Empty size
-> GenTriangularLoUp Arbitrary size Any Empty Empty
forall diag size a lo up.
Triangular lo diag up size -> GenTriangularLoUp diag size a lo up
GenTriangularLoUp (Triangular Empty Arbitrary Empty size
-> GenTriangularLoUp Arbitrary size Any Empty Empty)
-> Triangular Empty Arbitrary Empty size
-> GenTriangularLoUp Arbitrary size Any Empty Empty
forall a b. (a -> b) -> a -> b
$ Order -> size -> Triangular Empty Arbitrary Empty size
forall size. Order -> size -> Diagonal size
diagonal Order
order size
size)
(Triangular Empty Arbitrary Filled size
-> GenTriangularLoUp Arbitrary size Any Empty Filled
forall diag size a lo up.
Triangular lo diag up size -> GenTriangularLoUp diag size a lo up
GenTriangularLoUp (Triangular Empty Arbitrary Filled size
-> GenTriangularLoUp Arbitrary size Any Empty Filled)
-> Triangular Empty Arbitrary Filled size
-> GenTriangularLoUp Arbitrary size Any Empty Filled
forall a b. (a -> b) -> a -> b
$ Order -> size -> Triangular Empty Arbitrary Filled size
forall size. Order -> size -> UpperTriangular size
upperTriangular Order
order size
size)
(Triangular Filled Arbitrary Empty size
-> GenTriangularLoUp Arbitrary size Any Filled Empty
forall diag size a lo up.
Triangular lo diag up size -> GenTriangularLoUp diag size a lo up
GenTriangularLoUp (Triangular Filled Arbitrary Empty size
-> GenTriangularLoUp Arbitrary size Any Filled Empty)
-> Triangular Filled Arbitrary Empty size
-> GenTriangularLoUp Arbitrary size Any Filled Empty
forall a b. (a -> b) -> a -> b
$ Order -> size -> Triangular Filled Arbitrary Empty size
forall size. Order -> size -> LowerTriangular size
lowerTriangular Order
order size
size)
newtype GenTriangularDiag lo up size a diag =
GenTriangularDiag {
GenTriangularDiag lo up size a diag -> Triangular lo diag up size
runGenTriangularDiag :: Triangular lo diag up size
}
newtype GenTriangularLoUp diag size a lo up =
GenTriangularLoUp {
GenTriangularLoUp diag size a lo up -> Triangular lo diag up size
runGenTriangularLoUp :: Triangular lo diag up size
}
type LowerTriangular size = Quadratic Packed Arbitrary Filled Empty size
lowerTriangular :: Order -> size -> LowerTriangular size
lowerTriangular :: Order -> size -> LowerTriangular size
lowerTriangular Order
order size
size =
LowerTriangular size -> LowerTriangular size
forall diag size.
TriDiag diag =>
LowerTriangular size
-> Omni Packed diag Filled Empty Shape Small Small size size
LowerTriangular (LowerTriangular size -> LowerTriangular size)
-> LowerTriangular size -> LowerTriangular size
forall a b. (a -> b) -> a -> b
$ Order -> size -> LowerTriangular size
forall size. Order -> size -> LowerTriangular size
Layout.lowerTriangular Order
order size
size
type UpperTriangular size = Quadratic Packed Arbitrary Empty Filled size
upperTriangular :: Order -> size -> UpperTriangular size
upperTriangular :: Order -> size -> UpperTriangular size
upperTriangular Order
order size
size =
UpperTriangular size -> UpperTriangular size
forall diag size.
TriDiag diag =>
UpperTriangular size
-> Omni Packed diag Empty Filled Shape Small Small size size
UpperTriangular (UpperTriangular size -> UpperTriangular size)
-> UpperTriangular size -> UpperTriangular size
forall a b. (a -> b) -> a -> b
$ Order -> size -> UpperTriangular size
forall size. Order -> size -> UpperTriangular size
Layout.upperTriangular Order
order size
size
type Symmetric size = Quadratic Packed Omni.Symmetric Filled Filled size
symmetric :: Order -> size -> Symmetric size
symmetric :: Order -> size -> Symmetric size
symmetric Order
order size
size = Symmetric size -> Symmetric size
forall size.
Symmetric size
-> Omni Packed Symmetric Filled Filled Shape Small Small size size
Symmetric (Symmetric size -> Symmetric size)
-> Symmetric size -> Symmetric size
forall a b. (a -> b) -> a -> b
$ Order -> size -> Symmetric size
forall size. Order -> size -> Symmetric size
Layout.symmetric Order
order size
size
type Banded sub super meas vert horiz =
Omni Packed Arbitrary (Bands sub) (Bands super) meas vert horiz
bandedOffDiagonals ::
Omni Packed property (Bands sub) (Bands super)
meas vert horiz height width ->
(UnaryProxy sub, UnaryProxy super)
bandedOffDiagonals :: Omni
Packed
property
(Bands sub)
(Bands super)
meas
vert
horiz
height
width
-> (UnaryProxy sub, UnaryProxy super)
bandedOffDiagonals Omni
Packed
property
(Bands sub)
(Bands super)
meas
vert
horiz
height
width
_ = (UnaryProxy sub
forall a. Proxy a
Proxy, UnaryProxy super
forall a. Proxy a
Proxy)
type BandedGeneral sub super =
Omni Packed Arbitrary (Bands sub) (Bands super) Size Big Big
bandedGeneral ::
(Unary.Natural sub, Unary.Natural super,
Shape.C height, Shape.C width) =>
(UnaryProxy sub, UnaryProxy super) -> Order -> height -> width ->
BandedGeneral sub super height width
bandedGeneral :: (UnaryProxy sub, UnaryProxy super)
-> Order -> height -> width -> BandedGeneral sub super height width
bandedGeneral (UnaryProxy sub, UnaryProxy super)
offDiag Order
order height
height width
width =
Banded sub super Size Big Big height width
-> BandedGeneral sub super height width
forall sub super meas vert horiz height width.
(Natural sub, Natural super) =>
Banded sub super meas vert horiz height width
-> Omni
Packed
Arbitrary
(Bands sub)
(Bands super)
meas
vert
horiz
height
width
Banded (Banded sub super Size Big Big height width
-> BandedGeneral sub super height width)
-> Banded sub super Size Big Big height width
-> BandedGeneral sub super height width
forall a b. (a -> b) -> a -> b
$ (UnaryProxy sub, UnaryProxy super)
-> Order
-> height
-> width
-> Banded sub super Size Big Big height width
forall sub super height width.
(UnaryProxy sub, UnaryProxy super)
-> Order -> height -> width -> BandedGeneral sub super height width
Layout.bandedGeneral (UnaryProxy sub, UnaryProxy super)
offDiag Order
order height
height width
width
type BandedTriangular sub super size =
Quadratic Packed Arbitrary (Bands sub) (Bands super) size
type BandedLower sub size = BandedTriangular sub TypeNum.U0 size
type BandedUpper super size = BandedTriangular TypeNum.U0 super size
type BandedUnitTriangular sub super size =
Quadratic Packed Unit (Bands sub) (Bands super) size
type BandedUnitLower sub size = BandedUnitTriangular sub TypeNum.U0 size
type BandedUnitUpper super size = BandedUnitTriangular TypeNum.U0 super size
type BandedHermitian offDiag size =
Quadratic Packed Omni.HermitianUnknownDefiniteness
(Bands offDiag) (Bands offDiag) size
bandedHermitian ::
(Unary.Natural offDiag) =>
UnaryProxy offDiag -> Order -> size -> BandedHermitian offDiag size
bandedHermitian :: UnaryProxy offDiag -> Order -> size -> BandedHermitian offDiag size
bandedHermitian UnaryProxy offDiag
numOff Order
order size
size =
BandedHermitian offDiag size -> BandedHermitian offDiag size
forall neg zero pos offDiag size.
(C neg, C zero, C pos, Natural offDiag) =>
BandedHermitian offDiag size
-> Omni
Packed
(Hermitian neg zero pos)
(Bands offDiag)
(Bands offDiag)
Shape
Small
Small
size
size
BandedHermitian (BandedHermitian offDiag size -> BandedHermitian offDiag size)
-> BandedHermitian offDiag size -> BandedHermitian offDiag size
forall a b. (a -> b) -> a -> b
$ UnaryProxy offDiag -> Order -> size -> BandedHermitian offDiag size
forall off size.
UnaryProxy off -> Order -> size -> BandedHermitian off size
Layout.bandedHermitian UnaryProxy offDiag
numOff Order
order size
size
type RealDiagonal size = BandedHermitian TypeNum.U0 size
type PositiveDiagonal size =
Quadratic Packed Omni.HermitianPositiveDefinite Empty Empty size
type
UpperQuasitriangular size =
Quadratic Unpacked Arbitrary (Bands TypeNum.U1) Filled size