Ask Your Question

Revision history [back]

Interpreting an element of CyclotomicField as an element of polynomial ring

I am trying to write a function that sums up numbers in different cyclotomic field formally, i.e., as expressions in $z$ where $z$ is the corresponding primitive root of unity. I run into a type error, however, as sage wouldn't let me sum elements of two different cyclotomic fields. Is there a way to typecast an expression in one cyclotomic field into the other, or, better yet, to a polynomial ring?

Interpreting an element of CyclotomicField as an element of polynomial ring

I am trying to write a function that sums up numbers in different cyclotomic field formally, i.e., as expressions in $z$ where $z$ is the corresponding primitive root of unity. I run into a type error, however, as sage wouldn't let me sum elements of two different cyclotomic fields. Is there a way to typecast an expression in one cyclotomic field into the other, or, better yet, to a polynomial ring?