pub struct QuantumState {
pub amplitudes: Vec<f32>,
pub phases: Vec<f32>,
pub entanglement_matrix: Vec<Vec<f32>>,
pub probabilities: Vec<f32>,
}Expand description
Quantum state representation for vector search
Fields§
§amplitudes: Vec<f32>Amplitude coefficients for superposition states
phases: Vec<f32>Phase information for quantum interference
entanglement_matrix: Vec<Vec<f32>>Entanglement matrix between states
probabilities: Vec<f32>Probability distribution over states
Implementations§
Source§impl QuantumState
impl QuantumState
Sourcepub fn apply_superposition(&mut self, config: &QuantumSearchConfig)
pub fn apply_superposition(&mut self, config: &QuantumSearchConfig)
Apply quantum superposition to create multiple search paths
Sourcepub fn create_entanglement(&mut self, config: &QuantumSearchConfig)
pub fn create_entanglement(&mut self, config: &QuantumSearchConfig)
Create entanglement between quantum states
Sourcepub fn apply_interference(&mut self, target_similarity: f32)
pub fn apply_interference(&mut self, target_similarity: f32)
Apply quantum interference patterns
Sourcepub fn quantum_tunneling(&mut self, barrier_height: f32) -> Vec<usize>
pub fn quantum_tunneling(&mut self, barrier_height: f32) -> Vec<usize>
Simulate quantum tunneling for optimization landscape exploration
Sourcepub fn measure(&mut self, config: &QuantumSearchConfig) -> Vec<usize>
pub fn measure(&mut self, config: &QuantumSearchConfig) -> Vec<usize>
Measure quantum state and collapse to classical result
Trait Implementations§
Source§impl Clone for QuantumState
impl Clone for QuantumState
Source§fn clone(&self) -> QuantumState
fn clone(&self) -> QuantumState
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for QuantumState
impl RefUnwindSafe for QuantumState
impl Send for QuantumState
impl Sync for QuantumState
impl Unpin for QuantumState
impl UnwindSafe for QuantumState
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.