roseking's picture
Add lean source and binary files (part 16)
159357f verified
Raw History Blame Contribute Delete
14.8 kB
136
lemma integral_one_position (f : Space → ℝ) :
    (∫ x : Configuration 1, f (x 0)) = ∫ y, f y := by
proof · 2 lines
  exact (volume_preserving_funUnique (Fin 1) Space).integral_comp
    (MeasurableEquiv.funUnique (Fin 1) Space).measurableEmbedding f
141
lemma integral_one_configuration (f : Configuration 1 → ℝ) :
    (∫ y : Space, f (fun _ => y)) = ∫ x, f x := by
proof · 3 lines
  exact ((volume_preserving_funUnique (Fin 1) Space).symm
    (MeasurableEquiv.funUnique (Fin 1) Space)).integral_comp
    (MeasurableEquiv.funUnique (Fin 1) Space).symm.measurableEmbedding f
147
def packetDensity (y : Space) (R : ℝ) (x : Space) : ℝ :=
body · 1 line
  ∑ s : Spins 1, ‖(radialLocalOrbital y R).value s (fun _ => x)‖^2
150
lemma packetDensity_formula (y : Space) (R : ℝ) (x : Space) :
    packetDensity y R x = (Fintype.card (Spins 1) : ℝ) *
      (Real.sqrt (formMass (radialScaledRaw R)))⁻¹ ^ 2 *
      ‖radialPacketBase (R⁻¹ • (x-y))‖^2 := by
proof · 4 lines
  simp only [packetDensity,radialLocalOrbital,scaleForm,norm_real_mul_sq,radialLocalRaw_mass]
  simp only [radialLocalRaw,smoothForm,radialLocalSeed,radialScaledSeed,
    radialPacketSeed,radialCenterShift,Pi.smul_apply,Pi.add_apply,Finset.sum_const,
    Finset.card_univ,nsmul_eq_mul,sub_eq_add_neg,mul_assoc]
159
lemma packetDensity_continuous (y : Space) (R : ℝ) : Continuous (packetDensity y R) := by
proof · 7 lines
  change Continuous (fun x => packetDensity y R x)
  simp_rw [packetDensity_formula]
  have hc : Continuous (fun x : Space => R⁻¹ • (x-y)) :=
    (continuous_id.sub continuous_const).const_smul R⁻¹
  have hn : Continuous (fun x : Space => ‖radialPacketBase (R⁻¹ • (x-y))‖^2) :=
    (radialPacketBase_smooth.continuous.comp hc).norm.pow 2
  exact continuous_const.mul hn
168
lemma packetDensity_support (y : Space) {R : ℝ} (hR : 0 < R) {x : Space}
    (hx : packetDensity y R x ≠ 0) : ‖x-y‖ ≤ R := by
proof · 7 lines
  by_contra hh
  have hz := radialLocalOrbital_zero y hR (x := fun _ => x) (not_le.mp hh)
  apply hx
  unfold packetDensity
  apply Finset.sum_eq_zero
  intro s _
  rw [(hz s).1,norm_zero,zero_pow (by decide : (2:ℕ) ≠ 0)]
178
lemma packetDensity_compact (y : Space) {R : ℝ} (hR : 0 < R) :
    HasCompactSupport (packetDensity y R) := by
proof · 3 lines
  apply HasCompactSupport.of_support_subset_isCompact (isCompact_closedBall y R)
  intro x hx
  exact (Metric.mem_closedBall).mpr (packetDensity_support y hR hx)
184
lemma packetDensity_integrable (y : Space) {R : ℝ} (hR : 0 < R) :
    Integrable (packetDensity y R) :=
proof · 1 line
  (packetDensity_continuous y R).integrable_of_hasCompactSupport (packetDensity_compact y hR)
188
lemma packetDensity_memLp (y : Space) {R : ℝ} (hR : 0 < R) :
    MemLp (packetDensity y R) (5/3) :=
proof · 1 line
  (packetDensity_continuous y R).memLp_of_hasCompactSupport (packetDensity_compact y hR)
192
lemma packetDensity_mass (y : Space) {R : ℝ} (hR : 0 < R) :
    (∫ x, packetDensity y R x) = 1 := by
proof · 12 lines
  have hm := (radialLocalOrbital_admissible y hR).2.2.2.2.1
  change formMass (radialLocalOrbital y R) = 1 at hm
  rw [← hm]
  unfold packetDensity formMass
  rw [integral_finsetSum]
  · apply Finset.sum_congr rfl
    intro s _
    exact integral_one_configuration (fun x => ‖(radialLocalOrbital y R).value s x‖^2)
  · intro s _
    have hh := ((radialLocalOrbital_admissible y hR).1 s).integrable_norm_pow (by norm_num)
    exact ((volume_preserving_funUnique (Fin 1) Space).symm
        (MeasurableEquiv.funUnique (Fin 1) Space)).integrable_comp_of_integrable hh
