17#ifndef CUTOFFFUNCTION_H
18#define CUTOFFFUNCTION_H
112 double f(
double r)
const;
118 double df(
double r)
const;
126 void fdf(
double r,
double&
fc,
double& dfc)
const;
129 static double const PI;
131 static double const E;
158 double fHARD (
double r)
const;
159 double dfHARD (
double r)
const;
160 void fdfHARD (
double r,
double&
fc,
double& dfc)
const;
162 double fCOS (
double r)
const;
163 double dfCOS (
double r)
const;
164 void fdfCOS (
double r,
double&
fc,
double& dfc)
const;
166 double fTANHU(
double r)
const;
167 double dfTANHU(
double r)
const;
168 void fdfTANHU(
double r,
double&
fc,
double& dfc)
const;
170 double fTANH (
double r)
const;
171 double dfTANH (
double r)
const;
172 void fdfTANH (
double r,
double&
fc,
double& dfc)
const;
174 double fCORE (
double r)
const;
175 double dfCORE (
double r)
const;
176 void fdfCORE (
double r,
double&
fc,
double& dfc)
const;
200 if (r >=
rc)
return 0.0;
201 return (this->*
fPtr)(r);
206 if (r >=
rc)
return 0.0;
207 return (this->*
dfPtr)(r);
double fHARD(double r) const
CutoffType
List of available cutoff function types.
double rci
Inner cutoff for cutoff function types which allow shifting.
static double const TANH_PRE
double fCORE(double r) const
void fdfCOS(double r, double &fc, double &dfc) const
void fdfHARD(double r, double &fc, double &dfc) const
double f(double r) const
Cutoff function .
void fdfTANH(double r, double &fc, double &dfc) const
double rcinv
Inverse cutoff radius .
double fTANHU(double r) const
void fdfTANHU(double r, double &fc, double &dfc) const
double iw
Inverse width of cutoff function .
void fdf(double r, double &fc, double &dfc) const
Calculate cutoff function and derivative .
void fdfCORE(double r, double &fc, double &dfc) const
CutoffType getCutoffType() const
Getter for cutoffType.
double fTANH(double r) const
void setCutoffParameter(double const alpha)
Set parameter for polynomial cutoff function (CT_POLY).
double(CutoffFunction::* fPtr)(double r) const
Function pointer to f.
double dfCOS(double r) const
double fCOS(double r) const
CutoffFunction()
Constructor, initializes to ´CT_HARD´.
double dfTANH(double r) const
double dfCORE(double r) const
double(CutoffFunction::* dfPtr)(double r) const
Function pointer to df.
double getCutoffParameter() const
Getter for alpha.
double dfTANHU(double r) const
void setCutoffType(CutoffType const cutoffType)
Set cutoff type.
double rc
Outer cutoff radius .
double getCutoffRadius() const
Getter for rc.
CutoffType cutoffType
Cutoff function type.
double alpha
Cutoff function parameter for CT_POLYn and CT_EXP .
double dfHARD(double r) const
CoreFunction core
Core functions used by POLYN, if any.
double df(double r) const
Derivative of cutoff function .
void setCutoffRadius(double const cutoffRadius)
Set cutoff radius.
void(CutoffFunction::* fdfPtr)(double r, double &fc, double &dfc) const
Function pointer to fdf.