File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -157,6 +157,7 @@ theorem C_mul : (C (a * a') : MvPolynomial σ R) = C a * C a' :=
157157theorem C_pow (a : R) (n : ℕ) : (C (a ^ n) : MvPolynomial σ R) = C a ^ n :=
158158 map_pow _ _ _
159159
160+ @ [grind inj]
160161theorem C_injective (σ : Type *) (R : Type *) [CommSemiring R] :
161162 Function.Injective (C : R → MvPolynomial σ R) :=
162163 Finsupp.single_injective _
Original file line number Diff line number Diff line change @@ -679,6 +679,7 @@ theorem C_mul_X_eq_monomial : C a * X = monomial 1 a := by rw [← C_mul_X_pow_e
679679theorem toFinsupp_C_mul_X (a : R) : (C a * X).toFinsupp = .single 1 a := by
680680 rw [C_mul_X_eq_monomial, toFinsupp_monomial]
681681
682+ @ [grind inj]
682683theorem C_injective : Injective (C : R → R[X]) :=
683684 monomial_injective 0
684685
Original file line number Diff line number Diff line change @@ -351,6 +351,16 @@ theorem coeff_C [DecidableEq σ] (n : σ →₀ ℕ) (a : R) :
351351theorem coeff_zero_C (a : R) : coeff (0 : σ →₀ ℕ) (C a) = a :=
352352 coeff_monomial_same 0 a
353353
354+ @ [grind inj]
355+ theorem C_injective : Function.Injective (C : R → MvPowerSeries σ R) := by
356+ intro a b h
357+ rw [← coeff_zero_C a, h, coeff_zero_C]
358+
359+ theorem C_surjective [IsEmpty σ] : Function.Surjective (C : R → MvPowerSeries σ R) :=
360+ fun p => ⟨p 0 , by ext n; simpa [coeff_C, Subsingleton.eq_zero n] using coeff_apply _ _⟩
361+
362+ @[simp] theorem C_inj (r s : R) : (C r : MvPowerSeries σ R) = C s ↔ r = s := (C_injective).eq_iff
363+
354364/-- The variables of the multivariate formal power series ring. -/
355365def X (s : σ) : MvPowerSeries σ R :=
356366 monomial (single s 1 ) 1
Original file line number Diff line number Diff line change @@ -192,10 +192,8 @@ theorem coeff_ne_zero_C {a : R} {n : ℕ} (h : n ≠ 0) : coeff n (C a) = 0 := b
192192theorem coeff_succ_C {a : R} {n : ℕ} : coeff (n + 1 ) (C a) = 0 :=
193193 coeff_ne_zero_C n.succ_ne_zero
194194
195- theorem C_injective : Function.Injective (C (R := R)) := by
196- intro a b H
197- simp_rw [PowerSeries.ext_iff] at H
198- simpa only [coeff_zero_C] using H 0
195+ @ [grind inj]
196+ theorem C_injective : Function.Injective (C (R := R)) := MvPowerSeries.C_injective
199197
200198protected theorem subsingleton_iff : Subsingleton R⟦X⟧ ↔ Subsingleton R := by
201199 refine ⟨fun h ↦ ?_, fun _ ↦ inferInstance⟩
You can’t perform that action at this time.
0 commit comments