1 #ifndef MD_COULOMB_POTENTIAL_CPP 2 #define MD_COULOMB_POTENTIAL_CPP 11 #include "MdCoulombPotential.h" 12 #include <mcMd/simulation/System.h> 13 #include <mcMd/simulation/Simulation.h> 24 : isInitialized_(false),
43 UTIL_THROW(
"Unimplemented virtual set method");
55 UTIL_THROW(
"Unimplemented virtual get method");
166 pressures[i] = temp(i,i);
180 pressure += temp(i, i);
virtual double get(std::string name) const
Get an interaction parameter value, identified by a string.
const int Dimension
Dimensionality of space.
Setable< double > kSpaceEnergy_
K-space part of Coulomb energy.
A Vector is a Cartesian vector.
virtual void set(std::string name, double value)
Modify an interaction parameter, identified by a string.
double rSpaceEnergy()
Return short-range r-space part of Coulomb energy.
Tensor rSpaceStress()
Return the r-space stress (compute if necessary).
bool isSet() const
Is this object set (is the value known)?
double rSpaceEnergy()
Return the r-space energy (compute if necessary).
virtual void computeStress()=0
Compute kspace part of Coulomb stress.
A Tensor represents a Cartesian tensor.
virtual void unsetEnergy()
Unset k-space energy.
Tensor stress()
Get total Coulomb stress.
const T & value() const
Return value (if set).
Setable< Tensor > kSpaceStress_
K-space part of Coulomb stress.
#define UTIL_THROW(msg)
Macro for throwing an Exception, reporting function, file and line number.
Tensor kSpaceStress()
Get long-range k-space part of Coulomb stress.
virtual ~MdCoulombPotential()
Destructor (does nothing).
double kSpaceEnergy()
Get long-range k-space part of Coulomb energy.
EwaldRSpaceAccumulator rSpaceAccumulator_
Short-range real space energy and stress contributions.
Utility classes for scientific computation.
virtual void computeEnergy()=0
Calculate the long range kspace part of Coulomb energy.
void unset()
Unset the value (mark as unknown).
Single-processor Monte Carlo (MC) and molecular dynamics (MD).
bool hasWaves_
Are waves and k-space potential up to date? Unset if boundary or parameters change.
MdCoulombPotential()
Constructor.
void setClassName(const char *className)
Set class name string.
double pressure()
Get total Coulomb pressure.
virtual void unsetStress()
Unset k-space stress.
double energy()
Get total Coulomb energy.
void unsetWaves()
Unset all data that depends on the Boundary.
Tensor rSpaceStress()
Return short-range r-space part of Coulomb stress.