Free algebra quotient elements

AUTHORS:
  • William Stein (2011-11-19): improved doctest coverage to 100%
  • David Kohel (2005-09): initial version
class sage.algebras.free_algebra_quotient_element.FreeAlgebraQuotientElement(A, x)

Bases: sage.structure.element.AlgebraElement

Create the element x of the FreeAlgebraQuotient A.

EXAMPLES:

sage: H, (i,j,k) = sage.algebras.free_algebra_quotient.hamilton_quatalg(ZZ)
sage: sage.algebras.free_algebra_quotient.FreeAlgebraQuotientElement(H, i)
i
sage: a = sage.algebras.free_algebra_quotient.FreeAlgebraQuotientElement(H, 1); a
1
sage: a in H
True
vector()

Return underlying vector representation of this element.

EXAMPLES:

sage: H, (i,j,k) = sage.algebras.free_algebra_quotient.hamilton_quatalg(QQ)
sage: ((2/3)*i - j).vector()
(0, 2/3, -1, 0)
sage.algebras.free_algebra_quotient_element.is_FreeAlgebraQuotientElement(x)

EXAMPLES:

sage: H, (i,j,k) = sage.algebras.free_algebra_quotient.hamilton_quatalg(QQ)
sage: sage.algebras.free_algebra_quotient_element.is_FreeAlgebraQuotientElement(i)
True

Of course this is testing the data type:

sage: sage.algebras.free_algebra_quotient_element.is_FreeAlgebraQuotientElement(1)
False
sage: sage.algebras.free_algebra_quotient_element.is_FreeAlgebraQuotientElement(H(1))
True