Small refactor

This commit is contained in:
2022-12-27 22:37:12 +01:00
parent 8e25826f91
commit e3906aebaa
6 changed files with 358 additions and 163 deletions

View File

@@ -9,9 +9,7 @@ pub struct Gaussian {
}
impl Gaussian {
pub fn new(mu: f64, sigma: f64) -> Self {
debug_assert!(sigma >= 0.0, "sigma must be equal or larger than 0.0");
pub const fn from_ms(mu: f64, sigma: f64) -> Self {
Gaussian { mu, sigma }
}