From 01ff2cfb39635ad84d8281d58f2d620a18569ff3 Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Sun, 28 Jul 2019 11:21:00 -0400 Subject: [PATCH] eja: use FreeModules() category for operators instead of VectorSpaces(). This allows our characteristic polynomial algorithm to use real operators and not matrices. --- mjo/eja/euclidean_jordan_algebra.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/mjo/eja/euclidean_jordan_algebra.py b/mjo/eja/euclidean_jordan_algebra.py index 9072a12..ba2c63c 100644 --- a/mjo/eja/euclidean_jordan_algebra.py +++ b/mjo/eja/euclidean_jordan_algebra.py @@ -28,8 +28,11 @@ class FiniteDimensionalEuclideanJordanAlgebraOperator(Map): # We need to supply something here to avoid getting the # default Homset of the parent FiniteDimensionalAlgebra class, - # which messes up e.g. equality testing. - parent = Hom(domain_eja, codomain_eja, VectorSpaces(F)) + # which messes up e.g. equality testing. We use FreeModules(F) + # instead of VectorSpaces(F) because our characteristic polynomial + # algorithm will need to F to be a polynomial ring at some point. + # When F is a field, FreeModules(F) returns VectorSpaces(F) anyway. + parent = Hom(domain_eja, codomain_eja, FreeModules(F)) # The Map initializer will set our parent to a homset, which # is explicitly NOT what we want, because these ain't algebra -- 2.44.2