You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
//! The simulation of biological cells, which is as low-level as we go.
|
|
|
|
pub struct Cell {
|
|
x: f64,
|
|
y: f64
|
|
}
|
|
|
|
impl Cell {
|
|
pub fn distance_from_origin(&self) -> f64 {
|
|
f64::hypot(self.x, self.y)
|
|
}
|
|
}
|