Ticket #5978 (closed defect: fixed)
Can't construct the quotient of an univariate polynomial ring by its zero ideal
| Reported by: | jmbr | Owned by: | tbd |
|---|---|---|---|
| Priority: | minor | Milestone: | sage-5.8 |
| Component: | algebra | Keywords: | |
| Cc: | Work issues: | ||
| Report Upstream: | N/A | Reviewers: | Luis Felipe Tabera Alonso |
| Authors: | Travis Scrimshaw | Merged in: | sage-5.8.beta1 |
| Dependencies: | Stopgaps: |
Description (last modified by tscrim) (diff)
----------------------------------------------------------------------
| Sage Version 3.4.2.rc0, Release Date: 2009-04-30 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------
sage: R = QQ['x']
sage: R.quotient(R.zero_ideal())
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
/home/mabshoff/.sage/temp/sage.math.washington.edu/1567/_home_mabshoff__sage_init_sage_0.py in <module>()
/scratch/mabshoff/sage-3.4.2.final/local/lib/python2.5/site-packages/sage/rings/ring.so in sage.rings.ring.CommutativeRing.quotient (sage/rings/ring.c:6627)()
/scratch/mabshoff/sage-3.4.2.final/local/lib/python2.5/site-packages/sage/rings/quotient_ring.pyc in QuotientRing(R, I, names)
137 try:
138 if I.is_principal():
--> 139 return R.quotient_by_principal_ideal(I.gen(), names)
140 except (AttributeError, NotImplementedError):
141 pass
/scratch/mabshoff/sage-3.4.2.final/local/lib/python2.5/site-packages/sage/rings/polynomial/polynomial_ring.pyc in quotient_by_principal_ideal(self, f, names)
1092 """
1093 import sage.rings.polynomial.polynomial_quotient_ring
-> 1094 return sage.rings.polynomial.polynomial_quotient_ring.PolynomialQuotientRing(self, f, names)
1095
1096
/scratch/mabshoff/sage-3.4.2.final/local/lib/python2.5/site-packages/sage/rings/polynomial/polynomial_quotient_ring.pyc in PolynomialQuotientRing(ring, polynomial, names)
149 c = polynomial.leading_coefficient()
150 if not c.is_unit():
--> 151 raise TypeError, "polynomial must have unit leading coefficient"
152 R = ring.base_ring()
153 if isinstance(R, sage.rings.integral_domain.IntegralDomain):
TypeError: polynomial must have unit leading coefficient
Apply: trac_5978-quotient_zero_ideal-ts.patch
Attachments
Change History
comment:2 Changed 4 years ago by mabshoff
- Description modified (diff)
- Milestone set to sage-4.0
Do not attach the error message, but post it verbatim into the ticket.
Also always assign a milestone.
comment:3 Changed 4 years ago by AlexGhitza
- Summary changed from Can't construct the quotient of an univariate polynomial ring by it's zero ideal to Can't construct the quotient of an univariate polynomial ring by its zero ideal
comment:4 Changed 6 months ago by tscrim
- Status changed from new to needs_review
- Report Upstream set to N/A
- Authors set to Travis Scrimshaw
Fixed by making the quotient by a zero ideal return the original ring.
sage: ZZ.quotient(ZZ.zero_ideal()) is ZZ True sage: R = QQ['x'] sage: R.quotient(R.zero_ideal()) is R True
comment:5 Changed 6 months ago by tscrim
Fixed this for quotient_by_principal_ideal() method in polynomial ring as well.
For patchbot:
Apply: trac_5978-quotient_zero_ideal-ts.2.patch
comment:6 Changed 6 months ago by tscrim
- Description modified (diff)
Fixed other doctests.
For patchbot:
Apply: trac_5978-quotient_zero_ideal-ts.patch
comment:7 Changed 3 months ago by lftabera
- Status changed from needs_review to positive_review
- Reviewers set to Luis Felipe Tabera Alonso
the patch looks good to me. I have made also further tests. Positive review.
Apply: trac_5978-quotient_zero_ideal-ts.patch
comment:10 Changed 3 months ago by jdemeyer
- Status changed from positive_review to closed
- Resolution set to fixed
- Merged in set to sage-5.8.beta1
Note: See
TracTickets for help on using
tickets.

