# SageMath code for working with p-adic field 7.3.7.21a14.1. # Define the p-adic field: Prec = 100 # Default precision of 100 Q7 = Qp(7, Prec); x = polygen(QQ) L. = Q7.extension(x^3 + 6*x^2 + 4) K. = L.extension(x^7 + (35*t + 7)*x + 7) # Defining polynomial: K.defining_polynomial() # Base field Qp: K.base() # Degree over Qp: K.absolute_degree() # Ramification index: K.absolute_e() # Residue field degree (Inertia degree): K.absolute_f() # Maximal unramified subextension: K.maximal_unramified_subextension() # Roots of unity: len(K.roots_of_unity())