Skip to content
This repository was archived by the owner on Jul 24, 2024. It is now read-only.

Commit db24ba7

Browse files
committed
chore(number_theory/padics): stylistic changes (#15755)
Extracted stylistic changes (backticks, brackets, linebreaks, naming, spacing) from #15221 as suggested in the comments.
1 parent a12363e commit db24ba7

File tree

5 files changed

+287
-402
lines changed

5 files changed

+287
-402
lines changed

src/number_theory/padics/padic_integers.lean

Lines changed: 63 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -11,30 +11,30 @@ import topology.metric_space.cau_seq_filter
1111
/-!
1212
# p-adic integers
1313
14-
This file defines the p-adic integers `ℤ_p` as the subtype of `ℚ_p` with norm `≤ 1`.
15-
We show that `ℤ_p`
16-
* is complete
17-
* is nonarchimedean
18-
* is a normed ring
19-
* is a local ring
20-
* is a discrete valuation ring
14+
This file defines the `p`-adic integers `ℤ_[p]` as the subtype of `ℚ_[p]` with norm `≤ 1`.
15+
We show that `ℤ_[p]`
16+
* is complete,
17+
* is nonarchimedean,
18+
* is a normed ring,
19+
* is a local ring, and
20+
* is a discrete valuation ring.
2121
2222
The relation between `ℤ_[p]` and `zmod p` is established in another file.
2323
2424
## Important definitions
2525
26-
* `padic_int` : the type of p-adic numbers
26+
* `padic_int` : the type of `p`-adic integers
2727
2828
## Notation
2929
30-
We introduce the notation `ℤ_[p]` for the p-adic integers.
30+
We introduce the notation `ℤ_[p]` for the `p`-adic integers.
3131
3232
## Implementation notes
3333
3434
Much, but not all, of this file assumes that `p` is prime. This assumption is inferred automatically
35-
by taking `[fact (nat.prime p)] as a type class argument.
35+
by taking `[fact p.prime]` as a type class argument.
3636
37-
Coercions into `ℤ_p` are set up to work with the `norm_cast` tactic.
37+
Coercions into `ℤ_[p]` are set up to work with the `norm_cast` tactic.
3838
3939
## References
4040
@@ -51,8 +51,9 @@ open padic metric local_ring
5151
noncomputable theory
5252
open_locale classical
5353

54-
/-- The p-adic integers ℤ_p are the p-adic numbers with norm ≤ 1. -/
54+
/-- The `p`-adic integers `ℤ_[p]` are the `p`-adic numbers with norm `≤ 1`. -/
5555
def padic_int (p : ℕ) [fact p.prime] := {x : ℚ_[p] // ∥x∥ ≤ 1}
56+
5657
notation `ℤ_[`p`]` := padic_int p
5758

5859
namespace padic_int
@@ -67,7 +68,7 @@ lemma ext {x y : ℤ_[p]} : (x : ℚ_[p]) = y → x = y := subtype.ext
6768

6869
variables (p)
6970

70-
/-- The padic integers as a subring of the padics -/
71+
/-- The `p`-adic integers as a subring of `ℚ_[p]`. -/
7172
def subring : subring (ℚ_[p]) :=
7273
{ carrier := {x : ℚ_[p] | ∥x∥ ≤ 1},
7374
zero_mem' := by norm_num,
@@ -80,26 +81,25 @@ def subring : subring (ℚ_[p]) :=
8081

8182
variables {p}
8283

83-
/-- Addition on ℤ_p is inherited from ℚ_p. -/
84+
/-- Addition on `ℤ_[p]` is inherited from `ℚ_[p]`. -/
8485
instance : has_add ℤ_[p] := (by apply_instance : has_add (subring p))
8586

86-
/-- Multiplication on ℤ_p is inherited from ℚ_p. -/
87+
/-- Multiplication on `ℤ_[p]` is inherited from `ℚ_[p]`. -/
8788
instance : has_mul ℤ_[p] := (by apply_instance : has_mul (subring p))
8889

89-
/-- Negation on ℤ_p is inherited from ℚ_p. -/
90+
/-- Negation on `ℤ_[p]` is inherited from `ℚ_[p]`. -/
9091
instance : has_neg ℤ_[p] := (by apply_instance : has_neg (subring p))
9192

92-
/-- Subtraction on ℤ_p is inherited from ℚ_p. -/
93+
/-- Subtraction on `ℤ_[p]` is inherited from `ℚ_[p]`. -/
9394
instance : has_sub ℤ_[p] := (by apply_instance : has_sub (subring p))
9495

95-
/-- Zero on ℤ_p is inherited from ℚ_p. -/
96+
/-- Zero on `ℤ_[p]` is inherited from `ℚ_[p]`. -/
9697
instance : has_zero ℤ_[p] := (by apply_instance : has_zero (subring p))
9798

9899
instance : inhabited ℤ_[p] := ⟨0
99100

100-
/-- One on ℤ_p is inherited from ℚ_p. -/
101-
instance : has_one ℤ_[p] :=
102-
⟨⟨1, by norm_num⟩⟩
101+
/-- One on `ℤ_[p]` is inherited from `ℚ_[p]`. -/
102+
instance : has_one ℤ_[p] := ⟨⟨1, by norm_num⟩⟩
103103

104104
@[simp] lemma mk_zero {h} : (⟨0, h⟩ : ℤ_[p]) = (0 : ℤ_[p]) := rfl
105105

@@ -121,17 +121,17 @@ instance : comm_ring ℤ_[p] :=
121121
@[simp, norm_cast] lemma coe_nat_cast (n : ℕ) : ((n : ℤ_[p]) : ℚ_[p]) = n := rfl
122122
@[simp, norm_cast] lemma coe_int_cast (z : ℤ) : ((z : ℤ_[p]) : ℚ_[p]) = z := rfl
123123

124-
/-- The coercion from [p] to [p] as a ring homomorphism. -/
124+
/-- The coercion from `ℤ_[p]` to `ℚ_[p]` as a ring homomorphism. -/
125125
def coe.ring_hom : ℤ_[p] →+* ℚ_[p] := (subring p).subtype
126126

127127
@[simp, norm_cast] lemma coe_pow (x : ℤ_[p]) (n : ℕ) : (↑(x^n) : ℚ_[p]) = (↑x : ℚ_[p])^n := rfl
128128

129129
@[simp] lemma mk_coe (k : ℤ_[p]) : (⟨k, k.2⟩ : ℤ_[p]) = k := subtype.coe_eta _ _
130130

131-
/-- The inverse of a p-adic integer with norm equal to 1 is also a p-adic integer. Otherwise, the
132-
inverse is defined to be 0. -/
131+
/-- The inverse of a `p`-adic integer with norm equal to `1` is also a `p`-adic integer.
132+
Otherwise, the inverse is defined to be `0`. -/
133133
def inv : ℤ_[p] → ℤ_[p]
134-
| ⟨k, _⟩ := if h : ∥k∥ = 1 then1/k, by simp [h]⟩ else 0
134+
| ⟨k, _⟩ := if h : ∥k∥ = 1 thenk⁻¹, by simp [h]⟩ else 0
135135

136136
instance : char_zero ℤ_[p] :=
137137
{ cast_injective :=
@@ -142,10 +142,8 @@ instance : char_zero ℤ_[p] :=
142142
suffices (z1 : ℚ_[p]) = z2 ↔ z1 = z2, from iff.trans (by norm_cast) this,
143143
by norm_cast
144144

145-
/--
146-
A sequence of integers that is Cauchy with respect to the `p`-adic norm
147-
converges to a `p`-adic integer.
148-
-/
145+
/-- A sequence of integers that is Cauchy with respect to the `p`-adic norm converges to a `p`-adic
146+
integer. -/
149147
def of_int_seq (seq : ℕ → ℤ) (h : is_cau_seq (padic_norm p) (λ n, seq n)) : ℤ_[p] :=
150148
⟨⟦⟨_, h⟩⟧,
151149
show ↑(padic_seq.norm _) ≤ (1 : ℝ), begin
@@ -194,12 +192,11 @@ instance is_absolute_value : is_absolute_value (λ z : ℤ_[p], ∥z∥) :=
194192
{ abv_nonneg := norm_nonneg,
195193
abv_eq_zero := λ ⟨_, _⟩, by simp [norm_eq_zero],
196194
abv_add := λ ⟨_,_⟩ ⟨_, _⟩, norm_add_le _ _,
197-
abv_mul := λ _ _, by simp only [norm_def, padic_norm_e.mul, padic_int.coe_mul]}
195+
abv_mul := λ _ _, by simp only [norm_def, padic_norm_e.mul, padic_int.coe_mul] }
198196

199197
variables {p}
200198

201-
instance : is_domain ℤ_[p] :=
202-
function.injective.is_domain (subring p).subtype subtype.coe_injective
199+
instance : is_domain ℤ_[p] := function.injective.is_domain (subring p).subtype subtype.coe_injective
203200

204201
end padic_int
205202

@@ -211,64 +208,53 @@ variables {p : ℕ} [fact p.prime]
211208

212209
lemma norm_le_one (z : ℤ_[p]) : ∥z∥ ≤ 1 := z.2
213210

214-
@[simp] lemma norm_mul (z1 z2 : ℤ_[p]) : ∥z1 * z2∥ = ∥z1∥ * ∥z2∥ :=
215-
by simp [norm_def]
211+
@[simp] lemma norm_mul (z1 z2 : ℤ_[p]) : ∥z1 * z2∥ = ∥z1∥ * ∥z2∥ := by simp [norm_def]
216212

217-
@[simp] lemma norm_pow (z : ℤ_[p]) : ∀ n : ℕ, ∥z^n∥ = ∥z∥^n
213+
@[simp] lemma norm_pow (z : ℤ_[p]) : ∀ n : ℕ, ∥z ^ n∥ = ∥z∥ ^ n
218214
| 0 := by simp
219-
| (k+1) := by { rw [pow_succ, pow_succ, norm_mul], congr, apply norm_pow }
215+
| (k + 1) := by { rw [pow_succ, pow_succ, norm_mul], congr, apply norm_pow }
220216

221217
theorem nonarchimedean (q r : ℤ_[p]) : ∥q + r∥ ≤ max (∥q∥) (∥r∥) := padic_norm_e.nonarchimedean _ _
222218

223219
theorem norm_add_eq_max_of_ne {q r : ℤ_[p]} : ∥q∥ ≠ ∥r∥ → ∥q+r∥ = max (∥q∥) (∥r∥) :=
224220
padic_norm_e.add_eq_max_of_ne
225221

226-
lemma norm_eq_of_norm_add_lt_right {z1 z2 : ℤ_[p]}
227-
(h : ∥z1 + z2∥ < ∥z2∥) : ∥z1∥ = ∥z2∥ :=
228-
by_contradiction $ λ hne,
229-
not_lt_of_ge (by rw norm_add_eq_max_of_ne hne; apply le_max_right) h
222+
lemma norm_eq_of_norm_add_lt_right {z1 z2 : ℤ_[p]} (h : ∥z1 + z2∥ < ∥z2∥) : ∥z1∥ = ∥z2∥ :=
223+
by_contradiction $ λ hne, not_lt_of_ge (by rw norm_add_eq_max_of_ne hne; apply le_max_right) h
230224

231-
lemma norm_eq_of_norm_add_lt_left {z1 z2 : ℤ_[p]}
232-
(h : ∥z1 + z2∥ < ∥z1∥) : ∥z1∥ = ∥z2∥ :=
233-
by_contradiction $ λ hne,
234-
not_lt_of_ge (by rw norm_add_eq_max_of_ne hne; apply le_max_left) h
225+
lemma norm_eq_of_norm_add_lt_left {z1 z2 : ℤ_[p]} (h : ∥z1 + z2∥ < ∥z1∥) : ∥z1∥ = ∥z2∥ :=
226+
by_contradiction $ λ hne, not_lt_of_ge (by rw norm_add_eq_max_of_ne hne; apply le_max_left) h
235227

236-
@[simp] lemma padic_norm_e_of_padic_int (z : ℤ_[p]) : ∥(↑z : ℚ_[p])∥ = ∥z∥ :=
237-
by simp [norm_def]
228+
@[simp] lemma padic_norm_e_of_padic_int (z : ℤ_[p]) : ∥(z : ℚ_[p])∥ = ∥z∥ := by simp [norm_def]
238229

239-
lemma norm_int_cast_eq_padic_norm (z : ℤ) : ∥(z : ℤ_[p])∥ = ∥(z : ℚ_[p])∥ :=
240-
by simp [norm_def]
230+
lemma norm_int_cast_eq_padic_norm (z : ℤ) : ∥(z : ℤ_[p])∥ = ∥(z : ℚ_[p])∥ := by simp [norm_def]
241231

242-
@[simp] lemma norm_eq_padic_norm {q : ℚ_[p]} (hq : ∥q∥ ≤ 1) :
243-
@norm ℤ_[p] _ ⟨q, hq⟩ = ∥q∥ := rfl
232+
@[simp] lemma norm_eq_padic_norm {q : ℚ_[p]} (hq : ∥q∥ ≤ 1) : @norm ℤ_[p] _ ⟨q, hq⟩ = ∥q∥ := rfl
244233

245234
@[simp] lemma norm_p : ∥(p : ℤ_[p])∥ = p⁻¹ := padic_norm_e.norm_p
246235

247236
@[simp] lemma norm_p_pow (n : ℕ) : ∥(p : ℤ_[p])^n∥ = p^(-n:ℤ) := padic_norm_e.norm_p_pow n
248237

249-
private def cau_seq_to_rat_cau_seq (f : cau_seq ℤ_[p] norm) :
250-
cau_seq ℚ_[p] (λ a, ∥a∥) :=
251-
⟨ λ n, f n,
252-
λ _ hε, by simpa [norm, norm_def] using f.cauchy hε ⟩
238+
private def cau_seq_to_rat_cau_seq (f : cau_seq ℤ_[p] norm) : cau_seq ℚ_[p] (λ a, ∥a∥) :=
239+
⟨ λ n, f n, λ _ hε, by simpa [norm, norm_def] using f.cauchy hε ⟩
253240

254241
variables (p)
255242

256243
instance complete : cau_seq.is_complete ℤ_[p] norm :=
257244
⟨ λ f,
258245
have hqn : ∥cau_seq.lim (cau_seq_to_rat_cau_seq f)∥ ≤ 1,
259246
from padic_norm_e_lim_le zero_lt_one (λ _, norm_le_one _),
260-
⟨ ⟨_, hqn⟩,
261-
λ ε, by simpa [norm, norm_def] using cau_seq.equiv_lim (cau_seq_to_rat_cau_seq f) ε⟩⟩
247+
⟨⟨_, hqn⟩, λ ε, by simpa [norm, norm_def] using cau_seq.equiv_lim (cau_seq_to_rat_cau_seq f) ε⟩⟩
262248

263249
end padic_int
264250

265251
namespace padic_int
266252

267253
variables (p : ℕ) [hp : fact p.prime]
254+
268255
include hp
269256

270-
lemma exists_pow_neg_lt {ε : ℝ} (hε : 0 < ε) :
271-
∃ (k : ℕ), ↑p ^ -((k : ℕ) : ℤ) < ε :=
257+
lemma exists_pow_neg_lt {ε : ℝ} (hε : 0 < ε) : ∃ k : ℕ, ↑p ^ -(k : ℤ) < ε :=
272258
begin
273259
obtain ⟨k, hk⟩ := exists_nat_gt ε⁻¹,
274260
use k,
@@ -282,8 +268,7 @@ begin
282268
{ exact_mod_cast hp.1.pos }
283269
end
284270

285-
lemma exists_pow_neg_lt_rat {ε : ℚ} (hε : 0 < ε) :
286-
∃ (k : ℕ), ↑p ^ -((k : ℕ) : ℤ) < ε :=
271+
lemma exists_pow_neg_lt_rat {ε : ℚ} (hε : 0 < ε) : ∃ k : ℕ, ↑p ^ -(k : ℤ) < ε :=
287272
begin
288273
obtain ⟨k, hk⟩ := @exists_pow_neg_lt p _ ε (by exact_mod_cast hε),
289274
use k,
@@ -297,31 +282,27 @@ lemma norm_int_lt_one_iff_dvd (k : ℤ) : ∥(k : ℤ_[p])∥ < 1 ↔ (p : ℤ)
297282
suffices ∥(k : ℚ_[p])∥ < 1 ↔ ↑p ∣ k, by rwa norm_int_cast_eq_padic_norm,
298283
padic_norm_e.norm_int_lt_one_iff_dvd k
299284

300-
lemma norm_int_le_pow_iff_dvd {k : ℤ} {n : ℕ} : ∥(k : ℤ_[p])∥ ≤ p ^ (-n : ℤ) ↔ (p^n : ℤ) ∣ k :=
301-
suffices ∥(k : ℚ_[p])∥ ≤ ((↑p)^(-n : ℤ)) ↔ ↑(p^n) ∣ k,
285+
lemma norm_int_le_pow_iff_dvd {k : ℤ} {n : ℕ} : ∥(k : ℤ_[p])∥ ≤ p ^ (-n : ℤ) ↔ (p ^ n : ℤ) ∣ k :=
286+
suffices ∥(k : ℚ_[p])∥ ≤ p ^ (-n : ℤ) ↔ ↑(p ^ n) ∣ k,
302287
by simpa [norm_int_cast_eq_padic_norm], padic_norm_e.norm_int_le_pow_iff_dvd _ _
303288

304289
/-! ### Valuation on `ℤ_[p]` -/
305290

306-
/-- `padic_int.valuation` lifts the p-adic valuation on `ℚ` to `ℤ_[p]`. -/
291+
/-- `padic_int.valuation` lifts the `p`-adic valuation on `ℚ` to `ℤ_[p]`. -/
307292
def valuation (x : ℤ_[p]) := padic.valuation (x : ℚ_[p])
308293

309-
lemma norm_eq_pow_val {x : ℤ_[p]} (hx : x ≠ 0) :
310-
∥x∥ = p^(-x.valuation) :=
294+
lemma norm_eq_pow_val {x : ℤ_[p]} (hx : x ≠ 0) : ∥x∥ = (p : ℝ) ^ -x.valuation :=
311295
begin
312296
convert padic.norm_eq_pow_val _,
313297
contrapose! hx,
314298
exact subtype.val_injective hx
315299
end
316300

317-
@[simp] lemma valuation_zero : valuation (0 : ℤ_[p]) = 0 :=
318-
padic.valuation_zero
301+
@[simp] lemma valuation_zero : valuation (0 : ℤ_[p]) = 0 := padic.valuation_zero
319302

320-
@[simp] lemma valuation_one : valuation (1 : ℤ_[p]) = 0 :=
321-
padic.valuation_one
303+
@[simp] lemma valuation_one : valuation (1 : ℤ_[p]) = 0 := padic.valuation_one
322304

323-
@[simp] lemma valuation_p : valuation (p : ℤ_[p]) = 1 :=
324-
by simp [valuation]
305+
@[simp] lemma valuation_p : valuation (p : ℤ_[p]) = 1 := by simp [valuation]
325306

326307
lemma valuation_nonneg (x : ℤ_[p]) : 0 ≤ x.valuation :=
327308
begin
@@ -368,8 +349,7 @@ lemma mul_inv : ∀ {z : ℤ_[p]}, ∥z∥ = 1 → z * z.inv = 1
368349
simp [mul_inv_cancel hk]
369350
end
370351

371-
lemma inv_mul {z : ℤ_[p]} (hz : ∥z∥ = 1) : z.inv * z = 1 :=
372-
by rw [mul_comm, mul_inv hz]
352+
lemma inv_mul {z : ℤ_[p]} (hz : ∥z∥ = 1) : z.inv * z = 1 := by rw [mul_comm, mul_inv hz]
373353

374354
lemma is_unit_iff {z : ℤ_[p]} : is_unit z ↔ ∥z∥ = 1 :=
375355
⟨λ h, begin
@@ -383,8 +363,8 @@ lemma norm_lt_one_add {z1 z2 : ℤ_[p]} (hz1 : ∥z1∥ < 1) (hz2 : ∥z2∥ < 1
383363
lt_of_le_of_lt (nonarchimedean _ _) (max_lt hz1 hz2)
384364

385365
lemma norm_lt_one_mul {z1 z2 : ℤ_[p]} (hz2 : ∥z2∥ < 1) : ∥z1 * z2∥ < 1 :=
386-
calc ∥z1 * z2∥ = ∥z1∥ * ∥z2∥ : by simp
387-
... < 1 : mul_lt_one_of_nonneg_of_lt_one_right (norm_le_one _) (norm_nonneg _) hz2
366+
calc ∥z1 * z2∥ = ∥z1∥ * ∥z2∥ : by simp
367+
... < 1 : mul_lt_one_of_nonneg_of_lt_one_right (norm_le_one _) (norm_nonneg _) hz2
388368

389369
@[simp] lemma mem_nonunits {z : ℤ_[p]} : z ∈ nonunits ℤ_[p] ↔ ∥z∥ < 1 :=
390370
by rw lt_iff_le_and_ne; simp [norm_le_one z, nonunits, is_unit_iff]
@@ -393,24 +373,21 @@ by rw lt_iff_le_and_ne; simp [norm_le_one z, nonunits, is_unit_iff]
393373
def mk_units {u : ℚ_[p]} (h : ∥u∥ = 1) : ℤ_[p]ˣ :=
394374
let z : ℤ_[p] := ⟨u, le_of_eq h⟩ in ⟨z, z.inv, mul_inv h, inv_mul h⟩
395375

396-
@[simp]
397-
lemma mk_units_eq {u : ℚ_[p]} (h : ∥u∥ = 1) : ((mk_units h : ℤ_[p]) : ℚ_[p]) = u :=
398-
rfl
376+
@[simp] lemma mk_units_eq {u : ℚ_[p]} (h : ∥u∥ = 1) : ((mk_units h : ℤ_[p]) : ℚ_[p]) = u := rfl
399377

400-
@[simp] lemma norm_units (u : ℤ_[p]ˣ) : ∥(u : ℤ_[p])∥ = 1 :=
401-
is_unit_iff.mp $ by simp
378+
@[simp] lemma norm_units (u : ℤ_[p]ˣ) : ∥(u : ℤ_[p])∥ = 1 := is_unit_iff.mp $ by simp
402379

403380
/-- `unit_coeff hx` is the unit `u` in the unique representation `x = u * p ^ n`.
404381
See `unit_coeff_spec`. -/
405382
def unit_coeff {x : ℤ_[p]} (hx : x ≠ 0) : ℤ_[p]ˣ :=
406-
let u : ℚ_[p] := x*p^(-x.valuation) in
383+
let u : ℚ_[p] := x * p ^ -x.valuation in
407384
have hu : ∥u∥ = 1,
408385
by simp [hx, nat.zpow_ne_zero_of_pos (by exact_mod_cast hp.1.pos) x.valuation,
409386
norm_eq_pow_val, zpow_neg, inv_mul_cancel],
410387
mk_units hu
411388

412389
@[simp] lemma unit_coeff_coe {x : ℤ_[p]} (hx : x ≠ 0) :
413-
(unit_coeff hx : ℚ_[p]) = x * p ^ (-x.valuation) := rfl
390+
(unit_coeff hx : ℚ_[p]) = x * p ^ -x.valuation := rfl
414391

415392
lemma unit_coeff_spec {x : ℤ_[p]} (hx : x ≠ 0) :
416393
x = (unit_coeff hx : ℤ_[p]) * p ^ int.nat_abs (valuation x) :=
@@ -472,14 +449,12 @@ begin
472449
rw [norm_le_pow_iff_le_valuation x hx, mem_span_pow_iff_le_valuation x hx]
473450
end
474451

475-
lemma norm_le_pow_iff_norm_lt_pow_add_one (x : ℤ_[p]) (n : ℤ) :
476-
∥x∥ ≤ p ^ n ↔ ∥x∥ < p ^ (n + 1) :=
452+
lemma norm_le_pow_iff_norm_lt_pow_add_one (x : ℤ_[p]) (n : ℤ) : ∥x∥ ≤ p ^ n ↔ ∥x∥ < p ^ (n + 1) :=
477453
begin
478454
rw norm_def, exact padic.norm_le_pow_iff_norm_lt_pow_add_one _ _,
479455
end
480456

481-
lemma norm_lt_pow_iff_norm_le_pow_sub_one (x : ℤ_[p]) (n : ℤ) :
482-
∥x∥ < p ^ n ↔ ∥x∥ ≤ p ^ (n - 1) :=
457+
lemma norm_lt_pow_iff_norm_le_pow_sub_one (x : ℤ_[p]) (n : ℤ) : ∥x∥ < p ^ n ↔ ∥x∥ ≤ p ^ (n - 1) :=
483458
by rw [norm_le_pow_iff_norm_lt_pow_add_one, sub_add_cancel]
484459

485460
lemma norm_lt_one_iff_dvd (x : ℤ_[p]) : ∥x∥ < 1 ↔ ↑p ∣ x :=
@@ -523,16 +498,14 @@ begin
523498
{ exact_mod_cast hp.1.ne_zero }
524499
end
525500

526-
lemma irreducible_p : irreducible (p : ℤ_[p]) :=
527-
prime.irreducible prime_p
501+
lemma irreducible_p : irreducible (p : ℤ_[p]) := prime.irreducible prime_p
528502

529503
instance : discrete_valuation_ring ℤ_[p] :=
530504
discrete_valuation_ring.of_has_unit_mul_pow_irreducible_factorization
531505
⟨p, irreducible_p, λ x hx, ⟨x.valuation.nat_abs, unit_coeff hx,
532506
by rw [mul_comm, ← unit_coeff_spec hx]⟩⟩
533507

534-
lemma ideal_eq_span_pow_p {s : ideal ℤ_[p]} (hs : s ≠ ⊥) :
535-
∃ n : ℕ, s = ideal.span {p ^ n} :=
508+
lemma ideal_eq_span_pow_p {s : ideal ℤ_[p]} (hs : s ≠ ⊥) : ∃ n : ℕ, s = ideal.span {p ^ n} :=
536509
discrete_valuation_ring.ideal_eq_span_pow_irreducible hs irreducible_p
537510

538511
open cau_seq

0 commit comments

Comments
 (0)