Theorem: Polynomial.coeff_prod_mem_ideal_pow_tsub
File: Mathlib/RingTheory/Polynomial/Basic.lean

tactic: induction' s using Finset.induction with a s ha hs generalizing k
state_before: R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h : ∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
⊢ coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)

tactic: rw [sum_empty, prod_empty, coeff_one, zero_tsub, pow_zero, Ideal.one_eq_top]
state_before: case empty
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k✝ : ℕ
h : ∀ (i : ι), i ∈ ∅ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
⊢ coeff (Finset.prod ∅ f) k ∈ I ^ (Finset.sum ∅ n - k)

tactic: exact Submodule.mem_top
state_before: case empty
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k✝ : ℕ
h : ∀ (i : ι), i ∈ ∅ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
⊢ (if 0 = k then 1 else 0) ∈ ⊤

tactic: rw [sum_insert ha, prod_insert ha, coeff_mul]
state_before: case insert
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s✝ : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s✝ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k✝ : ℕ
a : ι
s : Finset ι
ha : ¬a ∈ s
hs :
  (∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)) →
    ∀ (k : ℕ), coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)
h : ∀ (i : ι), i ∈ insert a s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
⊢ coeff (Finset.prod (insert a s) f) k ∈ I ^ (Finset.sum (insert a s) n - k)

tactic: apply sum_mem
state_before: case insert
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s✝ : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s✝ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k✝ : ℕ
a : ι
s : Finset ι
ha : ¬a ∈ s
hs :
  (∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)) →
    ∀ (k : ℕ), coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)
h : ∀ (i : ι), i ∈ insert a s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
⊢ ∑ x in Nat.antidiagonal k, coeff (f a) x.fst * coeff (∏ x in s, f x) x.snd ∈ I ^ (n a + ∑ x in s, n x - k)

tactic: rintro ⟨i, j⟩ e
state_before: case insert.a
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s✝ : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s✝ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k✝ : ℕ
a : ι
s : Finset ι
ha : ¬a ∈ s
hs :
  (∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)) →
    ∀ (k : ℕ), coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)
h : ∀ (i : ι), i ∈ insert a s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
⊢ ∀ (c : ℕ × ℕ),
    c ∈ Nat.antidiagonal k → coeff (f a) c.fst * coeff (∏ x in s, f x) c.snd ∈ I ^ (n a + ∑ x in s, n x - k)

tactic: obtain rfl : i + j = k := Nat.mem_antidiagonal.mp e
state_before: case insert.a.mk
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s✝ : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s✝ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k✝ : ℕ
a : ι
s : Finset ι
ha : ¬a ∈ s
hs :
  (∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)) →
    ∀ (k : ℕ), coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)
h : ∀ (i : ι), i ∈ insert a s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k i j : ℕ
e : (i, j) ∈ Nat.antidiagonal k
⊢ coeff (f a) (i, j).fst * coeff (∏ x in s, f x) (i, j).snd ∈ I ^ (n a + ∑ x in s, n x - k)

tactic: apply Ideal.pow_le_pow add_tsub_add_le_tsub_add_tsub
state_before: case insert.a.mk
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s✝ : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s✝ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
a : ι
s : Finset ι
ha : ¬a ∈ s
hs :
  (∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)) →
    ∀ (k : ℕ), coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)
h : ∀ (i : ι), i ∈ insert a s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
i j : ℕ
e : (i, j) ∈ Nat.antidiagonal (i + j)
⊢ coeff (f a) (i, j).fst * coeff (∏ x in s, f x) (i, j).snd ∈ I ^ (n a + ∑ x in s, n x - (i + j))

tactic: rw [pow_add]
state_before: case insert.a.mk.a
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s✝ : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s✝ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
a : ι
s : Finset ι
ha : ¬a ∈ s
hs :
  (∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)) →
    ∀ (k : ℕ), coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)
h : ∀ (i : ι), i ∈ insert a s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
i j : ℕ
e : (i, j) ∈ Nat.antidiagonal (i + j)
⊢ coeff (f a) (i, j).fst * coeff (∏ x in s, f x) (i, j).snd ∈ I ^ (n a - i + (∑ x in s, n x - j))

tactic: exact
  Ideal.mul_mem_mul (h _ (Finset.mem_insert.mpr <| Or.inl rfl) _)
    (hs (fun i hi k => h _ (Finset.mem_insert.mpr <| Or.inr hi) _) j)
state_before: case insert.a.mk.a
R : Type u
S : Type ?u.185353
inst✝¹ : CommSemiring R
inst✝ : Semiring S
I✝ : Ideal R[X]
ι : Type u_1
s✝ : Finset ι
f : ι → R[X]
I : Ideal R
n : ι → ℕ
h✝ : ∀ (i : ι), i ∈ s✝ → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
k : ℕ
a : ι
s : Finset ι
ha : ¬a ∈ s
hs :
  (∀ (i : ι), i ∈ s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)) →
    ∀ (k : ℕ), coeff (Finset.prod s f) k ∈ I ^ (Finset.sum s n - k)
h : ∀ (i : ι), i ∈ insert a s → ∀ (k : ℕ), coeff (f i) k ∈ I ^ (n i - k)
i j : ℕ
e : (i, j) ∈ Nat.antidiagonal (i + j)
⊢ coeff (f a) (i, j).fst * coeff (∏ x in s, f x) (i, j).snd ∈ I ^ (n a - i) * I ^ (∑ x in s, n x - j)