207
lemma packetDensity_translate (y : Space) (R : ℝ) (x : Space) :
    packetDensity y R x = packetDensity 0 R (x-y) := by
proof · 1 line
  simp only [packetDensity_formula,sub_zero]
211
lemma packetDensity_radial (R : ℝ) : CoulombAnalysis.IsRadial (packetDensity 0 R) := by
proof · 2 lines
  intro x y hxy
  simp only [packetDensity_formula,sub_zero,radialPacketBase,norm_smul,hxy]
215
theorem packetDensity_potential (y : Space) {R : ℝ} (hR : 0 < R)
    {z : Space} (hz : R < ‖z-y‖) :
    (∫ x, packetDensity y R x / ‖z-x‖) = 1 / ‖z-y‖ := by
proof · 15 lines
  have ht := integral_add_right_eq_self (μ := volume)
    (fun x : Space => packetDensity y R x / ‖z-x‖) y
  rw [← ht]
  have he : (fun x => packetDensity y R (x+y) / ‖z-(x+y)‖) =
      (fun x => packetDensity 0 R x / ‖(z-y)-x‖) := by
    funext x
    rw [packetDensity_translate,add_sub_cancel_right]
    congr 2
    abel
  rw [he]
  have hn := CoulombAnalysis.tfPotential_newton_exterior
    (packetDensity_integrable 0 hR) (packetDensity_memLp 0 hR) (packetDensity_radial R)
    hR.le (fun x hx => by simpa only [sub_zero] using packetDensity_support 0 hR hx) hz
  rw [packetDensity_mass 0 hR] at hn
  exact hn
234
lemma packetDensity_eq_two (y : Space) (R : ℝ) (x : Space) (s : Spins 1) :
    packetDensity y R x = 2 * ‖(radialLocalOrbital y R).value s (fun _ => x)‖^2 := by
proof · 3 lines
  simp only [packetDensity,radialLocalOrbital,scaleForm,radialLocalRaw,smoothForm,
    Finset.sum_const,Finset.card_univ,nsmul_eq_mul]
  congr 1
240
lemma radialLocalOrbital_value_config (y : Space) (R : ℝ) (s : Spins 1)
    (x : Configuration 1) :
    (radialLocalOrbital y R).value s x =
      (radialLocalOrbital y R).value s (fun _ => x 0) := by
proof · 3 lines
  congr 1
  funext i
  exact congrArg x (Subsingleton.elim i 0)
248
lemma radialLocalOrbital_potential (y : Space) {R : ℝ} (hR : 0 < R)
    {z : Space} (hz : R < ‖z-y‖) (s : Spins 1) :
    (∫ x : Configuration 1, ‖(radialLocalOrbital y R).value s x‖^2 / ‖z-x 0‖) =
      (1/2 : ℝ) / ‖z-y‖ := by
proof · 10 lines
  have ht := packetDensity_potential y hR hz
  simp_rw [packetDensity_eq_two y R _ s,mul_div_assoc] at ht
  rw [integral_const_mul] at ht
  have he : (∫ x : Configuration 1, ‖(radialLocalOrbital y R).value s x‖^2 / ‖z-x 0‖) =
      ∫ v : Space, ‖(radialLocalOrbital y R).value s (fun _ => v)‖^2 / ‖z-v‖ := by
    rw [← integral_one_configuration]
  rw [he]
  calc
    _ = (1 / ‖z-y‖) / 2 := by linarith
    _ = _ := by ring
263
lemma radialLocalOrbital_nuclear (y : Space) {R : ℝ} (hR : 0 < R)
    (hy : R < ‖y‖) : formNuclear (radialLocalOrbital y R) = 1 / ‖y‖ := by
proof · 7 lines
  have hh (s : Spins 1) := radialLocalOrbital_potential y hR
    (z := 0) (by simpa only [zero_sub,norm_neg] using hy) s
  simp only [zero_sub,norm_neg] at hh
  unfold formNuclear
  simp only [Fin.sum_univ_one,hh,Finset.sum_const,Finset.card_univ,nsmul_eq_mul]
  norm_num [Spins]
  ring
273
lemma integral_join_left {N M : ℕ} {f : Configuration (N+M) → ℝ}
    (hf : Integrable f) :
    (∫ x : Configuration N, ∫ y : Configuration M, f (joinLists x y)) = ∫ z, f z := by
proof · 6 lines
  have hj := integrable_join (N := N) (M := M) hf
  have he := (configurationJoin_preserving N M).integral_comp
    (configurationJoin N M).toHomeomorph.measurableEmbedding f
  simp only [configurationJoin_apply_prod] at he
  rw [Measure.volume_eq_prod] at hj he
  exact (integral_prod _ hj).symm.trans he
