File size: 2,028 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
import OAI.Analysis.Calculus.Current.Smooth

namespace OAI.Analysis.Calculus.Current

noncomputable section

/-- The actual coordinate-derivative array in the three-slot convention
`(real, i, j)` used by the quaternionic calculus section. -/
def threeSlotMatrixDerivative {d : β„•}
    (A : (Index d β†’ ℝ) β†’ (Index d β†’ β„‚) β†’ Matrix (Index d) (Index d) (Quaternion ℝ))
    (x : Index d β†’ ℝ) (z : Index d β†’ β„‚)
    (p : Index d Γ— Fin 3) : Matrix (Index d) (Index d) (Quaternion ℝ) := fun r s =>
  ![quaternionRealD (fun q w => A q w r s) x z p.1,
    quaternionImagD (fun q w => A q w r s) x z p.1 1,
    quaternionImagD (fun q w => A q w r s) x z p.1 Complex.I] p.2

theorem strongDivergence_eq_quaternionDivergence {d : β„•}
    (A : (Index d β†’ ℝ) β†’ (Index d β†’ β„‚) β†’ Matrix (Index d) (Index d) (Quaternion ℝ))
    (x : Index d β†’ ℝ) (z : Index d β†’ β„‚) (b : Index d) :
    OAI.Analysis.Calculus.Quaternion.strongDivergence OAI.Analysis.Calculus.Quaternion.threeSlots (threeSlotMatrixDerivative A x z) b =
      quaternionDivergence (fun a q w => A q w a b) x z := by
  unfold OAI.Analysis.Calculus.Quaternion.strongDivergence quaternionDivergence
  apply Finset.sum_congr rfl
  intro a _
  simp [threeSlotMatrixDerivative, OAI.Analysis.Calculus.Quaternion.threeSlots, Fin.sum_univ_succ, qi, qj]
  ext <;> simp <;> ring

/-- The manuscript's strong-divergence identity for the exact normalized
outer-product wave current, using the actual coordinate derivatives. -/
theorem waveCurrent_strongDivergence {d : β„•} {ΞΉ : Type*} [Fintype ΞΉ]
    (ΞΊ cR cI : ΞΉ β†’ ℝ) (v : ΞΉ β†’ Fin d β†’ ℝ) (x : Index d β†’ ℝ) (z : Index d β†’ β„‚)
    (hY : z none β‰  0) (b : Index d) :
    OAI.Analysis.Calculus.Quaternion.strongDivergence OAI.Analysis.Calculus.Quaternion.threeSlots
      (threeSlotMatrixDerivative (waveCurrent ΞΊ cR cI v) x z) b = 0 := by
  rw [strongDivergence_eq_quaternionDivergence]
  exact waveCurrent_divergence ΞΊ cR cI v x z hY b

end
end OAI.Analysis.Calculus.Current