mathlib documentation

data.​padics.​padic_integers

data.​padics.​padic_integers

p-adic integers

This file defines the p-adic integers ℤ_p as the subtype of ℚ_p with norm ≤ 1. We show that ℤ_p is a complete nonarchimedean normed local ring.

Important definitions

Notation

We introduce the notation ℤ_[p] for the p-adic integers.

Implementation notes

Much, but not all, of this file assumes that p is prime. This assumption is inferred automatically by taking (prime p) as a type class argument.

Coercions into ℤ_p are set up to work with the norm_cast tactic.

References

Tags

p-adic, p adic, padic, p-adic integer

def padic_int (p : ) [fact (nat.prime p)] :
Type

The p-adic integers ℤ_p are the p-adic numbers with norm ≤ 1.

Equations
@[instance]

Equations
@[ext]
theorem padic_int.​ext {p : } [fact (nat.prime p)] {x y : ℤ_[p]} :
x = yx = y

@[instance]

Addition on ℤ_p is inherited from ℚ_p.

Equations
  • padic_int.has_add = {add := λ (_x : ℤ_[p]), padic_int.has_add._match_2 _x}
  • padic_int.has_add._match_2 x, hx⟩ = λ (_x : ℤ_[p]), padic_int.has_add._match_1 x hx _x
  • padic_int.has_add._match_1 x hx y, hy⟩ = x + y, _⟩
@[instance]

Multiplication on ℤ_p is inherited from ℚ_p.

Equations
  • padic_int.has_mul = {mul := λ (_x : ℤ_[p]), padic_int.has_mul._match_2 _x}
  • padic_int.has_mul._match_2 x, hx⟩ = λ (_x : ℤ_[p]), padic_int.has_mul._match_1 x hx _x
  • padic_int.has_mul._match_1 x hx y, hy⟩ = x * y, _⟩
@[instance]

Negation on ℤ_p is inherited from ℚ_p.

Equations
@[instance]

Zero on ℤ_p is inherited from ℚ_p.

Equations
@[instance]

Equations
@[instance]

One on ℤ_p is inherited from ℚ_p.

Equations
@[simp]
theorem padic_int.​mk_zero {p : } [fact (nat.prime p)] {h : 0 1} :
0, h⟩ = 0

@[simp]
theorem padic_int.​val_eq_coe {p : } [fact (nat.prime p)] (z : ℤ_[p]) :
z.val = z

@[simp]
theorem padic_int.​coe_add {p : } [fact (nat.prime p)] (z1 z2 : ℤ_[p]) :
(z1 + z2) = z1 + z2

@[simp]
theorem padic_int.​coe_mul {p : } [fact (nat.prime p)] (z1 z2 : ℤ_[p]) :
(z1 * z2) = z1 * z2

@[simp]
theorem padic_int.​coe_neg {p : } [fact (nat.prime p)] (z1 : ℤ_[p]) :
-z1 = -z1

@[simp]
theorem padic_int.​coe_one {p : } [fact (nat.prime p)] :
1 = 1

@[simp]
theorem padic_int.​coe_coe {p : } [fact (nat.prime p)] (n : ) :

@[simp]
theorem padic_int.​coe_zero {p : } [fact (nat.prime p)] :
0 = 0

@[simp]
theorem padic_int.​coe_sub {p : } [fact (nat.prime p)] (z1 z2 : ℤ_[p]) :
(z1 - z2) = z1 - z2

@[simp]
theorem padic_int.​cast_pow {p : } [fact (nat.prime p)] (x : ℤ_[p]) (n : ) :
(x ^ n) = x ^ n

@[simp]
theorem padic_int.​mk_coe {p : } [fact (nat.prime p)] (k : ℤ_[p]) :
k, _⟩ = k

def padic_int.​inv {p : } [fact (nat.prime p)] :

The inverse of a p-adic integer with norm equal to 1 is also a p-adic integer. Otherwise, the inverse is defined to be 0.

Equations
@[instance]

Equations
@[instance]

Equations
theorem padic_norm_z {p : } [fact (nat.prime p)] {z : ℤ_[p]} :

@[instance]

