qiu_classical_simulation.wave_optics.visualization
¶
Plots of transverse fields.
Functions:
-
plot_wavefunction–Plot the magnitude and the phase of a field over its samples, side by side.
plot_wavefunction
¶
plot_wavefunction(psi: ArrayLike, plot_size_scale: float = 1, normalize: bool = True, ylim: float | None = None) -> tuple[Figure, tuple[Axes, Axes]]
Plot the magnitude and the phase of a field over its samples, side by side.
Parameters:
-
psi(ArrayLike) –The amplitudes of the field.
-
plot_size_scale(float, default:1) –The scale of the figure size.
-
normalize(bool, default:True) –If True, plot the magnitude normalized to unit norm.
-
ylim(float | None, default:None) –The upper limit of the magnitude axis, if given.
Returns:
Source code in packages/qiu-classical-simulation/src/qiu_classical_simulation/wave_optics/visualization.py
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | |