From: Michael Orlitzky Date: Fri, 2 Aug 2019 20:24:19 +0000 (-0400) Subject: eja: use from_vector() instead of call magic in two more places. X-Git-Url: http://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=343dc3c4c02dd1fb344a23cb3323a5c8c82f30a9;p=sage.d.git eja: use from_vector() instead of call magic in two more places. --- diff --git a/mjo/eja/eja_element.py b/mjo/eja/eja_element.py index 107603c..4ed0a59 100644 --- a/mjo/eja/eja_element.py +++ b/mjo/eja/eja_element.py @@ -257,7 +257,7 @@ class FiniteDimensionalEuclideanJordanAlgebraElement(IndexedFreeModuleElement): sage: y = vector(QQ,[4,5,6]) sage: x.inner_product(y) 32 - sage: J(x).inner_product(J(y)) + sage: J.from_vector(x).inner_product(J.from_vector(y)) 32 The inner product on `S^n` is ` = trace(X*Y)`, where @@ -1046,7 +1046,7 @@ class FiniteDimensionalEuclideanJordanAlgebraElement(IndexedFreeModuleElement): raise ValueError("this only works with non-nilpotent elements!") J = self.subalgebra_generated_by() - u = J(self) + u = J.from_vector(self.to_vector()) # The image of the matrix of left-u^m-multiplication # will be minimal for some natural number s...