From: Michael Orlitzky Date: Sat, 7 Nov 2020 19:45:54 +0000 (-0500) Subject: eja: add "of" to the algebra characteristic_polynomial() method name. X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=d3e40bda3f50a2101103192b91b2ab2a911c0311;p=sage.d.git eja: add "of" to the algebra characteristic_polynomial() method name. --- diff --git a/mjo/eja/TODO b/mjo/eja/TODO index 8d212e1..e02257f 100644 --- a/mjo/eja/TODO +++ b/mjo/eja/TODO @@ -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." diff --git a/mjo/eja/eja_algebra.py b/mjo/eja/eja_algebra.py index 4e66b2d..9aa40ee 100644 --- a/mjo/eja/eja_algebra.py +++ b/mjo/eja/eja_algebra.py @@ -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 """ diff --git a/mjo/eja/eja_element.py b/mjo/eja/eja_element.py index a6230a4..0be0032 100644 --- a/mjo/eja/eja_element.py +++ b/mjo/eja/eja_element.py @@ -181,7 +181,7 @@ class FiniteDimensionalEuclideanJordanAlgebraElement(IndexedFreeModuleElement): True """ - p = self.parent().characteristic_polynomial() + p = self.parent().characteristic_polynomial_of() return p(*self.to_vector())