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

Commit aa0b274

Browse files
chore(*): split lines and move module doc measure_theory/category/Meas (#6459)
1 parent d1b7a67 commit aa0b274

File tree

12 files changed

+58
-37
lines changed

12 files changed

+58
-37
lines changed

src/deprecated/subgroup.lean

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -680,7 +680,8 @@ instance additive.simple_add_group [group G] [simple_group G] :
680680
theorem multiplicative.simple_group_iff [add_group A] :
681681
simple_group (multiplicative A) ↔ simple_add_group A :=
682682
⟨λ hs, ⟨λ N h, @simple_group.simple _ _ hs _ (by exactI multiplicative.normal_subgroup_iff.2 h)⟩,
683-
λ hs, ⟨λ N h, @simple_add_group.simple _ _ hs _ (by exactI multiplicative.normal_subgroup_iff.1 h)⟩⟩
683+
λ hs, ⟨λ N h,
684+
@simple_add_group.simple _ _ hs _ (by exactI multiplicative.normal_subgroup_iff.1 h)⟩⟩
684685

685686
instance multiplicative.simple_group [add_group A] [simple_add_group A] :
686687
simple_group (multiplicative A) := multiplicative.simple_group_iff.2 (by apply_instance)

src/deprecated/subring.lean

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ open group
1212

1313
variables {R : Type u} [ring R]
1414

15-
/-- `S` is a subring: a set containing 1 and closed under multiplication, addition and and additive inverse. -/
15+
/-- `S` is a subring: a set containing 1 and closed under multiplication, addition and additive
16+
inverse. -/
1617
class is_subring (S : set R) extends is_add_subgroup S, is_submonoid S : Prop.
1718

1819
/-- The ring structure on a subring coerced to a type. -/
@@ -130,7 +131,8 @@ begin
130131
{ rw [list.map_cons, list.sum_cons],
131132
exact ha this (ih HL.2) },
132133
replace HL := HL.1, clear ih tl,
133-
suffices : ∃ L : list R, (∀ x ∈ L, x ∈ s) ∧ (list.prod hd = list.prod L ∨ list.prod hd = -list.prod L),
134+
suffices : ∃ L : list R,
135+
(∀ x ∈ L, x ∈ s) ∧ (list.prod hd = list.prod L ∨ list.prod hd = -list.prod L),
134136
{ rcases this with ⟨L, HL', HP | HP⟩,
135137
{ rw HP, clear HP HL hd, induction L with hd tl ih, { exact h1 },
136138
rw list.forall_mem_cons at HL',

src/field_theory/chevalley_warning.lean

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ begin
7777
calc (∏ j : σ, (e a : σ → K) j ^ d j)
7878
= (e a : σ → K) i ^ d i * (∏ (j : {j // j ≠ i}), (e a : σ → K) j ^ d j) :
7979
by { rw [← e'.prod_comp, fintype.prod_sum_type, univ_unique, prod_singleton], refl }
80-
... = a ^ d i * (∏ (j : {j // j ≠ i}), (e a : σ → K) j ^ d j) : by rw equiv.subtype_equiv_codomain_symm_apply_eq
80+
... = a ^ d i * (∏ (j : {j // j ≠ i}), (e a : σ → K) j ^ d j) :
81+
by rw equiv.subtype_equiv_codomain_symm_apply_eq
8182
... = a ^ d i * (∏ j, x₀ j ^ d j) : congr_arg _ (fintype.prod_congr _ _ _) -- see below
8283
... = (∏ j, x₀ j ^ d j) * a ^ d i : mul_comm _ _,
8384
{ -- the remaining step of the calculation above
@@ -141,7 +142,8 @@ begin
141142
-- Now we prove the remaining step from the preceding calculation
142143
show (1 - f i ^ (q - 1)).total_degree ≤ (q - 1) * (f i).total_degree,
143144
calc (1 - f i ^ (q - 1)).total_degree
144-
≤ max (1 : mv_polynomial σ K).total_degree (f i ^ (q - 1)).total_degree : total_degree_sub _ _
145+
≤ max (1 : mv_polynomial σ K).total_degree (f i ^ (q - 1)).total_degree :
146+
total_degree_sub _ _
145147
... ≤ (f i ^ (q - 1)).total_degree : by simp only [max_eq_right, nat.zero_le, total_degree_one]
146148
... ≤ (q - 1) * (f i).total_degree : total_degree_pow _ _
147149
end

src/field_theory/finite/basic.lean

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ Throughout most of this file, `K` denotes a finite field
1818
and `q` is notation for the cardinality of `K`.
1919
2020
See `ring_theory.integral_domain` for the fact that the unit group of a finite field is a
21-
cyclic group, as well as the fact that every finite integral domain is a field (`field_of_integral_domain`).
21+
cyclic group, as well as the fact that every finite integral domain is a field
22+
(`field_of_integral_domain`).
2223
2324
## Main results
2425
@@ -51,8 +52,8 @@ open polynomial
5152

5253
/-- The cardinality of a field is at most `n` times the cardinality of the image of a degree `n`
5354
polynomial -/
54-
lemma card_image_polynomial_eval [decidable_eq R] [fintype R] {p : polynomial R} (hp : 0 < p.degree) :
55-
fintype.card R ≤ nat_degree p * (univ.image (λ x, eval x p)).card :=
55+
lemma card_image_polynomial_eval [decidable_eq R] [fintype R] {p : polynomial R}
56+
(hp : 0 < p.degree) : fintype.card R ≤ nat_degree p * (univ.image (λ x, eval x p)).card :=
5657
finset.card_le_mul_card_image _ _
5758
(λ a _, calc _ = (p - C a).roots.to_finset.card : congr_arg card
5859
(by simp [finset.ext_iff, mem_roots_sub_C hp])

src/field_theory/fixed.lean

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ then `findim (fixed_points G F) F = fintype.card G`.
2424
2525
## Main Definitions
2626
27-
- `fixed_points G F`, the subfield consisting of elements of `F` fixed_points by every element of `G`, where
28-
`G` is a group that acts on `F`.
27+
- `fixed_points G F`, the subfield consisting of elements of `F` fixed_points by every element of
28+
`G`, where `G` is a group that acts on `F`.
2929
3030
-/
3131

@@ -74,7 +74,8 @@ lemma linear_independent_smul_of_linear_independent {s : finset F} :
7474
linear_independent (fixed_points G F) (λ i : (↑s : set F), (i : F)) →
7575
linear_independent F (λ i : (↑s : set F), mul_action.to_fun G F i) :=
7676
begin
77-
refine finset.induction_on s (λ _, linear_independent_empty_type $ λ ⟨x⟩, x.2) (λ a s has ih hs, _),
77+
refine finset.induction_on s (λ _, linear_independent_empty_type $ λ ⟨x⟩, x.2)
78+
(λ a s has ih hs, _),
7879
rw coe_insert at hs ⊢,
7980
rw linear_independent_insert (mt mem_coe.1 has) at hs,
8081
rw linear_independent_insert' (mt mem_coe.1 has), refine ⟨ih hs.1, λ ha, _⟩,

src/field_theory/intermediate_field.lean

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,12 +147,14 @@ lemma multiset_sum_mem (m : multiset L) :
147147
(∀ a ∈ m, a ∈ S) → m.sum ∈ S :=
148148
S.to_subfield.multiset_sum_mem m
149149

150-
/-- Product of elements of an intermediate field indexed by a `finset` is in the intermediate_field. -/
150+
/-- Product of elements of an intermediate field indexed by a `finset` is in the intermediate_field.
151+
-/
151152
lemma prod_mem {ι : Type*} {t : finset ι} {f : ι → L} (h : ∀ c ∈ t, f c ∈ S) :
152153
∏ i in t, f i ∈ S :=
153154
S.to_subfield.prod_mem h
154155

155-
/-- Sum of elements in a `intermediate_field` indexed by a `finset` is in the `intermediate_field`. -/
156+
/-- Sum of elements in a `intermediate_field` indexed by a `finset` is in the `intermediate_field`.
157+
-/
156158
lemma sum_mem {ι : Type*} {t : finset ι} {f : ι → L} (h : ∀ c ∈ t, f c ∈ S) :
157159
∑ i in t, f i ∈ S :=
158160
S.to_subfield.sum_mem h

src/field_theory/primitive_element.lean

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ requires more unfolding without much obvious benefit.
2626
2727
## Tags
2828
29-
primitive element, separable field extension, separable extension, intermediate field, adjoin, exists_adjoin_simple_eq_top
29+
primitive element, separable field extension, separable extension, intermediate field, adjoin,
30+
exists_adjoin_simple_eq_top
3031
3132
-/
3233

src/field_theory/splitting_field.lean

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ section splits
2929

3030
variables (i : α →+* β)
3131

32-
/-- a polynomial `splits` iff it is zero or all of its irreducible factors have `degree` 1 -/
32+
/-- A polynomial `splits` iff it is zero or all of its irreducible factors have `degree` 1. -/
3333
def splits (f : polynomial α) : Prop :=
3434
f = 0 ∨ ∀ {g : polynomial β}, irreducible g → g ∣ f.map i → degree g = 1
3535

@@ -80,8 +80,10 @@ else or.inr $ λ p hp hpf, ((principal_ideal_ring.irreducible_iff_prime.1 hp).2.
8080

8181
lemma splits_of_splits_mul {f g : polynomial α} (hfg : f * g ≠ 0) (h : splits i (f * g)) :
8282
splits i f ∧ splits i g :=
83-
⟨or.inr $ λ g hgi hg, or.resolve_left h hfg hgi (by rw map_mul; exact dvd.trans hg (dvd_mul_right _ _)),
84-
or.inr $ λ g hgi hg, or.resolve_left h hfg hgi (by rw map_mul; exact dvd.trans hg (dvd_mul_left _ _))⟩
83+
⟨or.inr $ λ g hgi hg, or.resolve_left h hfg hgi
84+
(by rw map_mul; exact dvd.trans hg (dvd_mul_right _ _)),
85+
or.inr $ λ g hgi hg, or.resolve_left h hfg hgi
86+
(by rw map_mul; exact dvd.trans hg (dvd_mul_left _ _))⟩
8587

8688
lemma splits_of_splits_of_dvd {f g : polynomial α} (hf0 : f ≠ 0) (hf : splits i f) (hgf : g ∣ f) :
8789
splits i g :=
@@ -381,12 +383,14 @@ begin
381383
{ have hcoeff : p.leading_coeff ≠ 0,
382384
{ intro h, exact hzero (leading_coeff_eq_zero.1 h) },
383385
have hrootsnorm : (normalize p).roots.card = (normalize p).nat_degree,
384-
{ rw [roots_normalize, normalize_apply, nat_degree_mul hzero (units.ne_zero _), hroots, coe_norm_unit,
385-
nat_degree_C, add_zero], },
386-
have hprod := prod_multiset_X_sub_C_of_monic_of_roots_card_eq (monic_normalize hzero) hrootsnorm,
386+
{ rw [roots_normalize, normalize_apply, nat_degree_mul hzero (units.ne_zero _), hroots,
387+
coe_norm_unit, nat_degree_C, add_zero], },
388+
have hprod := prod_multiset_X_sub_C_of_monic_of_roots_card_eq (monic_normalize hzero)
389+
hrootsnorm,
387390
rw [roots_normalize, normalize_apply, coe_norm_unit_of_ne_zero hzero] at hprod,
388391
calc (C p.leading_coeff) * (multiset.map (λ (a : α), X - C a) p.roots).prod
389-
= p * C ((p.leading_coeff)⁻¹ * p.leading_coeff) : by rw [hprod, mul_comm, mul_assoc, ← C_mul]
392+
= p * C ((p.leading_coeff)⁻¹ * p.leading_coeff) :
393+
by rw [hprod, mul_comm, mul_assoc, ← C_mul]
390394
... = p * C 1 : by field_simp
391395
... = p : by simp only [mul_one, ring_hom.map_one], },
392396
end
@@ -495,7 +499,8 @@ end
495499
theorem factor_dvd_of_degree_ne_zero {f : polynomial α} (hf : f.degree ≠ 0) : factor f ∣ f :=
496500
factor_dvd_of_not_is_unit (mt degree_eq_zero_of_is_unit hf)
497501

498-
theorem factor_dvd_of_nat_degree_ne_zero {f : polynomial α} (hf : f.nat_degree ≠ 0) : factor f ∣ f :=
502+
theorem factor_dvd_of_nat_degree_ne_zero {f : polynomial α} (hf : f.nat_degree ≠ 0) :
503+
factor f ∣ f :=
499504
factor_dvd_of_degree_ne_zero (mt nat_degree_eq_of_degree_eq_some hf)
500505

501506
/-- Divide a polynomial f by X - C r where r is a root of f in a bigger field extension. -/
@@ -510,7 +515,8 @@ mul_div_by_monic_eq_iff_is_root.2 $ by rw [is_root.def, eval_map, hg, eval₂_mu
510515

511516
theorem nat_degree_remove_factor (f : polynomial α) :
512517
f.remove_factor.nat_degree = f.nat_degree - 1 :=
513-
by rw [remove_factor, nat_degree_div_by_monic _ (monic_X_sub_C _), nat_degree_map, nat_degree_X_sub_C]
518+
by rw [remove_factor, nat_degree_div_by_monic _ (monic_X_sub_C _), nat_degree_map,
519+
nat_degree_X_sub_C]
514520

515521
theorem nat_degree_remove_factor' {f : polynomial α} {n : ℕ} (hfn : f.nat_degree = n+1) :
516522
f.remove_factor.nat_degree = n :=
@@ -586,7 +592,8 @@ nat.rec_on n (λ α _ _ _ β _ j _, by exactI ⟨j, j.comp_id⟩) $ λ n ih α _
586592
have hndf : f.nat_degree ≠ 0, by { intro h, rw h at hf, cases hf },
587593
have hfn0 : f ≠ 0, by { intro h, rw h at hndf, exact hndf rfl },
588594
let ⟨r, hr⟩ := exists_root_of_splits _ (splits_of_splits_of_dvd j hfn0 hj
589-
(factor_dvd_of_nat_degree_ne_zero hndf)) (mt is_unit_iff_degree_eq_zero.2 f.irreducible_factor.1) in
595+
(factor_dvd_of_nat_degree_ne_zero hndf))
596+
(mt is_unit_iff_degree_eq_zero.2 f.irreducible_factor.1) in
590597
have hmf0 : map (adjoin_root.of f.factor) f ≠ 0, from map_ne_zero hfn0,
591598
have hsf : splits (adjoin_root.lift j r hr) f.remove_factor,
592599
by { rw ← X_sub_C_mul_remove_factor _ hndf at hmf0, refine (splits_of_splits_mul _ hmf0 _).2,

src/field_theory/subfield.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -446,8 +446,8 @@ lemma closure_eq_of_le {s : set K} {t : subfield K} (h₁ : s ⊆ t) (h₂ : t
446446
le_antisymm (closure_le.2 h₁) h₂
447447

448448
/-- An induction principle for closure membership. If `p` holds for `1`, and all elements
449-
of `s`, and is preserved under addition, negation, and multiplication, then `p` holds for all elements
450-
of the closure of `s`. -/
449+
of `s`, and is preserved under addition, negation, and multiplication, then `p` holds for all
450+
elements of the closure of `s`. -/
451451
@[elab_as_eliminator]
452452
lemma closure_induction {s : set K} {p : K → Prop} {x} (h : x ∈ closure s)
453453
(Hs : ∀ x ∈ s, p x) (H1 : p 1)

src/measure_theory/category/Meas.lean

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,22 @@ import topology.category.Top.basic
77
import measure_theory.giry_monad
88
import category_theory.monad.algebra
99

10-
/-
11-
* Meas, the category of measurable spaces
10+
/-!
11+
# The category of measurable spaces
12+
13+
Measurable spaces and measurable functions form a (concrete) category `Meas`.
1214
13-
Measurable spaces and measurable functions form a (concrete) category Meas.
15+
## Main definitions
1416
15-
Measure : Meas ⥤ Meas is the functor which sends a measurable space X
16-
to the space of measures on X; it is a monad (the "Giry monad").
17+
* `Measure : Meas ⥤ Meas`: the functor which sends a measurable space `X`
18+
to the space of measures on `X`; it is a monad (the "Giry monad").
1719
18-
Borel : Top ⥤ Meas sends a topological space X to X equipped with the
19-
σ-algebra of Borel sets (the σ-algebra generated by the open subsets of X).
20+
* `Borel : Top ⥤ Meas`: sends a topological space `X` to `X` equipped with the
21+
`σ`-algebra of Borel sets (the `σ`-algebra generated by the open subsets of `X`).
2022
2123
## Tags
2224
2325
measurable space, giry monad, borel
24-
2526
-/
2627

2728
noncomputable theory

0 commit comments

Comments
 (0)