eon.askmc#

Module Contents#

Classes#

ASKMC

This is a class to keep track of things associated with performing the Chatterjee & Voter accelerated superbasin KMC method.

Data#

API#

eon.askmc.logger#

‘getLogger(…)’

eon.askmc.processtable_head_fmt#

‘%7s %16s %11s %9s %16s %17s %8s %12s %7s\n’

eon.askmc.mod_processtable_head_fmt#

‘%7s %16s %11s %9s %16s %17s %8s %12s %12s\n’

eon.askmc.processtable_header#

None

eon.askmc.mod_processtable_header#

None

eon.askmc.processtable_line#

‘%7d %16.5f %11.5e %9d %16.5f %17.5e %8.5f %12.5e %7d\n’

class eon.askmc.ASKMC(kT, states, confidence, alpha, gamma, barrier_test_on, connection_test_on, sb_recycling_on, path_root, thermal_window, recycle_path)[source]#

This is a class to keep track of things associated with performing the Chatterjee & Voter accelerated superbasin KMC method.

Initialization

compile_process_table(current_state)[source]#

Load the normal process table, and replace all the rates edited by AS-KMC.

get_ratetable(current_state)[source]#

Generate a rate table according to the kT and thermal_window.

get_askmc_metadata()[source]#

Check to see if the AS-KMC data has been saved. If it hasn’t, simply use the correct starting values. Otherwise, read the current values.

save_askmc_metadata(sb_check_count, num_rate_changes)[source]#

Save the current values of the AS-KMC data.

get_real_process_table(current_state)[source]#

Return the real process table.

get_modified_process_table(current_state)[source]#

Return the table of modified processes. If it doesn’t exist yet, it’s hopefully because the system is in the first state. These will be “substituted” in place of their corresponding rates in the normal rate table.

save_modified_process_table(current_state, current_state_mod_procs)[source]#

Write the modified process table for the current state to disk.

append_modified_process_table(current_state, process_id, saddle_energy, prefactor, product, product_energy, product_prefactor, barrier, rate, view_count)[source]#

Append a single line to the modified process table on disk.

get_process_id(current_state_procs, next_state_num, flag)[source]#

Return the process id of the process going from the current state to the next state (number).

register_transition(current_state, next_state)[source]#

Whenever there is a move (in KMC), update the view_count, and potentially lower rate constants and raise the corresponding transition state energies. If superbasin recycling is on, and a superbasin has just been exited from, Perform the superbasin recycling.

in_array(test, array)[source]#

Determine whether two arrays are equivalent. Because of the use of numpy, the natural python ‘in’ test does not work properly. So this is a workaround. “test” should be a 1Xn (1X2) list, and “array” should be a mXn (mX2) array.

is_equal(a, b)[source]#

Determine whether two floats are ‘close’.

edgelist_to_statelist()[source]#

Compile a list of state numbers from the current edgelist with no repeats.

missed_connections(origEtrans)[source]#

Determine whether or not there are low barrier processes which connect states in the proposed superbasin which have been missed.

missed_low_barriers(origEtrans)[source]#

Determine whether or not there are low barrier processes originating from any of the states in identified superbasin that were missed.

locsearch(current_state, origEtrans)[source]#

Act recursively to find if the superbasic criterion is met. However, —Note— that in this implementation, not all neighbors are necessarily checked – just those which have been seen so far (which is probably all low barrier processes in a superbasin). This can be remedied by using the checksb_barriers option. origEtrans should be transition state energy (eV) of the process initially used for the call. Immediately before each call, self.welltest should be set to 1 and self.edgelist should be any 2X1 numpy array.

raiseup(current_state, next_state, sb_check_count, num_rate_changes)[source]#

Determine (with the aid of locsearch) if a superbasin is present. If a superbasin is found to be present, raise the rate constants, lower the saddle energies and the barriers, and save the states in the basin.