Skip to content

Migration guide

Use exponax for deterministic functionality and exponax_spde for its stochastic add-on. Installing the add-on installs exponax.

Former name Replacement
exponax_spde.BaseStepper exponax.BaseStepper
exponax_spde.ForcedStepper exponax.ForcedStepper
exponax_spde.RepeatedStepper exponax.RepeatedStepper
exponax_spde.derivative exponax.derivative
exponax_spde.fft exponax.fft
exponax_spde.ifft exponax.ifft
exponax_spde.get_spectrum exponax.get_spectrum
exponax_spde.make_grid exponax.make_grid
exponax_spde.rollout exponax.rollout
exponax_spde.repeat exponax.repeat
exponax_spde.stack_sub_trajectories exponax.stack_sub_trajectories
exponax_spde.build_ic_set exponax.build_ic_set
exponax_spde.wrap_bc exponax.wrap_bc
exponax_spde.metrics exponax.metrics
exponax_spde.etdrk exponax.etdrk
exponax_spde.ic exponax.ic
exponax_spde.viz exponax.viz
exponax_spde.spectral exponax.spectral
exponax_spde.FourierInterpolator exponax.FourierInterpolator
exponax_spde.map_between_resolutions exponax.map_between_resolutions
exponax_spde.stepper.HeatEquation exponax.stepper.Diffusion
exponax_spde.stepper.Burgers exponax.stepper.Burgers
exponax_spde.stepper.generic exponax.stepper.generic
exponax_spde.stepper.reaction exponax.stepper.reaction
Deterministic names under exponax_spde.nonlin_fun Same names under exponax.nonlin_fun
Helpers under exponax_spde._spectral Public helpers under exponax.spectral
exponax_spde.stepper.stochastic.StochasticAllenCahn exponax_spde.StochasticAllenCahn or exponax_spde.stepper.StochasticAllenCahn
Warnings under exponax_spde.stepper.stochastic Same warning classes at the exponax_spde root

TamedPolynomialNonlinearFun is available at the root and under exponax_spde.nonlin_fun. Version 0.4 removes the temporary migration messages and the exponax_spde.stepper.stochastic import stub. Use the replacement paths above. Private vendored modules were removed.

Initial conditions

The required exponax 0.2.1 produces a single output channel for Discontinuities even on a multidimensional grid. Update shape expectations from (d, *N) to (1, *N) where older code observed repeated masks. SineWaves1d accepts traced offsets. Concrete offsets still follow its normalisation constraints. See exponax PR #110 for discontinuities and exponax PR #109 for traced sine offsets.

Extras

Use pip install "exponax[vape4d]" for optional volume rendering in the validation notebook. The docs extra was removed in 0.3 and restored for the documentation site in 0.4. The add-on retains its test and dev extras.

Noise normalisation from v0.1.0

The noise model defines the Fourier weights and the variance of the additive convolution.

Additive migration

The legacy draw counted \(h\) both in its base variance and through \(F_h\). It also multiplied circular complex samples by \(R_k\). The real inverse projects the last-axis boundary planes, halving their expected power. Let \(g_k=1/2\) on these planes and \(g_k=1\) elsewhere. At fixed \(\sigma\),

\[ \frac{V_{\rm new}}{V_{\rm old}} =\frac{P\sum w_k q_k F_h(L_k)} {h\sum w_k g_k R_k^2 q_k F_h(L_k)}. \]

In 1-D with even \(N\), white noise and negligible drift, the ratio is \(4/((N+2)h)\). A matching one-step intensity for an illustration uses \(\sigma_{\rm matched}=\sigma_{\rm old}\sqrt{(N+2)h/4}\) in that case. For other settings divide by the square root of the weighted ratio. One matched value preserves only the aggregate variance because interior and boundary mode ratios differ. Several high-resolution 2-D and 3-D examples received too much legacy noise, for example the 2-D \(N=256\) and 3-D \(N=32\) validation figures with \(h=0.0005\). Keep physical \(\sigma\) fixed in quantitative comparisons.

Multiplicative migration

The v0.1.0 draw counted time twice, used reconstruction scaling and applied the linear-convolution factor to the noise before multiplication. It also projected the state and stochastic product. Its Milstein term subtracted a field in place of \(v_W\) and carried an extra time-step factor. The variance change depends on the grid, colour, step size and state. Keep physical \(\sigma\) fixed in quantitative work. For an illustration, match the conditional one-step variance at its initial field if the legacy noise level matters. Such a match preserves one aggregate variance and can leave different modal power and mean.