thunder4d.solver
UPPE propagator on a fixed grid (standard, non-paraxial). See Simulation for
the equation and the scheme, and LensFrameSolver for the
beam-following solver.
- class thunder4d.solver.UPPESolver(grid, medium, *, phi_max=0.02, dz_max=None, paraxial=False, self_steepening=True, absorber_frac=0.9, absorber_order=16, cache_size=4, kernels='auto')[source]
- Parameters:
phi_max (float) – maximum peak nonlinear phase per step [rad]; controls accuracy
dz_max (float) – maximum step [m] (default: a quarter of each propagated segment)
paraxial (bool) – use \(k_z \approx k - (k_x^2+k_y^2)/2k\)
self_steepening (bool) – frequency-dependent \(\gamma(\Omega)\) or constant \(n_2\omega_0/c\)
absorber_frac (float) – soft boundary absorbers reach 1/e at this fraction of the half-window (spatial, spectral and temporal versions)
absorber_order (int) – super-Gaussian order of the absorbers
cache_size (int) – number of linear propagators \(e^{iDh}\) kept in memory (each is one full field array)
kernels (str) – array operations between the FFTs on the CPU:
"auto"(Numba if installed, else NumPy; always NumPy/CuPy on the GPU),"numba"or"numpy"(see Numba kernels (CPU))
State:
B(accumulated on-axis peak B-integral [rad]),nsteps,z(propagated distance [m]),k0,k1,n2,D(linear operator),igamma,kernels("numba"or"numpy", as resolved).- propagate(Aw, L)[source]
Propagate over
L[m] with the adaptive split-step scheme and return the new field. If \(n_2 = 0\), a single exact linear step is used.
- nonlinear(Aw, track=False)[source]
Kerr right-hand side \(i\gamma\,\mathcal F_t[|A|^2A]\). With
track=Trueit updates the peak intensity used for step control. Override it to add physics (see Simulation).
- absorb(Aw, temporal=False)[source]
Apply the spatial and spectral absorbers (and the temporal one if requested).
Note
MPCSimulationapplies the absorbers twice per pass (at the mirror and at the centre), not at every step, so their filtering effect is small and independent of the step count.