Acceptance

class Acceptance

This object contains information necessary for Criteria to make a decision on whether or not to accept or reject a trial.

Public Functions

double ln_metropolis_prob() const

Return the natural logarithm of the Metropolis acceptance probability.

void set_ln_metropolis_prob(const double prob = 0)

Set the above quantity.

void add_to_ln_metropolis_prob(const double prob = 0)

Add to the above quantity.

bool reject() const

Return whether or not to reject the trial outright.

void set_reject(const bool reject = false)

Set the above quantity.

bool endpoint() const

Return whether or not to the trial was at a macrostate endpoint.

void set_endpoint(const bool endpoint = true)

Set the above quantity.

void reset()

Reset all stored quantities before each trial.

int updated(const int conf = 0) const

Return 1 if this conf has updated energy.

double energy_new(const int config = 0) const

Return the energy of the new configuration.

void set_energy_new(const double energy, const int config = 0)

Set the above quantity.

void add_to_energy_new(const double energy, const int config = 0)

Add to the above quantity.

int num_configurations() const

Return the configuration indices.

const std::vector<double> &energy_profile_new(const int config = 0) const

Return the energy profile of the new configuration.

void set_energy_profile_new(const std::vector<double> &energy, const int config = 0)

Set the above quantity.

void add_to_energy_profile_new(const std::vector<double> &energy, const int config = 0)

Add to the above quantity.

void subtract_from_energy_profile_new(const std::vector<double> &energy, const int config = 0)

Subtract from the above quantity.

double energy_old(const int config = 0) const

Return the energy of the old configuration.

void set_energy_old(const double energy, const int config = 0)

Set the above quantity.

void add_to_energy_old(const double energy, const int config = 0)

Add to the above quantity.

const std::vector<double> &energy_profile_old(const int config = 0) const

Return the energy profile of the old configuration.

void set_energy_profile_old(const std::vector<double> &energy, const int config = 0)

Set the above quantity.

void add_to_energy_profile_old(const std::vector<double> &energy, const int config = 0)

Add to the above quantity.

double energy_ref(const int config = 0) const

Return the energy of the reference.

void set_energy_ref(const double energy, const int config = 0)

Set the above quantity.

int macrostate_shift(const int config = 0) const

Return the shift in the macrostate due to an optimization where Perturb does not completely update system until finalize. This assumes a particular macrostate is used for the given trial.

void add_to_macrostate_shift(const int shift, const int config = 0)

Add to the above.

void add_to_perturbed(const Select &select, const int config = 0)

Add to perturbed selection and equate trial state.

void set_perturbed_state(const int state, const int config = 0)

Set perturbed trial state.

const Select &perturbed(const int config = 0) const

Return the perturbed selection.