X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=mjo%2Feja%2Feja_algebra.py;h=08ad700d77938c2bacaab4e337088ee1efc81afa;hb=8c02b1e4b574267d7571759315164ade1b26f6ce;hp=c7c0df8de0e67aef03b391099ea6a72374dce13a;hpb=073f207e9cb5f9c7f1fa347cb24866dbd7c05a0c;p=sage.d.git diff --git a/mjo/eja/eja_algebra.py b/mjo/eja/eja_algebra.py index c7c0df8..08ad700 100644 --- a/mjo/eja/eja_algebra.py +++ b/mjo/eja/eja_algebra.py @@ -2709,12 +2709,23 @@ class CartesianProductEJA(CombinatorialFreeModule_CartesianProduct, The ability to retrieve the original factors is implemented by our CombinatorialFreeModule Cartesian product superclass:: - sage: J1 = HadamardEJA(2, field=QQ) - sage: J2 = JordanSpinEJA(3, field=QQ) - sage: J = cartesian_product([J1,J2]) - sage: J.cartesian_factors() - (Euclidean Jordan algebra of dimension 2 over Rational Field, - Euclidean Jordan algebra of dimension 3 over Rational Field) + sage: J1 = HadamardEJA(2, field=QQ) + sage: J2 = JordanSpinEJA(3, field=QQ) + sage: J = cartesian_product([J1,J2]) + sage: J.cartesian_factors() + (Euclidean Jordan algebra of dimension 2 over Rational Field, + Euclidean Jordan algebra of dimension 3 over Rational Field) + + You can provide more than two factors:: + + sage: J1 = HadamardEJA(2) + sage: J2 = JordanSpinEJA(3) + sage: J3 = RealSymmetricEJA(3) + sage: cartesian_product([J1,J2,J3]) + Euclidean Jordan algebra of dimension 2 over Algebraic Real + Field (+) Euclidean Jordan algebra of dimension 3 over Algebraic + Real Field (+) Euclidean Jordan algebra of dimension 6 over + Algebraic Real Field TESTS: @@ -2726,6 +2737,7 @@ class CartesianProductEJA(CombinatorialFreeModule_CartesianProduct, Traceback (most recent call last): ... ValueError: all factors must share the same base field + """ def __init__(self, modules, **kwargs): CombinatorialFreeModule_CartesianProduct.__init__(self, modules, **kwargs) @@ -2833,10 +2845,6 @@ class CartesianProductEJA(CombinatorialFreeModule_CartesianProduct, sage: J1 = HadamardEJA(2) sage: J2 = RealSymmetricEJA(2) sage: J = cartesian_product([J1,J2]) - sage: J - foo - sage: J.cartesian_embedding - bar sage: J.cartesian_embedding(0) Linear operator between finite-dimensional Euclidean Jordan algebras represented by the matrix: