From f117a2240c2bb5e87cb82485db701a40d5dbad04 Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Fri, 26 Jul 2019 19:57:30 -0400 Subject: [PATCH] eja: fix the element inverse() implementation and some failing tests. --- mjo/eja/euclidean_jordan_algebra.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/mjo/eja/euclidean_jordan_algebra.py b/mjo/eja/euclidean_jordan_algebra.py index cc356dc..713eca5 100644 --- a/mjo/eja/euclidean_jordan_algebra.py +++ b/mjo/eja/euclidean_jordan_algebra.py @@ -1089,8 +1089,7 @@ class FiniteDimensionalEuclideanJordanAlgebra(FiniteDimensionalAlgebra): if not self.is_invertible(): raise ValueError("element is not invertible") - P = self.parent() - return P(self.quadratic_representation().inverse()*self.vector()) + return (~self.quadratic_representation())(self) def is_invertible(self): @@ -1475,7 +1474,7 @@ class FiniteDimensionalEuclideanJordanAlgebra(FiniteDimensionalAlgebra): sage: D = (x0^2 - x_bar.inner_product(x_bar))*D sage: D = D + 2*x_bar.tensor_product(x_bar) sage: Q = block_matrix(2,2,[A,B,C,D]) - sage: Q == x.quadratic_representation().operator_matrix() + sage: Q == x.quadratic_representation().matrix() True Test all of the properties from Theorem 11.2 in Alizadeh:: -- 2.44.2