]> gitweb.michael.orlitzky.com - sage.d.git/blobdiff - mjo/eja/eja_element.py
eja: fix a deorthonormalization bug.
[sage.d.git] / mjo / eja / eja_element.py
index 16e15e5d081447d9b5c046e88a02edfdf678f21c..14bc8cb742cc7cc95f6c55895c1e4946b95cb6ac 100644 (file)
@@ -131,7 +131,8 @@ class FiniteDimensionalEJAElement(IndexedFreeModuleElement):
 
         SETUP::
 
-            sage: from mjo.eja.eja_algebra import HadamardEJA
+            sage: from mjo.eja.eja_algebra import (random_eja,
+            ....:                                  HadamardEJA)
 
         EXAMPLES:
 
@@ -156,10 +157,10 @@ class FiniteDimensionalEJAElement(IndexedFreeModuleElement):
         to zero on that element::
 
             sage: set_random_seed()
-            sage: x = HadamardEJA(3).random_element()
+            sage: x = random_eja().random_element()
             sage: p = x.characteristic_polynomial()
-            sage: x.apply_univariate_polynomial(p)
-            0
+            sage: x.apply_univariate_polynomial(p).is_zero()
+            True
 
         The characteristic polynomials of the zero and unit elements
         should be what we think they are in a subalgebra, too::