Buckets:
| import Mathlib | |
| import OAI.Analysis.CoulombRadii.SpectralTheory.SectorFormBottom | |
| import OAI.Analysis.CoulombRadii.FieldAnalysis.RetainedFineDensity | |
| namespace OAI | |
| open MeasureTheory Set Filter | |
| open scoped ENNReal NNReal Classical BigOperators | |
| noncomputable section | |
| namespace Coulomb | |
| def atomicAttractionExcess {ι : Type*} (Z : ℕ) (X : ι → Space) (s : Finset ι) : ℝ := | |
| (Z:ℝ) * (∑ i ∈ s, coulombKernel (X i)) - | |
| (1/2:ℝ) * (∑ i ∈ s, ∑ j ∈ s, coulombKernel (X i-X j)) | |
| lemma atomicAttractionExcess_insert {ι : Type*} [DecidableEq ι] | |
| (Z : ℕ) (X : ι → Space) (s : Finset ι) (a : ι) (ha : a ∉ s) : | |
| atomicAttractionExcess Z X (insert a s) = atomicAttractionExcess Z X s + | |
| (Z:ℝ)*coulombKernel (X a) - ∑ j ∈ s, coulombKernel (X a-X j) := by | |
| simp only [atomicAttractionExcess, Finset.sum_insert ha, sub_self, coulombKernel, norm_zero, | |
| inv_zero, zero_add] | |
| have hsym : ∀ i, ‖X i-X a‖⁻¹ = ‖X a-X i‖⁻¹ := fun i => by rw [norm_sub_rev] | |
| simp_rw [hsym] | |
| rw [Finset.sum_add_distrib] | |
| ring | |
| lemma twice_pair_kernel_ge_outer {x y : Space} (hxy : x ≠ y) (hr : ‖y‖ ≤ ‖x‖) : | |
| coulombKernel x ≤ 2*coulombKernel (x-y) := by | |
| by_cases hx : x = 0 | |
| · subst x | |
| simp only [coulombKernel, norm_zero, inv_zero] | |
| positivity | |
| have hxpos : 0 < ‖x‖ := norm_pos_iff.mpr hx | |
| have hxypos : 0 < ‖x-y‖ := norm_pos_iff.mpr (sub_ne_zero.mpr hxy) | |
| have hdist : ‖x-y‖ ≤ 2*‖x‖ := (norm_sub_le x y).trans (by linarith) | |
| have h : 1 / ‖x‖ ≤ 2 / ‖x-y‖ := | |
| (div_le_div_iff₀ hxpos hxypos).mpr (by simpa using hdist) | |
| simpa only [coulombKernel, one_div, div_eq_mul_inv, one_mul] using h | |
| lemma atomicAttractionExcess_le {ι : Type*} [DecidableEq ι] | |
| (Z : ℕ) (X : ι → Space) (hX : Function.Injective X) | |
| (A : ℝ) (hA : 0 ≤ A) (s : Finset ι) | |
| (hc : ∀ i ∈ s, coulombKernel (X i) ≤ A) : | |
| atomicAttractionExcess Z X s ≤ (Z:ℝ)*(2*Z)*A := by | |
| induction s using Finset.strongInductionOn with | |
| | _ s IH => | |
| by_cases hs : s.card ≤ 2*Z | |
| · have hp : 0 ≤ ∑ i ∈ s, ∑ j ∈ s, coulombKernel (X i-X j) := | |
| Finset.sum_nonneg fun _ _ => Finset.sum_nonneg fun _ _ => coulombKernel_nonneg _ | |
| have hsum : ∑ i ∈ s, coulombKernel (X i) ≤ (s.card:ℝ)*A := by | |
| simpa using Finset.sum_le_sum hc | |
| have hcard : (s.card:ℝ) ≤ 2*(Z:ℝ) := by exact_mod_cast hs | |
| unfold atomicAttractionExcess | |
| nlinarith [mul_le_mul_of_nonneg_left hsum (Nat.cast_nonneg Z), | |
| mul_le_mul_of_nonneg_right hcard hA] | |
| · have hne : s.Nonempty := Finset.card_pos.mp (by omega) | |
| obtain ⟨a, ha, hmax⟩ := s.exists_max_image (fun i => ‖X i‖) hne | |
| have hsmall : s.erase a ⊂ s := Finset.erase_ssubset ha | |
| have hi := IH (s.erase a) hsmall (fun i hi => hc i (Finset.mem_of_mem_erase hi)) | |
| have hrep : (Z:ℝ)*coulombKernel (X a) ≤ ∑ j ∈ s.erase a, coulombKernel (X a-X j) := by | |
| have hsum : (s.erase a).card*coulombKernel (X a) ≤ | |
| 2*(∑ j ∈ s.erase a, coulombKernel (X a-X j)) := by | |
| calc | |
| _ = ∑ _j ∈ s.erase a, coulombKernel (X a) := by simp | |
| _ ≤ ∑ j ∈ s.erase a, 2*coulombKernel (X a-X j) := by | |
| apply Finset.sum_le_sum | |
| intro j hj | |
| exact twice_pair_kernel_ge_outer (fun h => | |
| (Finset.ne_of_mem_erase hj) (hX h).symm) (hmax j (Finset.mem_of_mem_erase hj)) | |
| _ = _ := by rw [Finset.mul_sum] | |
| have hcard : 2*(Z:ℝ) ≤ ((s.erase a).card : ℝ) := by | |
| have he := Finset.card_erase_of_mem ha | |
| exact_mod_cast (show 2*Z ≤ (s.erase a).card by omega) | |
| have hp := mul_le_mul_of_nonneg_right hcard (coulombKernel_nonneg (X a)) | |
| linarith | |
| rw [← Finset.insert_erase ha, atomicAttractionExcess_insert Z X (s.erase a) a | |
| (Finset.notMem_erase a s)] | |
| linarith | |
| lemma atomicAttractionExcess_quadratic_le {n : ℕ} (Z : ℕ) | |
| (X : Fin n → Space) (hX : Function.Injective X) : | |
| atomicAttractionExcess Z X Finset.univ ≤ | |
| (1/8:ℝ)*(∑ i, (coulombKernel (X i))^2) + 8*(Z:ℝ)^4 := by | |
| let H : ℝ := ∑ i, (coulombKernel (X i))^2 | |
| have hH : 0 ≤ H := Finset.sum_nonneg fun _ _ => sq_nonneg _ | |
| have hc (i : Fin n) (_hi : i ∈ Finset.univ) : coulombKernel (X i) ≤ Real.sqrt H := | |
| Real.le_sqrt_of_sq_le (show (coulombKernel (X i))^2 ≤ H from | |
| Finset.single_le_sum (fun j _ => sq_nonneg (coulombKernel (X j))) (Finset.mem_univ i)) | |
| have h := atomicAttractionExcess_le Z X hX (Real.sqrt H) (Real.sqrt_nonneg _) Finset.univ hc | |
| have hsq := Real.sq_sqrt hH | |
| change atomicAttractionExcess Z X Finset.univ ≤ (1/8:ℝ)*H + 8*(Z:ℝ)^4 | |
| nlinarith [sq_nonneg (Real.sqrt H-8*(Z:ℝ)^2)] | |
| lemma atom_potential_excess {n : ℕ} (Z : ℕ) (hZ : 1 ≤ Z) (x : Configuration n) : | |
| nuclearPotential (atom Z hZ) x-pairPotential x = | |
| atomicAttractionExcess Z (position x) Finset.univ := by | |
| have hn : nuclearPotential (atom Z hZ) x = (Z:ℝ)*∑ i, coulombKernel (position x i) := by | |
| simp [nuclearPotential, attraction, atom, Finset.mul_sum] | |
| rw [hn, atomicAttractionExcess, ← twice_pairPotential x] | |
| ring | |
| lemma H1Vector.nuclear_square_integrable_bound {n : ℕ} (ψ : H1Vector n) | |
| (s : Spins n) (i : Fin n) (R : Space) : | |
| Integrable (fun x => (coulombKernel (position x i-R))^2*‖ψ.value s x‖^2) ∧ | |
| (∫ x, (coulombKernel (position x i-R))^2*‖ψ.value s x‖^2) ≤ | |
| 4*∑ b : Fin 3, ∫ x, ‖ψ.gradient s (i,b) x‖^2 := by | |
| have he (x : Configuration n) : (blockRadiusSq i (nuclearHardyCoordinates i R) x)⁻¹ = | |
| (coulombKernel (position x i-R))^2 := by | |
| rw [← hardyCoulomb_sq, hardyCoulomb_nuclear] | |
| simpa only [he] using ψ.hardy s i (nuclearHardyCoordinates i R) | |
| theorem atom_form_uniform_lower {n : ℕ} (Z : ℕ) (hZ : 1 ≤ Z) (ψ : H1Vector n) : | |
| -(8*(Z:ℝ)^4)*mass ψ ≤ form (atom Z hZ) ψ := by | |
| have hb (s : Spins n) : | |
| (∫ x, nuclearPotential (atom Z hZ) x*‖ψ.value s x‖^2) - | |
| (∫ x, pairPotential x*‖ψ.value s x‖^2) ≤ | |
| (1/2:ℝ)*(∑ i : Fin n, ∑ b : Fin 3, ∫ x, ‖ψ.gradient s (i,b) x‖^2) + | |
| 8*(Z:ℝ)^4*(∫ x, ‖ψ.value s x‖^2) := by | |
| have hi (i : Fin n) := ψ.nuclear_square_integrable_bound s i 0 | |
| simp only [sub_zero] at hi | |
| have hI : Integrable (fun x => (∑ i, (coulombKernel (position x i))^2)*‖ψ.value s x‖^2) := by | |
| simp_rw [Finset.sum_mul] | |
| exact integrable_finsetSum _ fun i _ => (hi i).1 | |
| have hL : Integrable (fun x => ‖ψ.value s x‖^2) := (ψ.value_L2 s).norm.integrable_sq | |
| have hB := (hI.const_mul (1/8:ℝ)).add (hL.const_mul (8*(Z:ℝ)^4)) | |
| have hN := ψ.nuclear_integrable (atom Z hZ) s | |
| have hP := ψ.pair_integrable s | |
| change Integrable (fun x => nuclearPotential (atom Z hZ) x*‖ψ.value s x‖^2) at hN | |
| change Integrable (fun x => pairPotential x*‖ψ.value s x‖^2) at hP | |
| have he : ∀ᵐ x : Configuration n, | |
| nuclearPotential (atom Z hZ) x*‖ψ.value s x‖^2-pairPotential x*‖ψ.value s x‖^2 ≤ | |
| (1/8:ℝ)*((∑ i, (coulombKernel (position x i))^2)*‖ψ.value s x‖^2) + | |
| 8*(Z:ℝ)^4*‖ψ.value s x‖^2 := by | |
| filter_upwards [ae_position_injective n] with x hx | |
| have h := mul_le_mul_of_nonneg_right (atomicAttractionExcess_quadratic_le Z (position x) hx) | |
| (sq_nonneg ‖ψ.value s x‖) | |
| rw [← atom_potential_excess Z hZ x] at h | |
| nlinarith | |
| have hh := integral_mono_ae (hN.sub hP) hB he | |
| simp only [Pi.sub_apply, Pi.add_apply] at hh | |
| rw [integral_sub hN hP, integral_add (hI.const_mul _) (hL.const_mul _), | |
| integral_const_mul, integral_const_mul] at hh | |
| have hH : (∫ x, (∑ i, (coulombKernel (position x i))^2)*‖ψ.value s x‖^2) ≤ | |
| 4*(∑ i : Fin n, ∑ b : Fin 3, ∫ x, ‖ψ.gradient s (i,b) x‖^2) := by | |
| simp_rw [Finset.sum_mul] | |
| rw [integral_finsetSum _ (fun i _ => (hi i).1), Finset.mul_sum] | |
| exact Finset.sum_le_sum fun i _ => (hi i).2 | |
| linarith | |
| have hs := Finset.sum_le_sum (s := Finset.univ) (fun s _ => hb s) | |
| simp only [Finset.sum_sub_distrib, Finset.sum_add_distrib, ← Finset.mul_sum] at hs | |
| have hk : (1/2:ℝ)*(∑ s : Spins n, ∑ i : Fin n, ∑ b : Fin 3, | |
| ∫ x, ‖ψ.gradient s (i,b) x‖^2) = kinetic ψ := by | |
| simp [kinetic, Fintype.sum_prod_type] | |
| rw [hk] at hs | |
| change nuclearEnergy (atom Z hZ) ψ - pairEnergy ψ ≤ kinetic ψ + 8*(Z:ℝ)^4*mass ψ at hs | |
| unfold form | |
| linarith | |
| lemma atom_unrestricted_bottom_lower (Z : ℕ) (hZ : 1 ≤ Z) : | |
| (-(8*(Z:ℝ)^4) : EReal) ≤ unrestrictedFormBottom (atom Z hZ) := by | |
| apply le_iInf | |
| intro n | |
| apply le_sInf | |
| rintro e ⟨ψ, _ha, hm, rfl⟩ | |
| have h := atom_form_uniform_lower Z hZ ψ | |
| rw [hm, mul_one] at h | |
| exact EReal.coe_le_coe h | |
| lemma atom_unrestricted_bottom_ne_bot (Z : ℕ) (hZ : 1 ≤ Z) : | |
| unrestrictedFormBottom (atom Z hZ) ≠ ⊥ := by | |
| intro he | |
| have h := atom_unrestricted_bottom_lower Z hZ | |
| rw [he] at h | |
| exact EReal.coe_ne_bot _ (le_bot_iff.mp h) | |
| lemma atom_unrestricted_bottom_real {n : ℕ} (Z : ℕ) (hZ : 1 ≤ Z) | |
| (ψ : H1Vector n) (ha : Antisymmetric ψ) (hm : mass ψ = 1) : | |
| ((unrestrictedFormBottom (atom Z hZ)).toReal : EReal) = unrestrictedFormBottom (atom Z hZ) := by | |
| apply EReal.coe_toReal | |
| · intro he | |
| have h := unrestrictedFormBottom_le_trial (atom Z hZ) ψ ha hm | |
| rw [he] at h | |
| exact EReal.coe_ne_top _ (top_le_iff.mp h) | |
| · exact atom_unrestricted_bottom_ne_bot Z hZ | |
| end Coulomb | |
| end | |
| end OAI | |
Xet Storage Details
- Size:
- 9.55 kB
- Xet hash:
- b960a58fad804861415cf94a9c2d2a5c20c0f7b77797d38a9a1f346cf8086dc8
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.