Le 05/01/2017 à 11:33, Daniel Krenn a écrit :
On 2017-01-05 11:29, Daniel Krenn wrote:
On 2017-01-05 10:55, Daniel Krenn wrote:
as there is no *canonical* coercion as no embedding of the number field
is specified.

How can I specify this embedding such that it is used e.g. for the
symbolic I?

This looks weird: I is defined in sage.libs.pynac.pynac via
    K = QuadraticField(-1, 'I', embedding=CC.gen(), latex_name='i')
    pynac_I = K.gen()
so there is an embedding defined, but QQbar this seems to be not
sufficient to recognize it as an embedding into QQbar.

It seems like the embedding is simply ignored in some sense:
  sage: QQbar(QuadraticField(-1, 'I', embedding=-CC.gen()).gen())
  I

To my mind, this one should actually raise an error. The proper way to declare an embedding in QQbar is via

sage: K = QuadraticField(-1, 'I', embedding=-QQbar(I))
sage: K.0
I
sage: QQbar(K.0)
-I

which works perfectly fine.

Vincent

--
You received this message because you are subscribed to the Google Groups 
"sage-support" 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 https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.

Reply via email to