ASKSAGE: Sage Q&A Forum - Latest question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Thu, 07 Dec 2017 23:34:33 -0600Substituting a complex embedding for a number field elementhttp://ask.sagemath.org/question/40006/substituting-a-complex-embedding-for-a-number-field-element/Is there a way to take an element of a number field (or a polynomial or a number field) and replace the generator of the field by one of its complex embeddings? For example, something like
sage: K.<a> = NumberField(x^2 - 3)
sage: (3*a + 5).substitute(a=a.complex_embeddings()[1])
It's feasible to do this with `sage_eval`, but hopefully there is a better way.jaebondThu, 07 Dec 2017 23:34:33 -0600http://ask.sagemath.org/question/40006/From number field to interval fieldhttp://ask.sagemath.org/question/9217/from-number-field-to-interval-field/Hello,
I would like to understand why the following works
sage: K1.<s1> = NumberField(x^3 - 2, 's1', embedding=RR(1.26))
sage: RIF(s1)
1.259921049894873?
and the following does not
sage: K2.<s2> =NumberField(x^3 - 2, 's2', embedding=CC(-0.63,1.09))
sage: CIF(s2)
Traceback (most recent call last)
...
TypeError: unable to coerce to a ComplexIntervalFieldElement
Thank you,
VincentvdelecroixWed, 08 Aug 2012 00:39:23 -0500http://ask.sagemath.org/question/9217/