pub struct Axon {
pub terminal: [f32; 3],
pub myelin: u8,
pub health: u8,
}Expand description
Transmission apparatus — carries signal to targets.
Fields§
§terminal: [f32; 3]Where the axon ends (target region)
myelin: u8Myelination level (0=unmyelinated, 255=fully myelinated) Higher myelin = faster conduction, better protection from decay
health: u8Survival pressure (0=dead/pruned, 255=maximally healthy) Decays when inactive, boosted when carrying spikes
Implementations§
Source§impl Axon
impl Axon
Sourcepub const fn myelinated(terminal: [f32; 3], myelin: u8) -> Self
pub const fn myelinated(terminal: [f32; 3], myelin: u8) -> Self
Create a healthy, myelinated axon.
Sourcepub const fn is_myelinated(&self) -> bool
pub const fn is_myelinated(&self) -> bool
Is this axon myelinated?
Sourcepub fn myelinate(&mut self, amount: u8)
pub fn myelinate(&mut self, amount: u8)
Apply myelination (gradual process based on myelin_affinity).
Sourcepub fn retract_toward(&mut self, soma_pos: [f32; 3], fraction: f32)
pub fn retract_toward(&mut self, soma_pos: [f32; 3], fraction: f32)
Retract axon toward soma by a fraction.
Sourcepub fn extend_toward(&mut self, target: [f32; 3], step: f32)
pub fn extend_toward(&mut self, target: [f32; 3], step: f32)
Extend axon away from soma toward target.
Trait Implementations§
impl Copy for Axon
impl StructuralPartialEq for Axon
Auto Trait Implementations§
impl Freeze for Axon
impl RefUnwindSafe for Axon
impl Send for Axon
impl Sync for Axon
impl Unpin for Axon
impl UnwindSafe for Axon
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