[−][src]Trait qmc::sse::qmc_traits::DiagonalSubsection
Allows for mutations on subsections of the data.
Associated Types
type Args: MutateArgs
[src]
The type required for mutating p values.
Required methods
pub fn mutate_p<T, F>(
&mut self,
f: F,
p: usize,
t: T,
args: Self::Args
) -> (T, Self::Args) where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
[src]
&mut self,
f: F,
p: usize,
t: T,
args: Self::Args
) -> (T, Self::Args) where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
Mutate a single p value.
pub fn mutate_subsection<T, F>(
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
[src]
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
Mutate using a restricted prange and args. Allows for running on smaller subsections of the variables.
pub fn get_empty_args(
&mut self,
vars: SubvarAccess<'_, Self::Args>
) -> Self::Args
[src]
&mut self,
vars: SubvarAccess<'_, Self::Args>
) -> Self::Args
Get empty args for a subsection of variables, or from an existing set of args (does not clear).
pub fn fill_args_at_p(&self, p: usize, empty_args: Self::Args) -> Self::Args
[src]
Get the args required for mutation.
pub fn fill_args_at_p_with_hint<It>(
&self,
p: usize,
args: &mut Self::Args,
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,
[src]
&self,
p: usize,
args: &mut Self::Args,
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,
Use a list of ps to make args. Hint provides up to one ps per var in order.
pub fn return_args(&mut self, args: Self::Args)
[src]
Returns arg made for the mutation
pub fn get_propagated_substate_with_hint<It>(
&self,
p: usize,
substate: &mut [bool],
state: &[bool],
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,
[src]
&self,
p: usize,
substate: &mut [bool],
state: &[bool],
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,
Get the substate at p using ps to set values. Hint provides up to one ps per var in order. substate should start in p=0 configuration.
Provided methods
pub fn mutate_subsection_ops<T, F>(
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, &Self::Op, usize, T) -> (Option<Option<Self::Op>>, T),
[src]
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, &Self::Op, usize, T) -> (Option<Option<Self::Op>>, T),
Mutate ops using a restricted prange and args. Allows for running on smaller subsections of the variables.
pub fn iter_ops_above_p<T, F, G>(&self, p: usize, t: T, f: F, f_at_p: G) -> T where
F: Fn(usize, &Self::Node, T) -> (T, bool),
G: Fn(&Self::Node, T) -> (T, bool),
[src]
F: Fn(usize, &Self::Node, T) -> (T, bool),
G: Fn(&Self::Node, T) -> (T, bool),
Iterate over ops at indices less than or equal to p. Applies function f_at_p
only to the
op at p. Applies f
to all other ops above p.
Implementors
impl<O: Op + Clone> DiagonalSubsection for FastOpsTemplate<O>
[src]
type Args = FastOpMutateArgs
pub fn mutate_p<T, F>(
&mut self,
f: F,
p: usize,
t: T,
args: Self::Args
) -> (T, Self::Args) where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
[src]
&mut self,
f: F,
p: usize,
t: T,
args: Self::Args
) -> (T, Self::Args) where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
pub fn mutate_subsection<T, F>(
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
[src]
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, Option<&Self::Op>, T) -> (Option<Option<Self::Op>>, T),
pub fn mutate_subsection_ops<T, F>(
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, &Self::Op, usize, T) -> (Option<Option<Self::Op>>, T),
[src]
&mut self,
pstart: usize,
pend: usize,
t: T,
f: F,
args: Option<Self::Args>
) -> T where
F: Fn(&Self, &Self::Op, usize, T) -> (Option<Option<Self::Op>>, T),
pub fn get_empty_args(
&mut self,
vars: SubvarAccess<'_, FastOpMutateArgs>
) -> FastOpMutateArgs
[src]
&mut self,
vars: SubvarAccess<'_, FastOpMutateArgs>
) -> FastOpMutateArgs
pub fn fill_args_at_p(&self, p: usize, empty_args: Self::Args) -> Self::Args
[src]
pub fn fill_args_at_p_with_hint<It>(
&self,
p: usize,
args: &mut Self::Args,
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,
[src]
&self,
p: usize,
args: &mut Self::Args,
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,
pub fn return_args(&mut self, args: Self::Args)
[src]
pub fn get_propagated_substate_with_hint<It>(
&self,
p: usize,
substate: &mut [bool],
state: &[bool],
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,
[src]
&self,
p: usize,
substate: &mut [bool],
state: &[bool],
vars: &[usize],
hint: It
) where
It: IntoIterator<Item = Option<usize>>,