pub fn angular_function(
parity_kind: SpheroidalParity,
m: i32,
n: i32,
c: f64,
eta: f64,
) -> SpecialResult<(f64, f64)>Expand description
Evaluate the spheroidal angular function S_{m,n}(c, η) of the first kind
using the Flammer / Bouwkamp d-coefficient expansion, normalised to match
SciPy’s scipy.special.pro_ang1 / obl_ang1 convention.
The convention is non-Condon–Shortley: at c = 0,
S_{m,n}(0, η) = (-1)^m · [CS-Legendre P_n^m(η)] = [un-CS Legendre P_n^m(η)],
which matches the Meixner–Schäfke normalisation of Flammer (1957) §3.1.
§Algorithm
- Compute the Flammer eigenvalue
λand d-coefficients (withd[k_target] = 1). - Form the partial sums
S_raw(η) = Σ_p d_p · P_{m+r_p}^m(η),S_raw'(η) = Σ_p d_p · (P_{m+r_p}^m)'(η)in the Condon–Shortley basis. - Determine the Meixner–Schäfke normalisation factor
Kso that- even parity:
K · S_raw(0) = P_n^m(0)(Condon–Shortley); - odd parity:
K · S_raw'(0) = (P_n^m)'(0)(Condon–Shortley).
- even parity:
- Apply
(-1)^mfor the SciPy non-CS convention.
Returns (S, S').
§Errors
SpecialError::DomainErrorif(m, n)invalid or|η| > 1.SpecialError::ComputationErrorif d-coefficients fail to converge.