pub struct PointCharge {
pub atomic_number: u8,
pub position: [f64; 3],
pub charge: f64,
}Expand description
A point charge source external to the QEq system.
This struct represents an atom from the environment (e.g., a protein residue) that contributes a fixed electrostatic potential to the QEq system but does not participate in charge redistribution. Unlike QEq atoms, these charges remain constant throughout the calculation.
Fields§
§atomic_number: u8The atomic number of the external atom, used to retrieve screening parameters.
This allows the solver to compute screened Coulomb integrals using the same STO/GTO formalism as internal atoms, ensuring physical consistency at short distances.
position: [f64; 3]The 3D position of the external charge in Cartesian coordinates (Ångströms).
charge: f64The fixed partial charge assigned to this atom (elementary charge units).
This value typically comes from a classical force field (e.g., AMBER, CHARMM) and remains constant throughout the QEq calculation.
Implementations§
Source§impl PointCharge
impl PointCharge
Sourcepub fn new(atomic_number: u8, position: [f64; 3], charge: f64) -> Self
pub fn new(atomic_number: u8, position: [f64; 3], charge: f64) -> Self
Creates a new point charge with the specified parameters.
§Arguments
atomic_number- The atomic number of the element.position- The 3D Cartesian coordinates in Ångströms.charge- The fixed partial charge in elementary charge units.
§Returns
A new PointCharge instance.
§Examples
use cheq::PointCharge;
let oxygen = PointCharge::new(8, [1.234, 5.678, 9.012], -0.5679);Trait Implementations§
Source§impl Clone for PointCharge
impl Clone for PointCharge
Source§fn clone(&self) -> PointCharge
fn clone(&self) -> PointCharge
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PointCharge
impl Debug for PointCharge
Source§impl PartialEq for PointCharge
impl PartialEq for PointCharge
impl Copy for PointCharge
impl StructuralPartialEq for PointCharge
Auto Trait Implementations§
impl Freeze for PointCharge
impl RefUnwindSafe for PointCharge
impl Send for PointCharge
impl Sync for PointCharge
impl Unpin for PointCharge
impl UnsafeUnpin for PointCharge
impl UnwindSafe for PointCharge
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DistributionExt for Twhere
T: ?Sized,
impl<T> DistributionExt for Twhere
T: ?Sized,
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>
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>
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 more