finish poly_shifting

This commit is contained in:
chelseaandmadrid 2023-06-16 12:20:24 -07:00
parent 5f0bf3b066
commit 24d2f8e1f0

View file

@ -15,6 +15,7 @@ macro "obviously" : tactic =>
| simp; tauto; done; dbg_trace "it was simp tauto" | simp; tauto; done; dbg_trace "it was simp tauto"
| rfl; done; dbg_trace "it was rfl" | rfl; done; dbg_trace "it was rfl"
| norm_num; done; dbg_trace "it was norm_num" | norm_num; done; dbg_trace "it was norm_num"
| norm_cast; done; dbg_trace "it was norm_cast"
| /-change (@Eq _ _);-/ linarith; done; dbg_trace "it was linarith" | /-change (@Eq _ _);-/ linarith; done; dbg_trace "it was linarith"
-- | gcongr; done -- | gcongr; done
| ring; done; dbg_trace "it was ring" | ring; done; dbg_trace "it was ring"
@ -84,7 +85,7 @@ lemma Polynomial_shifting (F : Polynomial ) (s : ) : ∃ (G : Polynomial
sorry sorry
-- Shifting doesn't change the polynomial type -- Shifting doesn't change the polynomial type
lemma Poly_shifting (f : ) (g : ) (hf : PolyType f d) (s : ) (hfg : ∀ (n : ), f (n + s) = g (n)) : PolyType g d := by lemma Poly_shifting (f : ) (g : ) (hf : PolyType f d) (s : ) (hfg : ∀ (n : ), f (n + s) = g (n)) : PolyType g d := by
simp only [PolyType] simp only [PolyType]
rcases hf with ⟨F, hh⟩ rcases hf with ⟨F, hh⟩
rcases hh with ⟨N,s1, s2⟩ rcases hh with ⟨N,s1, s2⟩
@ -97,9 +98,15 @@ lemma Poly_shifting (f : ) (g : ) (hf : PolyType f d) (s :
· intro n · intro n
specialize s1 (n + s) specialize s1 (n + s)
intro hN intro hN
have this1 : f (n + s) = Polynomial.eval (n + s : ) F := by have this1 : f (n + s) = Polynomial.eval (n + (s : )) F := by
sorry have this2 : N ≤ n + s := by linarith
sorry have this3 : ↑(f (n + ↑s)) = Polynomial.eval (↑(n + ↑s)) F := by tauto
rw [this3]
norm_cast
specialize hfg n
rw [←hfg, this1]
specialize h1 n
tauto
· rw [h2, s2] · rw [h2, s2]
-- PolyType 0 = constant function -- PolyType 0 = constant function
@ -241,6 +248,9 @@ lemma b_to_a (f : ) (d : ) (poly : PolyType f d) :
rw [←PolyType_0]; exact Δ_d_PolyType_d_to_PolyType_0 f d poly rw [←PolyType_0]; exact Δ_d_PolyType_d_to_PolyType_0 f d poly
end end
-- @Additive lemma of length for a SES -- @Additive lemma of length for a SES
-- Given a SES 0 → A → B → C → 0, then length (A) - length (B) + length (C) = 0 -- Given a SES 0 → A → B → C → 0, then length (A) - length (B) + length (C) = 0
section section