Expand description
Special functions for science and engineering problems.
Provides several mathematical functions that often appear in many different disciplines of science and engineering.
The goal of this package is to provide simple-to-use, pure-rust implementations without many dependencies. Rather than trying to exhaustively provide as many functions as possible or to cover all possible argument types and ranges, implementing widely used functions in an efficient way is the first priority.
Three types of input arguments are possible for indicating the position at which the function is evaluated.
- Point evaluation: a single position
e.g.,
sph_bessel_kind1_ordern_arg_real(order: usize, x: f64)
, - Range evaluation: Three floating point arguments,
start
,end
, andstep
to indicate the range (inclusive ofstart
and exclusive ofend
).step
can be negative, in which caseend
should be less thanstart
. e.g.,sph_bessel_kind1_ordern_arg_real_ranged(order: usize, start: f64, end: f64, step: f64)
- Iterator evaluation: a collection of positions that implements IntoIterator
e.g.,
sph_bessel_kind1_ordern_arg_real_iterable(order: usize, x_list: impl IntoIterator<Item = f64>
Functionsยง
- range_
to_ vec - Accept the three arguments indicating a range, and return a vector of that range. It currently panics if wrong arguments are entered.
- sph_
bessel_ kind1_ order0_ arg_ real - Spherical Bessel function of the first kind, order = 0 j_n(x) = \sqrt{\pi/{2x}}J_{n+0.5}(x)
- sph_
bessel_ kind1_ order0_ arg_ real_ iterable - Spherical Bessel function of the first kind, order = 0, an iterable input
- sph_
bessel_ kind1_ order0_ arg_ real_ ranged - Spherical Bessel function of the first kind, order = 0, a range input It currently panics if wrong arguments are entered.
- sph_
bessel_ kind1_ ordern_ arg_ real - Spherical Bessel function of the first kind, order = n It currently panics if wrong arguments are entered.
- sph_
bessel_ kind1_ ordern_ arg_ real_ iterable - Spherical Bessel function of the first kind, order = n, an iterable input It currently panics if wrong arguments are entered.
- sph_
bessel_ kind1_ ordern_ arg_ real_ ranged - Spherical Bessel function of the first kind, order = n, a range input It currently panics if wrong arguments are entered.
- sph_
bessel_ kind2_ order0_ arg_ real - Spherical Bessel function of the second kind, order = 0 j_n(x) = \sqrt{\pi/{2x}}Y_{n+0.5}(x)
- sph_
bessel_ kind2_ order0_ arg_ real_ iterable - Spherical Bessel function of the second kind, order = 0, an iterable input
- sph_
bessel_ kind2_ order0_ arg_ real_ ranged - Spherical Bessel function of the second kind, order = 0, a range input It currently panics if wrong arguments are entered.
- sph_
bessel_ kind2_ ordern_ arg_ real - Spherical Bessel function of the second kind, order = n It currently panics if wrong arguments are entered.
- sph_
bessel_ kind2_ ordern_ arg_ real_ iterable - Spherical Bessel function of the second kind, order = n, an iterable input It currently panics if wrong arguments are entered.
- sph_
bessel_ kind2_ ordern_ arg_ real_ ranged - Spherical Bessel function of the second kind, order = n, a range input It currently panics if wrong arguments are entered. In the future the return type may be changed to Results to deal with errors graciously.