math / data /lean /OAI /Geometry /HeilbronnTriangle /AffineShellCount.lean
introvoyz045's picture
Migrated from GitHub
4a56cd6 verified
Raw History Blame Contribute Delete
2.4 kB
import Mathlib
namespace OAI
namespace Problem355.ZeroShell
open scoped BigOperators
theorem affine_shell_sum_le {Ξ± : Type*} (S : Finset Ξ±)
(f g len J : Ξ± β†’ ℝ) (R I A C : ℝ)
(hR : 0 < R) (hI : 0 < I) (hA : 0 ≀ A)
(hg : βˆ€ x ∈ S, 0 < g x) (hlen : βˆ€ x ∈ S, R ≀ len x)
(hJ : βˆ€ x ∈ S, J x = I * len x / g x)
(hf : βˆ€ x ∈ S, f x ≀ A / (J x) ^ 3)
(hmoment : βˆ‘ x ∈ S, (g x) ^ 3 ≀ C * R ^ 3 * I) :
βˆ‘ x ∈ S, f x ≀ A * C / I ^ 2 := by
have hpoint : βˆ€ x ∈ S, f x ≀ (A / (I ^ 3 * R ^ 3)) * (g x) ^ 3 := by
intro x hx
have hgx := hg x hx
have hlx : 0 < len x := lt_of_lt_of_le hR (hlen x hx)
have hlen3 : R ^ 3 ≀ (len x) ^ 3 := pow_le_pow_leftβ‚€ hR.le (hlen x hx) 3
have hden : I ^ 3 * R ^ 3 ≀ I ^ 3 * (len x) ^ 3 :=
mul_le_mul_of_nonneg_left hlen3 (pow_nonneg hI.le 3)
calc
f x ≀ A / (J x) ^ 3 := hf x hx
_ = (A * (g x) ^ 3) / (I ^ 3 * (len x) ^ 3) := by
rw [hJ x hx]
field_simp
_ ≀ (A * (g x) ^ 3) / (I ^ 3 * R ^ 3) :=
div_le_div_of_nonneg_left (by positivity) (by positivity) hden
_ = (A / (I ^ 3 * R ^ 3)) * (g x) ^ 3 := by ring
calc
(βˆ‘ x ∈ S, f x) ≀ βˆ‘ x ∈ S, (A / (I ^ 3 * R ^ 3)) * (g x) ^ 3 :=
Finset.sum_le_sum hpoint
_ = (A / (I ^ 3 * R ^ 3)) * βˆ‘ x ∈ S, (g x) ^ 3 := by rw [Finset.mul_sum]
_ ≀ (A / (I ^ 3 * R ^ 3)) * (C * R ^ 3 * I) :=
mul_le_mul_of_nonneg_left hmoment (by positivity)
_ = A * C / I ^ 2 := by
field_simp
theorem uniform_shell_sum_le {Ξ± : Type*} (S : Finset Ξ±)
(f g len J : Ξ± β†’ ℝ) (R I A C H : ℝ)
(hR : 0 < R) (hI : 0 < I) (hA : 0 ≀ A) (hH : 0 ≀ H)
(hg : βˆ€ x ∈ S, 0 < g x) (hlen : βˆ€ x ∈ S, R ≀ len x)
(hJ : βˆ€ x ∈ S, J x = I * len x / g x)
(hf : βˆ€ x ∈ S, f x ≀ A / (J x) ^ 3)
(hdivisor : βˆ€ x ∈ S, (g x) ^ 3 ≀ H * I)
(hcard : (S.card : ℝ) ≀ C * R ^ 3) :
βˆ‘ x ∈ S, f x ≀ A * (C * H) / I ^ 2 := by
apply affine_shell_sum_le S f g len J R I A (C * H) hR hI hA hg hlen hJ hf
calc
(βˆ‘ x ∈ S, (g x) ^ 3) ≀ βˆ‘ _x ∈ S, H * I := Finset.sum_le_sum hdivisor
_ = (S.card : ℝ) * (H * I) := by simp [nsmul_eq_mul]
_ ≀ (C * R ^ 3) * (H * I) := mul_le_mul_of_nonneg_right hcard (mul_nonneg hH hI.le)
_ = C * H * R ^ 3 * I := by ring
end Problem355.ZeroShell
end OAI