pub struct SelOwnBoundMut<'a> { /* private fields */ }Expand description
Read-write bound subsystem having access to all fields of Topology and State
Implementations§
Source§impl SelOwnBoundMut<'_>
impl SelOwnBoundMut<'_>
Sourcepub fn into_unbound(self) -> Sel
pub fn into_unbound(self) -> Sel
Create new sub-selection based on provided definition.
pub fn into_index(self) -> Sel
pub fn clone_index(&self) -> Sel
Trait Implementations§
Source§impl IndexSliceProvider for SelOwnBoundMut<'_>
impl IndexSliceProvider for SelOwnBoundMut<'_>
fn get_index_slice(&self) -> &[usize]
Source§impl Selectable for SelOwnBoundMut<'_>
impl Selectable for SelOwnBoundMut<'_>
Source§fn select(&self, def: impl SelectionDef) -> Result<Sel, SelectionError>
fn select(&self, def: impl SelectionDef) -> Result<Sel, SelectionError>
Create new unbound sub-selection based on provided definition.
Source§impl SelectionLogic for SelOwnBoundMut<'_>
impl SelectionLogic for SelOwnBoundMut<'_>
type DerivedSel = Sel
fn clone_with_index(&self, index: SVec) -> Self::DerivedSel
fn or(&self, rhs: &impl IndexSliceProvider) -> Self::DerivedSel
fn and( &self, rhs: &impl IndexSliceProvider, ) -> Result<Self::DerivedSel, SelectionError>
fn minus( &self, rhs: &impl IndexSliceProvider, ) -> Result<Self::DerivedSel, SelectionError>
fn invert(
&self,
rhs: &impl IndexSliceProvider,
) -> Result<Self::DerivedSel, SelectionError>where
Self: SystemProvider,
Source§impl SystemMutProvider for SelOwnBoundMut<'_>
impl SystemMutProvider for SelOwnBoundMut<'_>
fn get_system_mut(&mut self) -> *mut System
Source§impl SystemProvider for SelOwnBoundMut<'_>
impl SystemProvider for SelOwnBoundMut<'_>
fn get_system_ptr(&self) -> *const System
Auto Trait Implementations§
impl<'a> Freeze for SelOwnBoundMut<'a>
impl<'a> RefUnwindSafe for SelOwnBoundMut<'a>
impl<'a> Send for SelOwnBoundMut<'a>
impl<'a> Sync for SelOwnBoundMut<'a>
impl<'a> Unpin for SelOwnBoundMut<'a>
impl<'a> UnsafeUnpin for SelOwnBoundMut<'a>
impl<'a> !UnwindSafe for SelOwnBoundMut<'a>
Blanket Implementations§
Source§impl<T> AtomIterMutProvider for Twhere
T: AtomPosAnalysisMut,
impl<T> AtomIterMutProvider for Twhere
T: AtomPosAnalysisMut,
fn iter_atoms_mut(&mut self) -> impl AtomMutIterator<'_>
Source§fn set_same_name(&mut self, val: &str)where
Self: Sized,
fn set_same_name(&mut self, val: &str)where
Self: Sized,
Sets same name to all selected atoms
Source§fn set_same_resname(&mut self, val: &str)where
Self: Sized,
fn set_same_resname(&mut self, val: &str)where
Self: Sized,
Sets same resname to all selected atoms
Source§fn set_same_resid(&mut self, val: i32)where
Self: Sized,
fn set_same_resid(&mut self, val: i32)where
Self: Sized,
Sets same resid to all selected atoms
Source§fn set_same_chain(&mut self, val: char)where
Self: Sized,
fn set_same_chain(&mut self, val: char)where
Self: Sized,
Sets same chain to all selected atoms
Source§fn set_same_mass(&mut self, val: f32)where
Self: Sized,
fn set_same_mass(&mut self, val: f32)where
Self: Sized,
Sets same mass to all selected atoms
Source§fn set_same_bfactor(&mut self, val: f32)where
Self: Sized,
fn set_same_bfactor(&mut self, val: f32)where
Self: Sized,
Sets same B-factor to all selected atoms
Source§impl<T> AtomIterProvider for Twhere
T: AtomPosAnalysis,
impl<T> AtomIterProvider for Twhere
T: AtomPosAnalysis,
fn iter_atoms(&self) -> impl AtomIterator<'_>
Source§impl<T> AtomParIterMutProvider for Twhere
T: AtomPosAnalysisMut + IndexParProvider,
impl<T> AtomParIterMutProvider for Twhere
T: AtomPosAnalysisMut + IndexParProvider,
fn par_iter_atoms_mut(&mut self) -> impl IndexedParallelIterator
Source§impl<T> AtomParIterProvider for Twhere
T: AtomPosAnalysis + IndexParProvider,
impl<T> AtomParIterProvider for Twhere
T: AtomPosAnalysis + IndexParProvider,
fn par_iter_atoms(&self) -> impl IndexedParallelIterator
Source§impl<T> AtomPosAnalysis for Twhere
T: SystemProvider + IndexProvider,
impl<T> AtomPosAnalysis for Twhere
T: SystemProvider + IndexProvider,
fn atoms_ptr(&self) -> *const Atom
fn coords_ptr(&self) -> *const OPoint<f32, Const<3>>
Source§fn split_par<F, R>(&self, func: F) -> Result<ParSplit, SelectionError>
fn split_par<F, R>(&self, func: F) -> Result<ParSplit, SelectionError>
Creates a parallel split based on provided closure.
A closure takes a Particle and returns a distinct value for each piece.
New selection is created whenever new return value differes from the previous one.
fn split<RT, F>(&self, func: F) -> impl Iterator<Item = Sel>
fn split_resindex(&self) -> impl Iterator<Item = Sel>
Source§fn whole_attr<T>(&self, attr_fn: fn(&Atom) -> &T) -> Sel
fn whole_attr<T>(&self, attr_fn: fn(&Atom) -> &T) -> Sel
Creates an “expanded” selection that includes all atoms with the same attributes as encountered in current selection.
Provided closure takes an Atom and returns an “attribute” value (for example resid, resindex, chain).
All atoms in the parent Topology that have the same attribute as any atom of the current selection will be selected.
Functionally this method is equivalent to “same as” selections in VMD or Gromacs. Read more
Source§fn whole_residues(&self) -> Sel
fn whole_residues(&self) -> Sel
Selects whole residiues present in the current selection (in terms of resindex)
Source§fn whole_chains(&self) -> Sel
fn whole_chains(&self) -> Sel
Selects whole chains present in the current selection
Source§impl<T> AtomPosAnalysisMut for Twhere
T: SystemMutProvider + IndexProvider,
impl<T> AtomPosAnalysisMut for Twhere
T: SystemMutProvider + IndexProvider,
fn atoms_ptr_mut(&mut self) -> *mut Atom
fn coords_ptr_mut(&mut self) -> *mut Pos
Source§impl<T> BondIterProvider for Twhere
T: NonAtomPosAnalysis,
impl<T> BondIterProvider for Twhere
T: NonAtomPosAnalysis,
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> BoxMutProvider for Twhere
T: NonAtomPosAnalysisMut,
impl<T> BoxMutProvider for Twhere
T: NonAtomPosAnalysisMut,
fn get_box_mut(&mut self) -> Option<&mut PeriodicBox>
Source§impl<T> BoxProvider for Twhere
T: NonAtomPosAnalysis,
impl<T> BoxProvider for Twhere
T: NonAtomPosAnalysis,
Source§fn get_box(&self) -> Option<&PeriodicBox>
fn get_box(&self) -> Option<&PeriodicBox>
Get reference to the periodic box or
None if there is no box.Source§fn require_box(&self) -> Result<&PeriodicBox, PeriodicBoxError>
fn require_box(&self) -> Result<&PeriodicBox, PeriodicBoxError>
Get reference to the periodic box or an error if there is no box.
Source§impl<T> IndexParProvider for Twhere
T: IndexSliceProvider,
impl<T> IndexParProvider for Twhere
T: IndexSliceProvider,
fn par_iter_index(&self) -> impl IndexedParallelIterator
Source§impl<T> IndexProvider for Twhere
T: IndexSliceProvider,
impl<T> IndexProvider for Twhere
T: IndexSliceProvider,
unsafe fn get_index_unchecked(&self, i: usize) -> usize
fn iter_index(&self) -> impl Iterator<Item = usize>
fn first_index(&self) -> usize
fn last_index(&self) -> usize
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> LenProvider for Twhere
T: IndexSliceProvider,
impl<T> LenProvider for Twhere
T: IndexSliceProvider,
Source§impl<T> MassIterProvider for Twhere
T: AtomIterProvider,
impl<T> MassIterProvider for Twhere
T: AtomIterProvider,
fn iter_masses(&self) -> impl Iterator<Item = f32>
Source§impl<T> MeasureAtomPos for Twhere
T: AtomPosAnalysis,
impl<T> MeasureAtomPos for Twhere
T: AtomPosAnalysis,
Source§impl<T> MeasureMasses for Twhere
T: AtomPosAnalysis,
impl<T> MeasureMasses for Twhere
T: AtomPosAnalysis,
Source§fn center_of_mass(&self) -> Result<Pos, MeasureError>
fn center_of_mass(&self) -> Result<Pos, MeasureError>
Calculates the center of mass
Source§fn inertia(&self) -> Result<(Vector3f, Matrix3f), MeasureError>
fn inertia(&self) -> Result<(Vector3f, Matrix3f), MeasureError>
Calculates the moments and axes of inertia
Source§fn principal_transform(&self) -> Result<IsometryMatrix3<f32>, MeasureError>
fn principal_transform(&self) -> Result<IsometryMatrix3<f32>, MeasureError>
Computes transformation to principal axes of inertia
fn fit_transform(
&self,
other: &impl MeasureMasses,
) -> Result<IsometryMatrix3<f32>, MeasureError>where
Self: Sized,
Source§fn fit_transform_at_origin(
&self,
other: &impl MeasureMasses,
) -> Result<IsometryMatrix3<f32>, MeasureError>where
Self: Sized,
fn fit_transform_at_origin(
&self,
other: &impl MeasureMasses,
) -> Result<IsometryMatrix3<f32>, MeasureError>where
Self: Sized,
Like fit_transform but assumes both selections are centered at origin
Source§fn rmsd_mw(&self, other: &impl MeasureMasses) -> Result<f32, MeasureError>where
Self: Sized,
fn rmsd_mw(&self, other: &impl MeasureMasses) -> Result<f32, MeasureError>where
Self: Sized,
Calculates the mass-weighted Root Mean Square Deviation between two selections
Source§impl<T> MeasurePeriodic for Twhere
T: AtomPosAnalysis + NonAtomPosAnalysis,
impl<T> MeasurePeriodic for Twhere
T: AtomPosAnalysis + NonAtomPosAnalysis,
fn center_of_mass_pbc(&self) -> Result<Pos, MeasureError>
fn center_of_mass_pbc_dims(&self, dims: PbcDims) -> Result<Pos, MeasureError>
fn center_of_geometry_pbc(&self) -> Result<Pos, MeasureError>
fn center_of_geometry_pbc_dims( &self, dims: PbcDims, ) -> Result<Pos, MeasureError>
fn gyration_pbc(&self) -> Result<f32, MeasureError>
fn inertia_pbc(&self) -> Result<(Vector3f, Matrix3f), MeasureError>
fn principal_transform_pbc(&self) -> Result<IsometryMatrix3<f32>, MeasureError>
Source§impl<T> MeasurePos for Twhere
T: AtomPosAnalysis,
impl<T> MeasurePos for Twhere
T: AtomPosAnalysis,
Source§fn min_max(&self) -> (Pos, Pos)
fn min_max(&self) -> (Pos, Pos)
Returns the minimum and maximum coordinates across all dimensions
Source§fn center_of_geometry(&self) -> Pos
fn center_of_geometry(&self) -> Pos
Calculates the geometric center (centroid) of all positions
fn rmsd<S>(&self, other: &S) -> Result<f32, MeasureError>where
Self: Sized,
S: MeasurePos,
Source§impl<T> MeasureRandomAccess for Twhere
T: AtomPosAnalysis,
impl<T> MeasureRandomAccess for Twhere
T: AtomPosAnalysis,
Source§fn lipid_tail_order(
&self,
order_type: OrderType,
normals: &Vec<Vector3f>,
bond_orders: &Vec<u8>,
) -> Result<DVector<f32>, LipidOrderError>
fn lipid_tail_order( &self, order_type: OrderType, normals: &Vec<Vector3f>, bond_orders: &Vec<u8>, ) -> Result<DVector<f32>, LipidOrderError>
Computes order parameter of the lipid tail. Each position in Self is
supposed to represent a carbon atom of a single lipid tail. The size of the array
of normals is either
1 or N-2, where N is the number of position in Self.
In the first case the same normal is used for all bonds, in the second case each
bond in the range 1..N-1 has its own normal.
bonds_orders should contain either 1 or 2 for all N-1 bonds.
Formulas are taken from: Read moreSource§impl<T> ModifyPeriodic for Twhere
T: AtomPosAnalysisMut + NonAtomPosAnalysis,
impl<T> ModifyPeriodic for Twhere
T: AtomPosAnalysisMut + NonAtomPosAnalysis,
fn unwrap_simple_dim(&mut self, dims: PbcDims) -> Result<(), MeasureError>
fn unwrap_simple(&mut self) -> Result<(), MeasureError>
Source§impl<T> ModifyPos for Twhere
T: AtomPosAnalysisMut,
impl<T> ModifyPos for Twhere
T: AtomPosAnalysisMut,
Source§impl<T> ModifyRandomAccess for T
impl<T> ModifyRandomAccess for T
fn unwrap_connectivity(&mut self, cutoff: f32) -> Result<Vec<Sel>, MeasureError>where
Self: Selectable,
fn unwrap_connectivity_dim(
&mut self,
cutoff: f32,
dims: PbcDims,
) -> Result<Vec<Sel>, MeasureError>where
Self: Selectable,
Source§impl<T> MoleculeIterProvider for Twhere
T: NonAtomPosAnalysis,
impl<T> MoleculeIterProvider for Twhere
T: NonAtomPosAnalysis,
Source§impl<T> NonAtomPosAnalysis for Twhere
T: SystemProvider + IndexProvider,
impl<T> NonAtomPosAnalysis for Twhere
T: SystemProvider + IndexProvider,
Source§impl<T> NonAtomPosAnalysisMut for Twhere
T: SystemMutProvider + IndexProvider,
impl<T> NonAtomPosAnalysisMut for Twhere
T: SystemMutProvider + IndexProvider,
fn top_ptr_mut(&mut self) -> *mut Topology
fn st_ptr_mut(&mut self) -> *mut State
Source§impl<T> ParticleIterMutProvider for Twhere
T: AtomPosAnalysisMut,
impl<T> ParticleIterMutProvider for Twhere
T: AtomPosAnalysisMut,
fn iter_particle_mut(&mut self) -> impl Iterator<Item = ParticleMut<'_>>
Source§impl<T> ParticleIterProvider for Twhere
T: AtomPosAnalysis,
impl<T> ParticleIterProvider for Twhere
T: AtomPosAnalysis,
fn iter_particle(&self) -> impl Iterator<Item = Particle<'_>>
Source§impl<T> ParticleParIterMutProvider for Twhere
T: AtomPosAnalysisMut + IndexParProvider,
impl<T> ParticleParIterMutProvider for Twhere
T: AtomPosAnalysisMut + IndexParProvider,
fn par_iter_particle_mut(&mut self) -> impl IndexedParallelIterator
Source§impl<T> ParticleParIterProvider for Twhere
T: AtomPosAnalysis + IndexParProvider,
impl<T> ParticleParIterProvider for Twhere
T: AtomPosAnalysis + IndexParProvider,
fn par_iter_particle(&self) -> impl IndexedParallelIterator
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PosIterMutProvider for Twhere
T: AtomPosAnalysisMut,
impl<T> PosIterMutProvider for Twhere
T: AtomPosAnalysisMut,
fn iter_pos_mut(&mut self) -> impl PosMutIterator<'_>
Source§impl<T> PosIterProvider for Twhere
T: AtomPosAnalysis,
impl<T> PosIterProvider for Twhere
T: AtomPosAnalysis,
fn iter_pos(&self) -> impl PosIterator<'_>
Source§impl<T> PosParIterMutProvider for Twhere
T: AtomPosAnalysisMut + IndexParProvider,
impl<T> PosParIterMutProvider for Twhere
T: AtomPosAnalysisMut + IndexParProvider,
fn par_iter_pos_mut(&mut self) -> impl IndexedParallelIterator
Source§impl<T> PosParIterProvider for Twhere
T: AtomPosAnalysis + IndexParProvider,
impl<T> PosParIterProvider for Twhere
T: AtomPosAnalysis + IndexParProvider,
fn par_iter_pos(&self) -> impl IndexedParallelIterator
Source§impl<T> RandomAtomMutProvider for Twhere
T: AtomPosAnalysisMut,
impl<T> RandomAtomMutProvider for Twhere
T: AtomPosAnalysisMut,
unsafe fn get_atom_mut_unchecked(&mut self, i: usize) -> &mut Atom
fn get_atom_mut(&mut self, i: usize) -> Option<&mut Atom>
fn first_atom_mut(&mut self) -> &mut Atom
fn last_atom_mut(&mut self) -> &Atom
Source§impl<T> RandomAtomProvider for Twhere
T: AtomPosAnalysis,
impl<T> RandomAtomProvider for Twhere
T: AtomPosAnalysis,
Source§impl<T> RandomBondProvider for Twhere
T: NonAtomPosAnalysis,
impl<T> RandomBondProvider for Twhere
T: NonAtomPosAnalysis,
Source§impl<T> RandomMoleculeProvider for Twhere
T: NonAtomPosAnalysis,
impl<T> RandomMoleculeProvider for Twhere
T: NonAtomPosAnalysis,
fn num_molecules(&self) -> usize
unsafe fn get_molecule_unchecked(&self, i: usize) -> &[usize; 2]
fn get_molecule(&self, i: usize) -> Option<&[usize; 2]>
Source§fn split_mol_iter(&self) -> impl Iterator<Item = Sel>where
Self: Sized + IndexProvider,
fn split_mol_iter(&self) -> impl Iterator<Item = Sel>where
Self: Sized + IndexProvider,
Splits by molecule and returns an iterator over them.
If molecule is only partially contained in self then only this part is returned (molecules are clipped).
If there are no molecules in Topology return an empty iterator.
Source§impl<T> RandomParticleMutProvider for Twhere
T: AtomPosAnalysisMut,
impl<T> RandomParticleMutProvider for Twhere
T: AtomPosAnalysisMut,
unsafe fn get_particle_mut_unchecked(&mut self, i: usize) -> ParticleMut<'_>
fn first_particle_mut(&mut self) -> ParticleMut<'_>
fn last_particle_mut(&mut self) -> ParticleMut<'_>
fn get_particle_mut(&mut self, i: usize) -> Option<ParticleMut<'_>>
Source§impl<T> RandomParticleProvider for Twhere
T: AtomPosAnalysis,
impl<T> RandomParticleProvider for Twhere
T: AtomPosAnalysis,
unsafe fn get_particle_unchecked(&self, i: usize) -> Particle<'_>
fn first_particle(&self) -> Particle<'_>
fn last_particle(&self) -> Particle<'_>
fn get_particle(&self, i: usize) -> Option<Particle<'_>>
Source§impl<T> RandomPosMutProvider for Twhere
T: AtomPosAnalysisMut,
impl<T> RandomPosMutProvider for Twhere
T: AtomPosAnalysisMut,
Source§impl<T> RandomPosProvider for Twhere
T: AtomPosAnalysis,
impl<T> RandomPosProvider for Twhere
T: AtomPosAnalysis,
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.