@@ -47,9 +47,8 @@ lemma eval_T_real_chebyshevNode {n i : ℕ} (hn : n ≠ 0) :
4747
4848lemma strictAntiOn_chebyshevNode (n : ℕ) :
4949 StrictAntiOn (chebyshevNode n ·) (Finset.range (n + 1 )) := by
50- wlog hn : n ≠ 0
51- · push_neg at hn
52- simp [hn]
50+ wlog! hn : n ≠ 0
51+ · simp [hn]
5352 refine strictAntiOn_cos.comp_strictMonoOn ?_ (fun x hx => Set.mem_Icc.mpr ⟨by positivity, ?_⟩)
5453 · apply StrictMono.strictMonoOn
5554 exact StrictMono.mul_const
@@ -67,9 +66,8 @@ lemma chebyshevNode_lt {n i j : ℕ} (hi : i ≤ n) (hj : j ≤ n) (hij : i < j)
6766lemma zero_lt_prod_chebyshevNode_sub_chebyshevNode {n i : ℕ} (hi : i ≤ n) :
6867 0 < (-1 ) ^ i * ∏ j ∈ (Finset.range (n + 1 )).erase i, (chebyshevNode n i - chebyshevNode n j) :=
6968 by
70- wlog hn : n ≠ 0
71- · push_neg at hn
72- replace hi : i = 0 := Nat.le_zero.mp (le_of_le_of_eq hi hn)
69+ wlog! hn : n ≠ 0
70+ · replace hi : i = 0 := Nat.le_zero.mp (le_of_le_of_eq hi hn)
7371 simp [hn, hi]
7472 have h₁ : 0 < ∏ j ∈ Finset.range i, ((-1 ) * (chebyshevNode n i - chebyshevNode n j)) :=
7573 Finset.prod_pos (fun j hj => mul_pos_of_neg_of_neg neg_one_lt_zero <| sub_neg.mpr <|
@@ -99,9 +97,8 @@ theorem apply_le_apply_T_real {n : ℕ} {param : ℝ[X] → ℝ} {c : ℕ →
9997 (hcnonneg : ∀ i ≤ n, 0 ≤ (-1 ) ^ i * (c i))
10098 {P : ℝ[X]} (hPdeg : P.degree = n) (hPbnd : ∀ x ∈ Set.Icc (-1 ) 1 , P.eval x ∈ Set.Icc (-1 ) 1 ) :
10199 param P ≤ param (T ℝ n) := by
102- wlog hn : n ≠ 0
103- · push_neg at hn
104- rw [hparam P hPdeg, hparam (T ℝ n) (degree_T ℝ n), hn, show Finset.Iic 0 = {0 } by rfl,
100+ wlog! hn : n ≠ 0
101+ · rw [hparam P hPdeg, hparam (T ℝ n) (degree_T ℝ n), hn, show Finset.Iic 0 = {0 } by rfl,
105102 Nat.cast_zero, T_zero, Finset.sum_singleton, Finset.sum_singleton, chebyshevNode_eq_one,
106103 eval_one]
107104 exact mul_le_mul_of_nonneg_right (hPbnd 1 (by simp) |> Set.mem_Icc.mp).2
@@ -127,9 +124,8 @@ theorem apply_eq_apply_T_real_iff {n : ℕ} {param : ℝ[X] → ℝ} {c : ℕ
127124 {P : ℝ[X]} (hPdeg : P.degree = n) (hPbnd : ∀ x ∈ Set.Icc (-1 ) 1 , P.eval x ∈ Set.Icc (-1 ) 1 ) :
128125 (param P = param (T ℝ n)) ↔ P = T ℝ n := by
129126 refine ⟨fun h => ?_, by intro h; rw [h]⟩
130- wlog hn : n ≠ 0
131- · push_neg at hn
132- rw [hparam P hPdeg, hparam (T ℝ n) (degree_T ℝ n), hn, show Finset.Iic 0 = {0 } by rfl,
127+ wlog! hn : n ≠ 0
128+ · rw [hparam P hPdeg, hparam (T ℝ n) (degree_T ℝ n), hn, show Finset.Iic 0 = {0 } by rfl,
133129 Nat.cast_zero, T_zero, Finset.sum_singleton, Finset.sum_singleton, chebyshevNode_eq_one,
134130 eval_one, one_mul] at h
135131 rw [hn, Nat.cast_zero] at hPdeg
0 commit comments