lemmagraphComponent_permutation_norm {N : ℕ} (F : fermionGraph N)
(π : Equiv.Perm (FinN)) (s : SpinsN) (k : Option (FinN×Fin3)) :
∀ᵐ x : ConfigurationN, ‖graphComponent (s ∘ π)
(k.map fun j => (π.symm j.1,j.2)) F (x ∘ π)‖ = ‖graphComponent s k F x‖ :=by
proof · 13
lines
have he := congrArg (funG : SectorGraphN=> (G s).val k)
(sectorGraphPermutation_fixed F π)
rw [sectorGraphPermutation_component] at he
have ha :=Lp.coeFn_smul (((Equiv.Perm.sign π : ℤ) : ℂ))
(Lp.compMeasurePreserving (permuteConfiguration π) (permuteConfiguration_preserving π)
((F.val (s ∘ π)).val (k.map fun j => (π.symm j.1,j.2))))
have hb :=Lp.coeFn_compMeasurePreserving
((F.val (s ∘ π)).val (k.map fun j => (π.symm j.1,j.2))) (permuteConfiguration_preserving π)
rw [he] at ha
filter_upwards [ha, hb] with x hx hy
simp only [graphComponent_apply]
rw [hx, Pi.smul_apply, norm_smul, complex_sign_norm, one_mul, hy]
simp only [Function.comp_apply, permuteConfiguration_apply]
lemmagraphComponent_permutation_integral {N : ℕ} (F : fermionGraph N)
(π : Equiv.Perm (FinN)) (s : SpinsN) (k : Option (FinN×Fin3))
(w : ConfigurationN→ℝ) :
(∫ x, w x * ‖graphComponent (s ∘ π) (k.map fun j => (π.symm j.1,j.2)) F x‖ ^ 2) =
∫ x, w (x ∘ π) * ‖graphComponent s k F x‖ ^ 2:=by
proof · 6
lines
rw [← (permuteConfiguration_preserving π).integral_comp
(permuteConfiguration π).toHomeomorph.measurableEmbedding
(fun x => w x * ‖graphComponent (s ∘ π) (k.map fun j => (π.symm j.1,j.2)) F x‖ ^ 2)]
apply integral_congr_ae
filter_upwards [graphComponent_permutation_norm F π s k] with x hx
simp only [permuteConfiguration_apply, hx]
lemmasum_spins_permutation {N : ℕ} (π : Equiv.Perm (FinN)) (f : SpinsN→ℝ) :
(∑s : SpinsN, f (s ∘ π)) = ∑ s, f s :=by
proof · 6
lines
lete : SpinsN ≃ SpinsN:=
{ toFun :=fun s => s ∘ π
invFun :=fun s => s ∘ π.symm
left_inv :=fun s =>by funext i; simp
right_inv :=fun s =>by funext i; simp }
exact Equiv.sum_comp e f
lemmagraphComponent_permutation_sum_integral {N : ℕ} (F : fermionGraph N)
(π : Equiv.Perm (FinN)) (k : Option (FinN×Fin3))
(w : ConfigurationN→ℝ) :
(∑s : SpinsN, ∫ x, w x *
‖graphComponent s (k.map fun j => (π.symm j.1,j.2)) F x‖ ^ 2) =
∑s : SpinsN, ∫ x, w (x ∘ π) * ‖graphComponent s k F x‖ ^ 2:=by
proof · 3
lines
rw [← sum_spins_permutation π (fun s =>∫ x, w x *
‖graphComponent s (k.map fun j => (π.symm j.1,j.2)) F x‖ ^ 2)]
exact Finset.sum_congr rfl (fun s _ => graphComponent_permutation_integral F π s k w)
defquantumEnergyDensity {N : ℕ} (Z : ℝ) (ψ : FormVectorN) (s : SpinsN)
(x : ConfigurationN) : ℝ:=
body · 3
lines
(1/2:ℝ) * (∑ i, ∑ a, ‖ψ.gradient s i a x‖ ^ 2) -
Z * (∑ i, ‖ψ.value s x‖ ^ 2 / ‖x i‖) +
(1/2:ℝ) * (∑ i, ∑ j, if i ≠ j then ‖ψ.value s x‖ ^ 2 / ‖x i-x j‖ else0)
lemmaSobolevFermion.quantumEnergyDensity_integrable {N : ℕ} {ψ : FormVectorN}
(hψ : SobolevFermion ψ) (Z : ℝ) (s : SpinsN) :
Integrable (quantumEnergyDensity Z ψ s) :=by
proof · 14
lines
classical
have hn (i : FinN) := nuclear_integrable i (hψ.1 s) (hψ.2.1 s i) (hψ.2.2.1 s i)
have hp (i j : FinN) (hij : i ≠ j) := pair_integrable i j hij (hψ.1 s)
(hψ.2.1 s i) (hψ.2.2.1 s i)
apply Integrable.add
· exact ((integrable_finsetSum _ (fun i _ => integrable_finsetSum _
(fun a _ => (hψ.2.1 s i a).norm.integrable_sq))).const_mul _).sub
((integrable_finsetSum _ (fun i _ => hn i)).const_mul _)
· apply Integrable.const_mul
apply integrable_finsetSum; intro i _
apply integrable_finsetSum; intro j _
split_ifs with hij
· exact hp i j hij
· exact integrable_zero _ _ _
lemmaformEnergy_eq_density {N : ℕ} {ψ : FormVectorN} (hψ : SobolevFermion ψ) (Z : ℝ) :
formEnergy Z ψ = ∑ s, ∫ x, quantumEnergyDensity Z ψ s x :=by
proof · 42
lines
classical
have hn (s : SpinsN) (i : FinN) := nuclear_integrable i (hψ.1 s)
(hψ.2.1 s i) (hψ.2.2.1 s i)
have hp (s : SpinsN) (i j : FinN) : Integrable (fun x =>if i ≠ j then ‖ψ.value s x‖ ^ 2 / ‖x i-x j‖ else0) :=by
split_ifs with hij
· exact pair_integrable i j hij (hψ.1 s) (hψ.2.1 s i) (hψ.2.2.1 s i)
· exact integrable_zero _ _ _
have hk (s : SpinsN) := integrable_finsetSum Finset.univ (fun i _ =>
integrable_finsetSum Finset.univ (fun a _ => (hψ.2.1 s i a).norm.integrable_sq))
have hns (s : SpinsN) := integrable_finsetSum Finset.univ (fun i _ => hn s i)
have hps (s : SpinsN) := integrable_finsetSum Finset.univ (fun i _ =>
integrable_finsetSum Finset.univ (fun j _ => hp s i j))
have he (s : SpinsN) : (∫ x, quantumEnergyDensity Z ψ s x) =
(1/2:ℝ) * (∑ i, ∑ a, ∫ x, ‖ψ.gradient s i a x‖ ^ 2) -
Z * (∑ i, ∫ x, ‖ψ.value s x‖ ^ 2 / ‖x i‖) +
(1/2:ℝ) * (∑ i, ∑ j, ∫ x,
if i ≠ j then ‖ψ.value s x‖ ^ 2 / ‖x i-x j‖ else0) :=by
unfold quantumEnergyDensity
have hsum := integral_add (((hk s).const_mul (1/2:ℝ)).sub ((hns s).const_mul Z))
((hps s).const_mul (1/2:ℝ))
have hsub := integral_sub ((hk s).const_mul (1/2:ℝ)) ((hns s).const_mul Z)
simp only [Pi.sub_apply] at hsum hsub
rw [hsum, hsub]
simp only [integral_const_mul]
rw [integral_finsetSum _ (fun i _ => integrable_finsetSum _ (fun a _ =>
(hψ.2.1 s i a).norm.integrable_sq)), integral_finsetSum _ (fun i _ => hn s i),
integral_finsetSum _ (fun i _ => integrable_finsetSum _ (fun j _ => hp s i j))]
simp_rw [integral_finsetSum _ (fun a _ => (hψ.2.1 s _ a).norm.integrable_sq),
integral_finsetSum _ (fun j _ => hp s _ j)]
simp_rw [he]
have hint (s : SpinsN) (i j : FinN) :
(∫ x, if i ≠ j then ‖ψ.value s x‖ ^ 2 / ‖x i-x j‖ else0) =
if i ≠ j then (∫ x, ‖ψ.value s x‖ ^ 2 / ‖x i-x j‖) else0:=by
split_ifs <;> simp
simp_rw [hint]
have hs (s : SpinsN) (i j : FinN) :
(∫ x, ‖ψ.value s x‖ ^ 2 / ‖x i-x j‖) =
∫ x, ‖ψ.value s x‖ ^ 2 / ‖x j-x i‖ :=by simp only [norm_sub_rev]
simp_rw [← sum_pairs_half _ (hs _) ]
rw [Finset.sum_add_distrib, Finset.sum_sub_distrib, ←Finset.mul_sum, ←Finset.mul_sum]
rfl
defquantumCoreDensity {N : ℕ} (Z : ℝ) (ψ : FormVectorN) (i : FinN) (s : SpinsN)
(x : ConfigurationN) : ℝ:=
body · 4
lines
(1/2:ℝ) * (∑ j, if j ≠ i then∑ a, ‖ψ.gradient s j a x‖ ^ 2else0) -
Z * (∑ j, if j ≠ i then ‖ψ.value s x‖ ^ 2 / ‖x j‖ else0) +
(1/2:ℝ) * (∑ j, ∑ k,
if j ≠ i ∧ k ≠ i ∧ j ≠ k then ‖ψ.value s x‖ ^ 2 / ‖x j-x k‖ else0)
lemmaweighted_integral_join {NM : ℕ} {f : Configuration (N+M) →ℝ}
(hf : Integrable f) (w : ConfigurationM→ℝ) (hw : Continuous w)
{C : ℝ} (hwC : ∀ y, ‖w y‖ ≤C) :
(∫y : ConfigurationM, w y * ∫x : ConfigurationN, f (joinLists x y)) =
∫ z, w (exteriorCoordinates z) * f z :=by
proof · 7
lines
havehg : Integrable (fun z => w (exteriorCoordinates z) * f z) :=
hf.bdd_mul (hw.comp exteriorCoordinates_continuous).aestronglyMeasurable
(Eventually.of_forall fun z => hwC _)
rw [← integral_join (N:=N) (M:=M) hg]
apply integral_congr_ae
exact Eventually.of_forall fun y =>by
simp only [exteriorCoordinates_join, integral_const_mul]
lemmaweighted_sum_integral_join {NM : ℕ} {f : Spins (N+M) →Configuration (N+M) →ℝ}
(hf : ∀ u, Integrable (f u)) (w : ConfigurationM→ℝ) (hw : Continuous w)
{C : ℝ} (hwC : ∀ y, ‖w y‖ ≤C) :
(∑t : SpinsM, ∫ y, w y * (∑s : SpinsN, ∫ x, f (joinLists s t) (joinLists x y))) =
∑u : Spins (N+M), ∫ z, w (exteriorCoordinates z) * f u z :=by
proof · 8
lines
have hi (s : SpinsN) (t : SpinsM) :
Integrable (funy : ConfigurationM=> w y * ∫x : ConfigurationN,
f (joinLists s t) (joinLists x y)) :=
(integrable_join (hf (joinLists s t))).integral_prod_right.bdd_mul
hw.aestronglyMeasurable (Eventually.of_forall hwC)
simp_rw [Finset.mul_sum, integral_finsetSum _ (fun s _ => hi s _),
weighted_integral_join (hf _) w hw hwC]
exact sum_spin_join (fun u =>∫ z, w (exteriorCoordinates z) * f u z)
lemmaquantumCoreDensity_last {N : ℕ} (Z : ℝ) (ψ : FormVector (N+1))
(s : SpinsN) (t : Spins1) (x : ConfigurationN) (y : Configuration1) :
quantumCoreDensity Z ψ (Fin.last N) (joinLists s t) (joinLists x y) =
quantumEnergyDensity Z (coreSlice ψ t y) s x :=by
proof · 8
lines
classical
unfold quantumCoreDensity quantumEnergyDensity
simp only [Fin.sum_univ_castSucc, ne_eq, not_true_eq_false, ite_false, Fin.castSucc_ne_last,
not_false_eq_true, ite_true, add_zero, and_false, and_true, Fin.castSucc_inj]
simp only [true_and, false_and, ite_false, Finset.sum_const_zero, add_zero]
have hl (i : FinN) : joinLists x y i.castSucc = x i := joinLists_left x y i
simp only [hl, coreSlice, finSumFinEquiv_apply_left]
rfl
lemmacoreSlice_energy_weighted_reconstruction {N : ℕ} {ψ : FormVector (N+1)}
(hψ : SobolevFermion ψ) (Z : ℝ) (w : Configuration1→ℝ) (hw : Continuous w)
{C : ℝ} (hwC : ∀ y, ‖w y‖ ≤C) :
(∑t : Spins1, ∫ y, w y * formEnergy Z (coreSlice ψ t y)) =
∑s : Spins (N+1), ∫ z, w (exteriorCoordinates z) * quantumCoreDensity Z ψ (Fin.last N) s z :=by
proof · 8
lines
rw [← weighted_sum_integral_join
(fun s => hψ.quantumCoreDensity_integrable Z (Fin.last N) s) w hw hwC]
apply Finset.sum_congr rfl
intro t _
apply integral_congr_ae
filter_upwards [hψ.ae_coreSlice t] with y hy
rw [formEnergy_eq_density hy]
simp only [quantumCoreDensity_last]
lemmagraphFormVector_value_eq {N : ℕ} (F : fermionGraph N) (s : SpinsN) (x : ConfigurationN) :
(graphFormVector F).value s x = graphComponent s none F x := rfl
lemmagraphFormVector_gradient_eq {N : ℕ} (F : fermionGraph N) (s : SpinsN)
(i : FinN) (a : Fin3) (x : ConfigurationN) :
(graphFormVector F).gradient s i a x = graphComponent s (some (i,a)) F x := rfl
lemmasum_excluding_perm {α : Type*} [Fintype α] [DecidableEq α]
(π : Equiv.Perm α) (i : α) (f : α →ℝ) :
(∑ j, if j ≠ i then f (π j) else0) = ∑ j, if j ≠ π i then f j else0:=by
proof · 2
lines
rw [←Equiv.sum_comp π (fun j =>if j ≠ π i then f j else0)]
simp only [ne_eq, π.injective.eq_iff]
lemmasum_pairs_excluding_perm {α : Type*} [Fintype α] [DecidableEq α]
(π : Equiv.Perm α) (i : α) (f : α → α →ℝ) :
(∑ j, ∑ k, if j ≠ i ∧ k ≠ i ∧ j ≠ k then f (π j) (π k) else0) =
∑ j, ∑ k, if j ≠ π i ∧ k ≠ π i ∧ j ≠ k then f j k else0:=by
proof · 6
lines
rw [←Equiv.sum_comp π (fun j =>∑ k,
if j ≠ π i ∧ k ≠ π i ∧ j ≠ k then f j k else0)]
apply Finset.sum_congr rfl; intro j _
rw [←Equiv.sum_comp π (fun k =>if π j ≠ π i ∧ k ≠ π i ∧ π j ≠ k then f (π j) k else0)]
simp only [ne_eq, π.injective.eq_iff]
lemmaquantumCoreDensity_reindex {N : ℕ} (Z : ℝ) (ψ φ : FormVectorN)
(π : Equiv.Perm (FinN)) (i : FinN) (s t : SpinsN) (x y : ConfigurationN)
(hv : ‖φ.value t y‖ = ‖ψ.value s x‖)
(hg : ∀ j a, ‖φ.gradient t j a y‖ = ‖ψ.gradient s (π j) a x‖)
(hc : ∀ j, y j = x (π j)) :
quantumCoreDensity Z φ i t y = quantumCoreDensity Z ψ (π i) s x :=by
proof · 6
lines
classical
unfold quantumCoreDensity
simp only [hg, hv, hc]
rw [sum_excluding_perm π i (fun j =>∑ a, ‖ψ.gradient s j a x‖ ^ 2),
sum_excluding_perm π i (fun j => ‖ψ.value s x‖ ^ 2 / ‖x j‖),
sum_pairs_excluding_perm π i (fun j k => ‖ψ.value s x‖ ^ 2 / ‖x j-x k‖)]
lemmagraphFormVector_permutation_norm {N : ℕ} (F : fermionGraph N)
(π : Equiv.Perm (FinN)) (s : SpinsN) :
∀ᵐ x : ConfigurationN,
‖(graphFormVector F).value (s ∘ π) (x ∘ π)‖ = ‖(graphFormVector F).value s x‖ ∧∀ j a, ‖(graphFormVector F).gradient (s ∘ π) j a (x ∘ π)‖ =
‖(graphFormVector F).gradient s (π j) a x‖ :=by
proof · 9
lines
have hg (j : FinN) (a : Fin3) : ∀ᵐ x : ConfigurationN,
‖(graphFormVector F).gradient (s ∘ π) j a (x ∘ π)‖ =
‖(graphFormVector F).gradient s (π j) a x‖ :=by
simpa only [graphFormVector_gradient_eq, Option.map_some, Equiv.symm_apply_apply]
using graphComponent_permutation_norm F π s (some (π j,a))
havehv : ∀ᵐ x : ConfigurationN,
‖(graphFormVector F).value (s ∘ π) (x ∘ π)‖ = ‖(graphFormVector F).value s x‖ :=by
simpa only [graphFormVector_value_eq, Option.map_none] using graphComponent_permutation_norm F π s none
exact hv.and (ae_all_iff.mpr fun j => ae_all_iff.mpr fun a => hg j a)
lemmaquantumCoreDensity_permutation {N : ℕ} (Z : ℝ) (F : fermionGraph N)
(π : Equiv.Perm (FinN)) (i : FinN) (s : SpinsN) :
∀ᵐ x : ConfigurationN,
quantumCoreDensity Z (graphFormVector F) i (s ∘ π) (x ∘ π) =
quantumCoreDensity Z (graphFormVector F) (π i) s x :=by
proof · 2
lines
filter_upwards [graphFormVector_permutation_norm F π s] with x hx
exact quantumCoreDensity_reindex Z _ _ π i s (s ∘ π) x (x ∘ π) hx.1 hx.2 (fun _ => rfl)
lemmaweighted_core_permutation {N : ℕ} (Z : ℝ) (F : fermionGraph N)
(π : Equiv.Perm (FinN)) (i : FinN) (w : Space→ℝ) :
(∑ s, ∫ x, w (x i) * quantumCoreDensity Z (graphFormVector F) i s x) =
∑ s, ∫ x, w (x (π i)) * quantumCoreDensity Z (graphFormVector F) (π i) s x :=by
proof · 9
lines
rw [← sum_spins_permutation π (fun s =>∫ x, w (x i) *
quantumCoreDensity Z (graphFormVector F) i s x)]
apply Finset.sum_congr rfl; intro s _
rw [← (permuteConfiguration_preserving π).integral_comp
(permuteConfiguration π).toHomeomorph.measurableEmbedding
(fun x => w (x i) * quantumCoreDensity Z (graphFormVector F) i (s ∘ π) x)]
apply integral_congr_ae
filter_upwards [quantumCoreDensity_permutation ZF π i s] with x hx
simp only [permuteConfiguration_apply, Function.comp_apply, hx]
lemmasum_excluding_add {α : Type*} [Fintype α] [DecidableEq α] (i : α) (f : α →ℝ) :
(∑ j, if j ≠ i then f j else0) + f i = ∑ j, f j :=by
proof · 4
lines
have hh (j : α) : (if j ≠ i then f j else0) + (if j = i then f j else0) = f j :=byby_cases h : j = i <;> simp [h]
simpa only [Finset.sum_add_distrib, Finset.sum_ite_eq', Finset.mem_univ, ite_true] usingFinset.sum_congr (s₁ :=Finset.univ) (s₂ :=Finset.univ) rfl (fun j _ => hh j)
lemmapairs_excluding_add {α : Type*} [Fintype α] [DecidableEq α] (i : α)
(f : α → α →ℝ) (hs : ∀ j k, f j k = f k j) (hii : f i i = 0) :
(∑ j, ∑ k, if j ≠ i ∧ k ≠ i then f j k else0) + 2 * (∑ k, f i k) =
∑ j, ∑ k, f j k :=by
proof · 14
lines
have hinner (j : α) : (∑ k, if k ≠ i then f j k else0) + f j i = ∑ k, f j k :=
sum_excluding_add i (f j)
have houter := sum_excluding_add i (fun j =>∑ k, if k ≠ i then f j k else0)
have hr := sum_excluding_add i (f i)
rw [hii, add_zero] at hr
havehc : (∑ j, f j i) = ∑ j, f i j :=Finset.sum_congr rfl (fun j _ => hs j i)
havehd : (∑ j, if j ≠ i then∑ k, if k ≠ i then f j k else0else0) =
∑ j, ∑ k, if j ≠ i ∧ k ≠ i then f j k else0:=by
apply Finset.sum_congr rfl; intro j _
by_cases h : j = i <;> simp [h]
rw [hd, hr] at houter
have he :=Finset.sum_congr (s₁ :=Finset.univ) (s₂ :=Finset.univ) rfl (fun j _ => hinner j)
rw [Finset.sum_add_distrib, hc] at he
linarith
lemmaquantumEnergyDensity_delete {N : ℕ} (Z : ℝ) (ψ : FormVectorN)
(i : FinN) (s : SpinsN) (x : ConfigurationN) :
quantumEnergyDensity Z ψ s x = quantumCoreDensity Z ψ i s x +
(1/2:ℝ) * (∑ a, ‖ψ.gradient s i a x‖ ^ 2) - Z * (‖ψ.value s x‖ ^ 2 / ‖x i‖) +
(∑ j, if i ≠ j then ‖ψ.value s x‖ ^ 2 / ‖x i-x j‖ else0) :=by
proof · 19
lines
classical
have hk := sum_excluding_add i (fun j =>∑ a, ‖ψ.gradient s j a x‖ ^ 2)
have hn := sum_excluding_add i (fun j => ‖ψ.value s x‖ ^ 2 / ‖x j‖)
let f :=funj k : FinN=>if j ≠ k then ‖ψ.value s x‖ ^ 2 / ‖x j-x k‖ else0have hs (j k : FinN) : f j k = f k j :=by
dsimp [f]
by_cases h : j = k
· simp [h]
· simp [h, Ne.symm h, norm_sub_rev]
have hp := pairs_excluding_add i f hs (by simp [f])
have he (j k : FinN) : (if j ≠ i ∧ k ≠ i then f j k else0) =
if j ≠ i ∧ k ≠ i ∧ j ≠ k then ‖ψ.value s x‖ ^ 2 / ‖x j-x k‖ else0:=by
simp only [f]; split_ifs <;> simp_all
simp only [he] at hp
unfold quantumEnergyDensity quantumCoreDensity
change _ = _
dsimp only [f] at hp
rw [← hk, ← hn, ← hp]
ring