Changes between Version 8 and Version 9 of Ticket #23621
- Timestamp:
- 12/07/21 16:03:20 (8 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #23621
- Property Cc slelievre added
- Property Keywords ideal added
-
Property
Milestone
changed from
sage-8.1
tosage-9.5
-
Property
Summary
changed from
Quotients of univariate polynomial rings over ZZ return mathematical incorrect answers
toFix quotients of univariate polynomial rings over ZZ
-
Ticket #23621 – Description
v8 v9 1 The quotient of `ZZ[x]` by the ideal `(x, 2)` 2 works fine using a multivariate polynomial ring: 3 {{{ 4 sage: R.<x> = PolynomialRing(ZZ, 1) 5 sage: I = R.ideal([x, 2]) 6 sage: I 7 Ideal (x, 2) of Multivariate Polynomial Ring in x over Integer Ring 8 sage: S = R.quo(I) 9 sage: [[S(a) == S(b) for b in (0, 2, x)] for a in (0, 2, x)] 10 [[True, True, True], [True, True, True], [True, True, True]] 11 }}} 12 but it fails using a univariate polynomial ring, 13 returning mathematically wrong answers: 1 14 {{{ 2 15 sage: R.<x> = ZZ[] 3 sage: I = R.ideal([x,2]); I 16 sage: I = R.ideal([x, 2]) 17 sage: I 18 Ideal (x, 2) of Univariate Polynomial Ring in x over Integer Ring 4 19 sage: S = R.quo(I) 5 sage: S(x)==S(0) 6 False 7 sage: S(2)==S(2) 8 True 9 sage: S(2)==S(0) 10 False 20 sage: 21 sage: [[S(a) == S(b) for b in (0, 2, x)] for a in (0, 2, x)] 22 [[True, False, False], [False, True, False], [False, False, True]] 11 23 }}} 12 13 Note that if you create the quotient as a multivariate polynomial ring, then it works fine! 14 24 Expected: 15 25 {{{ 16 sage: R.<x> = PolynomialRing(ZZ,1) 17 sage: I = R.ideal([x,2]); I 18 Ideal (x, 2) of Multivariate Polynomial Ring in x over Integer Ring 19 sage: S = R.quo(I) 20 sage: S(x)==0 21 True 22 sage: S(2)==0 23 True 26 [[True, True, True], [True, True, True], [True, True, True]] 24 27 }}}