pub enum Method {
Moore,
VonNeumann,
}Expand description
Any cellular automata has one of two ways to determine whether any given cell is the neighbor of any other cell. This enum allows choosing which method is used by an automaton to determine neighbors.
Variants§
Moore
The Moore method counts any cell as a neighbor of a given cell if that cell is next to it, even if they don’t share a face. More mathmatically, if any two cells have coordinates that are only off by one from each-other for any given component, they are neighbors.
VonNeumann
The Von Neumann method counts any cell as a neighbor of a given cell if the cells share a face, or are touching.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Method
impl RefUnwindSafe for Method
impl Send for Method
impl Sync for Method
impl Unpin for Method
impl UnwindSafe for Method
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more