Number fields #
This file defines a number field and the ring of integers corresponding to it.
Main definitions #
NumberField
defines a number field as a field which has characteristic zero and is finite dimensional over β.RingOfIntegers
defines the ring of integers (or number ring) corresponding to a number field as the integral closure of β€ in the number field.
Implementation notes #
The definitions that involve a field of fractions choose a canonical field of fractions, but are independent of that choice.
References #
- [D. Marcus, Number Fields][marcus1977number]
- [J.W.S. Cassels, A. FrΓΆlich, Algebraic Number Theory][cassels1967algebraic]
- [P. Samuel, Algebraic Theory of Numbers][samuel1970algebraic]
Tags #
number field, ring of integers
A number field is a field which has characteristic zero and is finite dimensional over β.
- to_charZero : CharZero K
- to_finiteDimensional : FiniteDimensional β K
Instances
Equations
- β― = β―
The ring of integers (or number ring) corresponding to a number field is the integral closure of β€ in the number field.
This is defined as its own type, rather than a Subalgebra
, for performance reasons:
looking for instances of the form SMul (RingOfIntegers _) (RingOfIntegers _)
makes
much more effective use of the discrimination tree than instances of the form
SMul (Subtype _) (Subtype _)
.
The drawback is we have to copy over instances manually.
Equations
- NumberField.RingOfIntegers K = β₯(integralClosure β€ K)
Instances For
The ring of integers (or number ring) corresponding to a number field is the integral closure of β€ in the number field.
This is defined as its own type, rather than a Subalgebra
, for performance reasons:
looking for instances of the form SMul (RingOfIntegers _) (RingOfIntegers _)
makes
much more effective use of the discrimination tree than instances of the form
SMul (Subtype _) (Subtype _)
.
The drawback is we have to copy over instances manually.
Equations
- NumberField.termπ = Lean.ParserDescr.node `NumberField.termπ 1024 (Lean.ParserDescr.symbol "π")
Instances For
Equations
Equations
- β― = β―
Equations
- β― = β―
Equations
- NumberField.RingOfIntegers.instAlgebra K = inferInstanceAs (Algebra (β₯(integralClosure β€ K)) K)
Equations
- β― = β―
Equations
- β― = β―
The canonical coercion from π K
to K
.
Equations
- βx = (algebraMap (NumberField.RingOfIntegers K) K) x
Instances For
This instance has to be CoeHead
because we only want to apply it from π K
to K
.
Equations
- NumberField.RingOfIntegers.instCoeHead = { coe := NumberField.RingOfIntegers.val }
The canonical map from π K
to K
is injective.
This is a convenient abbreviation for NoZeroSMulDivisors.algebraMap_injective
.
The canonical map from π K
to K
is injective.
This is a convenient abbreviation for map_eq_zero_iff
applied to
NoZeroSMulDivisors.algebraMap_injective
.
The canonical map from π K
to K
is injective.
This is a convenient abbreviation for map_ne_zero_iff
applied to
NoZeroSMulDivisors.algebraMap_injective
.
Equations
- β― = β―
Equations
- β― = β―
Equations
- β― = β―
The ring of integers of K
are equivalent to any integral closure of β€
in K
Equations
- NumberField.RingOfIntegers.equiv R = (IsIntegralClosure.equiv β€ R K (NumberField.RingOfIntegers K)).symm.toRingEquiv
Instances For
Equations
- β― = β―
Equations
- β― = β―
The ring of integers of a number field is not a field.
Equations
- β― = β―
Equations
- β― = β―
Equations
- β― = β―
A β€-basis of the ring of integers of K
.
Equations
Instances For
Given f : M β K
such that β x, IsIntegral β€ (f x)
, the corresponding function
M β π K
.
Equations
- NumberField.RingOfIntegers.restrict f h x = β¨f x, β―β©
Instances For
Given f : M β+ K
such that β x, IsIntegral β€ (f x)
, the corresponding function
M β+ π K
.
Equations
- NumberField.RingOfIntegers.restrict_addMonoidHom f h = { toFun := NumberField.RingOfIntegers.restrict (βf) h, map_zero' := β―, map_add' := β― }
Instances For
Given f : M β* K
such that β x, IsIntegral β€ (f x)
, the corresponding function
M β* π K
.
Equations
- NumberField.RingOfIntegers.restrict_monoidHom f h = { toFun := NumberField.RingOfIntegers.restrict (βf) h, map_one' := β―, map_mul' := β― }
Instances For
A basis of K
over β
that is also a basis of π K
over β€
.
Equations
Instances For
The ring of integers of β
as a number field is just β€
.
Instances For
The quotient of β[X]
by the ideal generated by an irreducible polynomial of β[X]
is a number field.
Equations
- β― = β―