283
def coreCoulombAt {N : ℕ} (ψ : FormVector N) (y : Space) : ℝ :=
body · 1 line
  ∑ s : Spins N, ∑ i : Fin N, ∫ x, ‖ψ.value s x‖^2 / ‖x i-y‖
286
lemma tensor_packet_pair {N : ℕ} {ψ : FormVector N} (hψ : SobolevVector ψ)
    (y : Space) {R B : ℝ} (hR : 0 < R) (hRB : R < B)
    (hc : ∀ x i, ‖x i-y‖ < B → FormZeroAt ψ x)
    (s : Spins N) (t : Spins 1) (i : Fin N) :
    (∫ z, ‖(tensorForm ψ (radialLocalOrbital y R)).value (joinLists s t) z‖^2 /
      ‖z i.castSucc-z (Fin.last N)‖) =
      (1/2 : ℝ) * ∫ x, ‖ψ.value s x‖^2 / ‖x i-y‖ := by
proof · 21 lines
  have hφ := (radialLocalOrbital_admissible y hR).sobolevFermion.sobolevVector
  have hT := hψ.tensor hφ
  have hi := pair_integrable i.castSucc (Fin.last N) (Fin.castSucc_ne_last i)
    (hT.1 (joinLists s t)) (hT.2.1 (joinLists s t) _) (hT.2.2 (joinLists s t) _)
  rw [← integral_join_left hi]
  change (∫ x : Configuration N, ∫ v : Configuration 1,
    ‖(tensorForm ψ (radialLocalOrbital y R)).value (joinLists s t) (joinLists x v)‖^2 /
    ‖joinLists x v (finSumFinEquiv (Sum.inl i)) -
      joinLists x v (finSumFinEquiv (Sum.inr (0 : Fin 1)))‖) = _
  simp only [tensorForm_value_join,joinLists_left,joinLists_right,norm_mul,mul_pow,
    mul_div_assoc,integral_const_mul]
  rw [← integral_const_mul]
  apply integral_congr_ae
  apply Eventually.of_forall
  intro x
  by_cases hz : ψ.value s x = 0
  · simp only [hz,norm_zero,zero_pow (by decide : (2:ℕ) ≠ 0),zero_mul,zero_div,mul_zero]
  · have hd : R < ‖x i-y‖ := hRB.trans_le (le_of_not_gt fun hh => hz ((hc x i hh s).1))
    dsimp only
    rw [radialLocalOrbital_potential y hR hd]
    ring
315
lemma tensorCross_packet {N : ℕ} {ψ : FormVector N} (hψ : SobolevVector ψ)
    (y : Space) {R B : ℝ} (hR : 0 < R) (hRB : R < B)
    (hc : ∀ x i, ‖x i-y‖ < B → FormZeroAt ψ x) :
    tensorCross ψ (radialLocalOrbital y R) = coreCoulombAt ψ y := by
proof · 6 lines
  unfold tensorCross coreCoulombAt
  simp_rw [tensor_packet_pair hψ y hR hRB hc,← Finset.mul_sum]
  simp only [Finset.sum_const,Finset.card_univ,nsmul_eq_mul]
  norm_num [Spins]
  simp only [← Finset.mul_sum]
  ring
326
theorem local_point_field {N : ℕ} {ψ : FormVector N} (hψ : SobolevFermion ψ)
    (y : Space) {R B : ℝ} (hR : 0 < R) (hRB : R < B) (hy : R < ‖y‖)
    (hc : ∀ x i, ‖x i-y‖ < B → FormZeroAt ψ x)
    {Z lam : ℝ} (hZ : 0 ≤ Z) (hlam : 0 < lam) :
    Z * formMass ψ / ‖y‖ - coreCoulombAt ψ y ≤
      (formEnergy Z ψ + lam*N*formMass ψ - priceEnergy (energy Z) lam * formMass ψ) +
      formMass ψ * (radialPacketKinetic / R^2 + lam) := by
proof · 7 lines
  have hh := local_screened_insertion hψ (radialLocalOrbital_admissible y hR)
    (Metric.ball y B) (fun x i hi => hc x i (Metric.mem_ball.mp hi))
    (fun x hx => radialLocalOrbital_zero y hR (hRB.trans_le (le_of_not_gt
      (fun hh => hx (Metric.mem_ball.mpr hh))))) hZ hlam
  rw [radialLocalOrbital_nuclear y hR hy,tensorCross_packet hψ.sobolevVector y hR hRB hc,
    radialLocalOrbital_kinetic y hR] at hh
  simpa only [mul_one_div] using hh