CoulombGalore
Classes | Typedefs | Enumerations | Functions | Variables
CoulombGalore Namespace Reference

Classes

class  EnergyImplementation
 
class  Ewald
 
class  Fanourgakis
 
class  Fennell
 
class  Plain
 
class  Poisson
 
class  qPotential
 
class  ReactionField
 
class  SchemeBase
 
class  Splined
 
class  Wolf
 
class  Zahn
 
class  ZeroDipole
 

Typedefs

typedef Eigen::Vector3d vec3
 

Enumerations

enum  Scheme {
  plain, ewald, reactionfield, wolf,
  poisson, qpotential, fanourgakis, zerodipole,
  zahn, fennell, qpotential5, spline
}
 

Functions

constexpr unsigned int binomial (signed int n, signed int k)
 
std::shared_ptr< SchemeBasecreateScheme (const nlohmann::json &j)
 
constexpr unsigned int factorial (unsigned int n)
 
double powi (double x, int n)
 
double qPochhammerSymbol (double q, int l=0, int P=300)
 
double qPochhammerSymbolDerivative (double q, int l=0, int P=300)
 
double qPochhammerSymbolSecondDerivative (double q, int l=0, int P=300)
 
double qPochhammerSymbolThirdDerivative (double q, int l=0, int P=300)
 

Variables

constexpr double infinity = std::numeric_limits<double>::infinity()
 

Detailed Description

Namespace containing all of CoulombGalore

Typedef Documentation

§ vec3

typedef Eigen::Vector3d CoulombGalore::vec3

Typedef for 3D vector such a position or dipole moment

Definition at line 39 of file coulombgalore.h.

Enumeration Type Documentation

§ Scheme

enum CoulombGalore::Scheme
strong

Enum defining all possible schemes

Definition at line 44 of file coulombgalore.h.

Function Documentation

§ factorial()

constexpr unsigned int CoulombGalore::factorial ( unsigned int  n)

Returns the factorial of 'n'. Note that 'n' must be positive semidefinite.

Note
Calculated at compile time and thus have no run-time overhead.

Definition at line 76 of file coulombgalore.h.

§ powi()

double CoulombGalore::powi ( double  x,
int  n 
)

n'th integer power of float

On GCC/Clang this will use the fast __builtin_powi function.

Definition at line 64 of file coulombgalore.h.

§ qPochhammerSymbol()

double CoulombGalore::qPochhammerSymbol ( double  q,
int  l = 0,
int  P = 300 
)

Help-function for the q-potential scheme.

Returns
q-Pochhammer Symbol
Parameters
qNormalized distance, q = r / Rcutoff
lType of base interaction, l=0 is ion-ion, l=1 is ion-dipole, l=2 is dipole-dipole etc.
PNumber of higher order moments to cancel

The parameters are explaind in term of electrostatic moment cancellation as used in the q-potential scheme.

\[ (a;q)_P = \prod_{n=1}^P(1-aq^{n-1}) \]

where \( a=q^l \). In the implementation we use that \( (q^l;q)_P = (1-q)^P\prod_{n=1}^P\sum_{k=0}^{n+l}q^k \) which gives simpler expressions for the derivatives.

More information here: http://mathworld.wolfram.com/q-PochhammerSymbol.html

Definition at line 101 of file coulombgalore.h.