-
-
Notifications
You must be signed in to change notification settings - Fork 674
Open
Description
Demonstration:
sage: P.<x> = BooleanPolynomialRing()
sage: list(P(1))
[1]
sage: list(P(1))[0]
1
sage: list(P(1))[0] == 1
False
sage: type(list(P(1))[0])
<type 'sage.rings.polynomial.pbori.BooleanMonomial'>
Note that this behavior is inconsistent with the behavior for polynomial rings over finite fields:
sage: R.<y> = PolynomialRing(GF(2))
sage: list(R(1))[0] == 1
True
In the context of converting polynomials to lists, this has understandably caused confusion for at least one user on Ask SageMath.
Component: algebra
Keywords: BooleanMonomial, monomial, equality
Issue created by migration from https://trac.sagemath.org/ticket/27019