MultiSpacecraftAnalysis

Installation

using Pkg
Pkg.add("MultiSpacecraftAnalysis")

Reciprocal vectors

Paschmann and Daly [1], Chapter 4, Paschmann and Daly [2], Chapter 14,

MultiSpacecraftAnalysis.reciprocal_vectorFunction
reciprocal_vector(r_βα, r_βγ, r_βλ)

Compute the reciprocal vector $𝒌_α$ for a vertex of a tetrahedron given the relative position vectors.

\[𝒌_α = \frac{𝐫_{βγ} × 𝐫_{βλ}}{𝐫_{βα} ⋅ (𝐫_{βγ} × 𝐫_{βλ})}\]

where $𝐫_{αβ} = r_β - r_α$ are relative position vectors.

References

  • Multi-spacecraft analysis methods revisited : 4.3 Properties of reciprocal vectors
source
reciprocal_vector(rα, rβ, rγ, rλ)

Compute the reciprocal vector $𝒌_α$ for a vertex of a tetrahedron given the position vectors of all vertices.

The vertices (α, β, γ, λ) must form a cyclic permutation of (1, 2, 3, 4).

source
reciprocal_vector(rα, r0s)

Generalised reciprocal vector for N != 4

\[𝐪_α = 𝐑^{-1} 𝐫_α\]

See also: reciprocal_vector, position_tensor

source

Estimation of spatial gradients

MultiSpacecraftAnalysis.lingradestFunction
lingradest(B1, args...)

Vectorized method for simplified usage. Returns a StructArray containing the results.

Set flatten = true to flatten the output arrays, making the output shape similar to the input array shape.

source
lingradest(
    Bx1, Bx2, Bx3, Bx4,
    By1, By2, By3, By4,
    Bz1, Bz2, Bz3, Bz4,
    R1, R2, R3, R4
)

SPEDAS-argument-compatible version of lingradest.

source

Since $\tilde{g}$ and $\tilde{\boldsymbol{V}}$ are linear functions, the calculation of spatial derivatives, such as the gradient of some scalar function or the divergence or curl of a vector function, can be done quite easily. The results are:

\[\begin{aligned} \nabla g \simeq \nabla \tilde{g} & =\sum_{\alpha=0}^3 \boldsymbol{k}_\alpha g_\alpha \\ \hat{\boldsymbol{e}} \cdot \nabla g \simeq \hat{\boldsymbol{e}} \cdot \nabla \tilde{g} & =\sum_{\alpha=0}^3\left(\hat{\boldsymbol{e}} \cdot \boldsymbol{k}_\alpha\right) g_\alpha \\ \nabla \cdot \boldsymbol{V} \simeq \nabla \cdot \tilde{\boldsymbol{V}} & =\sum_{\alpha=0}^3 \boldsymbol{k}_\alpha \cdot \boldsymbol{V}_\alpha \\ \nabla \times \boldsymbol{V} \simeq \nabla \times \tilde{\boldsymbol{V}} & =\sum_{\alpha=0}^3 \boldsymbol{k}_\alpha \times \boldsymbol{V}_\alpha \end{aligned}\]

Multi-spacecraft timing

MultiSpacecraftAnalysis.ConstantVelocityApproachFunction
CVA(positions, times)

Constant Velocity Approach (CVA) for determining boundary normal and velocity. Solve timing equation: $D * m = Δts$

Parameters:

  • positions: Positions of 4 spacecraft (4×3 array)
  • times: Times of boundary crossing for each spacecraft
source
ConstantVelocityApproach(positions, times, durations)

Given durations of the boundary crossings, calculate the thickness of the boundary

source

API

MultiSpacecraftAnalysis.ConstantVelocityApproachMethod
CVA(positions, times)

Constant Velocity Approach (CVA) for determining boundary normal and velocity. Solve timing equation: $D * m = Δts$

Parameters:

  • positions: Positions of 4 spacecraft (4×3 array)
  • times: Times of boundary crossing for each spacecraft
source
MultiSpacecraftAnalysis._lingradestMethod
lingradest(B1, B2, B3, B4, R1, R2, R3, R4)

Compute spatial derivatives such as grad, div, curl and curvature using reciprocal vector technique (linear interpolation).

Arguments

  • B1, B2, B3, B4: 3-element vectors giving magnetic field measurements at each probe
  • R1, R2, R3, R4: 3-element vectors giving the probe positions

Returns

A named tuple containing: • Rbary: Barycenter position • Bbc: Magnetic field at the barycenter • Bmag: Magnetic field magnitude at the barycenter • LGBx, LGBy, LGBz: Linear gradient estimators for each component • LD: Linear divergence estimator • LCB: Linear curl estimator • curvature: Field-line curvature vector: 𝐛 · ∇𝐛 • R_c: Field-line curvature radius

References

Based on the method of Chanteur (ISSI, 1998, Ch. 11).

source
MultiSpacecraftAnalysis.lingradestMethod
lingradest(B1, args...)

Vectorized method for simplified usage. Returns a StructArray containing the results.

Set flatten = true to flatten the output arrays, making the output shape similar to the input array shape.

source
MultiSpacecraftAnalysis.reciprocal_vectorMethod
reciprocal_vector(rα, rβ, rγ, rλ)

Compute the reciprocal vector $𝒌_α$ for a vertex of a tetrahedron given the position vectors of all vertices.

The vertices (α, β, γ, λ) must form a cyclic permutation of (1, 2, 3, 4).

source
MultiSpacecraftAnalysis.reciprocal_vectorMethod
reciprocal_vector(r_βα, r_βγ, r_βλ)

Compute the reciprocal vector $𝒌_α$ for a vertex of a tetrahedron given the relative position vectors.

\[𝒌_α = \frac{𝐫_{βγ} × 𝐫_{βλ}}{𝐫_{βα} ⋅ (𝐫_{βγ} × 𝐫_{βλ})}\]

where $𝐫_{αβ} = r_β - r_α$ are relative position vectors.

References

  • Multi-spacecraft analysis methods revisited : 4.3 Properties of reciprocal vectors
source
[1]
G. Paschmann and P. W. Daly. Multi-Spacecraft Analysis Methods Revisited (ESA Communications, 2008).
[2]
G. Paschmann and P. W. Daly. Analysis Methods for Multi-Spacecraft Data (ESA Publications Division, 2000).