Module sleplet.plot_methods

Methods to help in creating plots.

Functions

def calc_plot_resolution(L: int) ‑> int

Calculate appropriate resolution for given L.

Args

L
The spherical harmonic bandlimit.

Returns

The output spherical harmonic bandlimit to boost the resolution.

def compute_amplitude_for_noisy_mesh_plots(f: MeshCoefficients) ‑> float | None

For the noised mesh plots fix the amplitude.

Args

f
The mesh field value.

Returns

The noise adjusted maximum amplitude.

def compute_amplitude_for_noisy_sphere_plots(f: Coefficients) ‑> float | None

For the noised sphere plots fix the amplitude.

Args

f
The spherical field value.

Returns

The noise adjusted maximum amplitude value.

def find_max_amplitude(function: Coefficients,
*,
plot_type: str = 'real',
upsample: bool = True) ‑> float

For a given set of coefficients it finds the largest absolute value for a given plot type such that plots can have the same scale as the input.

Args

function
The Coefficients value to find the amplitude of.
plot_type
Select the real, imag, abs or sum value of the field.
upsample
Whether to upsample the output.

Returns

The maximum amplitude value.