Clusters module¶
ClustersTask¶
-
class
esteem.tasks.clusters.
ClustersTask
(**kwargs)[source]¶ -
run
()[source]¶ Main routine for processing clusters and running them for excitations.
The steps involved are:
1. Load the trajectory file of MD snapshots, which for a given solvent solute pair it expects to find at ‘{solute}_{solvent}_solv.traj’ in the current directory
‘Carve’ spheres out of the trajectory, that is to say:
- Delete counterions (checking they are not within the sphere first)
b. Delete any whole solvent molecules for which no atoms of the solvent molecule are within
self.radius
of any atom in the solute molecule.c. Label solvent molecules with a tag if they are within
self.kernel
by the criteria above.d. Rotate and center the cluster in the simulation cell, using the two most-distant pairs of carbon atoms in the solute to find a common ‘plane’ for the solute snapshots.
3. Calculate electronic excitations for each cluster. This can currently be done with the ONETEP wrapper functions or with NWChem but other wrappers can be added.
Arguments
self: Argument list for the task, with attributes including:
solute
,solvent
,radius
,output
,task_id
,counterions
,charges
kernel
,basis
,func
,boxsize
,impsolv
,``nroots``,cleanup
,continuation
- wrapper: class
- Wrapper to use in the Clusters task
Output:
Ifself.task_id
is None, excited state calculations for the whole trajectory. If has a int value, then an excited state calculation for just that frame in the trajectory.
-
carve_spheres
(soluseed, solvseed, counterions=None, solvent_radius=0.0, kernel_radius=0.0, nmol_solvent_targ=None, boxsize=None, task_id=None)[source]¶ Carves out spheres from a periodic solvent model, centered on the solute
-
Standalone module routines¶
Performs processing of Molecular Dynamics Trajectories to extract cluster models centered on the solute molecule and including all solvent molecules within a given range
-
esteem.tasks.clusters.
delete_counterions
(t, solvent_radius, nat_tot, nat_solute, nat_counterions)[source]¶ Deletes counterions from an Atoms model. Assumes they appear in the range [nat_solute:nat_solute+nat_counterions]
-
esteem.tasks.clusters.
delete_excess_molecules
(t, nat_tot, nat_solvent, nat_solute, nmol_solvent_targ)[source]¶ Deletes solvent molecules
-
esteem.tasks.clusters.
delete_distant_molecules
(t, solvent_radius, nat_tot, nat_solvent, nmol_solvent, nat_solute)[source]¶ Deletes solvent molecules beyond a certain radius from the solute from an Atoms model Assumes that the first nat_solute atoms are the solute, and after that solvent atoms are arranged in nmol_solvent groups of size nat_solvent
-
esteem.tasks.clusters.
label_nearby_molecules
(t, kernel_radius, nat_tot, nat_solvent, nmol_solvent, nat_solute)[source]¶ Adds a tag to solvent molecules within a certain radius from the solute to an Atoms model Assumes that the first nat_solute atoms are the solute, and after that solvent atoms are arranged in nmol_solvent groups of size nat_solvent