summaryrefslogtreecommitdiff
path: root/packages/base
diff options
context:
space:
mode:
Diffstat (limited to 'packages/base')
-rw-r--r--packages/base/src/Numeric/LinearAlgebra/Static.hs15
1 files changed, 15 insertions, 0 deletions
diff --git a/packages/base/src/Numeric/LinearAlgebra/Static.hs b/packages/base/src/Numeric/LinearAlgebra/Static.hs
index 4de4d7a..3b7282a 100644
--- a/packages/base/src/Numeric/LinearAlgebra/Static.hs
+++ b/packages/base/src/Numeric/LinearAlgebra/Static.hs
@@ -643,3 +643,18 @@ instance (KnownNat n', KnownNat m') => Testable (L n' m')
643 where 643 where
644 checkT _ = test 644 checkT _ = test
645 645
646--------------------------------------------------------------------------------
647
648instance KnownNat n => Normed (R n)
649 where
650 norm_0 v = norm_0 (extract v)
651 norm_1 v = norm_1 (extract v)
652 norm_2 v = norm_2 (extract v)
653 norm_Inf v = norm_Inf (extract v)
654
655instance (KnownNat m, KnownNat n) => Normed (L m n)
656 where
657 norm_0 m = norm_0 (extract m)
658 norm_1 m = norm_1 (extract m)
659 norm_2 m = norm_2 (extract m)
660 norm_Inf m = norm_Inf (extract m)