#17117: UniversalCyclotomicField elements considered real
-----------------------------+----------------------------
   Reporter:  gagern         |            Owner:
       Type:  defect         |           Status:  new
   Priority:  major          |        Milestone:  sage-6.4
  Component:  number fields  |         Keywords:
  Merged in:                 |          Authors:
  Reviewers:                 |  Report Upstream:  N/A
Work issues:                 |           Branch:
     Commit:                 |     Dependencies:
   Stopgaps:                 |
-----------------------------+----------------------------
 This is certainly wrong:

 {{{
 sage: UCF.<E> = UniversalCyclotomicField()
 sage: E3 = E(3)
 sage: E3
 E(3)
 sage: N(E3)
 -0.500000000000000 + 0.866025403784439*I
 sage: real(E3)
 E(3)
 sage: imag(E3)
 0
 }}}

 This is probably due to the fact that `real` and `imag` aren't methods of
 this class, even though `conjugate` seems to work correctly.

 {{{
 sage: E3.conjugate()
 E(3)^2
 sage: conjugate(E3)
 E(3)^2
 sage: (E3 + E3.conjugate())/2
 -1/2
 sage: (E3 - E3.conjugate())/(2*E(4))
 -1/2*E(12)^7 + 1/2*E(12)^11
 }}}

 So I'd say these methods should be implemented, building on `conjugate`.
 Perhaps the functions will pick the methods up if they do exist, even
 though #17116 makes me far from certain on this point right now.

--
Ticket URL: <http://trac.sagemath.org/ticket/17117>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to