use sciforge::hub::prelude::biology::population::logistic_growth;
pub struct Population {
pub species_name: &'static str,
pub count: f64,
pub carrying_capacity: f64,
pub intrinsic_growth_rate: f64,
}
impl Population {
pub fn growth_rate(&self) -> f64 {
logistic_growth(
self.count,
self.intrinsic_growth_rate,
self.carrying_capacity,
)
}
}