elements.catalog.segments_for_frequency

elements.catalog.segments_for_frequency(
    length,
    sound_speed,
    f_max,
    points_per_wavelength=12,
)

Smallest segment count N that keeps each segment acoustically compact at f_max.

A discretization composite resolves waves only where each segment is short against the wavelength (k dL << 1). With P points per wavelength, N >= P * f_max * L / c. Use it to auto-size :func:fanno_pipe / :func:tapered_duct from the highest analysis frequency rather than guessing.

Parameters

Name Type Description Default
length float Element length L [m]. required
sound_speed float A representative mean sound speed c [m/s] (e.g. solution.field("c").mean()). required
f_max float Highest analysis frequency [Hz] the chain must resolve. required
points_per_wavelength int Target points per wavelength P (default 12; 10-20 is typical). 12

Returns

Name Type Description
int The recommended segment count N (>= 1).
Back to top