pub struct Sum<F: Field>(pub Vec<Box<dyn AmpLike<F>>>);
Tuple Fields§
§0: Vec<Box<dyn AmpLike<F>>>
Trait Implementations§
Source§impl<F: Field> AmpLike<F> for Sum<F>
impl<F: Field> AmpLike<F> for Sum<F>
Source§fn walk_mut(&mut self) -> Vec<&mut Amplitude<F>>
fn walk_mut(&mut self) -> Vec<&mut Amplitude<F>>
This method is similar to
AmpLike::walk
, but returns mutable references rather than
clones.Source§fn real(&self) -> Real<F>where
Self: Sized + 'static,
fn real(&self) -> Real<F>where
Self: Sized + 'static,
Take the real part of an
Amplitude
or Amplitude-like
struct.Source§fn imag(&self) -> Imag<F>where
Self: Sized + 'static,
fn imag(&self) -> Imag<F>where
Self: Sized + 'static,
Take the imaginary part of an
Amplitude
or Amplitude-like
struct.Source§impl<F: Field> AsTree for Sum<F>
impl<F: Field> AsTree for Sum<F>
Source§fn _get_tree(&self, bits: &mut Vec<bool>) -> String
fn _get_tree(&self, bits: &mut Vec<bool>) -> String
Prints the tree of an
AsTree
-implementor starting with a particular indentation structure
defined by bits
. A true
bit will print a vertical line, while a false
bit
will not.Source§fn get_tree(&self) -> String
fn get_tree(&self) -> String
Returns a string representing the node and its children with tree formatting.
Source§fn _get_indent(&self, bits: Vec<bool>) -> String
fn _get_indent(&self, bits: Vec<bool>) -> String
Returns a string with the proper indents for a given entry in
AsTree::get_tree
. A true
bit will yield a vertical line, while a
false
bit will not.Source§fn _get_intermediate(&self) -> String
fn _get_intermediate(&self) -> String
Returns a string with the intermediate branch symbol for a given entry in
AsTree::get_tree
.Source§fn _get_end(&self) -> String
fn _get_end(&self) -> String
Prints the a final branch for a given entry in
AsTree::get_tree
.Auto Trait Implementations§
impl<F> Freeze for Sum<F>
impl<F> !RefUnwindSafe for Sum<F>
impl<F> Send for Sum<F>
impl<F> Sync for Sum<F>
impl<F> Unpin for Sum<F>
impl<F> !UnwindSafe for Sum<F>
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<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.