Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 11 additions & 16 deletions src/sage/rings/polynomial/plural.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,16 @@ TESTS::
sage: TestSuite(P).run()
sage: loads(dumps(P)) is P
True

sage: A.<x,y,z> = FreeAlgebra(QQ, 3)
sage: P = A.g_algebra(relations={y*x:-x*y}, order = 'lex')
sage: P.is_commutative()
False

sage: R.<x,y,z> = FreeAlgebra(QQ, 3)
sage: P = R.g_algebra(relations={}, order='lex')
sage: P.is_commutative()
True
"""
from cysignals.memory cimport sig_malloc, sig_free

Expand Down Expand Up @@ -676,22 +686,7 @@ cdef class NCPolynomialRing_plural(Ring):
"""
return self._term_order

def is_commutative(self):
"""
Return ``False``.

.. TODO:: Provide a mathematically correct answer.

EXAMPLES::

sage: A.<x,y,z> = FreeAlgebra(QQ, 3)
sage: P = A.g_algebra(relations={y*x:-x*y}, order = 'lex')
sage: P.is_commutative()
False
"""
return False

def is_field(self, *args, **kwargs):
def is_field(self, *args, **kwargs) -> bool:
"""
Return ``False``.

Expand Down
Loading