pub struct NearestNeighborSuggestor;Expand description
Routes a vehicle via Nearest-Neighbour heuristic with time-window feasibility check.
Algorithm: O(n²) — at each stop, visit the nearest unvisited customer whose time window is still reachable. Backtracks to depot when no further customer is reachable.
Confidence: capped at 0.60 — nearest-neighbour can be 20-25% worse than optimal on real instances.
Trait Implementations§
Source§impl Suggestor for NearestNeighborSuggestor
impl Suggestor for NearestNeighborSuggestor
Source§fn dependencies(&self) -> &[ContextKey]
fn dependencies(&self) -> &[ContextKey]
Context keys this suggestor reads from. Read more
Source§fn complexity_hint(&self) -> Option<&'static str>
fn complexity_hint(&self) -> Option<&'static str>
Algorithmic complexity of this suggestor’s core computation. Read more
Auto Trait Implementations§
impl Freeze for NearestNeighborSuggestor
impl RefUnwindSafe for NearestNeighborSuggestor
impl Send for NearestNeighborSuggestor
impl Sync for NearestNeighborSuggestor
impl Unpin for NearestNeighborSuggestor
impl UnsafeUnpin for NearestNeighborSuggestor
impl UnwindSafe for NearestNeighborSuggestor
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