Whistler-mode waves generated near the equatorial plane do not propagate indefinitely — thermal electrons with velocities near the parallel Landau resonance absorb wave energy as the wave propagates poleward along a field line.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/stourgai/WPIT/llms.txt
Use this file to discover all available pages before exploring further.
LandauDamp_mod computes this spatial Landau damping rate step by step along a ray path, integrating the imaginary part of the hot-plasma dielectric tensor over velocity space at each location. The result is the normalized wave power as a function of position along the ray.
Physical Background
In a warm plasma the dielectric tensor acquires an imaginary part that depends on the slope of the velocity distribution function at the resonant velocity. For the Landau (m = 0) resonance, which is the dominant contribution for whistler waves, the resonant velocity is:Input: Ray Files
LandauDamp_mod is designed to work with ray-tracing output produced by an external ray-tracing code (not included in WPIT). The ray file is a whitespace-delimited ASCII file with one time step per row and the following columns:
| Column group | Contents |
|---|---|
ray, ray_stop, time | Ray identifier, stop flag, time (s) |
posx, posy, posz | Position (m), Solar-Magnetic Cartesian coordinates |
vprelx/y/z | Phase velocity (relative to c) |
vgrelx/y/z | Group velocity (relative to c) |
nx, ny, nz | Refractive index vector components |
Bx, By, Bz | Background magnetic field (T) |
w | Wave angular frequency (rad/s) |
Nspec | Number of plasma species |
qs1–qs4 | Species charges (C) |
ms1–ms4 | Species masses (kg) |
Ns1–Ns4 | Species number densities (m⁻³) |
nus1–nus4 | Collision frequencies |
Module_descriptions/example_rays/.
The landau_damping Function
ld.landau_damping(ray_file, distr) is the main entry point. It reads the ray file, loops over all time steps, computes the spatial damping rate at each step using the specified electron distribution, integrates the attenuation, and saves the result to a CSV file alongside the ray file. It also produces a plot of normalized wave power vs. time.
<ray_file>_damping.csv) contains two columns: time and damp (normalized wave power, starting at 1.0).
The resonance orders included in the damping calculation are m = −2, −1, 0, +1, +2. The m = 0 (Landau) term dominates for obliquely propagating whistler waves. The m ≠ 0 terms capture cyclotron resonance contributions, which can be significant for field-aligned propagation.
Electron Distribution Function Models
The damping rate depends critically on the slope of the electron distribution at the Landau resonant velocity. WPIT implements five models, reflecting different plasma environments:Bi-Maxwellian — ld.distribution_bimaxwellian(vperp, vpar)
An anisotropic Maxwellian with a loss-cone modification, suitable for the outer radiation belt. Key parameters (hard-coded in the current implementation):
- Hot electron density: nₕ = 2 × 10⁻³ m⁻³
- Parallel thermal speed: U‖ = 0.05 c
- Perpendicular thermal speed: U⊥ = 0.03 c
- Loss-cone parameter: β = 0.01
Bell (2002) — ld.distribution_bell(vperp, vpar)
Power-law distribution from Bell (2002), parameterized as a function of total speed v (in cm/s):
Bortnik et al. (2007) — ld.distribution_bortnik(vperp, vpar)
Thermal electron distribution following Bortnik et al. (2007a), parameterized as:
Golden et al. (2010) — ld.distribution_golden(vperp, vpar, kpmax, Lmeas)
A hybrid distribution that blends the Bell and Bortnik models using a sigmoid weighting function that depends on the distance of the observation point from the plasmapause:
Golden2 — ld.distribution_golden2(vperp, vpar)
A pre-configured version of the Golden distribution with fixed parameters (Kp_max = 5, L_meas = 2), useful for a quick comparison without having to supply storm-time indices.
When
landau_damping is called with distr='Golden', it internally uses distribution_golden2 (the pre-configured variant with fixed Kp_max = 5, L_meas = 2). Call ld.distribution_golden(vperp, vpar, kpmax, Lmeas) directly if you need activity-dependent blending weights.Ray Utilities (RayUtils_mod)
LandauDamp_mod includes a sub-package RayUtils_mod with helper functions for managing ray files:
| Function | Description |
|---|---|
read_input_ray(ray_file) | Read a raw ray file into a pandas DataFrame |
append_ray(ray_file) | Enrich the ray with derived quantities (psi, Stix parameters, L-shell, lat/lon via SpacePy) and merge with damping output; saves <ray_file>_appended.csv |
read_appended_ray(ray_file) | Read a previously appended CSV back into a DataFrame |
resonance_along_raypath(ray_file) | Compute and plot resonant velocities and energies along the ray |
ray_plots(ray_file) | Diagnostic plots of wave normal angle, Stix parameters, and frequencies along the ray |
Enhancement Factor
RayUtils_mod.enhancement_factor(ray_file_appended) estimates the wave cavity enhancement as a function of L-shell by tracking the wave power each time the ray crosses the geomagnetic equator:
Multi-ray and batch processing
Multi-ray and batch processing
To process many ray files (e.g., a frequency sweep or a range of wave normal angles), loop over the file list and call
landau_damping for each one. The output CSV naming convention (<ray_file>_damping.csv) ensures that results are saved alongside the inputs without overwriting each other. The Module_descriptions/LandauDamp_mod_description.ipynb notebook shows a complete batch workflow comparing multiple distribution functions on the same ray.