database_jones_numfield
).
sage: J = JonesDatabase() # requires optional database sage: J # requires optional database John Jones's table of number fields with bounded ramification and degree <= 6
sage: [(k.degree(), k.disc()) for k in J.unramified_outside([2])] # requires optional database [(1, 1), (2, 8), (2, -4), (2, -8), (4, 2048), (4, -1024), (4, 512), (4, -2048), (4, 256), (4, 2048), (4, 2048)]
List the discriminants of the fields of degree exactly 2 unramified outside 2:
sage: [k.disc() for k in J.unramified_outside([2],2)] # requires optional database [8, -4, -8]
List the discriminants of cubic field in the database ramified exactly at 3 and 5:
sage: [k.disc() for k in J.ramified_at([3,5],3)] # requires optional database [-6075, -6075, -675, -135] sage: factor(6075) 3^5 * 5^2 sage: factor(675) 3^3 * 5^2 sage: factor(135) 3^3 * 5
List all fields in the database ramified at 101:
sage: J.ramified_at(101) # requires optional database [Number Field in a with defining polynomial x^2 - 101, Number Field in a with defining polynomial x^4 - x^3 + 13*x^2 - 19*x + 361, Number Field in a with defining polynomial x^5 + 2*x^4 + 7*x^3 + 4*x^2 + 11*x - 6, Number Field in a with defining polynomial x^5 + x^4 - 6*x^3 - x^2 + 18*x + 4, Number Field in a with defining polynomial x^5 - x^4 - 40*x^3 - 93*x^2 - 21*x + 17]
class_number
is a method associated to a QuadraticField object:
sage: K = QuadraticField(29) sage: K.class_number() 1 sage: K = QuadraticField(65) sage: K.class_number() 2 sage: K = QuadraticField(-11) sage: K.class_number() 1 sage: K = QuadraticField(-15) sage: K.class_number() 2 sage: K.class_group() Multiplicative Abelian Group isomorphic to C2 sage: K = QuadraticField(401) sage: K.class_group() Multiplicative Abelian Group isomorphic to C5 sage: K.class_number() 5 sage: K.discriminant() 401 sage: K = QuadraticField(-479) sage: K.class_group() Multiplicative Abelian Group isomorphic to C25 sage: K.class_number() 25 sage: K.pari_polynomial() x^2 + 479 sage: K.degree() 2 sage: x = PolynomialRing(QQ).gen() sage: K = NumberField(x^5+10*x+1, 'a') sage: K Number Field in a with defining polynomial x^5 + 10*x + 1 sage: K.degree() 5 sage: K.pari_polynomial() x^5 + 10*x + 1 sage: K.discriminant() 25603125 sage: K.class_group() Trivial Abelian Group sage: K.class_number() 1
http://mathworld.wolfram.com/ClassNumber.html
at the Math World site for tables, formulas, and background information.
sage: CyclotomicField(3) Cyclotomic Field of order 3 and degree 2 sage: CyclotomicField(18) Cyclotomic Field of order 18 and degree 6 sage: z = CyclotomicField(6).gen(); z zeta6 sage: z**3 -1
ring/number_field.py
file.
sage: x = PolynomialRing(QQ).gen() sage: K = NumberField(x**5+10*x+1, 'a') sage: K.integral_basis() [1, a, a^2, a^3, a^4]
Next we compute the ring of integers of a cubic field in which 2 is an ``essential discriminant divisor", so the ring of integers is not generated by a single element.
sage: K = NumberField(x**3 + x**2 - 2*x + 8, 'a') sage: K.integral_basis() [1, a, 1/2*a^2 + 1/2*a]
See About this document... for information on suggesting changes.