File size: 9,127 Bytes
4a56cd6 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 | import OAI.Analysis.Fourier.WavePackets.Poisson
namespace OAI.Analysis.Fourier.WavePackets
open _root_.MeasureTheory
open scoped ContDiff RealInnerProductSpace FourierTransform
noncomputable def waveAmplitude {n : β} (Ο : EuclideanSpace β (Fin n) β β)
(h T : β) (ΞΎ : EuclideanSpace β (Fin n)) : β :=
Complex.exp (-Complex.I * (((T / h) * βΞΎβ : β) : β)) * Ο ΞΎ
theorem hasCompactSupport_waveAmplitude {n : β} {Ο : EuclideanSpace β (Fin n) β β}
(hs : HasCompactSupport Ο) (h T : β) : HasCompactSupport (waveAmplitude Ο h T) :=
hs.mul_left
theorem contDiff_waveAmplitude {n : β} {Ο : EuclideanSpace β (Fin n) β β}
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
(h T : β) : ContDiff β β (waveAmplitude Ο h T) := by
rw [contDiff_iff_contDiffAt]
intro ΞΎ
by_cases hΞΎ : ΞΎ = 0
Β· subst ΞΎ
have hz : (0 : EuclideanSpace β (Fin n)) β tsupport (waveAmplitude Ο h T) := by
exact fun hz => hzero (tsupport_mul_subset_right hz)
exact contDiffAt_const.congr_of_eventuallyEq (notMem_tsupport_iff_eventuallyEq.mp hz)
Β· have hc := Complex.ofRealCLM.contDiff.contDiffAt.comp ΞΎ
((contDiffAt_const : ContDiffAt β β (fun _ : EuclideanSpace β (Fin n) => T / h) ΞΎ).mul
(contDiffAt_norm β hΞΎ))
exact (((contDiffAt_const.mul hc).cexp).mul hΟ.contDiffAt)
/-- The Schwartz symbol expressed in the unit-torus dual coordinate. -/
noncomputable def periodicSchwartzSymbol {n : β}
{Ο : EuclideanSpace β (Fin n) β β} (hs : HasCompactSupport Ο)
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
{h : β} (hh : 0 < h) (T : β) : SchwartzMap (EuclideanSpace β (Fin n)) β :=
((hasCompactSupport_waveAmplitude hs h T).comp_smul
(show h * (2 * Real.pi / 100) β 0 by positivity)).toSchwartzMap
((contDiff_waveAmplitude hΟ hzero h T).comp (by fun_prop))
theorem periodicSchwartzSymbol_apply {n : β}
{Ο : EuclideanSpace β (Fin n) β β} (hs : HasCompactSupport Ο)
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
{h : β} (hh : 0 < h) (T : β) (ΞΎ : EuclideanSpace β (Fin n)) :
periodicSchwartzSymbol hs hΟ hzero hh T ΞΎ =
waveAmplitude Ο h T ((h * (2 * Real.pi / 100)) β’ ΞΎ) := rfl
theorem periodicSchwartzSymbol_integer {n : β}
{Ο : EuclideanSpace β (Fin n) β β} (hs : HasCompactSupport Ο)
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
{h : β} (hh : 0 < h) (T : β) (k : Fin n β β€) :
periodicSchwartzSymbol hs hΟ hzero hh T (integerVector k) = periodicSymbol Ο h T k := by
rw [periodicSchwartzSymbol_apply]
unfold waveAmplitude periodicSymbol periodicFrequency
rw [β smul_smul]
congr 2
rw [norm_smul, Real.norm_eq_abs, abs_of_pos hh]
field_simp
/-- The exact Poisson identity for the cutoff wave symbol, with the physical
side-100 kernel normalization. -/
theorem periodicKernel_eq_inverseSymbol_sum {n : β}
{Ο : EuclideanSpace β (Fin n) β β} (hs : HasCompactSupport Ο)
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
{h : β} (hh : 0 < h) (T : β) (x : EuclideanSpace β (Fin n)) :
periodicKernel Ο h T (torusProjection x) =
β' k : Fin n β β€, ((100 : β) ^ n)β»ΒΉ *
(πβ» (periodicSchwartzSymbol hs hΟ hzero hh T)) (integerVector k + x) := by
rw [tsum_mul_left, periodicKernel]
congr 1
rw [schwartz_poisson, FourierTransform.fourier_fourierInv_eq]
apply tsum_congr
intro k
rw [periodicSchwartzSymbol_integer]
theorem waveFourier_integrand_identity {n : β}
(Ο : EuclideanSpace β (Fin n) β β) {h : β} (hh : h β 0) (T : β)
(X ΞΎ : EuclideanSpace β (Fin n)) :
Complex.exp (((2 * Real.pi * βͺΞΎ, (1 / 100 : β) β’ Xβ« : β) : β) * Complex.I) *
waveAmplitude Ο h T ((h * (2 * Real.pi / 100)) β’ ΞΎ) =
oscillation (euclideanWavePhase X T) h ((h * (2 * Real.pi / 100)) β’ ΞΎ) *
Ο ((h * (2 * Real.pi / 100)) β’ ΞΎ) := by
unfold waveAmplitude oscillation euclideanWavePhase
rw [β mul_assoc, β Complex.exp_add]
congr 2
simp only [inner_smul_right, real_inner_comm ΞΎ X]
push_cast
have hh' : (h : β) β 0 := by exact_mod_cast hh
field_simp [hh']
ring
/-- Conversion from the unit-torus Fourier inversion convention to the
semiclassical angular-frequency kernel, including its `(2Ο)β»βΏ` factor. -/
theorem inverseSymbol_eq_semiclassicalKernel {n : β}
{Ο : EuclideanSpace β (Fin n) β β} (hs : HasCompactSupport Ο)
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
{h : β} (hh : 0 < h) (T : β) (X : EuclideanSpace β (Fin n)) :
((100 : β) ^ n)β»ΒΉ * (πβ» (periodicSchwartzSymbol hs hΟ hzero hh T))
((1 / 100 : β) β’ X) =
(((2 * Real.pi : β) : β) ^ n)β»ΒΉ * semiclassicalWaveKernel volume Ο h T X := by
rw [SchwartzMap.fourierInv_coe, Real.fourierInv_eq']
simp only [smul_eq_mul, periodicSchwartzSymbol_apply]
simp_rw [waveFourier_integrand_identity Ο hh.ne' T X]
rw [Measure.integral_comp_smul_of_nonneg volume
(fun ΞΎ => oscillation (euclideanWavePhase X T) h ΞΎ * Ο ΞΎ)
(h * (2 * Real.pi / 100)) (hR := by positivity)]
simp only [semiclassicalWaveKernel, finrank_euclideanSpace, Fintype.card_fin,
Complex.real_smul, Complex.ofReal_inv, Complex.ofReal_pow, Complex.ofReal_mul,
Complex.ofReal_div, Complex.ofReal_ofNat]
have hh' : (h : β) β 0 := by exact_mod_cast hh.ne'
have hpi : (Real.pi : β) β 0 := by exact_mod_cast Real.pi_ne_zero
field_simp [hh', hpi]
have hfactor : (1 / 50 : β) ^ n * (100 : β) ^ n = (2 : β) ^ n := by
rw [β mul_pow]
norm_num
linear_combination -(β« ΞΎ, oscillation (euclideanWavePhase X T) h ΞΎ * Ο ΞΎ) *
(Real.pi : β) ^ n * (h : β) ^ n * hfactor
/-- The Fourier-series kernel on the side-100 torus is exactly the lattice
periodization of the Euclidean semiclassical kernel. -/
theorem periodicKernel_eq_lattice_sum {n : β}
{Ο : EuclideanSpace β (Fin n) β β} (hs : HasCompactSupport Ο)
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
{h : β} (hh : 0 < h) (T : β) (X : EuclideanSpace β (Fin n)) :
periodicKernel Ο h T (torusProjection ((1 / 100 : β) β’ X)) =
β' k : Fin n β β€, (((2 * Real.pi : β) : β) ^ n)β»ΒΉ *
semiclassicalWaveKernel volume Ο h T (X + (100 : β) β’ integerVector k) := by
rw [periodicKernel_eq_inverseSymbol_sum hs hΟ hzero hh]
apply tsum_congr
intro k
have hx : integerVector k + (1 / 100 : β) β’ X =
(1 / 100 : β) β’ (X + (100 : β) β’ integerVector k) := by module
rw [hx, inverseSymbol_eq_semiclassicalKernel hs hΟ hzero hh]
theorem periodicKernel_eq_kernel_add_remainder {n : β}
{Ο : EuclideanSpace β (Fin n) β β} (hs : HasCompactSupport Ο)
(hΟ : ContDiff β β Ο) (hzero : (0 : EuclideanSpace β (Fin n)) β tsupport Ο)
{h : β} (hh : 0 < h) (T : β) (X : EuclideanSpace β (Fin n)) :
periodicKernel Ο h T (torusProjection ((1 / 100 : β) β’ X)) =
(((2 * Real.pi : β) : β) ^ n)β»ΒΉ *
(semiclassicalWaveKernel volume Ο h T X + periodizationRemainder volume Ο h T X) := by
classical
have hx (k : Fin n β β€) : integerVector k + (1 / 100 : β) β’ X =
(1 / 100 : β) β’ (X + (100 : β) β’ integerVector k) := by module
have hsum : Summable (fun k : Fin n β β€ => (((2 * Real.pi : β) : β) ^ n)β»ΒΉ *
semiclassicalWaveKernel volume Ο h T (X + (100 : β) β’ integerVector k)) := by
apply ((summable_norm_schwartz_lattice_add
(πβ» (periodicSchwartzSymbol hs hΟ hzero hh T)) ((1 / 100 : β) β’ X)).of_norm.mul_left
(((100 : β) ^ n)β»ΒΉ)).congr
intro k
rw [hx, inverseSymbol_eq_semiclassicalKernel hs hΟ hzero hh]
have hzeroEq : integerLatticeEquiv n 0 = 0 := by
apply Subtype.ext
ext i
simp [integerLatticeEquiv, integerVector]
have hz (k : Fin n β β€) : integerLatticeEquiv n k = 0 β k = 0 := by
rw [β hzeroEq]
exact (integerLatticeEquiv n).injective.eq_iff
have htail : (β' k : Fin n β β€,
if k = 0 then 0 else semiclassicalWaveKernel volume Ο h T (X + (100 : β) β’ integerVector k)) =
periodizationRemainder volume Ο h T X := by
have he := (integerLatticeEquiv n).tsum_eq (periodizationRemainderTerm volume Ο h T X)
unfold periodizationRemainder
convert he using 1
congr 1
funext k
simp only [periodizationRemainderTerm, hz]
rfl
rw [periodicKernel_eq_lattice_sum hs hΟ hzero hh, hsum.tsum_eq_add_tsum_ite 0]
have hvec : integerVector (0 : Fin n β β€) = 0 := by ext i; simp [integerVector]
simp only [hvec, smul_zero, add_zero]
rw [mul_add]
congr 1
rw [β htail, β tsum_mul_left]
apply tsum_congr
intro k
split_ifs <;> simp
end OAI.Analysis.Fourier.WavePackets
|