coulomb 0.5.0

Library for electrolytes and electrostatic interactions
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
/// Trait for objects that has an ionic strength
pub trait IonicStrength {
    /// Get the ionic strength in mol/l
    ///
    /// The default implementation returns `None`.
    fn ionic_strength(&self) -> Option<f64> {
        None
    }
    /// Try to set the ionic strength in mol/l
    ///
    /// The default implementation returns an error.
    fn set_ionic_strength(&mut self, _ionic_strength: f64) -> crate::Result<()> {
        Err(crate::Error::Unsupported("setting the ionic strength"))
    }
}