X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=mjo%2Feja%2Feja_element.py;h=166c9d217cf71d43fe4bfc0911e6fe6c3e1ec9d2;hb=5d646c586de50b571d2983b546a05899bf0c20c2;hp=bd45b179541487bd82e3b06768a902a77cd0899d;hpb=73ba2d67c0850074e655b4da61aa021e6d9b6816;p=sage.d.git diff --git a/mjo/eja/eja_element.py b/mjo/eja/eja_element.py index bd45b17..166c9d2 100644 --- a/mjo/eja/eja_element.py +++ b/mjo/eja/eja_element.py @@ -731,15 +731,29 @@ class FiniteDimensionalEuclideanJordanAlgebraElement(IndexedFreeModuleElement): sage: from mjo.eja.eja_algebra import (JordanSpinEJA, ....: RealSymmetricEJA, + ....: TrivialEJA, ....: random_eja) + EXAMPLES: + + Keeping in mind that the polynomial ``1`` evaluates the identity + element (also the zero element) of the trivial algebra, it is clear + that the polynomial ``1`` is the minimal polynomial of the only + element in a trivial algebra:: + + sage: J = TrivialEJA() + sage: J.one().minimal_polynomial() + 1 + sage: J.zero().minimal_polynomial() + 1 + TESTS: The minimal polynomial of the identity and zero elements are always the same:: sage: set_random_seed() - sage: J = random_eja() + sage: J = random_eja(nontrivial=True) sage: J.one().minimal_polynomial() t - 1 sage: J.zero().minimal_polynomial() @@ -1217,14 +1231,23 @@ class FiniteDimensionalEuclideanJordanAlgebraElement(IndexedFreeModuleElement): """ Return my trace, the sum of my eigenvalues. + In a trivial algebra, however you want to look at it, the trace is + an empty sum for which we declare the result to be zero. + SETUP:: sage: from mjo.eja.eja_algebra import (JordanSpinEJA, ....: RealCartesianProductEJA, + ....: TrivialEJA, ....: random_eja) EXAMPLES:: + sage: J = TrivialEJA() + sage: J.zero().trace() + 0 + + :: sage: J = JordanSpinEJA(3) sage: x = sum(J.gens()) sage: x.trace()