Ticket #1128 (closed defect: fixed)

Opened 2 years ago

Last modified 2 years ago

[with-patch+review] Coercion of complex numbers

Reported by: robertwb Owned by: roed
Priority: major Milestone: sage-2.8.15
Component: basic arithmetic Keywords:
Cc: Author(s):
Report Upstream: Reviewer(s):
Merged in: Work issues:

Description

sage: ComplexField(200)(1) + RealField(100)(1)
<type 'exceptions.TypeError'>: unsupported operand parent(s) for '+': 'Complex Field with 200 bits of precision' and 'Real Field with 100 bits of precision'

Should return an element of ComplexField?(100)

This should be an easy fix, see

 http://groups.google.com/group/sage-devel/browse_thread/thread/5bc6c9190a3da63e/597d0eb7a45dae11?lnk=gst&q=complexfield#597d0eb7a45dae11

Attachments

trac1128.patch Download (5.6 KB) - added by roed 2 years ago.
Adds algebraic completion functor
trac1128.2.patch Download (5.2 KB) - added by robertwb 2 years ago.
cleaner patch

Change History

Changed 2 years ago by mabshoff

  • milestone set to sage-2.8.13

Changed 2 years ago by roed

  • owner changed from somebody to roed

Changed 2 years ago by roed

Adds algebraic completion functor

Changed 2 years ago by roed

  • summary changed from Coercion of complex numbers to [with-patch] Coercion of complex numbers

Changed 2 years ago by robertwb

cleaner patch

Changed 2 years ago by robertwb

Yep, works great.

Changed 2 years ago by robertwb

  • summary changed from [with-patch] Coercion of complex numbers to [with-patch+review] Coercion of complex numbers

Changed 2 years ago by mabshoff

  • status changed from new to closed
  • resolution set to fixed

Merged in 2.8.15.alpha2. I did merge trac1128.2.patch.

Note: See TracTickets for help on using tickets.