Equations
theorem padic_int.​pmul_comm {p : } [fact (nat.prime p)] (z1 z2 : ℤ_[p]) :
z1 * z2 = z2 * z1

theorem padic_int.​zero_ne_one {p : } [fact (nat.prime p)] :
0 1

theorem padic_int.​eq_zero_or_eq_zero_of_mul_eq_zero {p : } [fact (nat.prime p)] (a b : ℤ_[p]) :
a * b = 0a = 0 b = 0

theorem padic_norm_z.​le_one {p : } [fact (nat.prime p)] (z : ℤ_[p]) :

@[simp]
theorem padic_norm_z.​one {p : } [fact (nat.prime p)] :

@[simp]
theorem padic_norm_z.​mul {p : } [fact (nat.prime p)] (z1 z2 : ℤ_[p]) :
z1 * z2 = z1 * z2

@[simp]
theorem padic_norm_z.​pow {p : } [fact (nat.prime p)] (z : ℤ_[p]) (n : ) :
z ^ n = z ^ n

theorem padic_norm_z.​eq_of_norm_add_lt_right {p : } [fact (nat.prime p)] {z1 z2 : ℤ_[p]} :
z1 + z2 < z2z1 = z2

theorem padic_norm_z.​eq_of_norm_add_lt_left {p : } [fact (nat.prime p)] {z1 z2 : ℤ_[p]} :
z1 + z2 < z1z1 = z2

@[simp]

@[simp]

@[simp]
theorem padic_norm_z.​norm_p_pow {p : } [fact (nat.prime p)] (n : ) :

Valuation on ℤ_[p]

padic_int.valuation lifts the p-adic valuation on to ℤ_[p].

Equations
theorem padic_int.​norm_eq_pow_val {p : } [fact (nat.prime p)] {x : ℤ_[p]} :
x 0x = p ^ -x.valuation

@[simp]

@[simp]

@[simp]

Units of ℤ_[p]

theorem padic_int.​mul_inv {p : } [fact (nat.prime p)] {z : ℤ_[p]} :
z = 1z * z.inv = 1

theorem padic_int.​inv_mul {p : } [fact (nat.prime p)] {z : ℤ_[p]} :
z = 1z.inv * z = 1

theorem padic_int.​is_unit_iff {p : } [fact (nat.prime p)] {z : ℤ_[p]} :

theorem padic_int.​norm_lt_one_add {p : } [fact (nat.prime p)] {z1 z2 : ℤ_[p]} :
z1 < 1z2 < 1z1 + z2 < 1

theorem padic_int.​norm_lt_one_mul {p : } [fact (nat.prime p)] {z1 z2 : ℤ_[p]} :
z2 < 1z1 * z2 < 1

@[simp]

def padic_int.​mk_units {p : } [fact (nat.prime p)] {u : ℚ_[p]} :

A p-adic number u with ∥u∥ = 1 is a unit of ℤ_[p].

Equations
@[simp]
theorem padic_int.​mk_units_eq {p : } [fact (nat.prime p)] {u : ℚ_[p]} (h : u = 1) :

@[simp]
theorem padic_int.​norm_units {p : } [fact (nat.prime p)] (u : units ℤ_[p]) :

def padic_int.​unit_coeff {p : } [fact (nat.prime p)] {x : ℤ_[p]} :
x 0units ℤ_[p]

unit_coeff hx is the unit u in the unique representation x = u * p ^ n. See unit_coeff_spec.

Equations
@[simp]
theorem padic_int.​unit_coeff_coe {p : } [fact (nat.prime p)] {x : ℤ_[p]} (hx : x 0) :

The coercion from ℤ[p] to ℚ[p] as a ring homomorphism.

Equations
theorem padic_int.​p_dvd_of_norm_lt_one {p : } [fact (nat.prime p)] {x : ℤ_[p]} :
x < 1p x

theorem padic_int.​ideal_eq_span_pow_p {p : } [fact (nat.prime p)] {s : ideal ℤ_[p]} :
s (∃ (n : ), s = ideal.span {p ^ n})

theorem padic_norm_z.​padic_val_of_cong_pow_p {p : } [fact (nat.prime p)] {z1 z2 : } {n : } :
z1 z2 [ZMOD (p ^ n)]z1 - z2 (p ^ -n)