treams.SphericalWaveBasis.defaultlmax¶
- static SphericalWaveBasis.defaultlmax(dim, nmax=1)¶
Calculate the default mode order for a given length.
Given the dimension of the T-matrix return the estimated maximal value of l. This is the inverse of
defaultdim()
. A value of zero is allowed for empty T-matrices.Example
>>> SphericalWaveBasis.defaultlmax(len(SphericalWaveBasis.default(3))) 3
- Parameters:
dim (int) – Dimension of the T-matrix, respectively number of modes.
nmax (int, optional) – Number of particles, defaults to 1.
- Returns:
int