@@ -11,30 +11,30 @@ import topology.metric_space.cau_seq_filter
11
11
/-!
12
12
# p-adic integers
13
13
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.
21
21
22
22
The relation between `ℤ_[p]` and `zmod p` is established in another file.
23
23
24
24
## Important definitions
25
25
26
- * `padic_int` : the type of p -adic numbers
26
+ * `padic_int` : the type of `p` -adic integers
27
27
28
28
## Notation
29
29
30
- We introduce the notation `ℤ_[p]` for the p -adic integers.
30
+ We introduce the notation `ℤ_[p]` for the `p` -adic integers.
31
31
32
32
## Implementation notes
33
33
34
34
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.
36
36
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.
38
38
39
39
## References
40
40
@@ -51,8 +51,9 @@ open padic metric local_ring
51
51
noncomputable theory
52
52
open_locale classical
53
53
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` . -/
55
55
def padic_int (p : ℕ) [fact p.prime] := {x : ℚ_[p] // ∥x∥ ≤ 1 }
56
+
56
57
notation `ℤ_ [`p `]` := padic_int p
57
58
58
59
namespace padic_int
@@ -67,7 +68,7 @@ lemma ext {x y : ℤ_[p]} : (x : ℚ_[p]) = y → x = y := subtype.ext
67
68
68
69
variables (p)
69
70
70
- /-- The padic integers as a subring of the padics -/
71
+ /-- The `p`-adic integers as a subring of `ℚ_[p]`. -/
71
72
def subring : subring (ℚ_[p]) :=
72
73
{ carrier := {x : ℚ_[p] | ∥x∥ ≤ 1 },
73
74
zero_mem' := by norm_num,
@@ -80,26 +81,25 @@ def subring : subring (ℚ_[p]) :=
80
81
81
82
variables {p}
82
83
83
- /-- Addition on ℤ_p is inherited from ℚ_p . -/
84
+ /-- Addition on `ℤ_[p]` is inherited from `ℚ_[p]` . -/
84
85
instance : has_add ℤ_[p] := (by apply_instance : has_add (subring p))
85
86
86
- /-- Multiplication on ℤ_p is inherited from ℚ_p . -/
87
+ /-- Multiplication on `ℤ_[p]` is inherited from `ℚ_[p]` . -/
87
88
instance : has_mul ℤ_[p] := (by apply_instance : has_mul (subring p))
88
89
89
- /-- Negation on ℤ_p is inherited from ℚ_p . -/
90
+ /-- Negation on `ℤ_[p]` is inherited from `ℚ_[p]` . -/
90
91
instance : has_neg ℤ_[p] := (by apply_instance : has_neg (subring p))
91
92
92
- /-- Subtraction on ℤ_p is inherited from ℚ_p . -/
93
+ /-- Subtraction on `ℤ_[p]` is inherited from `ℚ_[p]` . -/
93
94
instance : has_sub ℤ_[p] := (by apply_instance : has_sub (subring p))
94
95
95
- /-- Zero on ℤ_p is inherited from ℚ_p . -/
96
+ /-- Zero on `ℤ_[p]` is inherited from `ℚ_[p]` . -/
96
97
instance : has_zero ℤ_[p] := (by apply_instance : has_zero (subring p))
97
98
98
99
instance : inhabited ℤ_[p] := ⟨0 ⟩
99
100
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⟩⟩
103
103
104
104
@[simp] lemma mk_zero {h} : (⟨0 , h⟩ : ℤ_[p]) = (0 : ℤ_[p]) := rfl
105
105
@@ -121,17 +121,17 @@ instance : comm_ring ℤ_[p] :=
121
121
@[simp, norm_cast] lemma coe_nat_cast (n : ℕ) : ((n : ℤ_[p]) : ℚ_[p]) = n := rfl
122
122
@[simp, norm_cast] lemma coe_int_cast (z : ℤ) : ((z : ℤ_[p]) : ℚ_[p]) = z := rfl
123
123
124
- /-- The coercion from ℤ [ p ] to ℚ [ p ] as a ring homomorphism. -/
124
+ /-- The coercion from `ℤ_ [p]` to `ℚ_ [p]` as a ring homomorphism. -/
125
125
def coe.ring_hom : ℤ_[p] →+* ℚ_[p] := (subring p).subtype
126
126
127
127
@[simp, norm_cast] lemma coe_pow (x : ℤ_[p]) (n : ℕ) : (↑(x^n) : ℚ_[p]) = (↑x : ℚ_[p])^n := rfl
128
128
129
129
@[simp] lemma mk_coe (k : ℤ_[p]) : (⟨k, k.2 ⟩ : ℤ_[p]) = k := subtype.coe_eta _ _
130
130
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` . -/
133
133
def inv : ℤ_[p] → ℤ_[p]
134
- | ⟨k, _⟩ := if h : ∥k∥ = 1 then ⟨1 /k , by simp [h]⟩ else 0
134
+ | ⟨k, _⟩ := if h : ∥k∥ = 1 then ⟨k⁻¹ , by simp [h]⟩ else 0
135
135
136
136
instance : char_zero ℤ_[p] :=
137
137
{ cast_injective :=
@@ -142,10 +142,8 @@ instance : char_zero ℤ_[p] :=
142
142
suffices (z1 : ℚ_[p]) = z2 ↔ z1 = z2, from iff.trans (by norm_cast) this ,
143
143
by norm_cast
144
144
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. -/
149
147
def of_int_seq (seq : ℕ → ℤ) (h : is_cau_seq (padic_norm p) (λ n, seq n)) : ℤ_[p] :=
150
148
⟨⟦⟨_, h⟩⟧,
151
149
show ↑(padic_seq.norm _) ≤ (1 : ℝ), begin
@@ -194,12 +192,11 @@ instance is_absolute_value : is_absolute_value (λ z : ℤ_[p], ∥z∥) :=
194
192
{ abv_nonneg := norm_nonneg,
195
193
abv_eq_zero := λ ⟨_, _⟩, by simp [norm_eq_zero],
196
194
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] }
198
196
199
197
variables {p}
200
198
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
203
200
204
201
end padic_int
205
202
@@ -211,64 +208,53 @@ variables {p : ℕ} [fact p.prime]
211
208
212
209
lemma norm_le_one (z : ℤ_[p]) : ∥z∥ ≤ 1 := z.2
213
210
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]
216
212
217
- @[simp] lemma norm_pow (z : ℤ_[p]) : ∀ n : ℕ, ∥z^ n∥ = ∥z∥^ n
213
+ @[simp] lemma norm_pow (z : ℤ_[p]) : ∀ n : ℕ, ∥z ^ n∥ = ∥z∥ ^ n
218
214
| 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 }
220
216
221
217
theorem nonarchimedean (q r : ℤ_[p]) : ∥q + r∥ ≤ max (∥q∥) (∥r∥) := padic_norm_e.nonarchimedean _ _
222
218
223
219
theorem norm_add_eq_max_of_ne {q r : ℤ_[p]} : ∥q∥ ≠ ∥r∥ → ∥q+r∥ = max (∥q∥) (∥r∥) :=
224
220
padic_norm_e.add_eq_max_of_ne
225
221
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
230
224
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
235
227
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]
238
229
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]
241
231
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
244
233
245
234
@[simp] lemma norm_p : ∥(p : ℤ_[p])∥ = p⁻¹ := padic_norm_e.norm_p
246
235
247
236
@[simp] lemma norm_p_pow (n : ℕ) : ∥(p : ℤ_[p])^n∥ = p^(-n:ℤ) := padic_norm_e.norm_p_pow n
248
237
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ε ⟩
253
240
254
241
variables (p)
255
242
256
243
instance complete : cau_seq.is_complete ℤ_[p] norm :=
257
244
⟨ λ f,
258
245
have hqn : ∥cau_seq.lim (cau_seq_to_rat_cau_seq f)∥ ≤ 1 ,
259
246
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) ε⟩⟩
262
248
263
249
end padic_int
264
250
265
251
namespace padic_int
266
252
267
253
variables (p : ℕ) [hp : fact p.prime]
254
+
268
255
include hp
269
256
270
- lemma exists_pow_neg_lt {ε : ℝ} (hε : 0 < ε) :
271
- ∃ (k : ℕ), ↑p ^ -((k : ℕ) : ℤ) < ε :=
257
+ lemma exists_pow_neg_lt {ε : ℝ} (hε : 0 < ε) : ∃ k : ℕ, ↑p ^ -(k : ℤ) < ε :=
272
258
begin
273
259
obtain ⟨k, hk⟩ := exists_nat_gt ε⁻¹,
274
260
use k,
@@ -282,8 +268,7 @@ begin
282
268
{ exact_mod_cast hp.1 .pos }
283
269
end
284
270
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 : ℤ) < ε :=
287
272
begin
288
273
obtain ⟨k, hk⟩ := @exists_pow_neg_lt p _ ε (by exact_mod_cast hε),
289
274
use k,
@@ -297,31 +282,27 @@ lemma norm_int_lt_one_iff_dvd (k : ℤ) : ∥(k : ℤ_[p])∥ < 1 ↔ (p : ℤ)
297
282
suffices ∥(k : ℚ_[p])∥ < 1 ↔ ↑p ∣ k, by rwa norm_int_cast_eq_padic_norm,
298
283
padic_norm_e.norm_int_lt_one_iff_dvd k
299
284
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,
302
287
by simpa [norm_int_cast_eq_padic_norm], padic_norm_e.norm_int_le_pow_iff_dvd _ _
303
288
304
289
/-! ### Valuation on `ℤ_[p]` -/
305
290
306
- /-- `padic_int.valuation` lifts the p -adic valuation on `ℚ` to `ℤ_[p]`. -/
291
+ /-- `padic_int.valuation` lifts the `p` -adic valuation on `ℚ` to `ℤ_[p]`. -/
307
292
def valuation (x : ℤ_[p]) := padic.valuation (x : ℚ_[p])
308
293
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 :=
311
295
begin
312
296
convert padic.norm_eq_pow_val _,
313
297
contrapose! hx,
314
298
exact subtype.val_injective hx
315
299
end
316
300
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
319
302
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
322
304
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]
325
306
326
307
lemma valuation_nonneg (x : ℤ_[p]) : 0 ≤ x.valuation :=
327
308
begin
@@ -368,8 +349,7 @@ lemma mul_inv : ∀ {z : ℤ_[p]}, ∥z∥ = 1 → z * z.inv = 1
368
349
simp [mul_inv_cancel hk]
369
350
end
370
351
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]
373
353
374
354
lemma is_unit_iff {z : ℤ_[p]} : is_unit z ↔ ∥z∥ = 1 :=
375
355
⟨λ h, begin
@@ -383,8 +363,8 @@ lemma norm_lt_one_add {z1 z2 : ℤ_[p]} (hz1 : ∥z1∥ < 1) (hz2 : ∥z2∥ < 1
383
363
lt_of_le_of_lt (nonarchimedean _ _) (max_lt hz1 hz2)
384
364
385
365
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
388
368
389
369
@[simp] lemma mem_nonunits {z : ℤ_[p]} : z ∈ nonunits ℤ_[p] ↔ ∥z∥ < 1 :=
390
370
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]
393
373
def mk_units {u : ℚ_[p]} (h : ∥u∥ = 1 ) : ℤ_[p]ˣ :=
394
374
let z : ℤ_[p] := ⟨u, le_of_eq h⟩ in ⟨z, z.inv, mul_inv h, inv_mul h⟩
395
375
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
399
377
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
402
379
403
380
/-- `unit_coeff hx` is the unit `u` in the unique representation `x = u * p ^ n`.
404
381
See `unit_coeff_spec`. -/
405
382
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
407
384
have hu : ∥u∥ = 1 ,
408
385
by simp [hx, nat.zpow_ne_zero_of_pos (by exact_mod_cast hp.1 .pos) x.valuation,
409
386
norm_eq_pow_val, zpow_neg, inv_mul_cancel],
410
387
mk_units hu
411
388
412
389
@[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
414
391
415
392
lemma unit_coeff_spec {x : ℤ_[p]} (hx : x ≠ 0 ) :
416
393
x = (unit_coeff hx : ℤ_[p]) * p ^ int.nat_abs (valuation x) :=
@@ -472,14 +449,12 @@ begin
472
449
rw [norm_le_pow_iff_le_valuation x hx, mem_span_pow_iff_le_valuation x hx]
473
450
end
474
451
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 ) :=
477
453
begin
478
454
rw norm_def, exact padic.norm_le_pow_iff_norm_lt_pow_add_one _ _,
479
455
end
480
456
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 ) :=
483
458
by rw [norm_le_pow_iff_norm_lt_pow_add_one, sub_add_cancel]
484
459
485
460
lemma norm_lt_one_iff_dvd (x : ℤ_[p]) : ∥x∥ < 1 ↔ ↑p ∣ x :=
@@ -523,16 +498,14 @@ begin
523
498
{ exact_mod_cast hp.1 .ne_zero }
524
499
end
525
500
526
- lemma irreducible_p : irreducible (p : ℤ_[p]) :=
527
- prime.irreducible prime_p
501
+ lemma irreducible_p : irreducible (p : ℤ_[p]) := prime.irreducible prime_p
528
502
529
503
instance : discrete_valuation_ring ℤ_[p] :=
530
504
discrete_valuation_ring.of_has_unit_mul_pow_irreducible_factorization
531
505
⟨p, irreducible_p, λ x hx, ⟨x.valuation.nat_abs, unit_coeff hx,
532
506
by rw [mul_comm, ← unit_coeff_spec hx]⟩⟩
533
507
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} :=
536
509
discrete_valuation_ring.ideal_eq_span_pow_irreducible hs irreducible_p
537
510
538
511
open cau_seq
0 commit comments