@@ -151,6 +151,55 @@ end submodule
151
151
152
152
namespace ideal
153
153
154
+ section chinese_remainder
155
+ variables {R : Type u} [comm_ring R] {ι : Type v}
156
+
157
+ theorem exists_sub_one_mem_and_mem (s : finset ι) {f : ι → ideal R}
158
+ (hf : ∀ i ∈ s, ∀ j ∈ s, i ≠ j → f i ⊔ f j = ⊤) (i : ι) (his : i ∈ s) :
159
+ ∃ r : R, r - 1 ∈ f i ∧ ∀ j ∈ s, j ≠ i → r ∈ f j :=
160
+ begin
161
+ have : ∀ j ∈ s, j ≠ i → ∃ r : R, ∃ H : r - 1 ∈ f i, r ∈ f j,
162
+ { intros j hjs hji, specialize hf i his j hjs hji.symm,
163
+ rw [eq_top_iff_one, submodule.mem_sup] at hf,
164
+ rcases hf with ⟨r, hri, s, hsj, hrs⟩, refine ⟨1 - r, _, _⟩,
165
+ { rw [sub_right_comm, sub_self, zero_sub], exact (f i).neg_mem hri },
166
+ { rw [← hrs, add_sub_cancel'], exact hsj } },
167
+ classical,
168
+ have : ∃ g : ι → R, (∀ j, g j - 1 ∈ f i) ∧ ∀ j ∈ s, j ≠ i → g j ∈ f j,
169
+ { choose g hg1 hg2,
170
+ refine ⟨λ j, if H : j ∈ s ∧ j ≠ i then g j H.1 H.2 else 1 , λ j, _, λ j, _⟩,
171
+ { split_ifs with h, { apply hg1 }, rw sub_self, exact (f i).zero_mem },
172
+ { intros hjs hji, rw dif_pos, { apply hg2 }, exact ⟨hjs, hji⟩ } },
173
+ rcases this with ⟨g, hgi, hgj⟩, use (s.erase i).prod g, split,
174
+ { rw [← quotient.eq, quotient.mk_one, ← finset.prod_hom (quotient.mk (f i))],
175
+ apply finset.prod_eq_one, intros, rw [← quotient.mk_one, quotient.eq], apply hgi },
176
+ intros j hjs hji, rw [← quotient.eq_zero_iff_mem, ← finset.prod_hom (quotient.mk (f j))],
177
+ refine finset.prod_eq_zero (finset.mem_erase_of_ne_of_mem hji hjs) _,
178
+ rw quotient.eq_zero_iff_mem, exact hgj j hjs hji
179
+ end
180
+
181
+ /-- Chinese Remainder Theorem. Atiyah-Macdonald 1.10, Eisenbud Ex.2.6, Stacks 10.14.4 (00DT) -/
182
+ theorem exists_sub_mem [fintype ι] {f : ι → ideal R}
183
+ (hf : ∀ i j, i ≠ j → f i ⊔ f j = ⊤) (g : ι → R) :
184
+ ∃ r : R, ∀ i, r - g i ∈ f i :=
185
+ begin
186
+ have : ∃ φ : ι → R, (∀ i, φ i - 1 ∈ f i) ∧ (∀ i j, i ≠ j → φ i ∈ f j),
187
+ { have := exists_sub_one_mem_and_mem (finset.univ : finset ι) (λ i _ j _ hij, hf i j hij),
188
+ choose φ hφ, use λ i, φ i (finset.mem_univ i),
189
+ exact ⟨λ i, (hφ i _).1 , λ i j hij, (hφ i _).2 j (finset.mem_univ j) hij.symm⟩ },
190
+ rcases this with ⟨φ, hφ1 , hφ2 ⟩,
191
+ use finset.univ.sum (λ i, g i * φ i),
192
+ intros i,
193
+ rw [← quotient.eq, ← finset.sum_hom (quotient.mk (f i))],
194
+ refine eq.trans (finset.sum_eq_single i _ _) _,
195
+ { intros j _ hji, rw quotient.eq_zero_iff_mem, exact (f i).mul_mem_left (hφ2 j i hji) },
196
+ { intros hi, exact (hi $ finset.mem_univ i).elim },
197
+ specialize hφ1 i, rw [← quotient.eq, quotient.mk_one] at hφ1 ,
198
+ rw [quotient.mk_mul, hφ1 , mul_one]
199
+ end
200
+
201
+ end chinese_remainder
202
+
154
203
section mul_and_radical
155
204
variables {R : Type u} [comm_ring R]
156
205
variables {I J K L: ideal R}
0 commit comments