ModelParam

class ModelParam

Model parameters depend upon site types, such as epsilon, sigma, etc. These parameters may also be mixed between two different site types. Each model parameter has an assumed combining rule.

Subclassed by feasst::Anisotropic, feasst::Charge, feasst::CosPatchAngle, feasst::CutOff, feasst::CutoffOuter, feasst::DeltaSigma, feasst::Director, feasst::EnergyAtCutOff, feasst::EnergyDerivAtCutOff, feasst::Epsilon, feasst::Gamma, feasst::Lambda, feasst::MieLambdaA, feasst::MieLambdaR, feasst::MiePrefactor, feasst::ModelLJShapeEnergyAtCutoff, feasst::PatchAngle, feasst::Sigma, feasst::SpherocylinderLength

Public Functions

void add(const double value)

Add a new site type.

void set(const int site_type, const double value)

Set the value of the site type.

void add(const Site &site, const double default_value = 0)

Add a new site type. If the site does not contain the model parameter, then add the default value.

void add(const Particle &particle)

Add all site types in particle.

void mix()

Compute the mixed values.

void set_mixed(const int site_type1, const int site_type2, const double value)

Set the mixed value of the site types.

void set_max_and_mixed()

Compute and store the maximum mixed value.

double value(const int type) const

Return the value.

const std::vector<double> &values() const

Return the values.

double mixed_value(const int type1, const int type2) const

Return the mixed value.

const std::vector<std::vector<double>> &mixed_values() const

Return the mixed values.

int size() const

Return the number of values.

double max() const

Return the maximum.

double mixed_max() const

Return the mixed maximum.

virtual void set_param(const ModelParams &existing)

Define new parameters modeled after the existing ones.

std::string str(std::vector<std::string> *site_type_names = NULL) const

Return as a human readable string.

param site_type_names:

If provided, write the names of the site types instead of the indices.