class ChargeScreened : public feasst::ModelTwoBody

Compute energy between two point charges, \(q_i\) and \(q_j\) with a Gaussian screening cloud as utilized by the Ewald summation.

\(U = q_i q_j \chi erfc(\alpha r)/r\)

where \(erfc\) is the complimentary error function, \(r\) is the separation distance, and \(\chi\) is the charge conversion factor assuming the following units:

  1. length: Angstroms

  2. energy: kJ/mol

  3. charge: elementary

Avoid Coulomb explosion by returning a large number when \(r\) is near zero.

Public Functions

void precompute(const ModelParams &existing)

Precompute model parameters based on existing model parameters.

const Table1D *erfc(const double distance_squared) const

Return the erfc table.

void serialize(std::ostream &ostr) const

Output a serialized version of the existing model.


  • hard_sphere_threshold: return NEAR_INFINITY when distance is less than this threshold (default: 0.2).

  • erfc_table_size: size of linearly-interpolated tabular potential (default: 0). disable table if this value is less than or equal to zero.