[]Struct lumol::Interactions

pub struct Interactions {
    pub coulomb: Option<Box<dyn CoulombicPotential + 'static, Global>>,
    pub globals: Vec<Box<dyn GlobalPotential + 'static, Global>>,
    // some fields omitted
}

The Interaction type hold all data about the potentials in the system.

Its main role is to store and provide access

Fields

coulomb: Option<Box<dyn CoulombicPotential + 'static, Global>>

Coulombic potential solver

globals: Vec<Box<dyn GlobalPotential + 'static, Global>>

Global potentials

Implementations

impl Interactions

pub fn new() -> Interactions

Create a new empty Interactions

pub fn set_pair(&mut self, (&str, &str), potential: PairInteraction)

Set the pair interaction potential for atoms with types i and j

pub fn set_bond(
    &mut self,
    (&str, &str),
    potential: Box<dyn BondPotential + 'static, Global>
)

Set the bond interaction potential for atoms with types i and j

pub fn set_angle(
    &mut self,
    (&str, &str, &str),
    potential: Box<dyn AnglePotential + 'static, Global>
)

Set the angle interaction potential for atoms with types i, j, and k

pub fn set_dihedral(
    &mut self,
    (&str, &str, &str, &str),
    potential: Box<dyn DihedralPotential + 'static, Global>
)

Set the dihedral angle interaction potential for atoms with types i, j, k, and m.

impl Interactions

pub fn pair(
    &self,
    pair: (ParticleKind, ParticleKind)
) -> Option<&PairInteraction>

Get the pair interactions corresponding to the pair, if any exists.

pub fn bond(
    &self,
    bond: (ParticleKind, ParticleKind)
) -> Option<&dyn BondPotential>

Get the bond interactions corresponding to the bond, if any exists.

pub fn angle(
    &self,
    angle: (ParticleKind, ParticleKind, ParticleKind)
) -> Option<&dyn AnglePotential>

Get the angle interactions corresponding to the angle, if any exists.

pub fn dihedral(
    &self,
    dihedral: (ParticleKind, ParticleKind, ParticleKind, ParticleKind)
) -> Option<&dyn DihedralPotential>

Get the dihedral interactions corresponding to the dihedral, if any exists.

pub fn maximum_cutoff(&self) -> Option<f64>

Get maximum cutoff from coulomb, pairs and global interactons.

Trait Implementations

impl Clone for Interactions

Auto Trait Implementations

impl !RefUnwindSafe for Interactions

impl Send for Interactions

impl Sync for Interactions

impl Unpin for Interactions

impl !UnwindSafe for Interactions

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Pointable for T

type Init = T

The type for initializers.

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,