pub trait Li2<T> {
// Required method
fn li2(&self) -> T;
}
Expand description
Provides the 2nd order polylogarithm (dilogarithm) function
li2()
of a number of type T
.
Required Methods§
Implementations on Foreign Types§
source§impl Li2<Complex<f64>> for Complex<f64>
impl Li2<Complex<f64>> for Complex<f64>
source§fn li2(&self) -> Complex<f64>
fn li2(&self) -> Complex<f64>
Returns the dilogarithm of a complex number of type
Complex<f64>
.
This function has been translated from the SPheno package.
§Example:
use num::complex::Complex;
use polylog::Li2;
assert!((Complex::new(1.0_f64, 1.0_f64).li2() - Complex::new(0.6168502750680849_f64, 1.4603621167531195_f64)).norm() < 2.0_f64*std::f64::EPSILON);