ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Tue, 28 Nov 2023 23:10:54 +0100Cyclotomic Polynomials and Primitive Roots of Unityhttps://ask.sagemath.org/question/74565/cyclotomic-polynomials-and-primitive-roots-of-unity/I want to print the primitive root of unity $\zeta_m$ associated with the $m'th$ cyclotomic polynomial $\phi_m(x)$ where m is a power of two. I want to print the primitive root of this polynomial over $\mathbb{Z}_p$ with $p$ prime.
I tried the following as an example, with $p = 12206081$ and $m = 16384$. However this prints all the totient(16384) roots rather than just the primitive root.
x = PolynomialRing(GF(12206081), 'x').gen()
n = euler_phi(16384)
f = x^n + 1
print(f.roots())RohitTue, 28 Nov 2023 23:10:54 +0100https://ask.sagemath.org/question/74565/