]> gitweb.michael.orlitzky.com - dunshire.git/blobdiff - dunshire/matrices.py
Use "..." for floating point output in doctests.
[dunshire.git] / dunshire / matrices.py
index 29c5867aabe544f768a1b1ce3862f14c0a316712..6d5bbc8f667dce05feb93ec9fabcf42340f1157e 100644 (file)
@@ -330,12 +330,12 @@ def norm(matrix_or_vector):
     --------
 
         >>> v = matrix([1,1])
-        >>> print('{:.5f}'.format(norm(v)))
-        1.41421
+        >>> norm(v)
+        1.414...
 
         >>> A = matrix([1,1,1,1], (2,2))
         >>> norm(A)
-        2.0
+        2.0...
 
     """
     return sqrt(inner_product(matrix_or_vector, matrix_or_vector))
@@ -422,10 +422,6 @@ def condition_number(mat):
     Examples
     --------
 
-    >>> condition_number(identity(1, typecode='d'))
-    1.0
-    >>> condition_number(identity(2, typecode='d'))
-    1.0
     >>> condition_number(identity(3, typecode='d'))
     1.0