case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
⊢ degreeLT R n ≤ Submodule.span R ↑(image (fun n => X ^ n) (range n))

case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
⊢ Submodule.span R ↑(image (fun n => X ^ n) (range n)) ≤ degreeLT R n
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
⊢ degreeLT R n = Submodule.span R ↑(image (fun n => X ^ n) (range n))
apply le_antisymm
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
⊢ ↑(range n) ⊆ (fun n => X ^ n) ⁻¹' ↑(degreeLT R n)
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
⊢ Submodule.span R ↑(image (fun n => X ^ n) (range n)) ≤ degreeLT R n
rw [Submodule.span_le, Finset.coe_image, Set.image_subset_iff]
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n k : ℕ
hk : k ∈ ↑(range n)
⊢ k ∈ (fun n => X ^ n) ⁻¹' ↑(degreeLT R n)
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
⊢ ↑(range n) ⊆ (fun n => X ^ n) ⁻¹' ↑(degreeLT R n)
intro k hk
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n k : ℕ
hk : k ∈ ↑(range n)
⊢ degree ((fun n => X ^ n) k) < ↑n
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n k : ℕ
hk : k ∈ ↑(range n)
⊢ k ∈ (fun n => X ^ n) ⁻¹' ↑(degreeLT R n)
apply mem_degreeLT.2
no goals
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n k : ℕ
hk : k ∈ ↑(range n)
⊢ degree ((fun n => X ^ n) k) < ↑n
exact lt_of_le_of_lt (degree_X_pow_le _) (WithBot.coe_lt_coe.2 <| Finset.mem_range.1 hk)
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : p ∈ degreeLT R n
⊢ p ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
⊢ degreeLT R n ≤ Submodule.span R ↑(image (fun n => X ^ n) (range n))
intro p hp
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
⊢ p ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : p ∈ degreeLT R n
⊢ p ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
replace hp := mem_degreeLT.1 hp
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
⊢ ∑ n in support p, ↑(monomial n) (coeff p n) ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
⊢ p ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
rw [← Polynomial.sum_monomial_eq p, Polynomial.sum]
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
k : ℕ
hk : k ∈ support p
⊢ ↑(monomial k) (coeff p k) ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
⊢ ∑ n in support p, ↑(monomial n) (coeff p n) ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
refine' Submodule.sum_mem _ fun k hk => _
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
k : ℕ
hk : k ∈ support p
this : k < n
⊢ ↑(monomial k) (coeff p k) ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
k : ℕ
hk : k ∈ support p
⊢ ↑(monomial k) (coeff p k) ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
have := WithBot.coe_lt_coe.1 ((Finset.sup_lt_iff <| WithBot.bot_lt_coe n).1 hp k hk)
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
k : ℕ
hk : k ∈ support p
this : k < n
⊢ coeff p k • X ^ k ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
k : ℕ
hk : k ∈ support p
this : k < n
⊢ ↑(monomial k) (coeff p k) ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
rw [← C_mul_X_pow_eq_monomial, C_mul']
no goals
case a
R : Type u
S : Type ?u.15171
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : degree p < ↑n
k : ℕ
hk : k ∈ support p
this : k < n
⊢ coeff p k • X ^ k ∈ Submodule.span R ↑(image (fun n => X ^ n) (range n))
refine'
  Submodule.smul_mem _ _
    (Submodule.subset_span <|
      Finset.mem_coe.2 <| Finset.mem_image.2 ⟨_, Finset.mem_range.2 this, rfl⟩)