]> gitweb.michael.orlitzky.com - sage.d.git/commitdiff
eja: add "of" to the algebra characteristic_polynomial() method name.
authorMichael Orlitzky <michael@orlitzky.com>
Sat, 7 Nov 2020 19:45:54 +0000 (14:45 -0500)
committerMichael Orlitzky <michael@orlitzky.com>
Sat, 7 Nov 2020 19:45:54 +0000 (14:45 -0500)
mjo/eja/TODO
mjo/eja/eja_algebra.py
mjo/eja/eja_element.py

index 8d212e1d11fddf7d902b5f114d6143221f842be6..e02257f2b02776f7c19c0ebb54826ffaa82db364 100644 (file)
@@ -10,6 +10,3 @@
 
 5. Factor out the unit-norm basis (and operator symmetry) tests once
    all of the algebras pass.
-
-6. Rename the algebra "characteristic polynomial" method to
-   "characteristic polynomial of."
index 4e66b2db251274d3091875a20056692f33849513..9aa40eeacdacbb54c792158b1462d2f36d3dc4d6 100644 (file)
@@ -236,10 +236,12 @@ class FiniteDimensionalEuclideanJordanAlgebra(CombinatorialFreeModule):
         return self._multiplication_table[i][j]
 
     @cached_method
-    def characteristic_polynomial(self):
+    def characteristic_polynomial_of(self):
         """
-        Return a characteristic polynomial that works for all elements
-        of this algebra.
+        Return the algebra's "characteristic polynomial of" function,
+        which is itself a multivariate polynomial that, when evaluated
+        at the coordinates of some algebra element, returns that
+        element's characteristic polynomial.
 
         The resulting polynomial has `n+1` variables, where `n` is the
         dimension of this algebra. The first `n` variables correspond to
@@ -259,7 +261,7 @@ class FiniteDimensionalEuclideanJordanAlgebra(CombinatorialFreeModule):
         Alizadeh, Example 11.11::
 
             sage: J = JordanSpinEJA(3)
-            sage: p = J.characteristic_polynomial(); p
+            sage: p = J.characteristic_polynomial_of(); p
             X1^2 - X2^2 - X3^2 + (-2*t)*X1 + t^2
             sage: xvec = J.one().to_vector()
             sage: p(*xvec)
@@ -272,7 +274,7 @@ class FiniteDimensionalEuclideanJordanAlgebra(CombinatorialFreeModule):
         any argument::
 
             sage: J = TrivialEJA()
-            sage: J.characteristic_polynomial()
+            sage: J.characteristic_polynomial_of()
             1
 
         """
index a6230a40c2fa0ce88830366b7690eb57ef69963b..0be0032751d75b85edf5386b69945dcb7d72b60d 100644 (file)
@@ -181,7 +181,7 @@ class FiniteDimensionalEuclideanJordanAlgebraElement(IndexedFreeModuleElement):
             True
 
         """
-        p = self.parent().characteristic_polynomial()
+        p = self.parent().characteristic_polynomial_of()
         return p(*self.to_vector())