summaryrefslogtreecommitdiff
path: root/packages/base/src/Numeric/LinearAlgebra/Util.hs
diff options
context:
space:
mode:
authorAlberto Ruiz <aruiz@um.es>2014-05-24 20:33:05 +0200
committerAlberto Ruiz <aruiz@um.es>2014-05-24 20:33:05 +0200
commit365e2435e71de10ebe849acac5a107b6f43817c4 (patch)
tree08e0e8573c86f28bda920709ae84a1f2fd4911ee /packages/base/src/Numeric/LinearAlgebra/Util.hs
parent5b6de561f131d75049fdb999e98a07939ec2e8e7 (diff)
initial support for static dimension checking
Diffstat (limited to 'packages/base/src/Numeric/LinearAlgebra/Util.hs')
-rw-r--r--packages/base/src/Numeric/LinearAlgebra/Util.hs14
1 files changed, 14 insertions, 0 deletions
diff --git a/packages/base/src/Numeric/LinearAlgebra/Util.hs b/packages/base/src/Numeric/LinearAlgebra/Util.hs
index a7d6946..a319785 100644
--- a/packages/base/src/Numeric/LinearAlgebra/Util.hs
+++ b/packages/base/src/Numeric/LinearAlgebra/Util.hs
@@ -28,6 +28,7 @@ module Numeric.LinearAlgebra.Util(
28 (&), (¦), (——), (#), 28 (&), (¦), (——), (#),
29 (?), (¿), 29 (?), (¿),
30 Indexable(..), size, 30 Indexable(..), size,
31 Numeric,
31 rand, randn, 32 rand, randn,
32 cross, 33 cross,
33 norm, 34 norm,
@@ -101,6 +102,19 @@ mat
101 -> Matrix ℝ 102 -> Matrix ℝ
102mat c = reshape c . fromList 103mat c = reshape c . fromList
103 104
105
106
107class ( Container Vector t
108 , Container Matrix t
109 , Konst t Int Vector
110 , Konst t (Int,Int) Matrix
111 ) => Numeric t
112
113instance Numeric Double
114instance Numeric (Complex Double)
115
116
117
104{- | print a real matrix with given number of digits after the decimal point 118{- | print a real matrix with given number of digits after the decimal point
105 119
106>>> disp 5 $ ident 2 / 3 120>>> disp 5 $ ident 2 / 3