Source code for scm.input_classes.drivers.ams

from __future__ import annotations
from pathlib import Path
from typing import Iterable, Literal, Sequence
from scm.pisa.block import DriverBlock,EngineBlock,FixedBlock,FreeBlock,InputBlock
from scm.pisa.key import BoolKey,FloatKey,FloatListKey,IntKey,IntListKey,MultipleChoiceKey,PathStringKey,StringKey,BoolType

[docs]class AMS(DriverBlock): r""" :ivar EngineRestart: The path to the file from which to restart the engine. Should be a proper engine result file (like adf.rkf, band.rkf etc), or the name of the results directory containing it. :vartype EngineRestart: str | Path | StringKey :ivar FallbackSolveAfterEngineFailure: If the engine fails to Solve, try to re-run the Solve without restarting the engine from the previous results. This generally decreases the engine failure rate. Only relevant certain tasks, such as GeometryOptimization, MolecularDynamics, Replay, IRC. :vartype FallbackSolveAfterEngineFailure: BoolType | BoolKey :ivar LoadEngine: The path to the file from which to load the engine configuration. Replaces the Engine block. :vartype LoadEngine: str | Path | StringKey :ivar RNGSeed: Initial seed for the (pseudo)random number generator. This should be omitted in most calculations to avoid introducing bias into the results. If this is unset, the generator will be seeded randomly from external sources of entropy. If you want to exactly reproduce an older calculation, set this to the numbers printed in its output. :vartype RNGSeed: Iterable[int] | IntListKey :ivar Task: Specify the computational task to perform: • Single Point: keep geometry as is • Geometry Optimization: minimize energy • Transition State: search for a transition state • IRC: intrinsic reaction coordinate • PES Scan: scan the potential energy surface • NEB: Nudged elastic band for reaction path optimization • Vibrational Analysis: perform one of the analysis types selected on the options page • Molecular Dynamics: perform MD simulation • GCMC: Grand Canonical Monte Carlo simulation • PES Exploration: automated potential energy surface exploration • Replay: recompute frames from the trajectory of a previously run job :vartype Task: Literal["GCMC", "GeometryOptimization", "Idle", "IRC", "MolecularDynamics", "NEB", "PESExploration", "PESScan", "Pipe", "Replay", "SinglePoint", "SteepestDescent", "TestEngine", "TestSymmetry", "TransitionStateSearch", "VibrationalAnalysis"] :ivar Test: various technical tests that will be done for the system :vartype Test: Literal["Symmetry", "BareSymmetry", "Bonds", "SecondOrderBonds", "AtomTyping", "SystemMatching"] :ivar UseSymmetry: Whether to use the system's symmetry in AMS. Symmetry is recognized within a tolerance as given in the Symmetry key. :vartype UseSymmetry: BoolType | BoolKey :ivar BondOrders: Configures details regarding the calculation/guessing of bond orders. To request the calculation of bond orders, use the 'Properties%BondOrders' key. :vartype BondOrders: AMS._BondOrders :ivar Constraints: The Constraints block allows geometry optimizations and potential energy surface scans with constraints. The constraints do not have to be satisfied at the start of the calculation. :vartype Constraints: AMS._Constraints :ivar ElasticTensor: Options for numerical evaluation of the elastic tensor. :vartype ElasticTensor: AMS._ElasticTensor :ivar Engine: The input for the computational engine. The header of the block determines the type of the engine. :vartype Engine: EngineBlock :ivar EngineAddons: This block configures all the engine add-ons. :vartype EngineAddons: AMS._EngineAddons :ivar EngineDebugging: This block contains some options useful for debugging the computational engines. :vartype EngineDebugging: AMS._EngineDebugging :ivar ExitCondition: If any of the specified exitconditions are met, the AMS driver will exit cleanly. :vartype ExitCondition: AMS._ExitCondition :ivar GCMC: This block controls the Grand Canonical Monte Carlo (GCMC) task. By default, molecules are added at random positions in the simulation box. The initial position is controlled by :vartype GCMC: AMS._GCMC :ivar GeometryOptimization: Configures details of the geometry optimization and transition state searches. :vartype GeometryOptimization: AMS._GeometryOptimization :ivar IEEEExceptions: Whether this works or not depends on the way the program is compiled (compiler and settings). Only useful for developers debugging some numerical issue. :vartype IEEEExceptions: AMS._IEEEExceptions :ivar IRC: Configures details of the Intrinsic Reaction Coordinate optimization. :vartype IRC: AMS._IRC :ivar Idle: Configures details of the idle task, which does nothing for a specified amount of time. :vartype Idle: AMS._Idle :ivar LoadSystem: Block that controls reading the chemical system from a KF file instead of the [System] block. :vartype LoadSystem: AMS._LoadSystem :ivar Log: Configures the debugging loggers. Syntax: 'Level LoggerName'. Possible Levels: All, Debug, Info, Warning, Error, Fatal. :vartype Log: str | Sequence[str] | FreeBlock :ivar MolecularDynamics: Configures molecular dynamics (with the velocity-Verlet algorithm) with and without thermostats. This block allows to specify the details of the molecular dynamics calculation. :vartype MolecularDynamics: AMS._MolecularDynamics :ivar Molecules: Configures details of the molecular composition analysis enabled by the Properties%Molecules block. :vartype Molecules: AMS._Molecules :ivar NEB: Configures details of the Nudged Elastic Band optimization. :vartype NEB: AMS._NEB :ivar NormalModes: Configures details of a normal modes calculation. :vartype NormalModes: AMS._NormalModes :ivar NumericalDifferentiation: Define options for numerical differentiations, that is the numerical calculation of gradients, Hessian and the stress tensor for periodic systems. :vartype NumericalDifferentiation: AMS._NumericalDifferentiation :ivar NumericalPhonons: Configures details of a numerical phonons calculation. :vartype NumericalPhonons: AMS._NumericalPhonons :ivar PESExploration: Configures details of the automated PES exploration methods. :vartype PESExploration: AMS._PESExploration :ivar PESPointCharacter: Options for the characterization of PES points. :vartype PESPointCharacter: AMS._PESPointCharacter :ivar PESScan: Configures the details of the potential energy surface scanning task. :vartype PESScan: AMS._PESScan :ivar Phonons: Configures the phonons calculation. :vartype Phonons: AMS._Phonons :ivar Print: This block controls the printing of additional information to stdout. :vartype Print: AMS._Print :ivar Properties: Configures which AMS level properties to calculate for SinglePoint calculations or other important geometries (e.g. at the end of an optimization). :vartype Properties: AMS._Properties :ivar Raman: Configures details of the Raman or VROA calculation. :vartype Raman: AMS._Raman :ivar Replay: Configures the details of the Replay task. :vartype Replay: AMS._Replay :ivar Restraints: The Restraints block allows to add soft constraints to the system. A restraint is a potential energy function (a spring) attached to a certain coordinate, for example, an interatomic distance, with its minimum at the specified optimal value. A restraint is defined using one or two parameters: the ForceConstant and, for some types, the F(Inf) value. The ForceConstant parameter corresponds to second derivative of the restraint potential energy d2V(x)/dx^2 for any x (harmonic restraints) or only at at x=0 (other restraints). Here, x is a deviation from the restraint's optimal value. :vartype Restraints: AMS._Restraints :ivar RigidMotions: Specify which rigid motions of the total system are allowed. An external field is not considered part of the system. Normally the automatic option is doing what you want. However this feature can be used as a means of geometry constraint. :vartype RigidMotions: AMS._RigidMotions :ivar SCMLibrary: Technical settings affecting src/lib :vartype SCMLibrary: AMS._SCMLibrary :ivar SCMMatrix: Technical settings for programs using the AMT matrix system. Currently this is only used by DFTB :vartype SCMMatrix: AMS._SCMMatrix :ivar SerializedTensors: Technical settings affecting the SerializedTensors module, currently only used for HartreeFock :vartype SerializedTensors: AMS._SerializedTensors :ivar SteepestDescent: Configures details of the steepest descent task. :vartype SteepestDescent: AMS._SteepestDescent :ivar Symmetry: Specifying details about the details of symmetry detection and usage. :vartype Symmetry: AMS._Symmetry :ivar System: Specification of the chemical system. For some applications more than one system may be present in the input. In this case, all systems except one must have a non-empty string ID specified after the System keyword. The system without an ID is considered the main one. :vartype System: AMS._System :ivar Thermo: Options for thermodynamic properties (assuming an ideal gas). The properties are computed for all specified temperatures. :vartype Thermo: AMS._Thermo :ivar TransitionStateSearch: Configures some details of the transition state search. :vartype TransitionStateSearch: AMS._TransitionStateSearch :ivar VibrationalAnalysis: Input data for all vibrational analysis utilities in the AMS driver. :vartype VibrationalAnalysis: AMS._VibrationalAnalysis """
[docs] class _BondOrders(FixedBlock): r""" Configures details regarding the calculation/guessing of bond orders. To request the calculation of bond orders, use the 'Properties%BondOrders' key. :ivar Method: How to compute the bond orders when they are requested via the 'Properties%BondOrders' key. 'Engine': let the engine compute the bond orders. The specific method used to compute the bond orders depends on the engine selected, and it may be configurable in the engine's input. Note: the calculation may stop if the engine cannot compute bond orders. 'Guess': Use a bond guessing algorithm based on the system's geometry. This is the same algorithm that is used by the Graphical User Interface to guess bonds. 'EngineWithGuessFallback': let the engine compute the bond orders (same as in 'Engine' option) but if the engine did not produce any bond orders, use the bond guessing algorithm as a fallback option. :vartype Method: Literal["Engine", "Guess", "EngineWithGuessFallback"] """ def __post_init__(self): self.Method: Literal["Engine", "Guess", "EngineWithGuessFallback"] = MultipleChoiceKey(name='Method', comment="How to compute the bond orders when they are requested via the 'Properties%BondOrders' key.\n\n'Engine': let the engine compute the bond orders. The specific method used to compute the bond orders depends on the engine selected, and it may be configurable in the engine's input. Note: the calculation may stop if the engine cannot compute bond orders.\n\n'Guess': Use a bond guessing algorithm based on the system's geometry. This is the same algorithm that is used by the Graphical User Interface to guess bonds.\n\n'EngineWithGuessFallback': let the engine compute the bond orders (same as in 'Engine' option) but if the engine did not produce any bond orders, use the bond guessing algorithm as a fallback option.", default='EngineWithGuessFallback', choices=['Engine', 'Guess', 'EngineWithGuessFallback'])
[docs] class _Constraints(FixedBlock): r""" The Constraints block allows geometry optimizations and potential energy surface scans with constraints. The constraints do not have to be satisfied at the start of the calculation. :ivar All: Fix multiple distances using one the following formats: All [bondOrder] bonds at1 at2 [to distance] All triangles at1 at2 at3 The first option constrains all bonds between atoms at1 at2 to a certain length, while the second - bonds at1-at2 and at2-at3 as well as the angle between them. The [bondOrder] can be a number or a string such as single, double, triple or aromatic. If it's omitted then any bond between specified atoms will be constrained. Atom names are case-sensitive and they must be as they are in the Atoms block, or an asterisk '*' denoting any atom. If the distance is omitted then the bond length from the initial geometry is used. Important: only the bonds present in the system at the start of the simulation can be constrained, which means that the bonds may need to be specified in the System block. Valid examples: All single bonds C C to 1.4 All bonds O H to 0.98 All bonds O H All bonds H * All triangles H * H :vartype All: str | StringKey :ivar Angle: Fix the angle between three atoms. Three atom indices followed by an angle in degrees. :vartype Angle: str | StringKey :ivar Atom: Fix the position of an atom. Just one integer referring to the index of the atom in the [System%Atoms] block. :vartype Atom: int | IntKey :ivar AtomList: Fix positions of the specified atoms. A list of integers referring to indices of atoms in the [System%Atoms] block. :vartype AtomList: Iterable[int] | IntListKey :ivar Block: Name of the region to constrain as a rigid block. Regions are specified in the System%Atoms block. :vartype Block: str | StringKey :ivar BlockAtoms: List of atom indices for a block constraint, where the internal degrees of freedom are frozen. :vartype BlockAtoms: Iterable[int] | IntListKey :ivar Coordinate: Fix a particular coordinate of an atom. Atom index followed by (x|y|z). :vartype Coordinate: str | StringKey :ivar DifDist: Four atom indices i j k l followed by the distance in Angstrom. This will constrain the difference R(ij)-R(kl) at the given value. :vartype DifDist: str | StringKey :ivar Dihedral: Fix the dihedral angle between four atoms. Four atom indices followed by an angle in degrees. :vartype Dihedral: str | StringKey :ivar Distance: Fix the distance between two atoms. Two atom indices followed by the distance in Angstrom. :vartype Distance: str | StringKey :ivar EqualStrain: Exclusively for lattice optimizations: Accepts a set of strain components [xx, xy, xz, yy, yz, zz] which are to be kept equal. The applied strain will be determined by the average of the corresponding stress tensors components. In AMSinput just check the corresponding check buttons. :vartype EqualStrain: str | StringKey :ivar FixedRegion: Fix positions of all atoms in a region. :vartype FixedRegion: str | StringKey :ivar FreezeStrain: Exclusively for lattice optimizations: Freezes any lattice deformation corresponding to a particular component of the strain tensor. Accepts a set of strain components [xx, xy, xz, yy, yz, zz] to be frozen. In AMSinput just check the corresponding check buttons. :vartype FreezeStrain: str | StringKey :ivar SumDist: Four atom indices i j k l followed by the distance in Angstrom. This will constrain the sum R(ij)+R(kl) at the given value. :vartype SumDist: str | StringKey """ def __post_init__(self): self.All: str | StringKey = StringKey(name='All', comment="Fix multiple distances using one the following formats: \nAll [bondOrder] bonds at1 at2 [to distance]\nAll triangles at1 at2 at3\n\nThe first option constrains all bonds between atoms at1 at2 to a certain length, while the second - bonds at1-at2 and at2-at3 as well as the angle between them.\n\nThe [bondOrder] can be a number or a string such as single, double, triple or aromatic. If it's omitted then any bond between specified atoms will be constrained. Atom names are case-sensitive and they must be as they are in the Atoms block, or an asterisk '*' denoting any atom. If the distance is omitted then the bond length from the initial geometry is used.\n\nImportant: only the bonds present in the system at the start of the simulation can be constrained, which means that the bonds may need to be specified in the System block.\n\nValid examples:\nAll single bonds C C to 1.4\nAll bonds O H to 0.98\nAll bonds O H\nAll bonds H *\nAll triangles H * H", unique=False) self.Angle: str | StringKey = StringKey(name='Angle', comment='Fix the angle between three atoms. Three atom indices followed by an angle in degrees.', unique=False) self.Atom: int | IntKey = IntKey(name='Atom', comment='Fix the position of an atom. Just one integer referring to the index of the atom in the [System%Atoms] block.', unique=False) self.AtomList: Iterable[int] | IntListKey = IntListKey(name='AtomList', comment='Fix positions of the specified atoms. A list of integers referring to indices of atoms in the [System%Atoms] block.', unique=False) self.Block: str | StringKey = StringKey(name='Block', comment='Name of the region to constrain as a rigid block. Regions are specified in the System%Atoms block.', unique=False, gui_type='region') self.BlockAtoms: Iterable[int] | IntListKey = IntListKey(name='BlockAtoms', comment='List of atom indices for a block constraint, where the internal degrees of freedom are frozen.', unique=False) self.Coordinate: str | StringKey = StringKey(name='Coordinate', comment='Fix a particular coordinate of an atom. Atom index followed by (x|y|z).', unique=False) self.DifDist: str | StringKey = StringKey(name='DifDist', comment='Four atom indices i j k l followed by the distance in Angstrom. This will constrain the difference R(ij)-R(kl) at the given value.', unique=False) self.Dihedral: str | StringKey = StringKey(name='Dihedral', comment='Fix the dihedral angle between four atoms. Four atom indices followed by an angle in degrees.', unique=False) self.Distance: str | StringKey = StringKey(name='Distance', comment='Fix the distance between two atoms. Two atom indices followed by the distance in Angstrom.', unique=False) self.EqualStrain: str | StringKey = StringKey(name='EqualStrain', comment='Exclusively for lattice optimizations:\n\nAccepts a set of strain components [xx, xy, xz, yy, yz, zz] which are to be kept equal.\n\nThe applied strain will be determined by the average of the corresponding stress tensors components.\n\nIn AMSinput just check the corresponding check buttons.') self.FixedRegion: str | StringKey = StringKey(name='FixedRegion', comment='Fix positions of all atoms in a region.', unique=False, gui_type='region') self.FreezeStrain: str | StringKey = StringKey(name='FreezeStrain', comment='Exclusively for lattice optimizations:\n\nFreezes any lattice deformation corresponding to a particular component of the strain tensor.\n\nAccepts a set of strain components [xx, xy, xz, yy, yz, zz] to be frozen.\n\nIn AMSinput just check the corresponding check buttons.') self.SumDist: str | StringKey = StringKey(name='SumDist', comment='Four atom indices i j k l followed by the distance in Angstrom. This will constrain the sum R(ij)+R(kl) at the given value.', unique=False)
[docs] class _ElasticTensor(FixedBlock): r""" Options for numerical evaluation of the elastic tensor. :ivar ConvergenceQuality: The tightness of the convergence of the geometry optimizations for each strain deformation. This should not be set higher than the overall convergence quality of the preceding geometry optimization configured by the ``GeometryOptimization%Convergence%Quality`` keyword. :vartype ConvergenceQuality: Literal["Normal", "Good", "VeryGood", "Excellent"] :ivar StrainStepSize: Step size (relative) of strain deformations used for computing the elastic tensor numerically. :vartype StrainStepSize: float | FloatKey :ivar Parallel: Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :vartype Parallel: AMS._ElasticTensor._Parallel """
[docs] class _Parallel(FixedBlock): r""" Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :ivar nCoresPerGroup: Number of cores in each working group. :vartype nCoresPerGroup: int | IntKey :ivar nGroups: Total number of processor groups. This is the number of tasks that will be executed in parallel. :vartype nGroups: int | IntKey :ivar nNodesPerGroup: Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores. :vartype nNodesPerGroup: int | IntKey """ def __post_init__(self): self.nCoresPerGroup: int | IntKey = IntKey(name='nCoresPerGroup', comment='Number of cores in each working group.', gui_name='Cores per group:') self.nGroups: int | IntKey = IntKey(name='nGroups', comment='Total number of processor groups. This is the number of tasks that will be executed in parallel.', gui_name='Number of groups:') self.nNodesPerGroup: int | IntKey = IntKey(name='nNodesPerGroup', comment='Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores.', gui_name='Nodes per group:')
def __post_init__(self): self.ConvergenceQuality: Literal["Normal", "Good", "VeryGood", "Excellent"] = MultipleChoiceKey(name='ConvergenceQuality', comment='The tightness of the convergence of the geometry optimizations for each strain deformation. This should not be set higher than the overall convergence quality of the preceding geometry optimization configured by the ``GeometryOptimization%Convergence%Quality`` keyword.', gui_name='Convergence:', default='Good', choices=['Normal', 'Good', 'VeryGood', 'Excellent'], hiddenchoices=['Excellent']) self.StrainStepSize: float | FloatKey = FloatKey(name='StrainStepSize', comment='Step size (relative) of strain deformations used for computing the elastic tensor numerically.', default=0.001) self.Parallel: AMS._ElasticTensor._Parallel = self._Parallel(name='Parallel', comment='Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel.', extra_info='not_in_fragment', shared_id='AMSParallel')
[docs] class _Engine(EngineBlock): r""" The input for the computational engine. The header of the block determines the type of the engine. """ def __post_init__(self): pass
[docs] class _EngineAddons(FixedBlock): r""" This block configures all the engine add-ons. :ivar Pressure: Add a hydrostatic pressure term to the engine's energy and stress tensor. Can only be used for 3D periodic boundary conditions. :vartype Pressure: float | FloatKey :ivar AtomEnergies: Add an element-dependent energy per atom. On each line, give the chemical element followed by the energy (in atomic units). :vartype AtomEnergies: str | Sequence[str] | FreeBlock :ivar D3Dispersion: This block configures the add-on that adds the Grimme D3 dispersion correction to the engine's energy, gradients, and stress tensor. :vartype D3Dispersion: AMS._EngineAddons._D3Dispersion :ivar D4Dispersion: This block configures the addon that adds the Grimme D4(EEQ) dispersion correction to the engine's energy, gradients, stress tensor and Hessian. :vartype D4Dispersion: AMS._EngineAddons._D4Dispersion :ivar ExternalEngine: External engine as an addon :vartype ExternalEngine: AMS._EngineAddons._ExternalEngine :ivar ExternalStress: This block configures the addon that adds external stress term to the engine's energy and stress tensor. :vartype ExternalStress: AMS._EngineAddons._ExternalStress :ivar PipeEngine: Pipe engine as an addon :vartype PipeEngine: AMS._EngineAddons._PipeEngine :ivar Repulsion: This block configures an addon that adds a repulsive Weeks-Chandler-Andersen potential to all atom pairs. :vartype Repulsion: AMS._EngineAddons._Repulsion :ivar WallPotential: This block configures the addon that adds a spherical wall potential to the engine's energy and gradients. :vartype WallPotential: AMS._EngineAddons._WallPotential """
[docs] class _AtomEnergies(FreeBlock): r""" Add an element-dependent energy per atom. On each line, give the chemical element followed by the energy (in atomic units). """ def __post_init__(self): pass
[docs] class _D3Dispersion(FixedBlock): r""" This block configures the add-on that adds the Grimme D3 dispersion correction to the engine's energy, gradients, and stress tensor. :ivar Damping: Type of damping: BJ (Becke-Johnson) or Zero. BJ is recommended for most applications. :vartype Damping: Literal["BJ", "Zero"] :ivar Enabled: Enables the D3 dispersion correction addon. :vartype Enabled: BoolType | BoolKey :ivar Functional: Use the D3 parameterization by Grimme for a given xc-functional. Accepts the same values as the --func command line option of the official dftd3 program. Note: the naming convention is different from elsewhere in the AMS suite. For example, BLYP should be called b-lyp. :vartype Functional: str | StringKey :ivar a1: The a1 parameter. Only used if Damping is set to BJ. If set, it overwrites the a1 value for the chosen functional. :vartype a1: float | FloatKey :ivar a2: The a2 parameter. Only used if Damping is set to BJ. If set, it overwrites the a2 value for the chosen functional. :vartype a2: float | FloatKey :ivar alp: The a2 parameter. Only used if Damping is set to BJ. If set, it overwrites the a2 value for the chosen functional. :vartype alp: float | FloatKey :ivar s6: The s6 parameter, global scaling parameter. If set, it overwrites the s6 value for the chosen functional. :vartype s6: float | FloatKey :ivar s8: The s8 parameter. If set, it overwrites the s8 value for the chosen functional. :vartype s8: float | FloatKey :ivar sr6: The sr6 parameter. Only used if Damping is set to Zero. If set, it overwrites the sr6 value for the chosen functional. :vartype sr6: float | FloatKey """ def __post_init__(self): self.Damping: Literal["BJ", "Zero"] = MultipleChoiceKey(name='Damping', comment='Type of damping: BJ (Becke-Johnson) or Zero. BJ is recommended for most applications.', default='BJ', choices=['BJ', 'Zero']) self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Enables the D3 dispersion correction addon.', gui_name='D3 dispersion:', default=False) self.Functional: str | StringKey = StringKey(name='Functional', comment='Use the D3 parameterization by Grimme for a given xc-functional. Accepts the same values as the --func command line option of the official dftd3 program. Note: the naming convention is different from elsewhere in the AMS suite. For example, BLYP should be called b-lyp.', default='PBE') self.a1: float | FloatKey = FloatKey(name='a1', comment='The a1 parameter. Only used if Damping is set to BJ. If set, it overwrites the a1 value for the chosen functional.') self.a2: float | FloatKey = FloatKey(name='a2', comment='The a2 parameter. Only used if Damping is set to BJ. If set, it overwrites the a2 value for the chosen functional.') self.alp: float | FloatKey = FloatKey(name='alp', comment='The a2 parameter. Only used if Damping is set to BJ. If set, it overwrites the a2 value for the chosen functional.', hidden=True) self.s6: float | FloatKey = FloatKey(name='s6', comment='The s6 parameter, global scaling parameter. If set, it overwrites the s6 value for the chosen functional.') self.s8: float | FloatKey = FloatKey(name='s8', comment='The s8 parameter. If set, it overwrites the s8 value for the chosen functional.') self.sr6: float | FloatKey = FloatKey(name='sr6', comment='The sr6 parameter. Only used if Damping is set to Zero. If set, it overwrites the sr6 value for the chosen functional.')
[docs] class _D4Dispersion(FixedBlock): r""" This block configures the addon that adds the Grimme D4(EEQ) dispersion correction to the engine's energy, gradients, stress tensor and Hessian. :ivar Enabled: Enables the D4 dispersion correction addon. :vartype Enabled: BoolType | BoolKey :ivar Functional: Use the D4 parameterization by Grimme for a given xc-functional. :vartype Functional: Literal["HF", "BLYP", "BPBE", "BP86", "BPW", "LB94", "MPWLYP", "MPWPW91", "OLYP", "OPBE", "PBE", "RPBE", "REVPBE", "PW86PBE", "RPW86PBE", "PW91", "PW91P86", "XLYP", "B97", "TPSS", "REVTPSS", "SCAN", "B1LYP", "B3LYP", "BHLYP", "B1P86", "B3P86", "B1PW91", "B3PW91", "O3LYP", "REVPBE0", "REVPBE38", "PBE0", "PWP1", "PW1PW", "MPW1PW91", "MPW1LYP", "PW6B95", "TPSSH", "TPSS0", "X3LYP", "M06L", "M06", "OMEGAB97", "OMEGAB97X", "CAM-B3LYP", "LC-BLYP", "LH07TSVWN", "LH07SSVWN", "LH12CTSSIRPW92", "LH12CTSSIFPW92", "LH14TCALPBE", "B2PLYP", "B2GPPLYP", "MPW2PLYP", "PWPB95", "DSDBLYP", "DSDPBE", "DSDPBEB95", "DSDPBEP86", "DSDSVWN", "DODBLYP", "DODPBE", "DODPBEB95", "DODPBEP86", "DODSVWN", "PBE02", "PBE0DH", "DFTB(3ob)", "DFTB(mio)", "DFTB(pbc)", "DFTB(matsci)", "DFTB(ob2)", "B1B95", "MPWB1K", "REVTPSSH", "GLYP", "REVPBE0DH", "REVTPSS0", "REVDSDPBEP86", "REVDSDPBEPBE", "REVDSDBLYP", "REVDODPBEP86", "B97M", "OMEGAB97M", "R2SCAN"] :ivar Verbosity: Controls the verbosity of the dftd4 code. Equivalent to the --silent and --verbose command line switches of the official dftd4 program. :vartype Verbosity: Literal["Silent", "Normal", "Verbose", "VeryVerbose"] :ivar a1: The a1 parameter, see D4 article. The physically reasonable range for a1 is [0.0,1.0]. If set, it overwrites the a1 value for the chosen functional. :vartype a1: float | FloatKey :ivar a2: The a2 parameter, see D4 article. The physically reasonable range for a2 is [0.0,7.0]. If set, it overwrites the a2 value for the chosen functional. :vartype a2: float | FloatKey :ivar ga: The ga parameter. GCP :vartype ga: float | FloatKey :ivar gc: The gc parameter. GCP :vartype gc: float | FloatKey :ivar s6: The s6 parameter, see D4 article. The physically reasonable range for s6 is [0.0,1.0]. If set, it overwrites the s6 value for the chosen functional. :vartype s6: float | FloatKey :ivar s8: The s8 parameter, see D4 article. The physically reasonable range for s8 is [0.0,3.0]. If set, it overwrites the s8 value for the chosen functional. :vartype s8: float | FloatKey :ivar s9: The s9 parameter, see D4 article. If set, it overwrites the s9 value for the chosen functional. :vartype s9: float | FloatKey """ def __post_init__(self): self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Enables the D4 dispersion correction addon.', gui_name='D4 dispersion:', default=False) self.Functional: Literal["HF", "BLYP", "BPBE", "BP86", "BPW", "LB94", "MPWLYP", "MPWPW91", "OLYP", "OPBE", "PBE", "RPBE", "REVPBE", "PW86PBE", "RPW86PBE", "PW91", "PW91P86", "XLYP", "B97", "TPSS", "REVTPSS", "SCAN", "B1LYP", "B3LYP", "BHLYP", "B1P86", "B3P86", "B1PW91", "B3PW91", "O3LYP", "REVPBE0", "REVPBE38", "PBE0", "PWP1", "PW1PW", "MPW1PW91", "MPW1LYP", "PW6B95", "TPSSH", "TPSS0", "X3LYP", "M06L", "M06", "OMEGAB97", "OMEGAB97X", "CAM-B3LYP", "LC-BLYP", "LH07TSVWN", "LH07SSVWN", "LH12CTSSIRPW92", "LH12CTSSIFPW92", "LH14TCALPBE", "B2PLYP", "B2GPPLYP", "MPW2PLYP", "PWPB95", "DSDBLYP", "DSDPBE", "DSDPBEB95", "DSDPBEP86", "DSDSVWN", "DODBLYP", "DODPBE", "DODPBEB95", "DODPBEP86", "DODSVWN", "PBE02", "PBE0DH", "DFTB(3ob)", "DFTB(mio)", "DFTB(pbc)", "DFTB(matsci)", "DFTB(ob2)", "B1B95", "MPWB1K", "REVTPSSH", "GLYP", "REVPBE0DH", "REVTPSS0", "REVDSDPBEP86", "REVDSDPBEPBE", "REVDSDBLYP", "REVDODPBEP86", "B97M", "OMEGAB97M", "R2SCAN"] = MultipleChoiceKey(name='Functional', comment='Use the D4 parameterization by Grimme for a given xc-functional.', default='PBE', choices=['HF', 'BLYP', 'BPBE', 'BP86', 'BPW', 'LB94', 'MPWLYP', 'MPWPW91', 'OLYP', 'OPBE', 'PBE', 'RPBE', 'REVPBE', 'PW86PBE', 'RPW86PBE', 'PW91', 'PW91P86', 'XLYP', 'B97', 'TPSS', 'REVTPSS', 'SCAN', 'B1LYP', 'B3LYP', 'BHLYP', 'B1P86', 'B3P86', 'B1PW91', 'B3PW91', 'O3LYP', 'REVPBE0', 'REVPBE38', 'PBE0', 'PWP1', 'PW1PW', 'MPW1PW91', 'MPW1LYP', 'PW6B95', 'TPSSH', 'TPSS0', 'X3LYP', 'M06L', 'M06', 'OMEGAB97', 'OMEGAB97X', 'CAM-B3LYP', 'LC-BLYP', 'LH07TSVWN', 'LH07SSVWN', 'LH12CTSSIRPW92', 'LH12CTSSIFPW92', 'LH14TCALPBE', 'B2PLYP', 'B2GPPLYP', 'MPW2PLYP', 'PWPB95', 'DSDBLYP', 'DSDPBE', 'DSDPBEB95', 'DSDPBEP86', 'DSDSVWN', 'DODBLYP', 'DODPBE', 'DODPBEB95', 'DODPBEP86', 'DODSVWN', 'PBE02', 'PBE0DH', 'DFTB(3ob)', 'DFTB(mio)', 'DFTB(pbc)', 'DFTB(matsci)', 'DFTB(ob2)', 'B1B95', 'MPWB1K', 'REVTPSSH', 'GLYP', 'REVPBE0DH', 'REVTPSS0', 'REVDSDPBEP86', 'REVDSDPBEPBE', 'REVDSDBLYP', 'REVDODPBEP86', 'B97M', 'OMEGAB97M', 'R2SCAN']) self.Verbosity: Literal["Silent", "Normal", "Verbose", "VeryVerbose"] = MultipleChoiceKey(name='Verbosity', comment='Controls the verbosity of the dftd4 code. Equivalent to the --silent and --verbose command line switches of the official dftd4 program.', default='Silent', choices=['Silent', 'Normal', 'Verbose', 'VeryVerbose']) self.a1: float | FloatKey = FloatKey(name='a1', comment='The a1 parameter, see D4 article. The physically reasonable range for a1 is [0.0,1.0]. If set, it overwrites the a1 value for the chosen functional.') self.a2: float | FloatKey = FloatKey(name='a2', comment='The a2 parameter, see D4 article. The physically reasonable range for a2 is [0.0,7.0]. If set, it overwrites the a2 value for the chosen functional.') self.ga: float | FloatKey = FloatKey(name='ga', comment='The ga parameter. GCP', hidden=True) self.gc: float | FloatKey = FloatKey(name='gc', comment='The gc parameter. GCP', hidden=True) self.s6: float | FloatKey = FloatKey(name='s6', comment='The s6 parameter, see D4 article. The physically reasonable range for s6 is [0.0,1.0]. If set, it overwrites the s6 value for the chosen functional.') self.s8: float | FloatKey = FloatKey(name='s8', comment='The s8 parameter, see D4 article. The physically reasonable range for s8 is [0.0,3.0]. If set, it overwrites the s8 value for the chosen functional.') self.s9: float | FloatKey = FloatKey(name='s9', comment='The s9 parameter, see D4 article. If set, it overwrites the s9 value for the chosen functional.')
[docs] class _ExternalEngine(FixedBlock): r""" External engine as an addon :ivar Execute: execute command :vartype Execute: str | StringKey """ def __post_init__(self): self.Execute: str | StringKey = StringKey(name='Execute', comment='execute command', gui_name='Execute:')
[docs] class _ExternalStress(FixedBlock): r""" This block configures the addon that adds external stress term to the engine's energy and stress tensor. :ivar StressTensorVoigt: The elements of the external stress tensor in Voigt notation. One should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems. :vartype StressTensorVoigt: Iterable[float] | FloatListKey :ivar UpdateReferenceCell: Whether ot not the reference cell should be updated every time the system changes (see documentation). :vartype UpdateReferenceCell: BoolType | BoolKey """ def __post_init__(self): self.StressTensorVoigt: Iterable[float] | FloatListKey = FloatListKey(name='StressTensorVoigt', comment='The elements of the external stress tensor in Voigt notation. One should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems.', gui_name='External stress tensor:', unit='Hartree/Bohr^3') self.UpdateReferenceCell: BoolType | BoolKey = BoolKey(name='UpdateReferenceCell', comment='Whether ot not the reference cell should be updated every time the system changes (see documentation).', default=False)
[docs] class _PipeEngine(FixedBlock): r""" Pipe engine as an addon :ivar WorkerCommand: pipe worker command :vartype WorkerCommand: str | StringKey """ def __post_init__(self): self.WorkerCommand: str | StringKey = StringKey(name='WorkerCommand', comment='pipe worker command', gui_name='Worker command:')
[docs] class _Repulsion(FixedBlock): r""" This block configures an addon that adds a repulsive Weeks-Chandler-Andersen potential to all atom pairs. :ivar Enabled: Enables the repulsive Weeks-Chandler-Andersen potential addon. When enabled, all atom pairs will experience repulsion E = 4*epsilon*( (sigma/r)^12 - (sigma/r)^6 + 1/4 ) at the distances shorter than about 1.12*sigma. :vartype Enabled: BoolType | BoolKey :ivar Epsilon: The epsilon parameter in the potential equation. It is equal to the amount of energy added at r=sigma. :vartype Epsilon: float | FloatKey :ivar HydrogenSigmaScale: The sigma parameter for a pair of atoms where one of them is hydrogen is scaled with the given factor. For H-H interactions the sigma is scaled with this value squared. :vartype HydrogenSigmaScale: float | FloatKey :ivar Sigma: The sigma parameter in the potential equation. The potential is exactly zero at the distances larger than about 1.12*sigma :vartype Sigma: float | FloatKey :ivar SkinLength: Technical parameter specifying skin length for the neighbor list generation. A larger value increases the neighbor list cutoff (and cost) but reduces the frequency it needs to be re-created. :vartype SkinLength: float | FloatKey """ def __post_init__(self): self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Enables the repulsive Weeks-Chandler-Andersen potential addon.\n\nWhen enabled, all atom pairs will experience repulsion E = 4*epsilon*( (sigma/r)^12 - (sigma/r)^6 + 1/4 ) at the distances shorter than about 1.12*sigma.', gui_name='Repulsion:', default=False) self.Epsilon: float | FloatKey = FloatKey(name='Epsilon', comment='The epsilon parameter in the potential equation. It is equal to the amount of energy added at r=sigma.', default=0.01, unit='Hartree') self.HydrogenSigmaScale: float | FloatKey = FloatKey(name='HydrogenSigmaScale', comment='The sigma parameter for a pair of atoms where one of them is hydrogen is scaled with the given factor. For H-H interactions the sigma is scaled with this value squared.', default=0.75, unit='Angstrom') self.Sigma: float | FloatKey = FloatKey(name='Sigma', comment='The sigma parameter in the potential equation. The potential is exactly zero at the distances larger than about 1.12*sigma', default=0.55, unit='Angstrom') self.SkinLength: float | FloatKey = FloatKey(name='SkinLength', comment='Technical parameter specifying skin length for the neighbor list generation. A larger value increases the neighbor list cutoff (and cost) but reduces the frequency it needs to be re-created.', default=2.0, unit='Angstrom')
[docs] class _WallPotential(FixedBlock): r""" This block configures the addon that adds a spherical wall potential to the engine's energy and gradients. :ivar Enabled: Enables the wall potential addon. When enabled, a spherical wall of radius [Radius] around the origin will be added. The force due to the potential will decay exponentially inside the wall, will be close to [Prefactor*Gradient] outside and exactly half of that at the wall. :vartype Enabled: BoolType | BoolKey :ivar Gradient: The radial gradient outside the sphere. :vartype Gradient: float | FloatKey :ivar Prefactor: The multiplier for the overall strength of the potential. :vartype Prefactor: float | FloatKey :ivar Radius: The radius of the sphere, wherein the potential is close to zero. :vartype Radius: float | FloatKey """ def __post_init__(self): self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Enables the wall potential addon. When enabled, a spherical wall of radius [Radius] around the origin will be added. The force due to the potential will decay exponentially inside the wall, will be close to [Prefactor*Gradient] outside and exactly half of that at the wall.', default=False) self.Gradient: float | FloatKey = FloatKey(name='Gradient', comment='The radial gradient outside the sphere.', default=10.0, unit='1/Angstrom') self.Prefactor: float | FloatKey = FloatKey(name='Prefactor', comment='The multiplier for the overall strength of the potential.', default=0.01, unit='Hartree') self.Radius: float | FloatKey = FloatKey(name='Radius', comment='The radius of the sphere, wherein the potential is close to zero.', default=30.0, unit='Angstrom', range='value > 0')
def __post_init__(self): self.Pressure: float | FloatKey = FloatKey(name='Pressure', comment="Add a hydrostatic pressure term to the engine's energy and stress tensor. Can only be used for 3D periodic boundary conditions.", default=0.0, unit='GPa') self.AtomEnergies: str | Sequence[str] | FreeBlock = self._AtomEnergies(name='AtomEnergies', comment='Add an element-dependent energy per atom. On each line, give the chemical element followed by the energy (in atomic units).') self.D3Dispersion: AMS._EngineAddons._D3Dispersion = self._D3Dispersion(name='D3Dispersion', comment="This block configures the add-on that adds the Grimme D3 dispersion correction to the engine's energy, gradients, and stress tensor.") self.D4Dispersion: AMS._EngineAddons._D4Dispersion = self._D4Dispersion(name='D4Dispersion', comment="This block configures the addon that adds the Grimme D4(EEQ) dispersion correction to the engine's energy, gradients, stress tensor and Hessian.") self.ExternalEngine: AMS._EngineAddons._ExternalEngine = self._ExternalEngine(name='ExternalEngine', comment='External engine as an addon') self.ExternalStress: AMS._EngineAddons._ExternalStress = self._ExternalStress(name='ExternalStress', comment="This block configures the addon that adds external stress term to the engine's energy and stress tensor.") self.PipeEngine: AMS._EngineAddons._PipeEngine = self._PipeEngine(name='PipeEngine', comment='Pipe engine as an addon') self.Repulsion: AMS._EngineAddons._Repulsion = self._Repulsion(name='Repulsion', comment='This block configures an addon that adds a repulsive Weeks-Chandler-Andersen potential to all atom pairs.') self.WallPotential: AMS._EngineAddons._WallPotential = self._WallPotential(name='WallPotential', comment="This block configures the addon that adds a spherical wall potential to the engine's energy and gradients.")
[docs] class _EngineDebugging(FixedBlock): r""" This block contains some options useful for debugging the computational engines. :ivar AlwaysClaimSuccess: If an engine fails, pretend that it worked. This can be useful when you know that an SCF might fail. :vartype AlwaysClaimSuccess: BoolType | BoolKey :ivar CheckInAndOutput: Enables some additional checks on the input and output of an engine, e.g. for NaN values. :vartype CheckInAndOutput: BoolType | BoolKey :ivar ForceContinousPES: If this option is set, the engine will always run in continuous PES mode. For many engines this disables the use of symmetry, as this one always leads to a discontinuous PES around the symmetric points: Basically there is jump in the PES at the point where the symmetry detection starts classifying the system as symmetric. Normally the continuous PES mode of the engine (often disabling the symmetry) is only used when doing numerical derivatives, but this flag forces the engine to continuously run in this mode. :vartype ForceContinousPES: BoolType | BoolKey :ivar IgnoreEngineSupportsErrors: Pretend as if the engine supports anything requested. Use at your own risk. :vartype IgnoreEngineSupportsErrors: BoolType | BoolKey :ivar IgnoreGradientsRequest: If this option is set, the engine will not do analytical gradients if asked for it, so that gradients will have to be evaluated numerically by AMS. :vartype IgnoreGradientsRequest: BoolType | BoolKey :ivar IgnorePreviousResults: If this option is set, the engine will not receive information from previous calculations. Typically this information is used to restart the self consistent procedure of the engine. :vartype IgnorePreviousResults: BoolType | BoolKey :ivar IgnoreStressTensorRequest: If this option is set, the engine will not calculate an analytical stress tensor if asked for it, so that the stress tensor will have to be evaluated numerically by AMS. :vartype IgnoreStressTensorRequest: BoolType | BoolKey :ivar NeverQuiet: Makes the engine ignore the request to work quietly. :vartype NeverQuiet: BoolType | BoolKey :ivar RandomFailureChance: Makes the engine randomly report failures, even though the results are actually fine. Useful for testing error handling on the application level. :vartype RandomFailureChance: float | FloatKey :ivar RandomNoiseInEnergy: Adds a random noise to the energy returned by the engine. The random contribution is drawn from [-r,r] where r is the value of this keyword. :vartype RandomNoiseInEnergy: float | FloatKey :ivar RandomNoiseInGradients: Adds a random noise to the gradients returned by the engine. A random number in the range [-r,r] (where r is the value of this keyword) is drawn and added separately to each component of the gradient. :vartype RandomNoiseInGradients: float | FloatKey :ivar RandomStopChance: Makes the engine randomly stop. Can be used to simulate crashes. :vartype RandomStopChance: float | FloatKey """ def __post_init__(self): self.AlwaysClaimSuccess: BoolType | BoolKey = BoolKey(name='AlwaysClaimSuccess', comment='If an engine fails, pretend that it worked. This can be useful when you know that an SCF might fail.', default=False) self.CheckInAndOutput: BoolType | BoolKey = BoolKey(name='CheckInAndOutput', comment='Enables some additional checks on the input and output of an engine, e.g. for NaN values.', default=False) self.ForceContinousPES: BoolType | BoolKey = BoolKey(name='ForceContinousPES', comment='If this option is set, the engine will always run in continuous PES mode. For many engines this disables the use of symmetry, as this one always leads to a discontinuous PES around the symmetric points: Basically there is jump in the PES at the point where the symmetry detection starts classifying the system as symmetric. Normally the continuous PES mode of the engine (often disabling the symmetry) is only used when doing numerical derivatives, but this flag forces the engine to continuously run in this mode.', default=False) self.IgnoreEngineSupportsErrors: BoolType | BoolKey = BoolKey(name='IgnoreEngineSupportsErrors', comment='Pretend as if the engine supports anything requested. Use at your own risk.', hidden=True, default=False) self.IgnoreGradientsRequest: BoolType | BoolKey = BoolKey(name='IgnoreGradientsRequest', comment='If this option is set, the engine will not do analytical gradients if asked for it, so that gradients will have to be evaluated numerically by AMS.', default=False) self.IgnorePreviousResults: BoolType | BoolKey = BoolKey(name='IgnorePreviousResults', comment='If this option is set, the engine will not receive information from previous calculations. Typically this information is used to restart the self consistent procedure of the engine.', default=False) self.IgnoreStressTensorRequest: BoolType | BoolKey = BoolKey(name='IgnoreStressTensorRequest', comment='If this option is set, the engine will not calculate an analytical stress tensor if asked for it, so that the stress tensor will have to be evaluated numerically by AMS.', default=False) self.NeverQuiet: BoolType | BoolKey = BoolKey(name='NeverQuiet', comment='Makes the engine ignore the request to work quietly.', default=False) self.RandomFailureChance: float | FloatKey = FloatKey(name='RandomFailureChance', comment='Makes the engine randomly report failures, even though the results are actually fine. Useful for testing error handling on the application level.', default=0.0) self.RandomNoiseInEnergy: float | FloatKey = FloatKey(name='RandomNoiseInEnergy', comment='Adds a random noise to the energy returned by the engine. The random contribution is drawn from [-r,r] where r is the value of this keyword.', default=0.0, unit='Hartree') self.RandomNoiseInGradients: float | FloatKey = FloatKey(name='RandomNoiseInGradients', comment='Adds a random noise to the gradients returned by the engine. A random number in the range [-r,r] (where r is the value of this keyword) is drawn and added separately to each component of the gradient.', default=0.0, unit='Hartree/Angstrom') self.RandomStopChance: float | FloatKey = FloatKey(name='RandomStopChance', comment='Makes the engine randomly stop. Can be used to simulate crashes.', default=0.0)
[docs] class _ExitCondition(FixedBlock): r""" If any of the specified exitconditions are met, the AMS driver will exit cleanly. :ivar Type: The type of exitcondition specified :vartype Type: Literal["AtomsTooClose", "EngineEnergyUncertainty", "EngineGradientsUncertainty"] :ivar AtomsTooClose: If any pair of atoms is closer than the specified minimum value, the program will exit cleanly. :vartype AtomsTooClose: AMS._ExitCondition._AtomsTooClose :ivar EngineEnergyUncertainty: If the engine reports an uncertainty that is too high, the program will exit cleanly. :vartype EngineEnergyUncertainty: AMS._ExitCondition._EngineEnergyUncertainty :ivar EngineGradientsUncertainty: If the engine reports an uncertainty in the magnitude of the nuclear gradient of any atom that is too high, the program will exit cleanly. :vartype EngineGradientsUncertainty: AMS._ExitCondition._EngineGradientsUncertainty """
[docs] class _AtomsTooClose(FixedBlock): r""" If any pair of atoms is closer than the specified minimum value, the program will exit cleanly. :ivar MinimumDistance: Two atoms closer than this threshold value are considered too close. :vartype MinimumDistance: float | FloatKey :ivar PairCalculation: Two atoms closer than this threshold value are considered too close. :vartype PairCalculation: Literal["NeighborList", "DistanceMatrix"] """ def __post_init__(self): self.MinimumDistance: float | FloatKey = FloatKey(name='MinimumDistance', comment='Two atoms closer than this threshold value are considered too close.', default=0.7, unit='Angstrom') self.PairCalculation: Literal["NeighborList", "DistanceMatrix"] = MultipleChoiceKey(name='PairCalculation', comment='Two atoms closer than this threshold value are considered too close.', default='NeighborList', choices=['NeighborList', 'DistanceMatrix'])
[docs] class _EngineEnergyUncertainty(FixedBlock): r""" If the engine reports an uncertainty that is too high, the program will exit cleanly. :ivar MaxUncertainty: Threshold for Engine Energy Uncertainty divided by Normalization (by default the number of atoms) :vartype MaxUncertainty: float | FloatKey :ivar Normalization: Divide the reported Engine Energy Uncertainty by this normalization. Will divide by the number of atoms if unset. :vartype Normalization: float | FloatKey """ def __post_init__(self): self.MaxUncertainty: float | FloatKey = FloatKey(name='MaxUncertainty', comment='Threshold for Engine Energy Uncertainty divided by Normalization (by default the number of atoms)', default=0.001, unit='Hartree') self.Normalization: float | FloatKey = FloatKey(name='Normalization', comment='Divide the reported Engine Energy Uncertainty by this normalization. Will divide by the number of atoms if unset.', range='value >= 0.0')
[docs] class _EngineGradientsUncertainty(FixedBlock): r""" If the engine reports an uncertainty in the magnitude of the nuclear gradient of any atom that is too high, the program will exit cleanly. :ivar MaxUncertainty: Threshold for Engine Gradients Uncertainty. :vartype MaxUncertainty: float | FloatKey """ def __post_init__(self): self.MaxUncertainty: float | FloatKey = FloatKey(name='MaxUncertainty', comment='Threshold for Engine Gradients Uncertainty.', default=0.01580221, unit='Hartree/Angstrom')
def __post_init__(self): self.Type: Literal["AtomsTooClose", "EngineEnergyUncertainty", "EngineGradientsUncertainty"] = MultipleChoiceKey(name='Type', comment='The type of exitcondition specified', default='AtomsTooClose', choices=['AtomsTooClose', 'EngineEnergyUncertainty', 'EngineGradientsUncertainty']) self.AtomsTooClose: AMS._ExitCondition._AtomsTooClose = self._AtomsTooClose(name='AtomsTooClose', comment='If any pair of atoms is closer than the specified minimum value, the program will exit cleanly.') self.EngineEnergyUncertainty: AMS._ExitCondition._EngineEnergyUncertainty = self._EngineEnergyUncertainty(name='EngineEnergyUncertainty', comment='If the engine reports an uncertainty that is too high, the program will exit cleanly.') self.EngineGradientsUncertainty: AMS._ExitCondition._EngineGradientsUncertainty = self._EngineGradientsUncertainty(name='EngineGradientsUncertainty', comment='If the engine reports an uncertainty in the magnitude of the nuclear gradient of any atom that is too high, the program will exit cleanly.')
[docs] class _GCMC(FixedBlock): r""" This block controls the Grand Canonical Monte Carlo (GCMC) task. By default, molecules are added at random positions in the simulation box. The initial position is controlled by :ivar AccessibleVolume: Volume available to GCMC, in cubic Angstroms. AccessibleVolume should be specified for "Accessible" and "FreeAccessible" [VolumeOption]. :vartype AccessibleVolume: float | FloatKey :ivar Ensemble: Select the MC ensemble: Mu-VT for fixed volume or Mu-PT for variable volume. When the Mu-PT ensemble is selected the [Pressure] and [VolumeChangeMax] should also be specified. :vartype Ensemble: Literal["Mu-VT", "Mu-PT"] :ivar Iterations: Number of GCMC moves. :vartype Iterations: int | IntKey :ivar MapAtomsToOriginalCell: Keeps the atom (mostly) in the original cell by mapping them back before the geometry optimizations. :vartype MapAtomsToOriginalCell: BoolType | BoolKey :ivar MaxDistance: The max distance to other atoms of the system when adding the molecule. :vartype MaxDistance: float | FloatKey :ivar MinDistance: Keep the minimal distance to other atoms of the system when adding the molecule. :vartype MinDistance: float | FloatKey :ivar NonAccessibleVolume: Volume not available to GCMC, in cubic Angstroms. NonAccessibleVolume may be specified for the "Free" [VolumeOption] to reduce the accessible volume. :vartype NonAccessibleVolume: float | FloatKey :ivar NumAttempts: Try inserting/moving the selected molecule up to the specified number of times or until all constraints are satisfied. If all attempts fail a message will be printed and the simulation will stop. If the MaxDistance-MinDistance interval is small this number may have to be large. :vartype NumAttempts: int | IntKey :ivar Pressure: Pressure used to calculate the energy correction in the Mu-PT ensemble. Set it to zero for incompressible solid systems unless at very high pressures. :vartype Pressure: float | FloatKey :ivar Restart: Name of an RKF restart file. Upon restart, the information about the GCMC input parameters, the initial system (atomic coordinates, lattice, charge, etc.) and the MC molecules (both already inserted and to be inserted) are read from the restart file. The global GCMC input parameters and the MC Molecules can be modified from input. Any parameter not specified in the input will use its value from the restart file (i.e. not the default value). Molecules found in the restart file do not have to be present as named Systems in the input, however if there is a System present that matches the name of a molecule from restart then the System's geometry will replace that found in the restart file. It is also possible to specify new Molecules in the input, which will be added to the pool of the MC molecules from restart. :vartype Restart: str | Path | StringKey :ivar Temperature: Temperature of the simulation. Increase the temperature to improve the chance of accepting steps that result in a higher energy. :vartype Temperature: float | FloatKey :ivar UseGCPreFactor: Use the GC pre-exponential factor for probability. :vartype UseGCPreFactor: BoolType | BoolKey :ivar VolumeChangeMax: Fractional value by which logarithm of the volume is allowed to change at each step. The new volume is then calculated as Vnew = exp(random(-1:1)*VolumeChangeMax)*Vold :vartype VolumeChangeMax: float | FloatKey :ivar VolumeOption: Specifies the method to calculate the volume used to calculate the GC pre-exponential factor and the energy correction in the Mu-PT ensemble: Free: V = totalVolume - occupiedVolume - NonAccessibleVolume; Total: V = totalVolume; Accessible: V = AccessibleVolume; FreeAccessible: V = AccessibleVolume - occupiedVolume. The AccessibleVolume and NonAccessibleVolume are specified in the input, the occupiedVolume is calculated as a sum of atomic volumes. :vartype VolumeOption: Literal["Free", "Total", "Accessible", "FreeAccessible"] :ivar Box: Boundaries of the insertion space, i.e. coordinates of the origin of an inserted molecule (coordinates of an atom of the inserted system may fall outside the box). For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom (the system's bounding box extended by the MaxDistance value by default). :vartype Box: AMS._GCMC._Box :ivar Molecule: This block defines the molecule (or atom) that can be inserted/moved/deleted with the MC method. The coordinates should form a reasonable structure. The MC code uses these coordinates during the insertion step by giving them a random rotation, followed by a random translation to generate a random position of the molecule inside the box. Currently, there is no check to make sure all atoms of the molecule stay inside the simulation box. The program does check that the MaxDistance/MinDistance conditions are satisfied. :vartype Molecule: AMS._GCMC._Molecule :ivar Removables: The Removables can be used to specify a list of molecules that can be removed or moved during this GCMC calculation. Molecules are specified one per line in the format following format: MoleculeName atom1 atom2 ... The MoleculeName must match a name specified in one of the [Molecule] blocks. The atom indices refer to the whole input System and the number of atoms must match that in the specified Molecule. A suitable Removables block is written to the standard output after each accepted MC move. If you do so then you should also replace the initial atomic coordinates with the ones found in the same file. If a [Restart] key is present then the Removables block is ignored. :vartype Removables: str | Sequence[str] | FreeBlock :ivar SwapAtoms: Experimental: Occasionally swap the coordinates of a random pair of atoms from two regions. :vartype SwapAtoms: AMS._GCMC._SwapAtoms """
[docs] class _Box(FixedBlock): r""" Boundaries of the insertion space, i.e. coordinates of the origin of an inserted molecule (coordinates of an atom of the inserted system may fall outside the box). For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom (the system's bounding box extended by the MaxDistance value by default). :ivar Amax: Coordinate of the upper bound along the first axis. :vartype Amax: float | FloatKey :ivar Amin: Coordinate of the lower bound along the first axis. :vartype Amin: float | FloatKey :ivar Bmax: Coordinate of the upper bound along the second axis. :vartype Bmax: float | FloatKey :ivar Bmin: Coordinate of the lower bound along the second axis. :vartype Bmin: float | FloatKey :ivar Cmax: Coordinate of the upper bound along the third axis. :vartype Cmax: float | FloatKey :ivar Cmin: Coordinate of the lower bound along the third axis. :vartype Cmin: float | FloatKey """ def __post_init__(self): self.Amax: float | FloatKey = FloatKey(name='Amax', comment='Coordinate of the upper bound along the first axis.') self.Amin: float | FloatKey = FloatKey(name='Amin', comment='Coordinate of the lower bound along the first axis.') self.Bmax: float | FloatKey = FloatKey(name='Bmax', comment='Coordinate of the upper bound along the second axis.') self.Bmin: float | FloatKey = FloatKey(name='Bmin', comment='Coordinate of the lower bound along the second axis.') self.Cmax: float | FloatKey = FloatKey(name='Cmax', comment='Coordinate of the upper bound along the third axis.') self.Cmin: float | FloatKey = FloatKey(name='Cmin', comment='Coordinate of the lower bound along the third axis.')
[docs] class _Molecule(FixedBlock): r""" This block defines the molecule (or atom) that can be inserted/moved/deleted with the MC method. The coordinates should form a reasonable structure. The MC code uses these coordinates during the insertion step by giving them a random rotation, followed by a random translation to generate a random position of the molecule inside the box. Currently, there is no check to make sure all atoms of the molecule stay inside the simulation box. The program does check that the MaxDistance/MinDistance conditions are satisfied. :ivar ChemicalPotential: Chemical potential of the molecule (or atom) reservoir. It is used when calculating the Boltzmann accept/reject criteria after a MC move is executed. This value can be derived from first principles using statistical mechanics, or equivalently, it can be determined from thermochemical tables available in literature sources. For example, the proper chemical potential for a GCMC simulation in which single oxygen atoms are exchanged with a reservoir of O2 gas, should equal 1/2 the chemical potential of O2 at the temperature and pressure of the reservoir: cmpot = Mu_O(T,P) = 1/2*Mu_O2(T,P) = 1/2 * [Mu_ref(T,P_ref) + kT*Log(P/Pref) - E_diss] where the reference chemical potential [Mu_ref(T,P_ref)] is the experimentally determined chemical potential of O2 at T and Pref; kT*Log(P/Pref) is the pressure correction to the free energy, and E_diss is the dissociation energy of the O2 molecule. :vartype ChemicalPotential: float | FloatKey :ivar NoAddRemove: Set to True to tell the GCMC code to keep the number of molecules/atoms of this type fixed. It will thus disable Insert/Delete moves on this type, meaning it can only do a displacement move, or volume change move (for an NPT ensemble). :vartype NoAddRemove: BoolType | BoolKey :ivar SystemName: String ID of a named [System] to be inserted. The lattice specified with this System, if any, is ignored and the main system's lattice is used instead. :vartype SystemName: str | StringKey """ def __post_init__(self): self.ChemicalPotential: float | FloatKey = FloatKey(name='ChemicalPotential', comment='Chemical potential of the molecule (or atom) reservoir.\n\nIt is used when calculating the Boltzmann accept/reject criteria after a MC move is executed. This value can be derived from first principles using statistical mechanics, or equivalently, it can be determined from thermochemical tables available in literature sources. \n For example, the proper chemical potential for a GCMC simulation in which single oxygen atoms are exchanged with a reservoir of O2 gas, should equal 1/2 the chemical potential of O2 at the temperature and pressure of the reservoir: \n\n cmpot = Mu_O(T,P) = 1/2*Mu_O2(T,P) = 1/2 * [Mu_ref(T,P_ref) + kT*Log(P/Pref) - E_diss] \n\n where the reference chemical potential [Mu_ref(T,P_ref)] is the experimentally determined chemical potential of O2 at T and Pref; kT*Log(P/Pref) is the pressure correction to the free energy, and E_diss is the dissociation energy of the O2 molecule.', unit='Hartree') self.NoAddRemove: BoolType | BoolKey = BoolKey(name='NoAddRemove', comment='Set to True to tell the GCMC code to keep the number of molecules/atoms of this type fixed.\n\nIt will thus disable Insert/Delete moves on this type, meaning it can only do a displacement move, or volume change move (for an NPT ensemble).', gui_name='Fix molecule:', default=False) self.SystemName: str | StringKey = StringKey(name='SystemName', comment="String ID of a named [System] to be inserted. The lattice specified with this System, if any, is ignored and the main system's lattice is used instead. ", gui_name='Molecule:', gui_type='molecule-1')
[docs] class _Removables(FreeBlock): r""" The Removables can be used to specify a list of molecules that can be removed or moved during this GCMC calculation. Molecules are specified one per line in the format following format: MoleculeName atom1 atom2 ... The MoleculeName must match a name specified in one of the [Molecule] blocks. The atom indices refer to the whole input System and the number of atoms must match that in the specified Molecule. A suitable Removables block is written to the standard output after each accepted MC move. If you do so then you should also replace the initial atomic coordinates with the ones found in the same file. If a [Restart] key is present then the Removables block is ignored. """ def __post_init__(self): pass
[docs] class _SwapAtoms(FixedBlock): r""" Experimental: Occasionally swap the coordinates of a random pair of atoms from two regions. :ivar Probability: Probability of performing a swap move instead of any other GCMC move in a single GCMC iteration. :vartype Probability: float | FloatKey :ivar Regions: Names of two regions to swap between (separated by a space). :vartype Regions: str | StringKey """ def __post_init__(self): self.Probability: float | FloatKey = FloatKey(name='Probability', comment='Probability of performing a swap move instead of any other GCMC move in a single GCMC iteration.', default=0.0) self.Regions: str | StringKey = StringKey(name='Regions', comment='Names of two regions to swap between (separated by a space).')
def __post_init__(self): self.AccessibleVolume: float | FloatKey = FloatKey(name='AccessibleVolume', comment='Volume available to GCMC, in cubic Angstroms. AccessibleVolume should be specified for "Accessible" and "FreeAccessible" [VolumeOption].', default=0.0) self.Ensemble: Literal["Mu-VT", "Mu-PT"] = MultipleChoiceKey(name='Ensemble', comment='Select the MC ensemble: Mu-VT for fixed volume or Mu-PT for variable volume. When the Mu-PT ensemble is selected the [Pressure] and [VolumeChangeMax] should also be specified.', default='Mu-VT', choices=['Mu-VT', 'Mu-PT']) self.Iterations: int | IntKey = IntKey(name='Iterations', comment='Number of GCMC moves.', gui_name='Number of GCMC iterations:') self.MapAtomsToOriginalCell: BoolType | BoolKey = BoolKey(name='MapAtomsToOriginalCell', comment='Keeps the atom (mostly) in the original cell by mapping them back before the geometry optimizations.', default=True) self.MaxDistance: float | FloatKey = FloatKey(name='MaxDistance', comment='The max distance to other atoms of the system when adding the molecule.', gui_name='Add molecules within:', default=3.0, unit='Angstrom') self.MinDistance: float | FloatKey = FloatKey(name='MinDistance', comment='Keep the minimal distance to other atoms of the system when adding the molecule.', gui_name='Add molecules not closer than:', default=0.3, unit='Angstrom') self.NonAccessibleVolume: float | FloatKey = FloatKey(name='NonAccessibleVolume', comment='Volume not available to GCMC, in cubic Angstroms. NonAccessibleVolume may be specified for the "Free" [VolumeOption] to reduce the accessible volume.', gui_name='Non-accessible volume:', default=0.0) self.NumAttempts: int | IntKey = IntKey(name='NumAttempts', comment='Try inserting/moving the selected molecule up to the specified number of times or until all constraints are satisfied. If all attempts fail a message will be printed and the simulation will stop. If the MaxDistance-MinDistance interval is small this number may have to be large.', gui_name='Max tries:', default=1000) self.Pressure: float | FloatKey = FloatKey(name='Pressure', comment='Pressure used to calculate the energy correction in the Mu-PT ensemble. Set it to zero for incompressible solid systems unless at very high pressures.', default=0.0, unit='Pascal') self.Restart: str | Path | StringKey = PathStringKey(name='Restart', comment="Name of an RKF restart file. Upon restart, the information about the GCMC input parameters, the initial system (atomic coordinates, lattice, charge, etc.) and the MC molecules (both already inserted and to be inserted) are read from the restart file. The global GCMC input parameters and the MC Molecules can be modified from input. Any parameter not specified in the input will use its value from the restart file (i.e. not the default value). Molecules found in the restart file do not have to be present as named Systems in the input, however if there is a System present that matches the name of a molecule from restart then the System's geometry will replace that found in the restart file. It is also possible to specify new Molecules in the input, which will be added to the pool of the MC molecules from restart.", ispath=True) self.Temperature: float | FloatKey = FloatKey(name='Temperature', comment='Temperature of the simulation. Increase the temperature to improve the chance of accepting steps that result in a higher energy.', default=300.0, unit='Kelvin') self.UseGCPreFactor: BoolType | BoolKey = BoolKey(name='UseGCPreFactor', comment='Use the GC pre-exponential factor for probability.', gui_name='Use GC prefactor:', default=True) self.VolumeChangeMax: float | FloatKey = FloatKey(name='VolumeChangeMax', comment='Fractional value by which logarithm of the volume is allowed to change at each step. The new volume is then calculated as Vnew = exp(random(-1:1)*VolumeChangeMax)*Vold', default=0.05) self.VolumeOption: Literal["Free", "Total", "Accessible", "FreeAccessible"] = MultipleChoiceKey(name='VolumeOption', comment=' Specifies the method to calculate the volume used to calculate the GC pre-exponential factor and the energy correction in the Mu-PT ensemble: \n Free: V = totalVolume - occupiedVolume - NonAccessibleVolume; \n Total: V = totalVolume; \n Accessible: V = AccessibleVolume; \n FreeAccessible: V = AccessibleVolume - occupiedVolume. \n The AccessibleVolume and NonAccessibleVolume are specified in the input, the occupiedVolume is calculated as a sum of atomic volumes.', gui_name='Volume method:', default='Free', choices=['Free', 'Total', 'Accessible', 'FreeAccessible']) self.Box: AMS._GCMC._Box = self._Box(name='Box', comment="Boundaries of the insertion space, i.e. coordinates of the origin of an inserted molecule (coordinates of an atom of the inserted system may fall outside the box).\n\nFor a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom (the system's bounding box extended by the MaxDistance value by default).") self.Molecule: AMS._GCMC._Molecule = self._Molecule(name='Molecule', comment='This block defines the molecule (or atom) that can be inserted/moved/deleted with the MC method. The coordinates should form a reasonable structure. The MC code uses these coordinates during the insertion step by giving them a random rotation, followed by a random translation to generate a random position of the molecule inside the box. Currently, there is no check to make sure all atoms of the molecule stay inside the simulation box. The program does check that the MaxDistance/MinDistance conditions are satisfied.', unique=False, gui_name='Molecules') self.Removables: str | Sequence[str] | FreeBlock = self._Removables(name='Removables', comment='The Removables can be used to specify a list of molecules that can be removed or moved during this GCMC calculation. Molecules are specified one per line in the format following format: \n MoleculeName atom1 atom2 ... \n The MoleculeName must match a name specified in one of the [Molecule] blocks. The atom indices refer to the whole input System and the number of atoms must match that in the specified Molecule. A suitable Removables block is written to the standard output after each accepted MC move. If you do so then you should also replace the initial atomic coordinates with the ones found in the same file. If a [Restart] key is present then the Removables block is ignored.') self.SwapAtoms: AMS._GCMC._SwapAtoms = self._SwapAtoms(name='SwapAtoms', comment='Experimental: Occasionally swap the coordinates of a random pair of atoms from two regions.')
[docs] class _GeometryOptimization(FixedBlock): r""" Configures details of the geometry optimization and transition state searches. :ivar CalcPropertiesOnlyIfConverged: Compute the properties requested in the 'Properties' block, e.g. Frequencies or Phonons, only if the optimization (or transition state search) converged. If False, the properties will be computed even if the optimization did not converge. :vartype CalcPropertiesOnlyIfConverged: BoolType | BoolKey :ivar CoordinateType: Select the type of coordinates in which to perform the optimization. 'Auto' automatically selects the most appropriate CoordinateType for a given Method. If 'Auto' is selected, Delocalized coordinates will be used for the Quasi-Newton method, while Cartesian coordinates will be used for all other methods. :vartype CoordinateType: Literal["Auto", "Delocalized", "Cartesian"] :ivar KeepIntermediateResults: Whether the full engine result files of all intermediate steps are stored on disk. By default only the last step is kept, and only if the geometry optimization converged. This can easily lead to huge amounts of data being stored on disk, but it can sometimes be convenient to closely monitor a tricky optimization, e.g. excited state optimizations going through conical intersections, etc. ... :vartype KeepIntermediateResults: BoolType | BoolKey :ivar MaxIterations: The maximum number of geometry iterations allowed to converge to the desired structure. :vartype MaxIterations: int | IntKey :ivar MaxRestarts: If a geometry optimization of a system with no symmetry operators (or with explicitly disabled symmetry: ``UseSymmetry False``) and enabled PES point characterization converges to a transition state (or higher order saddle point), it can be restarted automatically after a small displacement along the imaginary vibrational mode. In case the restarted optimization again does not find a minimum, this can happen multiple times in succession. This keyword sets the maximum number of restarts. The default value is 0, so the automatic restarting is disabled by default. :vartype MaxRestarts: int | IntKey :ivar Method: Select the optimization algorithm employed for the geometry relaxation. Currently supported are: the Hessian-based Quasi-Newton-type BFGS algorithm, the fast inertial relaxation method (FIRE), the limited-memory BFGS method, and the conjugate gradients method. The default is to choose an appropriate method automatically based on the engine's speed, the system size and the supported optimization options. :vartype Method: Literal["Auto", "Quasi-Newton", "FIRE", "L-BFGS", "ConjugateGradients", "Dimer"] :ivar OptimizeLattice: Whether to also optimize the lattice for periodic structures. This is currently supported with the Quasi-Newton, FIRE, and L-BFGS optimizers. :vartype OptimizeLattice: BoolType | BoolKey :ivar PretendConverged: Normally a non-converged geometry optimization is considered an error. If this keyword is set to True, the optimizer will only produce a warning and still claim that the optimization is converged. (This is mostly useful for scripting applications, where one might want to consider non-converged optimizations still successful jobs.) :vartype PretendConverged: BoolType | BoolKey :ivar RestartDisplacement: If a geometry optimization of a system with no symmetry operators (or with explicitly disabled symmetry: ``UseSymmetry False``) and enabled PES point characterization converges to a transition state (or higher order saddle point), it can be restarted automatically after a small displacement along the imaginary vibrational mode. This keywords sets the size of the displacement for the furthest moving atom. :vartype RestartDisplacement: float | FloatKey :ivar Convergence: Convergence is monitored for up to 4 quantities: the energy change, the Cartesian gradients, the Cartesian step size, and for lattice optimizations the stress energy per atom. Convergence criteria can be specified separately for each of these items. :vartype Convergence: AMS._GeometryOptimization._Convergence :ivar Dimer: Options for the Dimer method for transition state search. :vartype Dimer: AMS._GeometryOptimization._Dimer :ivar EngineAutomations: The optimizer can change some settings of the engine, based for instance on the error. The idea is to allow the engine to be a bit quicker at the start, and more accurate towards the end. Automations are always engine specific. :vartype EngineAutomations: AMS._GeometryOptimization._EngineAutomations :ivar FIRE: This block configures the details of the FIRE optimizer. The keywords name correspond the the symbols used in the article describing the method, see PRL 97, 170201 (2006). :vartype FIRE: AMS._GeometryOptimization._FIRE :ivar HessianFree: Configures details of the Hessian-free (conjugate gradients or L-BFGS) geometry optimizer. :vartype HessianFree: AMS._GeometryOptimization._HessianFree :ivar InitialHessian: Options for initial model Hessian when optimizing systems with the Quasi-Newton method. :vartype InitialHessian: AMS._GeometryOptimization._InitialHessian :ivar Quasi-Newton: Configures details of the Quasi-Newton geometry optimizer. :vartype Quasi-Newton: AMS._GeometryOptimization._Quasi-Newton """
[docs] class _Convergence(FixedBlock): r""" Convergence is monitored for up to 4 quantities: the energy change, the Cartesian gradients, the Cartesian step size, and for lattice optimizations the stress energy per atom. Convergence criteria can be specified separately for each of these items. :ivar Energy: The criterion for changes in the energy. The energy is considered converged when the change in energy is smaller than this threshold times the number of atoms. :vartype Energy: float | FloatKey :ivar Gradients: Threshold for nuclear gradients. :vartype Gradients: float | FloatKey :ivar Quality: A quick way to change convergence thresholds: 'Good' will reduce all thresholds by an order of magnitude from their default value. 'VeryGood' will tighten them by two orders of magnitude. 'Basic' and 'VeryBasic' will increase the thresholds by one or two orders of magnitude respectively. :vartype Quality: Literal["VeryBasic", "Basic", "Normal", "Good", "VeryGood", "Excellent", "Custom"] :ivar Step: The maximum Cartesian step allowed for a converged geometry. :vartype Step: float | FloatKey :ivar StressEnergyPerAtom: Threshold used when optimizing the lattice vectors. The stress is considered 'converged' when the maximum value of stress_tensor * cell_volume / number_of_atoms is smaller than this threshold (for 2D and 1D systems, the cell_volume is replaced by the cell_area and cell_length respectively). :vartype StressEnergyPerAtom: float | FloatKey """ def __post_init__(self): self.Energy: float | FloatKey = FloatKey(name='Energy', comment='The criterion for changes in the energy. The energy is considered converged when the change in energy is smaller than this threshold times the number of atoms.', gui_name='Energy convergence:', default=1e-05, unit='Hartree', range='value > 0') self.Gradients: float | FloatKey = FloatKey(name='Gradients', comment='Threshold for nuclear gradients.', gui_name='Gradient convergence:', default=0.001, unit='Hartree/Angstrom', range='value > 0') self.Quality: Literal["VeryBasic", "Basic", "Normal", "Good", "VeryGood", "Excellent", "Custom"] = MultipleChoiceKey(name='Quality', comment="A quick way to change convergence thresholds: 'Good' will reduce all thresholds by an order of magnitude from their default value. 'VeryGood' will tighten them by two orders of magnitude. 'Basic' and 'VeryBasic' will increase the thresholds by one or two orders of magnitude respectively.", gui_name='Convergence:', default='Custom', choices=['VeryBasic', 'Basic', 'Normal', 'Good', 'VeryGood', 'Excellent', 'Custom'], hiddenchoices=['Excellent']) self.Step: float | FloatKey = FloatKey(name='Step', comment='The maximum Cartesian step allowed for a converged geometry.', gui_name='Step convergence:', default=0.01, unit='Angstrom', range='value > 0') self.StressEnergyPerAtom: float | FloatKey = FloatKey(name='StressEnergyPerAtom', comment="Threshold used when optimizing the lattice vectors. The stress is considered 'converged' when the maximum value of stress_tensor * cell_volume / number_of_atoms is smaller than this threshold (for 2D and 1D systems, the cell_volume is replaced by the cell_area and cell_length respectively).", default=0.0005, unit='Hartree', range='value > 0')
[docs] class _Dimer(FixedBlock): r""" Options for the Dimer method for transition state search. :ivar AngleThreshold: The rotation is considered converged when the the rotation angle falls below the specified threshold. :vartype AngleThreshold: float | FloatKey :ivar DimerDelta: Euclidian distance between the midpoint and the endpoint. :vartype DimerDelta: float | FloatKey :ivar ExtrapolateForces: Set to false to call engine to calculate forces at the extrapolated rotation angle instead of extrapolating them. :vartype ExtrapolateForces: BoolType | BoolKey :ivar LBFGSMaxVectors: Max number of vectors for the L-BFGS algorithm to save. :vartype LBFGSMaxVectors: int | IntKey :ivar MaxRotationIterations: Maximum number of rotation iterations for a single translation step. :vartype MaxRotationIterations: int | IntKey :ivar Region: Include only atoms of the specified region(s) in the rotations, which allows searching for a transition state involving selected atoms only. :vartype Region: str | StringKey :ivar RotationTrustRadius: L-BFGS trust radius during rotation iterations. :vartype RotationTrustRadius: float | FloatKey :ivar TranslationTrustRadius: L-BFGS trust radius during translation iterations. :vartype TranslationTrustRadius: float | FloatKey """ def __post_init__(self): self.AngleThreshold: float | FloatKey = FloatKey(name='AngleThreshold', comment='The rotation is considered converged when the the rotation angle falls below the specified threshold.', default=1.0, unit='Degree') self.DimerDelta: float | FloatKey = FloatKey(name='DimerDelta', comment='Euclidian distance between the midpoint and the endpoint.', default=0.01, unit='Angstrom') self.ExtrapolateForces: BoolType | BoolKey = BoolKey(name='ExtrapolateForces', comment='Set to false to call engine to calculate forces at the extrapolated rotation angle instead of extrapolating them.', default=True) self.LBFGSMaxVectors: int | IntKey = IntKey(name='LBFGSMaxVectors', comment='Max number of vectors for the L-BFGS algorithm to save.', default=10) self.MaxRotationIterations: int | IntKey = IntKey(name='MaxRotationIterations', comment='Maximum number of rotation iterations for a single translation step.', default=10) self.Region: str | StringKey = StringKey(name='Region', comment='Include only atoms of the specified region(s) in the rotations, which allows searching for a transition state involving selected atoms only.', default='*') self.RotationTrustRadius: float | FloatKey = FloatKey(name='RotationTrustRadius', comment='L-BFGS trust radius during rotation iterations.', default=0.1, unit='Angstrom') self.TranslationTrustRadius: float | FloatKey = FloatKey(name='TranslationTrustRadius', comment='L-BFGS trust radius during translation iterations.', default=0.1, unit='Angstrom')
[docs] class _EngineAutomations(FixedBlock): r""" The optimizer can change some settings of the engine, based for instance on the error. The idea is to allow the engine to be a bit quicker at the start, and more accurate towards the end. Automations are always engine specific. :ivar Enabled: Whether or not automations are enabled at all. :vartype Enabled: BoolType | BoolKey :ivar Gradient: A gradient-based automation. :vartype Gradient: AMS._GeometryOptimization._EngineAutomations._Gradient :ivar Iteration: Geometry step based automation. :vartype Iteration: AMS._GeometryOptimization._EngineAutomations._Iteration """
[docs] class _Gradient(FixedBlock): r""" A gradient-based automation. :ivar FinalValue: This value will be used whenever the gradient is less than GradientLow :vartype FinalValue: float | FloatKey :ivar HighGradient: Defines a large gradient. When the actual gradient is between GradientHigh and GradientLow a linear interpolation scheme is used for kT (on a log scale). :vartype HighGradient: float | FloatKey :ivar InitialValue: This value will be used at the first geometry, and whenever the gradient is higher than GradientHigh :vartype InitialValue: float | FloatKey :ivar LowGradient: Defines a small gradient, see GradientHigh :vartype LowGradient: float | FloatKey :ivar UseLogInterpolation: Whether to use interpolation on a log (y) scale or not :vartype UseLogInterpolation: BoolType | BoolKey :ivar Variable: variable to be tweaked for the engine. :vartype Variable: str | StringKey """ def __post_init__(self): self.FinalValue: float | FloatKey = FloatKey(name='FinalValue', comment='This value will be used whenever the gradient is less than GradientLow') self.HighGradient: float | FloatKey = FloatKey(name='HighGradient', comment='Defines a large gradient. When the actual gradient is between GradientHigh and GradientLow a linear interpolation scheme is used for kT (on a log scale).', default=1.0, unit='Hartree/Angstrom') self.InitialValue: float | FloatKey = FloatKey(name='InitialValue', comment='This value will be used at the first geometry, and whenever the gradient is higher than GradientHigh') self.LowGradient: float | FloatKey = FloatKey(name='LowGradient', comment='Defines a small gradient, see GradientHigh', default=1.0, unit='Hartree/Angstrom') self.UseLogInterpolation: BoolType | BoolKey = BoolKey(name='UseLogInterpolation', comment='Whether to use interpolation on a log (y) scale or not', default=True) self.Variable: str | StringKey = StringKey(name='Variable', comment='variable to be tweaked for the engine.', default='')
[docs] class _Iteration(FixedBlock): r""" Geometry step based automation. :ivar FinalValue: :vartype FinalValue: float | FloatKey :ivar FirstIteration: When the actual gradient is between the first and last iteration, a linear interpolation is used. :vartype FirstIteration: int | IntKey :ivar InitialValue: This value will be used when the iteration number is smaller or equal to FirstIteration :vartype InitialValue: float | FloatKey :ivar LastIteration: Where the automation should reach the FinalValue :vartype LastIteration: int | IntKey :ivar UseLogInterpolation: Whether to use interpolation on a log (y) scale or not :vartype UseLogInterpolation: BoolType | BoolKey :ivar Variable: variable to be tweaked for the engine. :vartype Variable: str | StringKey """ def __post_init__(self): self.FinalValue: float | FloatKey = FloatKey(name='FinalValue') self.FirstIteration: int | IntKey = IntKey(name='FirstIteration', comment='When the actual gradient is between the first and last iteration, a linear interpolation is used.', default=1) self.InitialValue: float | FloatKey = FloatKey(name='InitialValue', comment='This value will be used when the iteration number is smaller or equal to FirstIteration') self.LastIteration: int | IntKey = IntKey(name='LastIteration', comment='Where the automation should reach the FinalValue', default=10) self.UseLogInterpolation: BoolType | BoolKey = BoolKey(name='UseLogInterpolation', comment='Whether to use interpolation on a log (y) scale or not', default=True) self.Variable: str | StringKey = StringKey(name='Variable', comment='variable to be tweaked for the engine.', default='')
def __post_init__(self): self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Whether or not automations are enabled at all.', default=True) self.Gradient: AMS._GeometryOptimization._EngineAutomations._Gradient = self._Gradient(name='Gradient', comment='A gradient-based automation.', unique=False) self.Iteration: AMS._GeometryOptimization._EngineAutomations._Iteration = self._Iteration(name='Iteration', comment='Geometry step based automation.', unique=False)
[docs] class _FIRE(FixedBlock): r""" This block configures the details of the FIRE optimizer. The keywords name correspond the the symbols used in the article describing the method, see PRL 97, 170201 (2006). :ivar AllowOverallRotation: Whether or not the system is allowed to freely rotate during the optimization. This is relevant when optimizing structures in the presence of external fields. :vartype AllowOverallRotation: BoolType | BoolKey :ivar AllowOverallTranslation: Whether or not the system is allowed to translate during the optimization. This is relevant when optimizing structures in the presence of external fields. :vartype AllowOverallTranslation: BoolType | BoolKey :ivar MapAtomsToUnitCell: Map the atoms to the central cell at each geometry step. :vartype MapAtomsToUnitCell: BoolType | BoolKey :ivar NMin: Number of steps after stopping before increasing the time step again. :vartype NMin: int | IntKey :ivar alphaStart: Steering coefficient. :vartype alphaStart: float | FloatKey :ivar atomMass: Fictitious atomic mass used for all atoms. There is no reason to change this, as it just corresponds to using a different integration timestep. :vartype atomMass: float | FloatKey :ivar dtMax: Maximum time step used for the integration. For ReaxFF and APPLE&P, this value is reduced by 50%. :vartype dtMax: float | FloatKey :ivar dtStart: Initial time step for the integration. :vartype dtStart: float | FloatKey :ivar fAlpha: Reduction factor for the steering coefficient. :vartype fAlpha: float | FloatKey :ivar fDec: Reduction factor for reducing the time step in case of uphill movement. :vartype fDec: float | FloatKey :ivar fInc: Growth factor for the integration time step. :vartype fInc: float | FloatKey :ivar strainMass: Fictitious relative mass of the lattice degrees of freedom. This controls the stiffness of the lattice degrees of freedom relative to the atomic degrees of freedom, with smaller values resulting in a more aggressive optimization of the lattice. :vartype strainMass: float | FloatKey """ def __post_init__(self): self.AllowOverallRotation: BoolType | BoolKey = BoolKey(name='AllowOverallRotation', comment='Whether or not the system is allowed to freely rotate during the optimization. This is relevant when optimizing structures in the presence of external fields.', default=True) self.AllowOverallTranslation: BoolType | BoolKey = BoolKey(name='AllowOverallTranslation', comment='Whether or not the system is allowed to translate during the optimization. This is relevant when optimizing structures in the presence of external fields.', default=False) self.MapAtomsToUnitCell: BoolType | BoolKey = BoolKey(name='MapAtomsToUnitCell', comment='Map the atoms to the central cell at each geometry step.', default=False) self.NMin: int | IntKey = IntKey(name='NMin', comment='Number of steps after stopping before increasing the time step again.', default=5) self.alphaStart: float | FloatKey = FloatKey(name='alphaStart', comment='Steering coefficient.', default=0.1) self.atomMass: float | FloatKey = FloatKey(name='atomMass', comment='Fictitious atomic mass used for all atoms. There is no reason to change this, as it just corresponds to using a different integration timestep.', hidden=True, default=1.0, unit='Dalton') self.dtMax: float | FloatKey = FloatKey(name='dtMax', comment='Maximum time step used for the integration. For ReaxFF and APPLE&P, this value is reduced by 50%.', default=1.0, unit='Femtoseconds') self.dtStart: float | FloatKey = FloatKey(name='dtStart', comment='Initial time step for the integration.', default=0.25, unit='Femtoseconds') self.fAlpha: float | FloatKey = FloatKey(name='fAlpha', comment='Reduction factor for the steering coefficient.', default=0.99) self.fDec: float | FloatKey = FloatKey(name='fDec', comment='Reduction factor for reducing the time step in case of uphill movement.', default=0.5) self.fInc: float | FloatKey = FloatKey(name='fInc', comment='Growth factor for the integration time step.', default=1.1) self.strainMass: float | FloatKey = FloatKey(name='strainMass', comment='Fictitious relative mass of the lattice degrees of freedom. This controls the stiffness of the lattice degrees of freedom relative to the atomic degrees of freedom, with smaller values resulting in a more aggressive optimization of the lattice.', default=0.5)
[docs] class _HessianFree(FixedBlock): r""" Configures details of the Hessian-free (conjugate gradients or L-BFGS) geometry optimizer. :ivar Step: :vartype Step: AMS._GeometryOptimization._HessianFree._Step """
[docs] class _Step(FixedBlock): r""" :ivar MaxCartesianStep: Limit on a single Cartesian component of the step. :vartype MaxCartesianStep: float | FloatKey :ivar MinRadius: Minimum value for the trust radius. :vartype MinRadius: float | FloatKey :ivar TrialStep: Length of the finite-difference step when determining curvature. Should be smaller than the step convergence criterion. :vartype TrialStep: float | FloatKey :ivar TrustRadius: Initial value of the trust radius. :vartype TrustRadius: float | FloatKey """ def __post_init__(self): self.MaxCartesianStep: float | FloatKey = FloatKey(name='MaxCartesianStep', comment='Limit on a single Cartesian component of the step.', default=0.1, unit='Angstrom') self.MinRadius: float | FloatKey = FloatKey(name='MinRadius', comment='Minimum value for the trust radius.', default=0.0, unit='Angstrom') self.TrialStep: float | FloatKey = FloatKey(name='TrialStep', comment='Length of the finite-difference step when determining curvature. Should be smaller than the step convergence criterion.', default=0.0005, unit='Angstrom') self.TrustRadius: float | FloatKey = FloatKey(name='TrustRadius', comment='Initial value of the trust radius.', default=0.2, unit='Angstrom')
def __post_init__(self): self.Step: AMS._GeometryOptimization._HessianFree._Step = self._Step(name='Step')
[docs] class _InitialHessian(FixedBlock): r""" Options for initial model Hessian when optimizing systems with the Quasi-Newton method. :ivar File: KF file containing the initial Hessian (or the results dir. containing it). This can be used to load a Hessian calculated in a previously with the [Properties%Hessian] keyword. :vartype File: str | Path | StringKey :ivar Type: Select the type of initial Hessian. Auto: let the program pick an initial model Hessian. UnitMatrix: simplest initial model Hessian, just a unit matrix in the optimization coordinates. Swart: model Hessian from M. Swart. FromFile: load the Hessian from the results of a previous calculation (see InitialHessian%File). Calculate: compute the initial Hessian (this may be computationally expensive and it is mostly recommended for TransitionStateSearch calculations). CalculateWithFastEngine: compute the initial Hessian with a faster engine. :vartype Type: Literal["Auto", "UnitMatrix", "Swart", "FromFile", "Calculate", "CalculateWithFastEngine"] """ def __post_init__(self): self.File: str | Path | StringKey = PathStringKey(name='File', comment='KF file containing the initial Hessian (or the results dir. containing it). This can be used to load a Hessian calculated in a previously with the [Properties%Hessian] keyword.', gui_name='Initial Hessian from:', ispath=True, gui_type='.rkf {{{RKF Result Files} .rkf} {{Any Files} *}}') self.Type: Literal["Auto", "UnitMatrix", "Swart", "FromFile", "Calculate", "CalculateWithFastEngine"] = MultipleChoiceKey(name='Type', comment='Select the type of initial Hessian. Auto: let the program pick an initial model Hessian. UnitMatrix: simplest initial model Hessian, just a unit matrix in the optimization coordinates. Swart: model Hessian from M. Swart. FromFile: load the Hessian from the results of a previous calculation (see InitialHessian%File). Calculate: compute the initial Hessian (this may be computationally expensive and it is mostly recommended for TransitionStateSearch calculations). CalculateWithFastEngine: compute the initial Hessian with a faster engine.', gui_name='Initial Hessian:', default='Auto', choices=['Auto', 'UnitMatrix', 'Swart', 'FromFile', 'Calculate', 'CalculateWithFastEngine'])
[docs] class _Quasi_Newton(FixedBlock): r""" Configures details of the Quasi-Newton geometry optimizer. :ivar EnforceConstraints: Whether to enforce constraints at each steps exactly or add them to the optimization space as Lagrange multipliers. :vartype EnforceConstraints: BoolType | BoolKey :ivar MaxGDIISVectors: Sets the maximum number of GDIIS vectors. Setting this to a number >0 enables the GDIIS method. :vartype MaxGDIISVectors: int | IntKey :ivar UpdateTSVectorEveryStep: Whether to update the TS reaction coordinate at each step with the current eigenvector. :vartype UpdateTSVectorEveryStep: BoolType | BoolKey :ivar Step: :vartype Step: AMS._GeometryOptimization._Quasi-Newton._Step """
[docs] class _Step(FixedBlock): r""" :ivar TrustRadius: Initial value of the trust radius. :vartype TrustRadius: float | FloatKey :ivar VaryTrustRadius: Whether to allow the trust radius to change during optimization. By default True during energy minimization and False during transition state search. :vartype VaryTrustRadius: BoolType | BoolKey """ def __post_init__(self): self.TrustRadius: float | FloatKey = FloatKey(name='TrustRadius', comment='Initial value of the trust radius.') self.VaryTrustRadius: BoolType | BoolKey = BoolKey(name='VaryTrustRadius', comment='Whether to allow the trust radius to change during optimization. By default True during energy minimization and False during transition state search.')
def __post_init__(self): self.EnforceConstraints: BoolType | BoolKey = BoolKey(name='EnforceConstraints', comment='Whether to enforce constraints at each steps exactly or add them to the optimization space as Lagrange multipliers.', hidden=True, default=True) self.MaxGDIISVectors: int | IntKey = IntKey(name='MaxGDIISVectors', comment='Sets the maximum number of GDIIS vectors. Setting this to a number >0 enables the GDIIS method.', default=0) self.UpdateTSVectorEveryStep: BoolType | BoolKey = BoolKey(name='UpdateTSVectorEveryStep', comment='Whether to update the TS reaction coordinate at each step with the current eigenvector.', gui_name='Update TSRC vector every step:', default=True) self.Step: AMS._GeometryOptimization._Quasi-Newton._Step = self._Step(name='Step')
def __post_init__(self): self.CalcPropertiesOnlyIfConverged: BoolType | BoolKey = BoolKey(name='CalcPropertiesOnlyIfConverged', comment="Compute the properties requested in the 'Properties' block, e.g. Frequencies or Phonons, only if the optimization (or transition state search) converged. If False, the properties will be computed even if the optimization did not converge.", default=True) self.CoordinateType: Literal["Auto", "Delocalized", "Cartesian"] = MultipleChoiceKey(name='CoordinateType', comment="Select the type of coordinates in which to perform the optimization. 'Auto' automatically selects the most appropriate CoordinateType for a given Method. \n\n If 'Auto' is selected, Delocalized coordinates will be used for the Quasi-Newton method, while Cartesian coordinates will be used for all other methods.", gui_name='Optimization space:', default='Auto', choices=['Auto', 'Delocalized', 'Cartesian']) self.KeepIntermediateResults: BoolType | BoolKey = BoolKey(name='KeepIntermediateResults', comment='Whether the full engine result files of all intermediate steps are stored on disk. By default only the last step is kept, and only if the geometry optimization converged. This can easily lead to huge amounts of data being stored on disk, but it can sometimes be convenient to closely monitor a tricky optimization, e.g. excited state optimizations going through conical intersections, etc. ...', default=False) self.MaxIterations: int | IntKey = IntKey(name='MaxIterations', comment='The maximum number of geometry iterations allowed to converge to the desired structure.', gui_name='Maximum number of iterations:', range='value >= 0') self.MaxRestarts: int | IntKey = IntKey(name='MaxRestarts', comment='If a geometry optimization of a system with no symmetry operators (or with explicitly disabled symmetry: ``UseSymmetry False``) and enabled PES point characterization converges to a transition state (or higher order saddle point), it can be restarted automatically after a small displacement along the imaginary vibrational mode. In case the restarted optimization again does not find a minimum, this can happen multiple times in succession. This keyword sets the maximum number of restarts. The default value is 0, so the automatic restarting is disabled by default.', default=0) self.Method: Literal["Auto", "Quasi-Newton", "FIRE", "L-BFGS", "ConjugateGradients", "Dimer"] = MultipleChoiceKey(name='Method', comment="Select the optimization algorithm employed for the geometry relaxation. Currently supported are: \n\nthe Hessian-based Quasi-Newton-type BFGS algorithm, \n\nthe fast inertial relaxation method (FIRE), \n\nthe limited-memory BFGS method, \n\nand the conjugate gradients method. The default is to choose an appropriate method automatically based on the engine's speed, the system size and the supported optimization options.", gui_name='Optimization method:', default='Auto', choices=['Auto', 'Quasi-Newton', 'FIRE', 'L-BFGS', 'ConjugateGradients', 'Dimer']) self.OptimizeLattice: BoolType | BoolKey = BoolKey(name='OptimizeLattice', comment='Whether to also optimize the lattice for periodic structures. This is currently supported with the Quasi-Newton, FIRE, and L-BFGS optimizers.', default=False) self.PretendConverged: BoolType | BoolKey = BoolKey(name='PretendConverged', comment='Normally a non-converged geometry optimization is considered an error. If this keyword is set to True, the optimizer will only produce a warning and still claim that the optimization is converged. (This is mostly useful for scripting applications, where one might want to consider non-converged optimizations still successful jobs.)', default=False) self.RestartDisplacement: float | FloatKey = FloatKey(name='RestartDisplacement', comment='If a geometry optimization of a system with no symmetry operators (or with explicitly disabled symmetry: ``UseSymmetry False``) and enabled PES point characterization converges to a transition state (or higher order saddle point), it can be restarted automatically after a small displacement along the imaginary vibrational mode. This keywords sets the size of the displacement for the furthest moving atom.', default=0.05, unit='Angstrom') self.Convergence: AMS._GeometryOptimization._Convergence = self._Convergence(name='Convergence', comment='Convergence is monitored for up to 4 quantities: the energy change, the Cartesian gradients, the Cartesian step size, and for lattice optimizations the stress energy per atom. Convergence criteria can be specified separately for each of these items.') self.Dimer: AMS._GeometryOptimization._Dimer = self._Dimer(name='Dimer', comment='Options for the Dimer method for transition state search.') self.EngineAutomations: AMS._GeometryOptimization._EngineAutomations = self._EngineAutomations(name='EngineAutomations', comment='The optimizer can change some settings of the engine, based for instance on the error.\nThe idea is to allow the engine to be a bit quicker at the start, and more accurate towards the end.\nAutomations are always engine specific.') self.FIRE: AMS._GeometryOptimization._FIRE = self._FIRE(name='FIRE', comment='This block configures the details of the FIRE optimizer. The keywords name correspond the the symbols used in the article describing the method, see PRL 97, 170201 (2006).') self.HessianFree: AMS._GeometryOptimization._HessianFree = self._HessianFree(name='HessianFree', comment='Configures details of the Hessian-free (conjugate gradients or L-BFGS) geometry optimizer.') self.InitialHessian: AMS._GeometryOptimization._InitialHessian = self._InitialHessian(name='InitialHessian', comment='Options for initial model Hessian when optimizing systems with the Quasi-Newton method.') self.Quasi_Newton: AMS._GeometryOptimization._Quasi-Newton = self._Quasi_Newton(name='Quasi-Newton', comment='Configures details of the Quasi-Newton geometry optimizer.')
[docs] class _IEEEExceptions(FixedBlock): r""" Whether this works or not depends on the way the program is compiled (compiler and settings). Only useful for developers debugging some numerical issue. :ivar All: Activates all IEEEExceptions known to ams, see list below. The corresponding environment variable is SCM_IEEEException_All. :vartype All: BoolType | BoolKey :ivar DivideByZero: Stop program when a divide by zero exception occurs. The corresponding environment variable is SCM_IEEEException_DivideByZero. :vartype DivideByZero: BoolType | BoolKey :ivar Invalid: Stop program when an invalid exception occurs. This may be about sqrt(-1)., or 0/0, and generally leads to a NaN. The corresponding environment variable is SCM_IEEEException_Invalid. :vartype Invalid: BoolType | BoolKey :ivar Overflow: Stop program when an overflow exception occurs. The corresponding environment variable is SCM_IEEEException_Overflow :vartype Overflow: BoolType | BoolKey :ivar Print: Print feedback on activated IEEEExceptions in the logfile. The corresponding environment variable is SCM_IEEEException_Print. :vartype Print: BoolType | BoolKey """ def __post_init__(self): self.All: BoolType | BoolKey = BoolKey(name='All', comment='Activates all IEEEExceptions known to ams, see list below. The corresponding environment variable is SCM_IEEEException_All.', hidden=True, default=False) self.DivideByZero: BoolType | BoolKey = BoolKey(name='DivideByZero', comment='Stop program when a divide by zero exception occurs. The corresponding environment variable is SCM_IEEEException_DivideByZero.', hidden=True, default=False) self.Invalid: BoolType | BoolKey = BoolKey(name='Invalid', comment='Stop program when an invalid exception occurs. This may be about sqrt(-1)., or 0/0, and generally leads to a NaN. The corresponding environment variable is SCM_IEEEException_Invalid.', hidden=True, default=False) self.Overflow: BoolType | BoolKey = BoolKey(name='Overflow', comment='Stop program when an overflow exception occurs. The corresponding environment variable is SCM_IEEEException_Overflow', hidden=True, default=False) self.Print: BoolType | BoolKey = BoolKey(name='Print', comment='Print feedback on activated IEEEExceptions in the logfile. The corresponding environment variable is SCM_IEEEException_Print.', hidden=True, default=False)
[docs] class _IRC(FixedBlock): r""" Configures details of the Intrinsic Reaction Coordinate optimization. :ivar CoordinateType: Select the type of coordinates in which to perform the optimization. Note that the Delocalized option should be considered experimental. :vartype CoordinateType: Literal["Cartesian", "Delocalized"] :ivar Direction: Select direction of the IRC path. The difference between the Forward and the Backward directions is determined by the sign of the largest component of the vibrational normal mode corresponding to the reaction coordinate at the transition state geometry. The Forward path correspond to the positive sign of the component. If Both is selected then first the Forward path is computed followed by the Backward one. :vartype Direction: Literal["Both", "Forward", "Backward"] :ivar KeepConvergedResults: Keep the binary RKF result file for every converged IRC point. These files may contain more information than the main ams.rkf result file. :vartype KeepConvergedResults: BoolType | BoolKey :ivar MaxIRCSteps: Soft limit on the number of IRC points to compute in each direction. After the specified number of IRC steps the program will switch to energy minimization and complete the path. This option should be used when you are interested only in the reaction path area near the transition state. Note that even if the soft limit has been hit and the calculation has completed, the IRC can still be restarted with a 'RedoBackward' or 'RedoForward' option. :vartype MaxIRCSteps: int | IntKey :ivar MaxIterations: The maximum number of geometry iterations allowed to converge the inner IRC loop. If optimization does not converge within the specified number of steps, the calculation is aborted. :vartype MaxIterations: int | IntKey :ivar MaxPoints: Hard limit on the number of IRC points to compute in each direction. After the specified number of IRC steps the program will stop with the current direction and switch to the next one. If both 'MaxPoints' and 'MaxIRCSteps' are set to the same value then 'MaxPoints' takes precedence, therefore this option should be used to set a limit on the number of IRC steps if you intend to use the results later for a restart. :vartype MaxPoints: int | IntKey :ivar MinEnergyProfile: Calculate minimum energy profile (i.e. no mass-weighting) instead of the IRC. :vartype MinEnergyProfile: BoolType | BoolKey :ivar MinPathLength: Minimum length of the path required before switching to energy minimization. Use this to overcome a small kink or a shoulder on the path. :vartype MinPathLength: float | FloatKey :ivar Step: IRC step size in mass-weighted coordinates, sqrt(amu)*bohr. One may have to increase this value when heavy atoms are involved in the reaction, or decrease it if the reactant or products are very close to the transition state. :vartype Step: float | FloatKey :ivar Convergence: Convergence at each given point is monitored for two items: the Cartesian gradient and the calculated step size. Convergence criteria can be specified separately for each of these items. The same criteria are used both in the inner IRC loop and when performing energy minimization at the path ends. :vartype Convergence: AMS._IRC._Convergence :ivar InitialHessian: Options for initial Hessian at the transition state. The first eigenvalue of the initial Hessian defines direction of the first forward or backward step. This block is ignored when restarting from a previous IRC calculation because the initial Hessian found in the restart file is used. :vartype InitialHessian: AMS._IRC._InitialHessian :ivar Restart: Restart options. Upon restart, the information about the IRC input parameters and the initial system (atomic coordinates, lattice, charge, etc.) is read from the restart file. The IRC input parameters can be modified from input. Except for 'MaxPoints' and 'Direction' all parameters not specified in the input will use their values from the restart file. The 'MaxPoints' and 'Direction' will be reset to their respective default values if not specified in the input. By default, the IRC calculation will continue from the point where it left off. However, the 'RedoForward' and/or 'RedoBackward' option can be used to enforce recalculation of a part of the reaction path, for example, using a different 'Step' value. :vartype Restart: AMS._IRC._Restart """
[docs] class _Convergence(FixedBlock): r""" Convergence at each given point is monitored for two items: the Cartesian gradient and the calculated step size. Convergence criteria can be specified separately for each of these items. The same criteria are used both in the inner IRC loop and when performing energy minimization at the path ends. :ivar Gradients: Convergence criterion for the max component of the residual energy gradient. :vartype Gradients: float | FloatKey :ivar Step: Convergence criterion for the max component of the step in the optimization coordinates. :vartype Step: float | FloatKey """ def __post_init__(self): self.Gradients: float | FloatKey = FloatKey(name='Gradients', comment='Convergence criterion for the max component of the residual energy gradient.', gui_name='Gradient convergence:', default=0.001, unit='Hartree/Angstrom') self.Step: float | FloatKey = FloatKey(name='Step', comment='Convergence criterion for the max component of the step in the optimization coordinates.', gui_name='Step convergence:', default=0.001, unit='Angstrom')
[docs] class _InitialHessian(FixedBlock): r""" Options for initial Hessian at the transition state. The first eigenvalue of the initial Hessian defines direction of the first forward or backward step. This block is ignored when restarting from a previous IRC calculation because the initial Hessian found in the restart file is used. :ivar File: If 'Type' is set to 'FromFile' then in this key you should specify the RKF file containing the initial Hessian (or the ams results dir. containing it). This can be used to load a Hessian calculated previously with the 'Properties%Hessian' keyword. If you want to also use this file for the initial geometry then also specify it in a 'LoadSystem' block. :vartype File: str | Path | StringKey :ivar Type: Calculate the exact Hessian for the input geometry or load it from the results of a previous calculation. :vartype Type: Literal["Calculate", "FromFile"] """ def __post_init__(self): self.File: str | Path | StringKey = PathStringKey(name='File', comment="If 'Type' is set to 'FromFile' then in this key you should specify the RKF file containing the initial Hessian (or the ams results dir. containing it). This can be used to load a Hessian calculated previously with the 'Properties%Hessian' keyword. If you want to also use this file for the initial geometry then also specify it in a 'LoadSystem' block.", gui_name='File:', ispath=True, gui_type='.rkf {{{AMS result file} .rkf}}') self.Type: Literal["Calculate", "FromFile"] = MultipleChoiceKey(name='Type', comment='Calculate the exact Hessian for the input geometry or load it from the results of a previous calculation.', gui_name='Initial Hessian:', default='Calculate', choices=['Calculate', 'FromFile'])
[docs] class _Restart(FixedBlock): r""" Restart options. Upon restart, the information about the IRC input parameters and the initial system (atomic coordinates, lattice, charge, etc.) is read from the restart file. The IRC input parameters can be modified from input. Except for 'MaxPoints' and 'Direction' all parameters not specified in the input will use their values from the restart file. The 'MaxPoints' and 'Direction' will be reset to their respective default values if not specified in the input. By default, the IRC calculation will continue from the point where it left off. However, the 'RedoForward' and/or 'RedoBackward' option can be used to enforce recalculation of a part of the reaction path, for example, using a different 'Step' value. :ivar File: Name of an RKF restart file generated by a previous IRC calculation. Do not use this key to provide an RKF file generated by a TransitionStateSearch or a SinglePoint calculation, use the 'LoadSystem' block instead. :vartype File: str | Path | StringKey :ivar RedoBackward: IRC step number to start recalculating the backward path from. By default, if the backward path has not been completed then start after the last completed step. If the backward path has been completed and the 'RedoBackward' is omitted then no point on the backward path will be recomputed. :vartype RedoBackward: int | IntKey :ivar RedoForward: IRC step number to start recalculating the forward path from. By default, if the forward path has not been completed then start after the last completed step. If the forward path has been completed and the 'RedoForward' is omitted then no point on the forward path will be recomputed. :vartype RedoForward: int | IntKey """ def __post_init__(self): self.File: str | Path | StringKey = PathStringKey(name='File', comment="Name of an RKF restart file generated by a previous IRC calculation. Do not use this key to provide an RKF file generated by a TransitionStateSearch or a SinglePoint calculation, use the 'LoadSystem' block instead.", gui_name='Restart:', ispath=True, gui_type='.rkf {{{AMS result file} .rkf}}') self.RedoBackward: int | IntKey = IntKey(name='RedoBackward', comment="IRC step number to start recalculating the backward path from. By default, if the backward path has not been completed then start after the last completed step. If the backward path has been completed and the 'RedoBackward' is omitted then no point on the backward path will be recomputed.", default=0) self.RedoForward: int | IntKey = IntKey(name='RedoForward', comment="IRC step number to start recalculating the forward path from. By default, if the forward path has not been completed then start after the last completed step. If the forward path has been completed and the 'RedoForward' is omitted then no point on the forward path will be recomputed.", default=0)
def __post_init__(self): self.CoordinateType: Literal["Cartesian", "Delocalized"] = MultipleChoiceKey(name='CoordinateType', comment='Select the type of coordinates in which to perform the optimization. Note that the Delocalized option should be considered experimental.', gui_name='Coordinates used for optimization:', default='Cartesian', choices=['Cartesian', 'Delocalized']) self.Direction: Literal["Both", "Forward", "Backward"] = MultipleChoiceKey(name='Direction', comment='Select direction of the IRC path. The difference between the Forward and the Backward directions is determined by the sign of the largest component of the vibrational normal mode corresponding to the reaction coordinate at the transition state geometry. The Forward path correspond to the positive sign of the component. If Both is selected then first the Forward path is computed followed by the Backward one.', default='Both', choices=['Both', 'Forward', 'Backward']) self.KeepConvergedResults: BoolType | BoolKey = BoolKey(name='KeepConvergedResults', comment='Keep the binary RKF result file for every converged IRC point. These files may contain more information than the main ams.rkf result file.', default=True) self.MaxIRCSteps: int | IntKey = IntKey(name='MaxIRCSteps', comment="Soft limit on the number of IRC points to compute in each direction. After the specified number of IRC steps the program will switch to energy minimization and complete the path. This option should be used when you are interested only in the reaction path area near the transition state. Note that even if the soft limit has been hit and the calculation has completed, the IRC can still be restarted with a 'RedoBackward' or 'RedoForward' option.", gui_name='Maximum IRC steps:') self.MaxIterations: int | IntKey = IntKey(name='MaxIterations', comment='The maximum number of geometry iterations allowed to converge the inner IRC loop. If optimization does not converge within the specified number of steps, the calculation is aborted.', gui_name='Maximum iterations:', default=300) self.MaxPoints: int | IntKey = IntKey(name='MaxPoints', comment="Hard limit on the number of IRC points to compute in each direction. After the specified number of IRC steps the program will stop with the current direction and switch to the next one. If both 'MaxPoints' and 'MaxIRCSteps' are set to the same value then 'MaxPoints' takes precedence, therefore this option should be used to set a limit on the number of IRC steps if you intend to use the results later for a restart. ", gui_name='Maximum points:', default=100) self.MinEnergyProfile: BoolType | BoolKey = BoolKey(name='MinEnergyProfile', comment='Calculate minimum energy profile (i.e. no mass-weighting) instead of the IRC.', gui_name='Minimum energy profile:', default=False) self.MinPathLength: float | FloatKey = FloatKey(name='MinPathLength', comment='Minimum length of the path required before switching to energy minimization. Use this to overcome a small kink or a shoulder on the path.', default=0.1, unit='Angstrom') self.Step: float | FloatKey = FloatKey(name='Step', comment='IRC step size in mass-weighted coordinates, sqrt(amu)*bohr. One may have to increase this value when heavy atoms are involved in the reaction, or decrease it if the reactant or products are very close to the transition state.', gui_name='Step size:', default=0.2) self.Convergence: AMS._IRC._Convergence = self._Convergence(name='Convergence', comment='Convergence at each given point is monitored for two items: the Cartesian gradient and the calculated step size. Convergence criteria can be specified separately for each of these items. The same criteria are used both in the inner IRC loop and when performing energy minimization at the path ends.') self.InitialHessian: AMS._IRC._InitialHessian = self._InitialHessian(name='InitialHessian', comment='Options for initial Hessian at the transition state. The first eigenvalue of the initial Hessian defines direction of the first forward or backward step. This block is ignored when restarting from a previous IRC calculation because the initial Hessian found in the restart file is used.') self.Restart: AMS._IRC._Restart = self._Restart(name='Restart', comment="Restart options. Upon restart, the information about the IRC input parameters and the initial system (atomic coordinates, lattice, charge, etc.) is read from the restart file. The IRC input parameters can be modified from input. Except for 'MaxPoints' and 'Direction' all parameters not specified in the input will use their values from the restart file. The 'MaxPoints' and 'Direction' will be reset to their respective default values if not specified in the input. By default, the IRC calculation will continue from the point where it left off. However, the 'RedoForward' and/or 'RedoBackward' option can be used to enforce recalculation of a part of the reaction path, for example, using a different 'Step' value.")
[docs] class _Idle(FixedBlock): r""" Configures details of the idle task, which does nothing for a specified amount of time. :ivar Time: Controls how long AMS will be idle before exiting. :vartype Time: int | IntKey """ def __post_init__(self): self.Time: int | IntKey = IntKey(name='Time', comment='Controls how long AMS will be idle before exiting.', default=3, unit='Seconds', range='value > 0')
[docs] class _LoadSystem(FixedBlock): r""" Block that controls reading the chemical system from a KF file instead of the [System] block. :ivar File: The path of the KF file from which to load the system. It may also be the results directory containing it. :vartype File: str | Path | StringKey :ivar Section: The section on the KF file from which to load the system. :vartype Section: str | StringKey """ def __post_init__(self): self.File: str | Path | StringKey = PathStringKey(name='File', comment='The path of the KF file from which to load the system. It may also be the results directory containing it.', ispath=True) self.Section: str | StringKey = StringKey(name='Section', comment='The section on the KF file from which to load the system.', default='Molecule')
[docs] class _Log(FreeBlock): r""" Configures the debugging loggers. Syntax: 'Level LoggerName'. Possible Levels: All, Debug, Info, Warning, Error, Fatal. """ def __post_init__(self): pass
[docs] class _MolecularDynamics(FixedBlock): r""" Configures molecular dynamics (with the velocity-Verlet algorithm) with and without thermostats. This block allows to specify the details of the molecular dynamics calculation. :ivar CalcPressure: Calculate the pressure in periodic systems. This may be computationally expensive for some engines that require numerical differentiation. Some other engines can calculate the pressure for negligible additional cost and will always do so, even if this option is disabled. :vartype CalcPressure: BoolType | BoolKey :ivar CopyRestartTrajectory: If the keyword Restart is present, the content of the restartfile is copied to the ams.rkf file. :vartype CopyRestartTrajectory: BoolType | BoolKey :ivar NSteps: The number of steps to be taken in the MD simulation. :vartype NSteps: int | IntKey :ivar Restart: The path to the ams.rkf file from which to restart the simulation. :vartype Restart: str | Path | StringKey :ivar TimeStep: The time difference per step. :vartype TimeStep: float | FloatKey :ivar AddMolecules: This block controls adding molecules to the system (a.k.a. the Molecule Gun). Multiple occurrences of this block are possible. By default, molecules are added at random positions in the simulation box with velocity matching the current system temperature. The initial position can be modified using one of the following keywords: Coords, CoordsBox, FractionalCoords, FractionalCoordsBox. The Coords and FractionalCoords keys can optionally be accompanied by CoordsSigma or FractionalCoordsSigma, respectively. :vartype AddMolecules: AMS._MolecularDynamics._AddMolecules :ivar ApplyForce: The ApplyForce keyword can be used to apply an arbitrary constant force to a certain (subgroups of) atoms in the system :vartype ApplyForce: AMS._MolecularDynamics._ApplyForce :ivar ApplyVelocity: The ApplyVelocity keyword can be used to move an arbitrary group of atoms in the system with a constant net velocity :vartype ApplyVelocity: AMS._MolecularDynamics._ApplyVelocity :ivar Barostat: This block allows to specify the use of a barostat during the simulation. :vartype Barostat: AMS._MolecularDynamics._Barostat :ivar BinLog: This block controls writing the BinLog section in ams.rkf, which contains the selected MD state scalars and tensors from every MD step. No per-atom data is written. If you need the per-atom data then you can set the sampling frequency to 1 and get the required data from the MDHistory section. The tensors are written per component, that is, the pressure tensor is written as six variables: PressureTensor_xx, PressureTensor_yy, etc.. To reduce the file size, all data is written in blocks. :vartype BinLog: AMS._MolecularDynamics._BinLog :ivar BondBoost: Forced reaction (bond boost) definitions. Multiple BondBoost blocks may be specified, which will be treated independently. :vartype BondBoost: AMS._MolecularDynamics._BondBoost :ivar CRESTMTD: Input for CREST metadynamics simulation. :vartype CRESTMTD: AMS._MolecularDynamics._CRESTMTD :ivar CVHD: Input for the Collective Variable-driven HyperDynamics (CVHD). :vartype CVHD: AMS._MolecularDynamics._CVHD :ivar CheckTemperature: Check at every time step if the temperature has exceeded a threshold. If it has, it is assumed the system exploded, and the simulation will stop. :vartype CheckTemperature: AMS._MolecularDynamics._CheckTemperature :ivar Checkpoint: Sets the frequency for storing the entire MD state necessary for restarting the calculation. :vartype Checkpoint: AMS._MolecularDynamics._Checkpoint :ivar CosineShear: Apply an external acceleration to all atoms of a fluid using a periodic (cosine) function along a selected coordinate axis. This induces a periodic shear flow profile which can be used to determine the viscosity. :vartype CosineShear: AMS._MolecularDynamics._CosineShear :ivar Deformation: Deform the periodic lattice of the system during the simulation. :vartype Deformation: AMS._MolecularDynamics._Deformation :ivar Gravity: Apply a constant acceleration in -z. :vartype Gravity: AMS._MolecularDynamics._Gravity :ivar HeatExchange: Input for the heat-exchange non-equilibrium MD (T-NEMD). :vartype HeatExchange: AMS._MolecularDynamics._HeatExchange :ivar InitialVelocities: Sets the frequency for printing to stdout and storing the molecular configuration on the .rkf file. :vartype InitialVelocities: AMS._MolecularDynamics._InitialVelocities :ivar MovingRestraints: Define a set of moving restraints. :vartype MovingRestraints: AMS._MolecularDynamics._MovingRestraints :ivar PRD: This block is used for Parallel Replica Dynamics simulations. :vartype PRD: AMS._MolecularDynamics._PRD :ivar Plumed: Input for PLUMED (version 2.5.0). The parallel option is still experimental. :vartype Plumed: AMS._MolecularDynamics._Plumed :ivar Preserve: Periodically remove numerical drift accumulated during the simulation to preserve different whole-system parameters. :vartype Preserve: AMS._MolecularDynamics._Preserve :ivar Print: This block controls the printing of additional information to stdout. :vartype Print: AMS._MolecularDynamics._Print :ivar ReactionBoost: Define a series of transitions between different states of the system. Each transition is defined by a TargetSystem and by a set of restraints that force the transition. :vartype ReactionBoost: AMS._MolecularDynamics._ReactionBoost :ivar Reactor: Define one phase of the nanoreactor. A reactor is a region of space surrounded by an elastic wall. Atoms inside the region are not affected. Atoms outside it will be pushed back with force depending on the [ForceConstant] and the [MassScaled] flag. :vartype Reactor: AMS._MolecularDynamics._Reactor :ivar ReflectiveWall: Apply a reflective wall in space :vartype ReflectiveWall: AMS._MolecularDynamics._ReflectiveWall :ivar Remap: Control periodic remapping (backtranslation) of atoms into the PBC box. :vartype Remap: AMS._MolecularDynamics._Remap :ivar RemoveMolecules: This block controls removal of molecules from the system. Multiple occurrences of this block are possible. :vartype RemoveMolecules: AMS._MolecularDynamics._RemoveMolecules :ivar ReplicaExchange: This block is used for (temperature) Replica Exchange MD (Parallel Tempering) simulations. :vartype ReplicaExchange: AMS._MolecularDynamics._ReplicaExchange :ivar Shake: Parameters of the Shake/Rattle algorithm. :vartype Shake: AMS._MolecularDynamics._Shake :ivar Thermostat: This block allows to specify the use of a thermostat during the simulation. Depending on the selected thermostat type, different additional options may be needed to characterize the specific thermostat's behavior. :vartype Thermostat: AMS._MolecularDynamics._Thermostat :ivar Trajectory: Sets the frequency for printing to stdout and storing the molecular configuration on the .rkf file. :vartype Trajectory: AMS._MolecularDynamics._Trajectory :ivar fbMC: This block sets up force bias Monte Carlo interleaved with the molecular dynamics simulation. :vartype fbMC: AMS._MolecularDynamics._fbMC """
[docs] class _AddMolecules(FixedBlock): r""" This block controls adding molecules to the system (a.k.a. the Molecule Gun). Multiple occurrences of this block are possible. By default, molecules are added at random positions in the simulation box with velocity matching the current system temperature. The initial position can be modified using one of the following keywords: Coords, CoordsBox, FractionalCoords, FractionalCoordsBox. The Coords and FractionalCoords keys can optionally be accompanied by CoordsSigma or FractionalCoordsSigma, respectively. :ivar AtomTemperature: Add random velocity corresponding to the specified temperature to individual atoms of the molecule. This only affects rotational and internal degrees of freedom, not the net translational velocity of the inserted molecule as set by the other options. :vartype AtomTemperature: float | FloatKey :ivar ContactDistance: Translate the bullet along the velocity vector until it comes within ContactDistance of any other atom. :vartype ContactDistance: float | FloatKey :ivar Coords: Place molecules at or around the specified Cartesian coordinates. This setting takes precedence over other ways to specify initial coordinates of the molecule: [CoordsBox], [FractionalCoords], and [FractionalCoordsBox]. :vartype Coords: Iterable[float] | FloatListKey :ivar CoordsBox: Place molecules at random locations inside the specified box in Cartesian coordinates. Coordinates of the box corners are specified as: Xmin, Xmax, Ymin, Ymax, Zmin, Zmax. This setting is ignored if Coords is used. In AMSinput, if this field is not empty it will be used instead of the default Coords. :vartype CoordsBox: Iterable[float] | FloatListKey :ivar CoordsSigma: Sigma values (one per Cartesian axis) for a Gauss distribution of the initial coordinates. Can only be used together with Coords. :vartype CoordsSigma: Iterable[float] | FloatListKey :ivar DeviationAngle: Randomly tilt the shooting direction up to this angle away from the VelocityDirection vector. :vartype DeviationAngle: float | FloatKey :ivar Energy: Initial kinetic energy of the molecule in the shooting direction. :vartype Energy: float | FloatKey :ivar EnergySigma: Sigma value for the Gauss distribution of the initial kinetic energy around the specified value. Should only be used together with Energy. :vartype EnergySigma: float | FloatKey :ivar FractionalCoords: Place molecules at or around the specified fractional coordinates in the main system's lattice. For non-periodic dimensions a Cartesian value in Angstrom is expected. This setting is ignored if [Coords] or [CoordsBox] is used. :vartype FractionalCoords: Iterable[float] | FloatListKey :ivar FractionalCoordsBox: Place molecules at random locations inside the box specified as fractional coordinates in the main system's lattice. Coordinates of the box corners are specified as: Xmin, Xmax, Ymin, Ymax, Zmin, Zmax. For non-periodic dimensions the Cartesian value in Angstrom is expected. This setting is ignored if [Coords], [CoordsBox], or [FractionalCoords] is used. :vartype FractionalCoordsBox: Iterable[float] | FloatListKey :ivar FractionalCoordsSigma: Sigma values (one per axis) for a Gauss distribution of the initial coordinates. For non-periodic dimensions the Cartesian value in Angstrom is expected. Can only be used together with FractionalCoords. :vartype FractionalCoordsSigma: Iterable[float] | FloatListKey :ivar Frequency: A molecule is added every [Frequency] steps after the StartStep. There is never a molecule added at step 0. :vartype Frequency: int | IntKey :ivar MinDistance: Keep the minimal distance to other atoms of the system when adding the molecule. :vartype MinDistance: float | FloatKey :ivar MoleFraction: Defines a mixture to be deposited using one AddMolecules block per component. AMS will randomly alternate between any guns that have MoleFraction set. These need to all have the same settings for StartStep, StopStep and Frequency. Any additional AddMolecules blocks without MoleFraction will remain completely independent. :vartype MoleFraction: float | FloatKey :ivar NumAttempts: Try adding the molecule up to the specified number of times or until the MinDistance constraint is satisfied. If all attempts fail a message will be printed and the simulation will continue normally. :vartype NumAttempts: int | IntKey :ivar Rotate: Rotate the molecule randomly before adding it to the system. :vartype Rotate: BoolType | BoolKey :ivar StartStep: Step number when the first molecule should be added. After that, molecules are added every Frequency steps. For example, ff StartStep=99 and Frequency=100 then a molecule will be added at steps 99, 199, 299, etc... No molecule will be added at step 0, so if StartStep=0 the first molecule is added at the step number equal to [Frequency]. :vartype StartStep: int | IntKey :ivar StopStep: Do not add this molecule after the specified step. :vartype StopStep: int | IntKey :ivar System: String ID of the [System] that will be added with this 'gun'. The lattice specified with this System is ignored and the main system's lattice is used instead. AMSinput adds the system at the coordinates of the System (thus setting Coords to the center of the System). :vartype System: str | StringKey :ivar Temperature: Initial energy of the molecule in the shooting direction will correspond to the given temperature. :vartype Temperature: float | FloatKey :ivar TemperatureSigma: Sigma value for the Gauss distribution of the initial temperature the specified value. Should only be used together with Temperature. :vartype TemperatureSigma: float | FloatKey :ivar Velocity: Initial velocity of the molecule in the shooting direction. :vartype Velocity: float | FloatKey :ivar VelocityDirection: Velocity direction vector for aimed shooting. It will be random if not specified. In AMSinput add one or two atoms (which may be dummies). One atom: use vector from center of the system to add to that atom. Two atoms: use vector from the first to the second atom. :vartype VelocityDirection: Iterable[float] | FloatListKey :ivar VelocitySigma: Sigma value for the Gauss distribution of the initial velocity around the specified value. Should only be used together with Velocity. :vartype VelocitySigma: float | FloatKey """ def __post_init__(self): self.AtomTemperature: float | FloatKey = FloatKey(name='AtomTemperature', comment='Add random velocity corresponding to the specified temperature to individual atoms of the molecule. This only affects rotational and internal degrees of freedom, not the net translational velocity of the inserted molecule as set by the other options.', default=0.0, unit='Kelvin') self.ContactDistance: float | FloatKey = FloatKey(name='ContactDistance', comment='Translate the bullet along the velocity vector until it comes within ContactDistance of any other atom.', default=0.0, unit='Angstrom') self.Coords: Iterable[float] | FloatListKey = FloatListKey(name='Coords', comment='Place molecules at or around the specified Cartesian coordinates.\n\nThis setting takes precedence over other ways to specify initial coordinates of the molecule: [CoordsBox], [FractionalCoords], and [FractionalCoordsBox].', unit='Angstrom') self.CoordsBox: Iterable[float] | FloatListKey = FloatListKey(name='CoordsBox', comment='Place molecules at random locations inside the specified box in Cartesian coordinates.\n\nCoordinates of the box corners are specified as: Xmin, Xmax, Ymin, Ymax, Zmin, Zmax.\nThis setting is ignored if Coords is used.\n\nIn AMSinput, if this field is not empty it will be used instead of the default Coords.', unit='Angstrom', gui_type='nfloat 6') self.CoordsSigma: Iterable[float] | FloatListKey = FloatListKey(name='CoordsSigma', comment='Sigma values (one per Cartesian axis) for a Gauss distribution of the initial coordinates. Can only be used together with Coords.', unit='Angstrom', gui_type='nfloat 3') self.DeviationAngle: float | FloatKey = FloatKey(name='DeviationAngle', comment='Randomly tilt the shooting direction up to this angle away from the VelocityDirection vector.', default=0.0, unit='Degree') self.Energy: float | FloatKey = FloatKey(name='Energy', comment='Initial kinetic energy of the molecule in the shooting direction.', unit='Hartree') self.EnergySigma: float | FloatKey = FloatKey(name='EnergySigma', comment='Sigma value for the Gauss distribution of the initial kinetic energy around the specified value. Should only be used together with Energy.', default=0.0, unit='Hartree') self.FractionalCoords: Iterable[float] | FloatListKey = FloatListKey(name='FractionalCoords', comment="Place molecules at or around the specified fractional coordinates in the main system's lattice. For non-periodic dimensions a Cartesian value in Angstrom is expected. This setting is ignored if [Coords] or [CoordsBox] is used.") self.FractionalCoordsBox: Iterable[float] | FloatListKey = FloatListKey(name='FractionalCoordsBox', comment="Place molecules at random locations inside the box specified as fractional coordinates in the main system's lattice.\n\nCoordinates of the box corners are specified as: Xmin, Xmax, Ymin, Ymax, Zmin, Zmax.\n\nFor non-periodic dimensions the Cartesian value in Angstrom is expected.\n\nThis setting is ignored if [Coords], [CoordsBox], or [FractionalCoords] is used.", gui_type='nfloat 6') self.FractionalCoordsSigma: Iterable[float] | FloatListKey = FloatListKey(name='FractionalCoordsSigma', comment='Sigma values (one per axis) for a Gauss distribution of the initial coordinates. For non-periodic dimensions the Cartesian value in Angstrom is expected. Can only be used together with FractionalCoords.') self.Frequency: int | IntKey = IntKey(name='Frequency', comment='A molecule is added every [Frequency] steps after the StartStep.\n\nThere is never a molecule added at step 0.', default=0) self.MinDistance: float | FloatKey = FloatKey(name='MinDistance', comment='Keep the minimal distance to other atoms of the system when adding the molecule.', default=0.0, unit='Angstrom') self.MoleFraction: float | FloatKey = FloatKey(name='MoleFraction', comment='Defines a mixture to be deposited using one AddMolecules block per component.\n\nAMS will randomly alternate between any guns that have MoleFraction set. These need to all have the same settings for StartStep, StopStep and Frequency. Any additional AddMolecules blocks without MoleFraction will remain completely independent.') self.NumAttempts: int | IntKey = IntKey(name='NumAttempts', comment='Try adding the molecule up to the specified number of times or until the MinDistance constraint is satisfied. If all attempts fail a message will be printed and the simulation will continue normally.', default=10) self.Rotate: BoolType | BoolKey = BoolKey(name='Rotate', comment='Rotate the molecule randomly before adding it to the system.', default=False) self.StartStep: int | IntKey = IntKey(name='StartStep', comment='Step number when the first molecule should be added. After that, molecules are added every Frequency steps.\n\nFor example, ff StartStep=99 and Frequency=100 then a molecule will be added at steps 99, 199, 299, etc...\n\nNo molecule will be added at step 0, so if StartStep=0 the first molecule is added at the step number equal to [Frequency].', default=0) self.StopStep: int | IntKey = IntKey(name='StopStep', comment='Do not add this molecule after the specified step.') self.System: str | StringKey = StringKey(name='System', comment="String ID of the [System] that will be added with this 'gun'.\n\nThe lattice specified with this System is ignored and the main system's lattice is used instead.\n\nAMSinput adds the system at the coordinates of the System (thus setting Coords to the center of the System).", gui_type='region') self.Temperature: float | FloatKey = FloatKey(name='Temperature', comment='Initial energy of the molecule in the shooting direction will correspond to the given temperature.', unit='Kelvin') self.TemperatureSigma: float | FloatKey = FloatKey(name='TemperatureSigma', comment='Sigma value for the Gauss distribution of the initial temperature the specified value. Should only be used together with Temperature.', default=0.0, unit='Kelvin') self.Velocity: float | FloatKey = FloatKey(name='Velocity', comment='Initial velocity of the molecule in the shooting direction.', unit='Angstrom/fs') self.VelocityDirection: Iterable[float] | FloatListKey = FloatListKey(name='VelocityDirection', comment='Velocity direction vector for aimed shooting. It will be random if not specified.\n\nIn AMSinput add one or two atoms (which may be dummies).\n\nOne atom: use vector from center of the system to add to that atom.\n\nTwo atoms: use vector from the first to the second atom.') self.VelocitySigma: float | FloatKey = FloatKey(name='VelocitySigma', comment='Sigma value for the Gauss distribution of the initial velocity around the specified value. Should only be used together with Velocity.', default=0.0, unit='Angstrom/fs')
[docs] class _ApplyForce(FixedBlock): r""" The ApplyForce keyword can be used to apply an arbitrary constant force to a certain (subgroups of) atoms in the system :ivar CalculateViscosity: Calculates Viscosity property yes/no. If yes is chosen, the global viscosity of the system is calculated and written into the RKF-file. The formula used for the viscosity calculation is eta = - Pxz / (dVx/dz) :vartype CalculateViscosity: BoolType | BoolKey :ivar CalculateViscosityBins: Amount of bins used to determine (dVx/dz) :vartype CalculateViscosityBins: int | IntKey :ivar CalculateViscosityEnd: end index to select region in space to calculate (dVx/dz) :vartype CalculateViscosityEnd: int | IntKey :ivar CalculateViscosityStart: Start index to select region in space to calculate (dVx/dz) :vartype CalculateViscosityStart: int | IntKey :ivar Force: Defines the constant force vector :vartype Force: Iterable[float] | FloatListKey :ivar PerAtom: If enabled, the Force vector is applied separately to every atom in the selected Region, so that the total net force on the Region equals the value of Force times the number of atoms in Region. This was the behavior of ApplyForce in AMS2022. By default, with PerAtom disabled, the Force vector defines the total net force on the Region, so the force applied to each atom equals the value of Force divided by the number of atoms in Region. :vartype PerAtom: BoolType | BoolKey :ivar Region: Apply the constant force to all atoms in this region. :vartype Region: str | StringKey """ def __post_init__(self): self.CalculateViscosity: BoolType | BoolKey = BoolKey(name='CalculateViscosity', comment='Calculates Viscosity property yes/no. If yes is chosen, the global viscosity of the system is calculated and written into the RKF-file. The formula used for the viscosity calculation is eta = - Pxz / (dVx/dz)', hidden=True) self.CalculateViscosityBins: int | IntKey = IntKey(name='CalculateViscosityBins', comment='Amount of bins used to determine (dVx/dz)', hidden=True, default=20) self.CalculateViscosityEnd: int | IntKey = IntKey(name='CalculateViscosityEnd', comment='end index to select region in space to calculate (dVx/dz)', hidden=True, default=3) self.CalculateViscosityStart: int | IntKey = IntKey(name='CalculateViscosityStart', comment='Start index to select region in space to calculate (dVx/dz)', hidden=True, default=1) self.Force: Iterable[float] | FloatListKey = FloatListKey(name='Force', comment='Defines the constant force vector', default=[0.0, 0.0, 0.0], unit='Hartree/Bohr', gui_type='nfloat 3') self.PerAtom: BoolType | BoolKey = BoolKey(name='PerAtom', comment='If enabled, the Force vector is applied separately to every atom in the selected Region, so that the total net force on the Region equals the value of Force times the number of atoms in Region. This was the behavior of ApplyForce in AMS2022. By default, with PerAtom disabled, the Force vector defines the total net force on the Region, so the force applied to each atom equals the value of Force divided by the number of atoms in Region.', default=False) self.Region: str | StringKey = StringKey(name='Region', comment='Apply the constant force to all atoms in this region.', unique=False, gui_type='region')
[docs] class _ApplyVelocity(FixedBlock): r""" The ApplyVelocity keyword can be used to move an arbitrary group of atoms in the system with a constant net velocity :ivar CalculateViscosity: Calculates Viscosity property yes/no. If yes is chosen, the global viscosity of the system is calculated and written into the RKF-file. The formula used for the viscosity calculation is eta = - Pxz / (dVx/dz) :vartype CalculateViscosity: BoolType | BoolKey :ivar CalculateViscosityBins: Amount of bins used to determine (dVx/dz) :vartype CalculateViscosityBins: int | IntKey :ivar CalculateViscosityEnd: end index to select region in space to calculate (dVx/dz) :vartype CalculateViscosityEnd: int | IntKey :ivar CalculateViscosityStart: Start index to select region in space to calculate (dVx/dz) :vartype CalculateViscosityStart: int | IntKey :ivar Components: Select which components of the Velocity vector are used to set the corresponding components of the net velocity of the specified set of atoms. Any other components of Velocity are ignored and the motion of the selected atoms in those directions is unaffected by ApplyVelocity. :vartype Components: Literal["X", "Y", "Z", "XY", "YZ", "XZ", "XYZ"] :ivar Region: Applies the defined velocity to all atoms in this region. :vartype Region: str | StringKey :ivar Velocity: The constant velocity that will be applied to the specified atoms. :vartype Velocity: Iterable[float] | FloatListKey """ def __post_init__(self): self.CalculateViscosity: BoolType | BoolKey = BoolKey(name='CalculateViscosity', comment='Calculates Viscosity property yes/no. If yes is chosen, the global viscosity of the system is calculated and written into the RKF-file. The formula used for the viscosity calculation is eta = - Pxz / (dVx/dz)', hidden=True) self.CalculateViscosityBins: int | IntKey = IntKey(name='CalculateViscosityBins', comment='Amount of bins used to determine (dVx/dz)', hidden=True, default=20) self.CalculateViscosityEnd: int | IntKey = IntKey(name='CalculateViscosityEnd', comment='end index to select region in space to calculate (dVx/dz)', hidden=True, default=3) self.CalculateViscosityStart: int | IntKey = IntKey(name='CalculateViscosityStart', comment='Start index to select region in space to calculate (dVx/dz)', hidden=True, default=1) self.Components: Literal["X", "Y", "Z", "XY", "YZ", "XZ", "XYZ"] = MultipleChoiceKey(name='Components', comment='Select which components of the Velocity vector are used to set the corresponding components of the net velocity of the specified set of atoms. Any other components of Velocity are ignored and the motion of the selected atoms in those directions is unaffected by ApplyVelocity.', default='XY', choices=['X', 'Y', 'Z', 'XY', 'YZ', 'XZ', 'XYZ']) self.Region: str | StringKey = StringKey(name='Region', comment='Applies the defined velocity to all atoms in this region.', unique=False, gui_type='region') self.Velocity: Iterable[float] | FloatListKey = FloatListKey(name='Velocity', comment='The constant velocity that will be applied to the specified atoms.', default=[0.0, 0.0, 0.0], unit='Angstrom/fs', gui_type='nfloat 3')
[docs] class _Barostat(FixedBlock): r""" This block allows to specify the use of a barostat during the simulation. :ivar BulkModulus: An estimate of the bulk modulus (inverse compressibility) of the system for the Berendsen barostat. This is only used to make Tau correspond to the true observed relaxation time constant. Values are commonly on the order of 10-100 GPa (1e10 to 1e11) for solids and 1 GPa (1e9) for liquids (2.2e9 for water). Use 1e9 to match the behavior of standalone ReaxFF. :vartype BulkModulus: float | FloatKey :ivar ConstantVolume: Keep the volume constant while allowing the box shape to change. This is currently supported only by the MTK barostat. :vartype ConstantVolume: BoolType | BoolKey :ivar Duration: Specifies how many steps should a transition from a particular pressure to the next one in sequence take. :vartype Duration: Iterable[int] | IntListKey :ivar Equal: Enforce equal scaling of the selected set of dimensions. They will be barostatted as one dimension according to the average pressure over the components. :vartype Equal: Literal["None", "XYZ", "XY", "YZ", "XZ"] :ivar Pressure: Specifies the target pressure. You can specify multiple pressures (separated by spaces). In that case the Duration field specifies how many steps to use for the transition from one p to the next p (using a linear ramp). :vartype Pressure: Iterable[float] | FloatListKey :ivar Scale: Dimensions that should be scaled by the barostat to maintain pressure. Selecting Shape means that all three dimensions and also all the cell angles are allowed to change. :vartype Scale: Literal["XYZ", "Shape", "X", "Y", "Z", "XY", "YZ", "XZ"] :ivar Tau: Specifies the time constant of the barostat. :vartype Tau: float | FloatKey :ivar Type: Selects the type of the barostat. :vartype Type: Literal["None", "Berendsen", "MTK"] """ def __post_init__(self): self.BulkModulus: float | FloatKey = FloatKey(name='BulkModulus', comment='An estimate of the bulk modulus (inverse compressibility) of the system for the Berendsen barostat.\n\nThis is only used to make Tau correspond to the true observed relaxation time constant. Values are commonly on the order of 10-100 GPa (1e10 to 1e11) for solids and 1 GPa (1e9) for liquids (2.2e9 for water). Use 1e9 to match the behavior of standalone ReaxFF.', default=2200000000.0, unit='Pascal') self.ConstantVolume: BoolType | BoolKey = BoolKey(name='ConstantVolume', comment='Keep the volume constant while allowing the box shape to change.\n\nThis is currently supported only by the MTK barostat.', default=False) self.Duration: Iterable[int] | IntListKey = IntListKey(name='Duration', comment='Specifies how many steps should a transition from a particular pressure to the next one in sequence take.') self.Equal: Literal["None", "XYZ", "XY", "YZ", "XZ"] = MultipleChoiceKey(name='Equal', comment='Enforce equal scaling of the selected set of dimensions. They will be barostatted as one dimension according to the average pressure over the components.', default='None', choices=['None', 'XYZ', 'XY', 'YZ', 'XZ']) self.Pressure: Iterable[float] | FloatListKey = FloatListKey(name='Pressure', comment='Specifies the target pressure. \n\nYou can specify multiple pressures (separated by spaces). In that case the Duration field specifies how many steps to use for the transition from one p to the next p (using a linear ramp).', unit='Pascal') self.Scale: Literal["XYZ", "Shape", "X", "Y", "Z", "XY", "YZ", "XZ"] = MultipleChoiceKey(name='Scale', comment='Dimensions that should be scaled by the barostat to maintain pressure. Selecting Shape means that all three dimensions and also all the cell angles are allowed to change.', default='XYZ', choices=['XYZ', 'Shape', 'X', 'Y', 'Z', 'XY', 'YZ', 'XZ']) self.Tau: float | FloatKey = FloatKey(name='Tau', comment='Specifies the time constant of the barostat.', gui_name='Damping constant:', unit='Femtoseconds') self.Type: Literal["None", "Berendsen", "MTK"] = MultipleChoiceKey(name='Type', comment='Selects the type of the barostat.', gui_name='Barostat:', default='None', choices=['None', 'Berendsen', 'MTK'])
[docs] class _BinLog(FixedBlock): r""" This block controls writing the BinLog section in ams.rkf, which contains the selected MD state scalars and tensors from every MD step. No per-atom data is written. If you need the per-atom data then you can set the sampling frequency to 1 and get the required data from the MDHistory section. The tensors are written per component, that is, the pressure tensor is written as six variables: PressureTensor_xx, PressureTensor_yy, etc.. To reduce the file size, all data is written in blocks. :ivar BiasEnergy: Write the CVHD bias energy at every time step. :vartype BiasEnergy: BoolType | BoolKey :ivar BoostFactor: Write the CVHD boost factor at every time step. :vartype BoostFactor: BoolType | BoolKey :ivar ConservedEnergy: Write the conserved energy value at every time step. :vartype ConservedEnergy: BoolType | BoolKey :ivar Density: Write the density at every time step. :vartype Density: BoolType | BoolKey :ivar DipoleMoment: Write the dipole moment at every time step. Each component of the tensor is written in its own variable. :vartype DipoleMoment: BoolType | BoolKey :ivar Hypertime: Write the CVHD hypertime at every time step. :vartype Hypertime: BoolType | BoolKey :ivar KineticEnergy: Write the kinetic energy value at every time step. :vartype KineticEnergy: BoolType | BoolKey :ivar MaxBiasEnergy: Write the max CVHD bias energy at every time step. :vartype MaxBiasEnergy: BoolType | BoolKey :ivar MaxBoostFactor: Write the max CVHD boost factor at every time step. :vartype MaxBoostFactor: BoolType | BoolKey :ivar PotentialEnergy: Write the potential energy value at every time step. :vartype PotentialEnergy: BoolType | BoolKey :ivar Pressure: Write the pressure at every time step. :vartype Pressure: BoolType | BoolKey :ivar PressureTensor: Write the pressure tensor in Voigt notation at every time step. Each component of the tensor is written in its own variable. :vartype PressureTensor: BoolType | BoolKey :ivar Step: Write the step index during the simulation at every time step. :vartype Step: BoolType | BoolKey :ivar Temperature: Write the temperature at every time step. :vartype Temperature: BoolType | BoolKey :ivar Time: Write the simulation time (fs) at every time step. :vartype Time: BoolType | BoolKey :ivar TotalEnergy: Write the total energy value at every time step. :vartype TotalEnergy: BoolType | BoolKey :ivar Volume: Write the simulation cell volume, area or length, depending on the system periodicity, at every time step. :vartype Volume: BoolType | BoolKey """ def __post_init__(self): self.BiasEnergy: BoolType | BoolKey = BoolKey(name='BiasEnergy', comment='Write the CVHD bias energy at every time step.', default=False) self.BoostFactor: BoolType | BoolKey = BoolKey(name='BoostFactor', comment='Write the CVHD boost factor at every time step.', default=False) self.ConservedEnergy: BoolType | BoolKey = BoolKey(name='ConservedEnergy', comment='Write the conserved energy value at every time step.', default=False) self.Density: BoolType | BoolKey = BoolKey(name='Density', comment='Write the density at every time step.', default=False) self.DipoleMoment: BoolType | BoolKey = BoolKey(name='DipoleMoment', comment='Write the dipole moment at every time step. Each component of the tensor is written in its own variable.', gui_name='Dipole moment binlog:', default=False) self.Hypertime: BoolType | BoolKey = BoolKey(name='Hypertime', comment='Write the CVHD hypertime at every time step.', default=False) self.KineticEnergy: BoolType | BoolKey = BoolKey(name='KineticEnergy', comment='Write the kinetic energy value at every time step.', default=False) self.MaxBiasEnergy: BoolType | BoolKey = BoolKey(name='MaxBiasEnergy', comment='Write the max CVHD bias energy at every time step.', default=False) self.MaxBoostFactor: BoolType | BoolKey = BoolKey(name='MaxBoostFactor', comment='Write the max CVHD boost factor at every time step.', default=False) self.PotentialEnergy: BoolType | BoolKey = BoolKey(name='PotentialEnergy', comment='Write the potential energy value at every time step.', default=False) self.Pressure: BoolType | BoolKey = BoolKey(name='Pressure', comment='Write the pressure at every time step.', default=False) self.PressureTensor: BoolType | BoolKey = BoolKey(name='PressureTensor', comment='Write the pressure tensor in Voigt notation at every time step. Each component of the tensor is written in its own variable.', gui_name='Pressure tensor binlog:', default=False) self.Step: BoolType | BoolKey = BoolKey(name='Step', comment='Write the step index during the simulation at every time step.', default=False) self.Temperature: BoolType | BoolKey = BoolKey(name='Temperature', comment='Write the temperature at every time step.', default=False) self.Time: BoolType | BoolKey = BoolKey(name='Time', comment='Write the simulation time (fs) at every time step.', gui_name='Time (fs) binlog:', default=False) self.TotalEnergy: BoolType | BoolKey = BoolKey(name='TotalEnergy', comment='Write the total energy value at every time step.', default=False) self.Volume: BoolType | BoolKey = BoolKey(name='Volume', comment='Write the simulation cell volume, area or length, depending on the system periodicity, at every time step.', default=False)
[docs] class _BondBoost(FixedBlock): r""" Forced reaction (bond boost) definitions. Multiple BondBoost blocks may be specified, which will be treated independently. :ivar AddBond: [Reserved] Add a bond to the system or change its order. Specify two atom indices followed by the bond's order. The indices indicate positions of the atoms in the AtomNames key. Currently no engine will honor bond changes caused by this key. :vartype AddBond: str | StringKey :ivar DistanceRestraint: Specify two atom indices followed by the target distance in Angstrom, the first parameter and, optionally, the profile type and the second parameter. For periodic systems, restraints follow the minimum image convention. Each atom index indicates a position of the corresponding atom in the AtomNames key. Currently recognized restraint profile types: Harmonic (default), Hyperbolic, Erf, GaussianWell. The profile name can optionally be prefixed by "OneSided-", thus making this particular restraint one-sided. A one-sided restraint will only push or pull the distance towards its target value depending on the sign of the difference between the initial and the target distance. For example, if the initial distance is larger than the target one then the restraint will only push the value down. This is especially useful with moving restraints because then the restraint will effectively disappear as soon as the system crosses a barrier along the reaction path. By default, the restraints are two-sided, which means they will try to keep the distance between the two specified atoms near the (possibly moving) target value. For moving restraints, this means that after crossing a reaction barrier the system will slide slowly towards products held back by the restraints. The first parameter is the force constant for the Harmonic, Hyperbolic, and Erf profiles, or well depth for GaussianWell. The second parameter is the asymptotic force value F(Inf) for Hyperbolic and Erf profiles, or the factor before x^2 in the exponent for GaussianWell. Note: the GaussianWell restraint should be used with the Moving flag. :vartype DistanceRestraint: str | StringKey :ivar Moving: Move the restraints created with this BondBoost. The restraint value will start at the current coordinate's value and will move towards the optimum during the restraint's lifetime. The increment is calculated from the initial deviation and the [NSteps] parameter. This feature should be used with the GaussianWell restraint types. :vartype Moving: BoolType | BoolKey :ivar NSteps: Number of steps the restraints will remain active until removed. Atoms participating in one reaction are not available for the given number of steps. :vartype NSteps: int | IntKey :ivar NumInstances: Number of reactions of this type taking place simultaneously. :vartype NumInstances: int | IntKey :ivar RemoveBond: [Reserved] Remove a bond from the system. Specify two atom indices. The indices indicate positions of the atoms in the AtomNames key. Currently no engine will honor bond changes caused by this key. :vartype RemoveBond: str | StringKey :ivar SetAtomName: Change the specified atom's name. Specify atom index followed by the new name. The index indicates position of the atom in the AtomNames key. Note: this action will change the atom name only and not other properties (element name, mass, etc.). This may be useful to change atom names to affect future chain detections. The atom name length is limited to 32 characters. :vartype SetAtomName: str | StringKey :ivar Units: Change energy, force and force constant units in the DistanceRestraint key from the default (atomic units) to those often used in the MD community (based on kcal/mol and Angstrom). Units for the optimum distances are not affected. :vartype Units: Literal["Default", "MD"] :ivar Chain: Specifications of a chain of atoms. When a chain is detected the distance restraints will be activated. No other chain of this type will be detected while any restraints for this chain is active. :vartype Chain: AMS._MolecularDynamics._BondBoost._Chain """
[docs] class _Chain(FixedBlock): r""" Specifications of a chain of atoms. When a chain is detected the distance restraints will be activated. No other chain of this type will be detected while any restraints for this chain is active. :ivar AtomNames: Atom names specifying the chain. An atom name can optionally be followed by '@' and a region name, in this case only atoms of this type from the given region will be matched. A leading '@' followed by a number indicates that this position in the chain must be occupied by the atom found earlier at the specified position in the chain. For example "O H N C @1" indicates that the last atom in the chain of the five atoms must be the first oxygen, thus defining a 4-membered ring. This is the only way to define a ring because implicit rings will not be detected. For example, "O H N C O" does not include rings. :vartype AtomNames: str | StringKey :ivar MaxDistances: Maximum distances for each pair of atoms in the chain. The number of distances must be one less than the number of AtomNames. :vartype MaxDistances: Iterable[float] | FloatListKey :ivar MinDistances: Minimum distances for each pair of atoms in the chain. The number of distances must be one less than the number of AtomNames. :vartype MinDistances: Iterable[float] | FloatListKey """ def __post_init__(self): self.AtomNames: str | StringKey = StringKey(name='AtomNames', comment='Atom names specifying the chain. An atom name can optionally be followed by \'@\' and a region name, in this case only atoms of this type from the given region will be matched. A leading \'@\' followed by a number indicates that this position in the chain must be occupied by the atom found earlier at the specified position in the chain. For example "O H N C @1" indicates that the last atom in the chain of the five atoms must be the first oxygen, thus defining a 4-membered ring. This is the only way to define a ring because implicit rings will not be detected. For example, "O H N C O" does not include rings.') self.MaxDistances: Iterable[float] | FloatListKey = FloatListKey(name='MaxDistances', comment='Maximum distances for each pair of atoms in the chain. The number of distances must be one less than the number of AtomNames.', unit='Angstrom') self.MinDistances: Iterable[float] | FloatListKey = FloatListKey(name='MinDistances', comment='Minimum distances for each pair of atoms in the chain. The number of distances must be one less than the number of AtomNames.', unit='Angstrom')
def __post_init__(self): self.AddBond: str | StringKey = StringKey(name='AddBond', comment="[Reserved] Add a bond to the system or change its order. Specify two atom indices followed by the bond's order. The indices indicate positions of the atoms in the AtomNames key. Currently no engine will honor bond changes caused by this key.", hidden=True, unique=False) self.DistanceRestraint: str | StringKey = StringKey(name='DistanceRestraint', comment='Specify two atom indices followed by the target distance in Angstrom, the first parameter and, optionally, the profile type and the second parameter.\n\nFor periodic systems, restraints follow the minimum image convention.\n\nEach atom index indicates a position of the corresponding atom in the AtomNames key. Currently recognized restraint profile types: Harmonic (default), Hyperbolic, Erf, GaussianWell. The profile name can optionally be prefixed by "OneSided-", thus making this particular restraint one-sided. A one-sided restraint will only push or pull the distance towards its target value depending on the sign of the difference between the initial and the target distance. For example, if the initial distance is larger than the target one then the restraint will only push the value down. This is especially useful with moving restraints because then the restraint will effectively disappear as soon as the system crosses a barrier along the reaction path. By default, the restraints are two-sided, which means they will try to keep the distance between the two specified atoms near the (possibly moving) target value. For moving restraints, this means that after crossing a reaction barrier the system will slide slowly towards products held back by the restraints. \n\nThe first parameter is the force constant for the Harmonic, Hyperbolic, and Erf profiles, or well depth for GaussianWell. The second parameter is the asymptotic force value F(Inf) for Hyperbolic and Erf profiles, or the factor before x^2 in the exponent for GaussianWell.\n\nNote: the GaussianWell restraint should be used with the Moving flag.', unique=False) self.Moving: BoolType | BoolKey = BoolKey(name='Moving', comment="Move the restraints created with this BondBoost. The restraint value will start at the current coordinate's value and will move towards the optimum during the restraint's lifetime. The increment is calculated from the initial deviation and the [NSteps] parameter.\n\n This feature should be used with the GaussianWell restraint types.", gui_name='Move restraint', default=False) self.NSteps: int | IntKey = IntKey(name='NSteps', comment='Number of steps the restraints will remain active until removed. Atoms participating in one reaction are not available for the given number of steps.', gui_name='Boost lifetime:') self.NumInstances: int | IntKey = IntKey(name='NumInstances', comment='Number of reactions of this type taking place simultaneously.', gui_name='Number of instances:', default=1) self.RemoveBond: str | StringKey = StringKey(name='RemoveBond', comment='[Reserved] Remove a bond from the system. Specify two atom indices. The indices indicate positions of the atoms in the AtomNames key. Currently no engine will honor bond changes caused by this key.', hidden=True, unique=False) self.SetAtomName: str | StringKey = StringKey(name='SetAtomName', comment="Change the specified atom's name. Specify atom index followed by the new name. The index indicates position of the atom in the AtomNames key. Note: this action will change the atom name only and not other properties (element name, mass, etc.). This may be useful to change atom names to affect future chain detections. The atom name length is limited to 32 characters.", hidden=True, unique=False) self.Units: Literal["Default", "MD"] = MultipleChoiceKey(name='Units', comment='Change energy, force and force constant units in the DistanceRestraint key from the default (atomic units) to those often used in the MD community (based on kcal/mol and Angstrom). Units for the optimum distances are not affected.', gui_name='Restr. parameter units:', default='Default', choices=['Default', 'MD']) self.Chain: AMS._MolecularDynamics._BondBoost._Chain = self._Chain(name='Chain', comment='Specifications of a chain of atoms. When a chain is detected the distance restraints will be activated. No other chain of this type will be detected while any restraints for this chain is active.')
[docs] class _CRESTMTD(FixedBlock): r""" Input for CREST metadynamics simulation. :ivar AddEnergy: Add the bias energy to the potential energy (to match the gradients) :vartype AddEnergy: BoolType | BoolKey :ivar Height: The height of the Gaussians added :vartype Height: float | FloatKey :ivar NGaussiansMax: Maximum number of Gaussians stored :vartype NGaussiansMax: int | IntKey :ivar NSteps: Interval of Gaussian placement :vartype NSteps: int | IntKey :ivar Region: Restrict the range of atoms for RMSD calculation to the specified region. :vartype Region: str | StringKey :ivar RestartFile: Filename for file from which to read data on Gaussians placed previously. :vartype RestartFile: str | Path | StringKey :ivar Width: The width of the Gaussians added in terms of the RMSD :vartype Width: float | FloatKey :ivar GaussianScaling: Options for gradual introduction of the Gaussians :vartype GaussianScaling: AMS._MolecularDynamics._CRESTMTD._GaussianScaling """
[docs] class _GaussianScaling(FixedBlock): r""" Options for gradual introduction of the Gaussians :ivar ScaleGaussians: Introduce the Gaussians gradually, using a scaling function :vartype ScaleGaussians: BoolType | BoolKey :ivar ScalingSlope: Slope of the scaling function for the Gaussians with respect to time :vartype ScalingSlope: float | FloatKey """ def __post_init__(self): self.ScaleGaussians: BoolType | BoolKey = BoolKey(name='ScaleGaussians', comment='Introduce the Gaussians gradually, using a scaling function', default=True) self.ScalingSlope: float | FloatKey = FloatKey(name='ScalingSlope', comment='Slope of the scaling function for the Gaussians with respect to time', default=0.03)
def __post_init__(self): self.AddEnergy: BoolType | BoolKey = BoolKey(name='AddEnergy', comment='Add the bias energy to the potential energy (to match the gradients)', default=False) self.Height: float | FloatKey = FloatKey(name='Height', comment='The height of the Gaussians added', unit='Hartree') self.NGaussiansMax: int | IntKey = IntKey(name='NGaussiansMax', comment='Maximum number of Gaussians stored') self.NSteps: int | IntKey = IntKey(name='NSteps', comment='Interval of Gaussian placement') self.Region: str | StringKey = StringKey(name='Region', comment='Restrict the range of atoms for RMSD calculation to the specified region.', default='*', gui_type='region') self.RestartFile: str | Path | StringKey = PathStringKey(name='RestartFile', comment='Filename for file from which to read data on Gaussians placed previously.', ispath=True) self.Width: float | FloatKey = FloatKey(name='Width', comment='The width of the Gaussians added in terms of the RMSD', unit='Bohr') self.GaussianScaling: AMS._MolecularDynamics._CRESTMTD._GaussianScaling = self._GaussianScaling(name='GaussianScaling', comment='Options for gradual introduction of the Gaussians')
[docs] class _CVHD(FixedBlock): r""" Input for the Collective Variable-driven HyperDynamics (CVHD). :ivar Frequency: Frequency of adding a new bias peak, in steps. New bias is deposited every [Frequency] steps after [StartStep] if the following conditions are satisfied: the current CV value is less than 0.9 (to avoid creating barriers at the transition state), the step number is greater than or equal to [StartStep], and the step number is less than or equal to [StopStep]. :vartype Frequency: int | IntKey :ivar MaxEvents: Max number of events to allow during dynamics. When this number is reached no new bias will be added for this input block. :vartype MaxEvents: int | IntKey :ivar StartStep: If this key is specified, the first bias will be deposited at this step. Otherwise, the first bias peak is added at the step number equal to the Frequency parameter. The bias is never deposited at step 0. :vartype StartStep: int | IntKey :ivar StopStep: No bias will be deposited after the specified step. The already deposited bias will continue to be applied until the reaction event occurs. After that no new CVHD will be started. By default, the CVHD runs for the whole duration of the MD calculation. :vartype StopStep: int | IntKey :ivar WaitSteps: If the CV value becomes equal to 1 and remains at this value for this many steps then the reaction event is considered having taken place. After this, the collective variable will be reset and the bias will be removed. :vartype WaitSteps: int | IntKey :ivar Bias: The bias is built from a series of Gaussian peaks deposited on the collective variable axis every [Frequency] steps during MD. Each peak is characterized by its (possibly damped) height and the RMS width (standard deviation). :vartype Bias: AMS._MolecularDynamics._CVHD._Bias :ivar ColVarBB: Description of a bond-breaking collective variable (CV) as described in [Bal & Neyts, JCTC, 11 (2015)]. A collective variable may consist of multiple ColVar blocks. :vartype ColVarBB: AMS._MolecularDynamics._CVHD._ColVarBB :ivar ColVarBM: Description of a bond-making collective variable (CV). A collective variable may consist of multiple ColVar blocks. :vartype ColVarBM: AMS._MolecularDynamics._CVHD._ColVarBM """
[docs] class _Bias(FixedBlock): r""" The bias is built from a series of Gaussian peaks deposited on the collective variable axis every [Frequency] steps during MD. Each peak is characterized by its (possibly damped) height and the RMS width (standard deviation). :ivar DampingTemp: During well-tempered hyperdynamics the height of the added bias is scaled down with an exp(-E/kT) factor [PhysRevLett 100, 020603 (2008)], where E is the current value of the bias at the given CV value and T is the damping temperature DampingTemp. If DampingTemp is zero then no damping is applied. :vartype DampingTemp: float | FloatKey :ivar Delta: Standard deviation parameter of the Gaussian bias peak. :vartype Delta: float | FloatKey :ivar Height: Height of the Gaussian bias peak. :vartype Height: float | FloatKey """ def __post_init__(self): self.DampingTemp: float | FloatKey = FloatKey(name='DampingTemp', comment='During well-tempered hyperdynamics the height of the added bias is scaled down with an exp(-E/kT) factor [PhysRevLett 100, 020603 (2008)], where E is the current value of the bias at the given CV value and T is the damping temperature DampingTemp. If DampingTemp is zero then no damping is applied.', gui_name='Bias damping T:', default=0.0, unit='Kelvin') self.Delta: float | FloatKey = FloatKey(name='Delta', comment='Standard deviation parameter of the Gaussian bias peak.') self.Height: float | FloatKey = FloatKey(name='Height', comment='Height of the Gaussian bias peak.', unit='Hartree')
[docs] class _ColVarBB(FixedBlock): r""" Description of a bond-breaking collective variable (CV) as described in [Bal & Neyts, JCTC, 11 (2015)]. A collective variable may consist of multiple ColVar blocks. :ivar cutoff: Bond order cutoff. Bonds with BO below this value are ignored when creating the initial bond list for the CV. The bond list does not change during lifetime of the variable even if some bond orders drop below the cutoff. :vartype cutoff: float | FloatKey :ivar p: Exponent value p used to calculate the p-norm for this CV. :vartype p: int | IntKey :ivar rmax: Max bond distance parameter Rmax used for calculating the CV. It should be close to the transition-state distance for the corresponding bond. :vartype rmax: float | FloatKey :ivar rmin: Min bond distance parameter Rmin used for calculating the CV. It should be close to equilibrium distance for the corresponding bond. :vartype rmin: float | FloatKey :ivar at1: Specifies the first bonded atom in the collective variable. :vartype at1: AMS._MolecularDynamics._CVHD._ColVarBB._at1 :ivar at2: Specifies the second bonded atom in the collective variable. :vartype at2: AMS._MolecularDynamics._CVHD._ColVarBB._at2 """
[docs] class _at1(FixedBlock): r""" Specifies the first bonded atom in the collective variable. :ivar region: Restrict the selection of bonded atoms to a specific region. If this is not set, atoms anywhere in the system will be selected. :vartype region: str | StringKey :ivar symbol: Atom type name of the first atom of the bond. The name must be as it appears in the System block. That is, if the atom name contains an extension (e.g C.1) then the full name including the extension must be used here. :vartype symbol: str | StringKey """ def __post_init__(self): self.region: str | StringKey = StringKey(name='region', comment='Restrict the selection of bonded atoms to a specific region. If this is not set, atoms anywhere in the system will be selected.', default='*', gui_type='region') self.symbol: str | StringKey = StringKey(name='symbol', comment='Atom type name of the first atom of the bond. The name must be as it appears in the System block. That is, if the atom name contains an extension (e.g C.1) then the full name including the extension must be used here.')
[docs] class _at2(FixedBlock): r""" Specifies the second bonded atom in the collective variable. :ivar region: Restrict the selection of bonded atoms to a specific region. If this is not set, atoms anywhere in the system will be selected. :vartype region: str | StringKey :ivar symbol: Atom type name of the second atom of the bond. The value is allowed to be the same as [at1], in which case bonds between atoms of the same type will be included. :vartype symbol: str | StringKey """ def __post_init__(self): self.region: str | StringKey = StringKey(name='region', comment='Restrict the selection of bonded atoms to a specific region. If this is not set, atoms anywhere in the system will be selected.', default='*', gui_type='region') self.symbol: str | StringKey = StringKey(name='symbol', comment='Atom type name of the second atom of the bond. The value is allowed to be the same as [at1], in which case bonds between atoms of the same type will be included.')
def __post_init__(self): self.cutoff: float | FloatKey = FloatKey(name='cutoff', comment='Bond order cutoff. Bonds with BO below this value are ignored when creating the initial bond list for the CV. The bond list does not change during lifetime of the variable even if some bond orders drop below the cutoff.', gui_name='Bond order cutoff:', default=0.3) self.p: int | IntKey = IntKey(name='p', comment='Exponent value p used to calculate the p-norm for this CV.', gui_name='Exponent p:', default=6) self.rmax: float | FloatKey = FloatKey(name='rmax', comment='Max bond distance parameter Rmax used for calculating the CV. It should be close to the transition-state distance for the corresponding bond.', gui_name='R max:', unit='Angstrom') self.rmin: float | FloatKey = FloatKey(name='rmin', comment='Min bond distance parameter Rmin used for calculating the CV. It should be close to equilibrium distance for the corresponding bond.', gui_name='R min:', unit='Angstrom') self.at1: AMS._MolecularDynamics._CVHD._ColVarBB._at1 = self._at1(name='at1', comment='Specifies the first bonded atom in the collective variable.') self.at2: AMS._MolecularDynamics._CVHD._ColVarBB._at2 = self._at2(name='at2', comment='Specifies the second bonded atom in the collective variable.')
[docs] class _ColVarBM(FixedBlock): r""" Description of a bond-making collective variable (CV). A collective variable may consist of multiple ColVar blocks. :ivar cutoff: Bond order cutoff. Bonds with BO above this value are ignored when creating the initial atom-pair list for the CV. The list does not change during lifetime of the variable even if some bond orders rise above the cutoff. :vartype cutoff: float | FloatKey :ivar p: Exponent value p used to calculate the p-norm for this CV. :vartype p: int | IntKey :ivar rmax: Max bond distance parameter Rmax used for calculating the CV. It should be much larger than the corresponding Rmin. :vartype rmax: float | FloatKey :ivar rmin: Min bond distance parameter Rmin used for calculating the CV. It should be close to the transition-state distance for the corresponding bond. :vartype rmin: float | FloatKey :ivar at1: Specifies selection criteria for the first atom of a pair in the collective variable. :vartype at1: AMS._MolecularDynamics._CVHD._ColVarBM._at1 :ivar at2: Specifies selection criteria for the second atom of a pair in the collective variable. :vartype at2: AMS._MolecularDynamics._CVHD._ColVarBM._at2 """
[docs] class _at1(FixedBlock): r""" Specifies selection criteria for the first atom of a pair in the collective variable. :ivar region: Restrict the selection to a specific region. If this is not set, atoms anywhere in the system will be selected. :vartype region: str | StringKey :ivar symbol: Atom type name of the first atom of the pair. The name must be as it appears in the System block. That is, if the atom name contains an extension (e.g C.1) then the full name including the extension must be used here. :vartype symbol: str | StringKey """ def __post_init__(self): self.region: str | StringKey = StringKey(name='region', comment='Restrict the selection to a specific region. If this is not set, atoms anywhere in the system will be selected.', default='*', gui_type='region') self.symbol: str | StringKey = StringKey(name='symbol', comment='Atom type name of the first atom of the pair. The name must be as it appears in the System block. That is, if the atom name contains an extension (e.g C.1) then the full name including the extension must be used here.')
[docs] class _at2(FixedBlock): r""" Specifies selection criteria for the second atom of a pair in the collective variable. :ivar region: Restrict the selection to a specific region. If this is not set, atoms anywhere in the system will be selected. :vartype region: str | StringKey :ivar symbol: Atom type name of the second atom of the pair. The value is allowed to be the same as [at1], in which case pairs of atoms of the same type will be included. :vartype symbol: str | StringKey """ def __post_init__(self): self.region: str | StringKey = StringKey(name='region', comment='Restrict the selection to a specific region. If this is not set, atoms anywhere in the system will be selected.', default='*', gui_type='region') self.symbol: str | StringKey = StringKey(name='symbol', comment='Atom type name of the second atom of the pair. The value is allowed to be the same as [at1], in which case pairs of atoms of the same type will be included.')
def __post_init__(self): self.cutoff: float | FloatKey = FloatKey(name='cutoff', comment='Bond order cutoff. Bonds with BO above this value are ignored when creating the initial atom-pair list for the CV. The list does not change during lifetime of the variable even if some bond orders rise above the cutoff.', gui_name='Bond order cutoff:', default=0.3) self.p: int | IntKey = IntKey(name='p', comment='Exponent value p used to calculate the p-norm for this CV.', gui_name='Exponent p:', default=6) self.rmax: float | FloatKey = FloatKey(name='rmax', comment='Max bond distance parameter Rmax used for calculating the CV. It should be much larger than the corresponding Rmin.', gui_name='R max:', unit='Angstrom') self.rmin: float | FloatKey = FloatKey(name='rmin', comment='Min bond distance parameter Rmin used for calculating the CV. It should be close to the transition-state distance for the corresponding bond.', gui_name='R min:', unit='Angstrom') self.at1: AMS._MolecularDynamics._CVHD._ColVarBM._at1 = self._at1(name='at1', comment='Specifies selection criteria for the first atom of a pair in the collective variable.') self.at2: AMS._MolecularDynamics._CVHD._ColVarBM._at2 = self._at2(name='at2', comment='Specifies selection criteria for the second atom of a pair in the collective variable.')
def __post_init__(self): self.Frequency: int | IntKey = IntKey(name='Frequency', comment='Frequency of adding a new bias peak, in steps. \n New bias is deposited every [Frequency] steps after [StartStep] if the following conditions are satisfied: \n the current CV value is less than 0.9 (to avoid creating barriers at the transition state), \n the step number is greater than or equal to [StartStep], and \n the step number is less than or equal to [StopStep].') self.MaxEvents: int | IntKey = IntKey(name='MaxEvents', comment='Max number of events to allow during dynamics. When this number is reached no new bias will be added for this input block. ', default=0) self.StartStep: int | IntKey = IntKey(name='StartStep', comment='If this key is specified, the first bias will be deposited at this step. Otherwise, the first bias peak is added at the step number equal to the Frequency parameter. The bias is never deposited at step 0.') self.StopStep: int | IntKey = IntKey(name='StopStep', comment='No bias will be deposited after the specified step. The already deposited bias will continue to be applied until the reaction event occurs. After that no new CVHD will be started. By default, the CVHD runs for the whole duration of the MD calculation.') self.WaitSteps: int | IntKey = IntKey(name='WaitSteps', comment='If the CV value becomes equal to 1 and remains at this value for this many steps then the reaction event is considered having taken place. After this, the collective variable will be reset and the bias will be removed.') self.Bias: AMS._MolecularDynamics._CVHD._Bias = self._Bias(name='Bias', comment='The bias is built from a series of Gaussian peaks deposited on the collective variable axis every [Frequency] steps during MD. Each peak is characterized by its (possibly damped) height and the RMS width (standard deviation).') self.ColVarBB: AMS._MolecularDynamics._CVHD._ColVarBB = self._ColVarBB(name='ColVarBB', comment='Description of a bond-breaking collective variable (CV) as described in [Bal & Neyts, JCTC, 11 (2015)]. A collective variable may consist of multiple ColVar blocks.', unique=False, gui_name='Collective Variable', gui_type='Repeat at least once') self.ColVarBM: AMS._MolecularDynamics._CVHD._ColVarBM = self._ColVarBM(name='ColVarBM', comment='Description of a bond-making collective variable (CV). A collective variable may consist of multiple ColVar blocks.', unique=False, gui_name='Collective Variable', gui_type='Repeat at least once')
[docs] class _CheckTemperature(FixedBlock): r""" Check at every time step if the temperature has exceeded a threshold. If it has, it is assumed the system exploded, and the simulation will stop. :ivar Enabled: If enabled, the simulation will stop if the temperature becomes too large. :vartype Enabled: BoolType | BoolKey :ivar MaxTemperature: Maximum temperature the system can have. If larger, the simulation will stop. :vartype MaxTemperature: float | FloatKey """ def __post_init__(self): self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='If enabled, the simulation will stop if the temperature becomes too large.', default=True) self.MaxTemperature: float | FloatKey = FloatKey(name='MaxTemperature', comment='Maximum temperature the system can have. If larger, the simulation will stop.', default=1e+20)
[docs] class _Checkpoint(FixedBlock): r""" Sets the frequency for storing the entire MD state necessary for restarting the calculation. :ivar Frequency: Write the MD state to the Molecule and MDResults sections on ams.rkf once every N steps. Setting this to zero disables checkpointing during the simulation, but one checkpoint at the very end of the simulation will always be written. :vartype Frequency: int | IntKey :ivar WriteProperties: Honor top-level Properties input block when writing engine results files. DEPRECATED: This input option will be removed in AMS2026 and will be considered always enabled. If you rely on it being disabled, please contact [email protected]. :vartype WriteProperties: BoolType | BoolKey """ def __post_init__(self): self.Frequency: int | IntKey = IntKey(name='Frequency', comment='Write the MD state to the Molecule and MDResults sections on ams.rkf once every N steps. Setting this to zero disables checkpointing during the simulation, but one checkpoint at the very end of the simulation will always be written.', gui_name='Checkpoint frequency:', default=1000) self.WriteProperties: BoolType | BoolKey = BoolKey(name='WriteProperties', comment='Honor top-level Properties input block when writing engine results files.\n\nDEPRECATED: This input option will be removed in AMS2026 and will be considered always enabled. If you rely on it being disabled, please contact [email protected].', default=False)
[docs] class _CosineShear(FixedBlock): r""" Apply an external acceleration to all atoms of a fluid using a periodic (cosine) function along a selected coordinate axis. This induces a periodic shear flow profile which can be used to determine the viscosity. :ivar Acceleration: Amplitude of the applied cosine shear acceleration profile. The default value should be a rough first guess for water and it needs to be adjusted by experimentation for other systems. :vartype Acceleration: float | FloatKey :ivar Enabled: Apply a cosine shear acceleration profile for a NEMD calculation of viscosity. :vartype Enabled: BoolType | BoolKey :ivar FlowDirection: The direction in which to apply the shear acceleration, in Cartesian coordinates. The magnitude of this vector is ignored (AMS will normalize it internally). FlowDirection has to be perpendicular to ProfileAxis. :vartype FlowDirection: Iterable[float] | FloatListKey :ivar ProfileAxis: The Cartesian coordinate axis along which the cosine wave runs :vartype ProfileAxis: Literal["X", "Y", "Z"] """ def __post_init__(self): self.Acceleration: float | FloatKey = FloatKey(name='Acceleration', comment='Amplitude of the applied cosine shear acceleration profile. The default value should be a rough first guess for water and it needs to be adjusted by experimentation for other systems.', default=5e-06, unit='Angstrom/fs^2') self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Apply a cosine shear acceleration profile for a NEMD calculation of viscosity.', gui_name='Enable cosine shear', default=False) self.FlowDirection: Iterable[float] | FloatListKey = FloatListKey(name='FlowDirection', comment='The direction in which to apply the shear acceleration, in Cartesian coordinates. The magnitude of this vector is ignored (AMS will normalize it internally). FlowDirection has to be perpendicular to ProfileAxis.', default=[1.0, 0.0, 0.0], gui_type='nfloat 3') self.ProfileAxis: Literal["X", "Y", "Z"] = MultipleChoiceKey(name='ProfileAxis', comment='The Cartesian coordinate axis along which the cosine wave runs', default='Z', choices=['X', 'Y', 'Z'])
[docs] class _Deformation(FixedBlock): r""" Deform the periodic lattice of the system during the simulation. :ivar LengthRate: Relative rate of change of each lattice vector per step. :vartype LengthRate: Iterable[float] | FloatListKey :ivar LengthVelocity: Change the length of each lattice vector with this velocity. With Type=Exponential, LengthVelocity is divided by the current lattice vector lengths on StartStep to determine a LengthRate, which is then applied on all subsequent steps. For Type Sine and Cosine, this defines the maximum velocity (at the inflection point). :vartype LengthVelocity: Iterable[float] | FloatListKey :ivar Period: Period of oscillation for Type Sine and Cosine. :vartype Period: float | FloatKey :ivar ScaleAtoms: Scale the atomic positions together with the lattice vectors. Disable this to deform only the lattice, keeping the coordinates of atoms unchanged. :vartype ScaleAtoms: BoolType | BoolKey :ivar StartStep: First step at which the deformation will be applied. :vartype StartStep: int | IntKey :ivar StopStep: Last step at which the deformation will be applied. If unset or zero, nSteps will be used instead. :vartype StopStep: int | IntKey :ivar TargetDensity: Target density of the system to be achieved by StopStep by isotropically rescaling the lattice. This can only be used for 3D-periodic systems. Note that the selected Type determines how the lengths of the lattice vectors will evolve (linearly or as a sine/cosine), the evolution of the volume or density is thus necessarily non-linear. :vartype TargetDensity: float | FloatKey :ivar TargetLength: Target lengths of each lattice vector to be achieved by StopStep. The number of values should equal the periodicity of the system. If a value is zero, the corresponding lattice vector will not be modified. :vartype TargetLength: Iterable[float] | FloatListKey :ivar Type: Function defining the time dependence of the deformed lattice parameters. Linear increments the lattice parameters by the same absolute amount every timestep. Exponential multiplies the lattice parameters by the same factor every timestep. Only StrainRate, LengthRate, and LengthVelocity are supported for Type=Exponential. Sine deforms the system from the starting lattice to TargetLattice/TargetLength and then by the same amount to the opposite direction, while Cosine deforms the system from the starting lattice to the target and back. :vartype Type: Literal["Linear", "Exponential", "Sine", "Cosine"] :ivar LatticeVelocity: Velocity of individual lattice vector components in Angstrom/fs. The format is identical to the System%Lattice block. For Type Sine and Cosine, this defines the maximum velocity (at the inflection point). :vartype LatticeVelocity: str | Sequence[str] | FreeBlock :ivar StrainRate: Strain rate matrix to be applied on every step. The format is identical to the System%Lattice block. :vartype StrainRate: str | Sequence[str] | FreeBlock :ivar TargetLattice: Target lattice vectors to be achieved by StopStep. The format is identical to the System%Lattice block. :vartype TargetLattice: str | Sequence[str] | FreeBlock """
[docs] class _LatticeVelocity(FreeBlock): r""" Velocity of individual lattice vector components in Angstrom/fs. The format is identical to the System%Lattice block. For Type Sine and Cosine, this defines the maximum velocity (at the inflection point). """ def __post_init__(self): pass
[docs] class _StrainRate(FreeBlock): r""" Strain rate matrix to be applied on every step. The format is identical to the System%Lattice block. """ def __post_init__(self): pass
[docs] class _TargetLattice(FreeBlock): r""" Target lattice vectors to be achieved by StopStep. The format is identical to the System%Lattice block. """ def __post_init__(self): pass
def __post_init__(self): self.LengthRate: Iterable[float] | FloatListKey = FloatListKey(name='LengthRate', comment='Relative rate of change of each lattice vector per step.', default=[0.0, 0.0, 0.0], gui_type='nfloat 3') self.LengthVelocity: Iterable[float] | FloatListKey = FloatListKey(name='LengthVelocity', comment='Change the length of each lattice vector with this velocity. With Type=Exponential, LengthVelocity is divided by the current lattice vector lengths on StartStep to determine a LengthRate, which is then applied on all subsequent steps. For Type Sine and Cosine, this defines the maximum velocity (at the inflection point).', default=[0.0, 0.0, 0.0], unit='Angstrom/fs', gui_type='nfloat 3') self.Period: float | FloatKey = FloatKey(name='Period', comment='Period of oscillation for Type Sine and Cosine.', unit='Femtoseconds') self.ScaleAtoms: BoolType | BoolKey = BoolKey(name='ScaleAtoms', comment='Scale the atomic positions together with the lattice vectors. Disable this to deform only the lattice, keeping the coordinates of atoms unchanged.', default=True) self.StartStep: int | IntKey = IntKey(name='StartStep', comment='First step at which the deformation will be applied.', default=1) self.StopStep: int | IntKey = IntKey(name='StopStep', comment='Last step at which the deformation will be applied. If unset or zero, nSteps will be used instead.', default=0) self.TargetDensity: float | FloatKey = FloatKey(name='TargetDensity', comment='Target density of the system to be achieved by StopStep by isotropically rescaling the lattice.\n\nThis can only be used for 3D-periodic systems. Note that the selected Type determines how the lengths of the lattice vectors will evolve (linearly or as a sine/cosine), the evolution of the volume or density is thus necessarily non-linear.', unit='g/cm3') self.TargetLength: Iterable[float] | FloatListKey = FloatListKey(name='TargetLength', comment='Target lengths of each lattice vector to be achieved by StopStep. The number of values should equal the periodicity of the system. If a value is zero, the corresponding lattice vector will not be modified.', default=[0.0, 0.0, 0.0], unit='Angstrom', gui_type='nfloat 3') self.Type: Literal["Linear", "Exponential", "Sine", "Cosine"] = MultipleChoiceKey(name='Type', comment='Function defining the time dependence of the deformed lattice parameters.\n\nLinear increments the lattice parameters by the same absolute amount every timestep. Exponential multiplies the lattice parameters by the same factor every timestep. Only StrainRate, LengthRate, and LengthVelocity are supported for Type=Exponential. Sine deforms the system from the starting lattice to TargetLattice/TargetLength and then by the same amount to the opposite direction, while Cosine deforms the system from the starting lattice to the target and back.', default='Linear', choices=['Linear', 'Exponential', 'Sine', 'Cosine']) self.LatticeVelocity: str | Sequence[str] | FreeBlock = self._LatticeVelocity(name='LatticeVelocity', comment='Velocity of individual lattice vector components in Angstrom/fs. The format is identical to the System%Lattice block. For Type Sine and Cosine, this defines the maximum velocity (at the inflection point).', gui_type='matrix float 3 3 {v a⃗} {v b⃗} {v c⃗}') self.StrainRate: str | Sequence[str] | FreeBlock = self._StrainRate(name='StrainRate', comment='Strain rate matrix to be applied on every step. The format is identical to the System%Lattice block.', gui_type='matrix float 3 3') self.TargetLattice: str | Sequence[str] | FreeBlock = self._TargetLattice(name='TargetLattice', comment='Target lattice vectors to be achieved by StopStep. The format is identical to the System%Lattice block.', gui_type='matrix float 3 3 a⃗ b⃗ c⃗')
[docs] class _Gravity(FixedBlock): r""" Apply a constant acceleration in -z. :ivar Acceleration: Magnitude of the applied acceleration. :vartype Acceleration: float | FloatKey """ def __post_init__(self): self.Acceleration: float | FloatKey = FloatKey(name='Acceleration', comment='Magnitude of the applied acceleration.', default=0.0, unit='Angstrom/fs^2')
[docs] class _HeatExchange(FixedBlock): r""" Input for the heat-exchange non-equilibrium MD (T-NEMD). :ivar HeatingRate: Rate at which the energy is added to the Source and removed from the Sink. A heating rate of 1 Hartree/fs equals to about 0.00436 Watt of power being transferred through the system. :vartype HeatingRate: float | FloatKey :ivar Method: Heat exchange method used. Simple: kinetic energy of the atoms of the source and sink regions is modified irrespective of that of the center of mass (CoM) of the region (recommended for solids). HEX: kinetic energy of the atoms of these regions is modified keeping that of the corresponding CoM constant. eHEX: an enhanced version of HEX that conserves the total energy better (recommended for gases and liquids). :vartype Method: Literal["Simple", "HEX", "eHEX"] :ivar StartStep: Index of the MD step at which the heat exchange will start. :vartype StartStep: int | IntKey :ivar StopStep: Index of the MD step at which the heat exchange will stop. :vartype StopStep: int | IntKey :ivar Sink: Defines the heat sink region (where the heat will be removed). :vartype Sink: AMS._MolecularDynamics._HeatExchange._Sink :ivar Source: Defines the heat source region (where the heat will be added). :vartype Source: AMS._MolecularDynamics._HeatExchange._Source """
[docs] class _Sink(FixedBlock): r""" Defines the heat sink region (where the heat will be removed). :ivar AtomList: The atoms that are part of the sink. This key is ignored if the [Box] block or [Region] key is present. :vartype AtomList: Iterable[int] | IntListKey :ivar FirstAtom: Index of the first atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present. :vartype FirstAtom: int | IntKey :ivar LastAtom: Index of the last atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present. :vartype LastAtom: int | IntKey :ivar Region: The region that is the sink. This key is ignored if the [Box] block is present. :vartype Region: str | StringKey :ivar Show: Show the sink in the AMSinput :vartype Show: BoolType | BoolKey :ivar Box: Part of the simulation box (in fractional cell coordinates) defining the heat sink. If this block is specified, then by default, the whole box in each of the three dimensions is used, which usually does not make much sense. Normally, you will want to set the bounds along one of the axes. :vartype Box: AMS._MolecularDynamics._HeatExchange._Sink._Box """
[docs] class _Box(FixedBlock): r""" Part of the simulation box (in fractional cell coordinates) defining the heat sink. If this block is specified, then by default, the whole box in each of the three dimensions is used, which usually does not make much sense. Normally, you will want to set the bounds along one of the axes. :ivar Amax: Coordinate of the upper bound along the first axis. :vartype Amax: float | FloatKey :ivar Amin: Coordinate of the lower bound along the first axis. :vartype Amin: float | FloatKey :ivar Bmax: Coordinate of the upper bound along the second axis. :vartype Bmax: float | FloatKey :ivar Bmin: Coordinate of the lower bound along the second axis. :vartype Bmin: float | FloatKey :ivar Cmax: Coordinate of the upper bound along the third axis. :vartype Cmax: float | FloatKey :ivar Cmin: Coordinate of the lower bound along the third axis. :vartype Cmin: float | FloatKey """ def __post_init__(self): self.Amax: float | FloatKey = FloatKey(name='Amax', comment='Coordinate of the upper bound along the first axis.', default=1.0) self.Amin: float | FloatKey = FloatKey(name='Amin', comment='Coordinate of the lower bound along the first axis.', default=0.0) self.Bmax: float | FloatKey = FloatKey(name='Bmax', comment='Coordinate of the upper bound along the second axis.', default=1.0) self.Bmin: float | FloatKey = FloatKey(name='Bmin', comment='Coordinate of the lower bound along the second axis.', default=0.0) self.Cmax: float | FloatKey = FloatKey(name='Cmax', comment='Coordinate of the upper bound along the third axis.', default=1.0) self.Cmin: float | FloatKey = FloatKey(name='Cmin', comment='Coordinate of the lower bound along the third axis.', default=0.0)
def __post_init__(self): self.AtomList: Iterable[int] | IntListKey = IntListKey(name='AtomList', comment='The atoms that are part of the sink.\n\nThis key is ignored if the [Box] block or [Region] key is present.', gui_name='Sink region:', gui_type='region') self.FirstAtom: int | IntKey = IntKey(name='FirstAtom', comment='Index of the first atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present.', hidden=True) self.LastAtom: int | IntKey = IntKey(name='LastAtom', comment='Index of the last atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present.', hidden=True) self.Region: str | StringKey = StringKey(name='Region', comment='The region that is the sink.\n\nThis key is ignored if the [Box] block is present.', gui_name='Sink region:', gui_type='region') self.Show: BoolType | BoolKey = BoolKey(name='Show', comment='Show the sink in the AMSinput', hidden=True, gui_name='Sink box: Show', default=False) self.Box: AMS._MolecularDynamics._HeatExchange._Sink._Box = self._Box(name='Box', comment='Part of the simulation box (in fractional cell coordinates) defining the heat sink. If this block is specified, then by default, the whole box in each of the three dimensions is used, which usually does not make much sense. Normally, you will want to set the bounds along one of the axes.')
[docs] class _Source(FixedBlock): r""" Defines the heat source region (where the heat will be added). :ivar AtomList: The atoms that are part of the source. This key is ignored if the [Box] block or [Region] key is present. :vartype AtomList: Iterable[int] | IntListKey :ivar FirstAtom: Index of the first atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present. :vartype FirstAtom: int | IntKey :ivar LastAtom: Index of the last atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present. :vartype LastAtom: int | IntKey :ivar Region: The region that is the source. This key is ignored if the [Box] block is present. :vartype Region: str | StringKey :ivar Show: Show the source in the AMSinput :vartype Show: BoolType | BoolKey :ivar Box: Part of the simulation box (in fractional cell coordinates) defining the heat source. If this block is specified, then by default, the whole box in each of the three dimensions is used, which usually does not make much sense. Normally, you will want to set the bounds along one of the axes. This block is mutually exclusive with the FirstAtom/LastAtom setting. :vartype Box: AMS._MolecularDynamics._HeatExchange._Source._Box """
[docs] class _Box(FixedBlock): r""" Part of the simulation box (in fractional cell coordinates) defining the heat source. If this block is specified, then by default, the whole box in each of the three dimensions is used, which usually does not make much sense. Normally, you will want to set the bounds along one of the axes. This block is mutually exclusive with the FirstAtom/LastAtom setting. :ivar Amax: Coordinate of the upper bound along the first axis. :vartype Amax: float | FloatKey :ivar Amin: Coordinate of the lower bound along the first axis. :vartype Amin: float | FloatKey :ivar Bmax: Coordinate of the upper bound along the second axis. :vartype Bmax: float | FloatKey :ivar Bmin: Coordinate of the lower bound along the second axis. :vartype Bmin: float | FloatKey :ivar Cmax: Coordinate of the upper bound along the third axis. :vartype Cmax: float | FloatKey :ivar Cmin: Coordinate of the lower bound along the third axis. :vartype Cmin: float | FloatKey """ def __post_init__(self): self.Amax: float | FloatKey = FloatKey(name='Amax', comment='Coordinate of the upper bound along the first axis.', default=1.0) self.Amin: float | FloatKey = FloatKey(name='Amin', comment='Coordinate of the lower bound along the first axis.', default=0.0) self.Bmax: float | FloatKey = FloatKey(name='Bmax', comment='Coordinate of the upper bound along the second axis.', default=1.0) self.Bmin: float | FloatKey = FloatKey(name='Bmin', comment='Coordinate of the lower bound along the second axis.', default=0.0) self.Cmax: float | FloatKey = FloatKey(name='Cmax', comment='Coordinate of the upper bound along the third axis.', default=1.0) self.Cmin: float | FloatKey = FloatKey(name='Cmin', comment='Coordinate of the lower bound along the third axis.', default=0.0)
def __post_init__(self): self.AtomList: Iterable[int] | IntListKey = IntListKey(name='AtomList', comment='The atoms that are part of the source.\n\nThis key is ignored if the [Box] block or [Region] key is present.', gui_name='Source region:', gui_type='region') self.FirstAtom: int | IntKey = IntKey(name='FirstAtom', comment='Index of the first atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present.', hidden=True) self.LastAtom: int | IntKey = IntKey(name='LastAtom', comment='Index of the last atom of the region. This key is ignored if the [Box] block or the [AtomList] key is present.', hidden=True) self.Region: str | StringKey = StringKey(name='Region', comment='The region that is the source.\n\nThis key is ignored if the [Box] block is present.', gui_name='Source region:', gui_type='region') self.Show: BoolType | BoolKey = BoolKey(name='Show', comment='Show the source in the AMSinput', hidden=True, gui_name='Source box: Show', default=False) self.Box: AMS._MolecularDynamics._HeatExchange._Source._Box = self._Box(name='Box', comment='Part of the simulation box (in fractional cell coordinates) defining the heat source. If this block is specified, then by default, the whole box in each of the three dimensions is used, which usually does not make much sense. Normally, you will want to set the bounds along one of the axes. This block is mutually exclusive with the FirstAtom/LastAtom setting.')
def __post_init__(self): self.HeatingRate: float | FloatKey = FloatKey(name='HeatingRate', comment='Rate at which the energy is added to the Source and removed from the Sink. A heating rate of 1 Hartree/fs equals to about 0.00436 Watt of power being transferred through the system. ', unit='Hartree/fs') self.Method: Literal["Simple", "HEX", "eHEX"] = MultipleChoiceKey(name='Method', comment='Heat exchange method used.\n\n Simple: kinetic energy of the atoms of the source and sink regions is modified irrespective of that of the center of mass (CoM) of the region (recommended for solids). \n\n HEX: kinetic energy of the atoms of these regions is modified keeping that of the corresponding CoM constant. \n\n eHEX: an enhanced version of HEX that conserves the total energy better (recommended for gases and liquids).', default='Simple', choices=['Simple', 'HEX', 'eHEX']) self.StartStep: int | IntKey = IntKey(name='StartStep', comment='Index of the MD step at which the heat exchange will start.', default=0) self.StopStep: int | IntKey = IntKey(name='StopStep', comment='Index of the MD step at which the heat exchange will stop.') self.Sink: AMS._MolecularDynamics._HeatExchange._Sink = self._Sink(name='Sink', comment='Defines the heat sink region (where the heat will be removed).') self.Source: AMS._MolecularDynamics._HeatExchange._Source = self._Source(name='Source', comment='Defines the heat source region (where the heat will be added).')
[docs] class _InitialVelocities(FixedBlock): r""" Sets the frequency for printing to stdout and storing the molecular configuration on the .rkf file. :ivar File: AMS RKF file containing the initial velocities. :vartype File: str | Path | StringKey :ivar RandomVelocitiesMethod: Specifies how are random velocities generated. Three methods are available. Exact: Velocities are scaled to exactly match set random velocities temperature. Boltzmann: Velocities are not scaled and sample Maxwell-Boltzmann distribution. However, the distribution is not corrected for constraints. Gromacs: Velocities are scaled to match set random velocities temperature, but removal of net momentum is performed only after the scaling. Resulting kinetic energy is lower based on how much net momentum the system had. :vartype RandomVelocitiesMethod: Literal["Exact", "Boltzmann", "Gromacs"] :ivar Temperature: Sets the temperature for the Maxwell-Boltzmann distribution when the type of the initial velocities is set to random, in which case specifying this key is mandatory. AMSinput will use the first temperature of the first thermostat as default. :vartype Temperature: float | FloatKey :ivar Type: Specifies the initial velocities to assign to the atoms. Three methods to assign velocities are available. Zero: All atom are at rest at the beginning of the calculation. Random: Initial atom velocities follow a Maxwell-Boltzmann distribution for the temperature given by the [MolecularDynamics%InitialVelocities%Temperature] keyword. FromFile: Load the velocities from a previous ams result file. Input: Atom's velocities are set to the values specified in the [MolecularDynamics%InitialVelocities%Values] block, which can be accessed via the Expert AMS panel in AMSinput. :vartype Type: Literal["Zero", "Random", "FromFile", "Input"] :ivar Values: This block specifies the velocity of each atom, in Angstrom/fs, when [MolecularDynamics%InitialVelocities%Type] is set to Input. Each row must contain three floating point values (corresponding to the x,y,z component of the velocity vector) and a number of rows equal to the number of atoms must be present, given in the same order as the [System%Atoms] block. :vartype Values: str | Sequence[str] | FreeBlock """
[docs] class _Values(FreeBlock): r""" This block specifies the velocity of each atom, in Angstrom/fs, when [MolecularDynamics%InitialVelocities%Type] is set to Input. Each row must contain three floating point values (corresponding to the x,y,z component of the velocity vector) and a number of rows equal to the number of atoms must be present, given in the same order as the [System%Atoms] block. """ def __post_init__(self): pass
def __post_init__(self): self.File: str | Path | StringKey = PathStringKey(name='File', comment='AMS RKF file containing the initial velocities.', ispath=True, gui_type='{} {{{AMS result file} .rkf}}') self.RandomVelocitiesMethod: Literal["Exact", "Boltzmann", "Gromacs"] = MultipleChoiceKey(name='RandomVelocitiesMethod', comment='Specifies how are random velocities generated. Three methods are available.\n\nExact: Velocities are scaled to exactly match set random velocities temperature. \n\nBoltzmann: Velocities are not scaled and sample Maxwell-Boltzmann distribution. However, the distribution is not corrected for constraints.\n\nGromacs: Velocities are scaled to match set random velocities temperature, but removal of net momentum is performed only after the scaling. Resulting kinetic energy is lower based on how much net momentum the system had.', gui_name='Velocity randomization method:', default='Exact', choices=['Exact', 'Boltzmann', 'Gromacs']) self.Temperature: float | FloatKey = FloatKey(name='Temperature', comment='Sets the temperature for the Maxwell-Boltzmann distribution when the type of the initial velocities is set to random, in which case specifying this key is mandatory.\n\nAMSinput will use the first temperature of the first thermostat as default.', gui_name='Initial temperature:', unit='Kelvin') self.Type: Literal["Zero", "Random", "FromFile", "Input"] = MultipleChoiceKey(name='Type', comment="Specifies the initial velocities to assign to the atoms. Three methods to assign velocities are available.\n\nZero: All atom are at rest at the beginning of the calculation.\n\nRandom: Initial atom velocities follow a Maxwell-Boltzmann distribution for the temperature given by the [MolecularDynamics%InitialVelocities%Temperature] keyword.\n\nFromFile: Load the velocities from a previous ams result file.\n\nInput: Atom's velocities are set to the values specified in the [MolecularDynamics%InitialVelocities%Values] block, which can be accessed via the Expert AMS panel in AMSinput.", gui_name='Initial velocities:', default='Random', choices=['Zero', 'Random', 'FromFile', 'Input']) self.Values: str | Sequence[str] | FreeBlock = self._Values(name='Values', comment='This block specifies the velocity of each atom, in Angstrom/fs, when [MolecularDynamics%InitialVelocities%Type] is set to Input. Each row must contain three floating point values (corresponding to the x,y,z component of the velocity vector) and a number of rows equal to the number of atoms must be present, given in the same order as the [System%Atoms] block.')
[docs] class _MovingRestraints(FixedBlock): r""" Define a set of moving restraints. :ivar Change: Type of function defining how the target restraint value will change over time: Linear - linearly between the StartValue and EndValue. Sine - oscillating around StartValue with an amplitude equal to the difference between EndValue and StartValue. Cosine - oscillating between StartValue and EndValue. :vartype Change: Literal["Linear", "Sine", "Cosine"] :ivar Name: Optional name to be used for plotting. :vartype Name: str | StringKey :ivar Period: Period of oscillation for Sine and Cosine change types. :vartype Period: float | FloatKey :ivar RestraintType: Select type of the moving restraint profile. The force for Hyperbolic and Erf is bounded by a user-defined value, the latter converging to it faster than the former. The GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable. :vartype RestraintType: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] :ivar StartStep: First step number at which the restraints will be applied. :vartype StartStep: int | IntKey :ivar StopStep: Last step number at which the restraints will be applied. :vartype StopStep: int | IntKey :ivar Distance: Define a distance restraint between pair of atoms. For linear-type :vartype Distance: AMS._MolecularDynamics._MovingRestraints._Distance :ivar Erf: Define parameters for the Int(erf) restraint potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :vartype Erf: AMS._MolecularDynamics._MovingRestraints._Erf :ivar GaussianWell: Define parameters in the Gaussian well restraint potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :vartype GaussianWell: AMS._MolecularDynamics._MovingRestraints._GaussianWell :ivar Harmonic: Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :vartype Harmonic: AMS._MolecularDynamics._MovingRestraints._Harmonic :ivar Hyperbolic: Define parameters for the hyperbolic restraint potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :vartype Hyperbolic: AMS._MolecularDynamics._MovingRestraints._Hyperbolic """
[docs] class _Distance(FixedBlock): r""" Define a distance restraint between pair of atoms. For linear-type :ivar Atom1: First atom of the distance restraint. :vartype Atom1: int | IntKey :ivar Atom2: Second atom of the distance restraint. :vartype Atom2: int | IntKey :ivar EndValue: Linear: final target distance. Sine: target distance at 1/4 of the period. Cosine: target distance at 1/2 of the period. :vartype EndValue: float | FloatKey :ivar StartValue: Initial target distance. :vartype StartValue: float | FloatKey """ def __post_init__(self): self.Atom1: int | IntKey = IntKey(name='Atom1', comment='First atom of the distance restraint.') self.Atom2: int | IntKey = IntKey(name='Atom2', comment='Second atom of the distance restraint.') self.EndValue: float | FloatKey = FloatKey(name='EndValue', comment='Linear: final target distance.\nSine: target distance at 1/4 of the period.\nCosine: target distance at 1/2 of the period.', unit='Angstrom') self.StartValue: float | FloatKey = FloatKey(name='StartValue', comment='Initial target distance.', unit='Angstrom')
[docs] class _Erf(FixedBlock): r""" Define parameters for the Int(erf) restraint potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', gui_name='Erf force constant:', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', gui_name='Erf F(Inf):', default=0.05, unit='Hartree/Bohr')
[docs] class _GaussianWell(FixedBlock): r""" Define parameters in the Gaussian well restraint potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :ivar Sigma: Sigma parameter in the potential expression. :vartype Sigma: float | FloatKey :ivar WellDepth: WellDepth parameter in the potential expression. :vartype WellDepth: float | FloatKey """ def __post_init__(self): self.Sigma: float | FloatKey = FloatKey(name='Sigma', comment='Sigma parameter in the potential expression.', gui_name='Gaussian well sigma:', default=1.0, unit='1/Bohr^2') self.WellDepth: float | FloatKey = FloatKey(name='WellDepth', comment='WellDepth parameter in the potential expression.', gui_name='Gaussian well depth:', default=1.0, unit='Hartree')
[docs] class _Harmonic(FixedBlock): r""" Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :ivar ForceConstant: The FC parameter of the harmonic potential. :vartype ForceConstant: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The FC parameter of the harmonic potential.', gui_name='Harmonic force constant:', default=0.5, unit='Hartree/Bohr^2')
[docs] class _Hyperbolic(FixedBlock): r""" Define parameters for the hyperbolic restraint potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', gui_name='Hyperbolic force constant:', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', gui_name='Hyperbolic F(Inf):', default=0.05, unit='Hartree/Bohr')
def __post_init__(self): self.Change: Literal["Linear", "Sine", "Cosine"] = MultipleChoiceKey(name='Change', comment='Type of function defining how the target restraint value will change over time:\n\nLinear - linearly between the StartValue and EndValue.\nSine - oscillating around StartValue with an amplitude equal to the difference between EndValue and StartValue.\nCosine - oscillating between StartValue and EndValue.', gui_name='Move type:', default='Linear', choices=['Linear', 'Sine', 'Cosine']) self.Name: str | StringKey = StringKey(name='Name', comment='Optional name to be used for plotting.', gui_name='Name:') self.Period: float | FloatKey = FloatKey(name='Period', comment='Period of oscillation for Sine and Cosine change types.', default=0.0, unit='Femtoseconds') self.RestraintType: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] = MultipleChoiceKey(name='RestraintType', comment='Select type of the moving restraint profile. The force for Hyperbolic and Erf is bounded by a user-defined value, the latter converging to it faster than the former. The GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable.', gui_name='Restraint type:', default='None', choices=['None', 'Harmonic', 'Hyperbolic', 'Erf', 'GaussianWell']) self.StartStep: int | IntKey = IntKey(name='StartStep', comment='First step number at which the restraints will be applied.', gui_name='Start step:', default=1) self.StopStep: int | IntKey = IntKey(name='StopStep', comment='Last step number at which the restraints will be applied.', gui_name='End step:', default=0) self.Distance: AMS._MolecularDynamics._MovingRestraints._Distance = self._Distance(name='Distance', comment='Define a distance restraint between pair of atoms. For linear-type ', unique=False) self.Erf: AMS._MolecularDynamics._MovingRestraints._Erf = self._Erf(name='Erf', comment='Define parameters for the Int(erf) restraint potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce.') self.GaussianWell: AMS._MolecularDynamics._MovingRestraints._GaussianWell = self._GaussianWell(name='GaussianWell', comment='Define parameters in the Gaussian well restraint potential V=-WellDepth*exp(-Sigma*(r-r0)^2).') self.Harmonic: AMS._MolecularDynamics._MovingRestraints._Harmonic = self._Harmonic(name='Harmonic', comment='Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2.') self.Hyperbolic: AMS._MolecularDynamics._MovingRestraints._Hyperbolic = self._Hyperbolic(name='Hyperbolic', comment='Define parameters for the hyperbolic restraint potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta')
[docs] class _PRD(FixedBlock): r""" This block is used for Parallel Replica Dynamics simulations. :ivar CorrelatedSteps: How many steps to wait for correlated events after detecting an initial event. :vartype CorrelatedSteps: int | IntKey :ivar DephasingSteps: Spend this many steps dephasing the individual replicas after an event. :vartype DephasingSteps: int | IntKey :ivar nReplicas: Number of replicas to run in parallel. :vartype nReplicas: int | IntKey :ivar BondChange: Detect changes to the bonding topology and bond orders returned by the engine. :vartype BondChange: AMS._MolecularDynamics._PRD._BondChange :ivar MolCount: Detect changes to the molecular composition of the system. :vartype MolCount: AMS._MolecularDynamics._PRD._MolCount """
[docs] class _BondChange(FixedBlock): r""" Detect changes to the bonding topology and bond orders returned by the engine. :ivar ChangeThreshold: Trigger an event when the bond order of a bond changes from the reference state by more than this value. :vartype ChangeThreshold: float | FloatKey :ivar DissociationThreshold: Trigger an event when a bond dissociates (its bond order drops below this value while it was above FormationThreshold in the reference state). :vartype DissociationThreshold: float | FloatKey :ivar FormationThreshold: Trigger an event when a new bond forms (its bond order exceeds this value while it was below DissociationThreshold in the reference state). :vartype FormationThreshold: float | FloatKey """ def __post_init__(self): self.ChangeThreshold: float | FloatKey = FloatKey(name='ChangeThreshold', comment='Trigger an event when the bond order of a bond changes from the reference state by more than this value.', default=0.5) self.DissociationThreshold: float | FloatKey = FloatKey(name='DissociationThreshold', comment='Trigger an event when a bond dissociates (its bond order drops below this value while it was above FormationThreshold in the reference state).', default=0.3) self.FormationThreshold: float | FloatKey = FloatKey(name='FormationThreshold', comment='Trigger an event when a new bond forms (its bond order exceeds this value while it was below DissociationThreshold in the reference state).', default=0.8)
[docs] class _MolCount(FixedBlock): r""" Detect changes to the molecular composition of the system. """ def __post_init__(self): pass
def __post_init__(self): self.CorrelatedSteps: int | IntKey = IntKey(name='CorrelatedSteps', comment='How many steps to wait for correlated events after detecting an initial event.', default=100) self.DephasingSteps: int | IntKey = IntKey(name='DephasingSteps', comment='Spend this many steps dephasing the individual replicas after an event.', default=100) self.nReplicas: int | IntKey = IntKey(name='nReplicas', comment='Number of replicas to run in parallel.', gui_name='Number of replicas:', default=1) self.BondChange: AMS._MolecularDynamics._PRD._BondChange = self._BondChange(name='BondChange', comment='Detect changes to the bonding topology and bond orders returned by the engine.', unique=False, gui_name='Bond Change') self.MolCount: AMS._MolecularDynamics._PRD._MolCount = self._MolCount(name='MolCount', comment='Detect changes to the molecular composition of the system.', unique=False)
[docs] class _Plumed(FixedBlock): r""" Input for PLUMED (version 2.5.0). The parallel option is still experimental. :ivar Input: Input for PLUMED. Contents of this block is passed to PLUMED as is. :vartype Input: str | Sequence[str] | FreeBlock :ivar Parallel: Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :vartype Parallel: AMS._MolecularDynamics._Plumed._Parallel """
[docs] class _Input(FreeBlock): r""" Input for PLUMED. Contents of this block is passed to PLUMED as is. """ def __post_init__(self): pass
[docs] class _Parallel(FixedBlock): r""" Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :ivar nCoresPerGroup: Number of cores in each working group. :vartype nCoresPerGroup: int | IntKey :ivar nGroups: Total number of processor groups. This is the number of tasks that will be executed in parallel. :vartype nGroups: int | IntKey :ivar nNodesPerGroup: Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores. :vartype nNodesPerGroup: int | IntKey """ def __post_init__(self): self.nCoresPerGroup: int | IntKey = IntKey(name='nCoresPerGroup', comment='Number of cores in each working group.', gui_name='Cores per group:') self.nGroups: int | IntKey = IntKey(name='nGroups', comment='Total number of processor groups. This is the number of tasks that will be executed in parallel.', gui_name='Number of groups:') self.nNodesPerGroup: int | IntKey = IntKey(name='nNodesPerGroup', comment='Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores.', gui_name='Nodes per group:')
def __post_init__(self): self.Input: str | Sequence[str] | FreeBlock = self._Input(name='Input', comment='Input for PLUMED. Contents of this block is passed to PLUMED as is.') self.Parallel: AMS._MolecularDynamics._Plumed._Parallel = self._Parallel(name='Parallel', comment='Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel.', extra_info='not_in_fragment', shared_id='AMSParallel')
[docs] class _Preserve(FixedBlock): r""" Periodically remove numerical drift accumulated during the simulation to preserve different whole-system parameters. :ivar AngularMomentum: Remove overall angular momentum of the system. This option is ignored for 2D and 3D-periodic systems, and disabled by default for systems which are not translationally invariant (for example when frozen atoms are present). :vartype AngularMomentum: BoolType | BoolKey :ivar CenterOfMass: Translate the system to keep its center of mass at the coordinate origin. This option is not very useful for 3D-periodic systems. :vartype CenterOfMass: BoolType | BoolKey :ivar Momentum: Remove overall (linear) momentum of the system. This is disabled by default for systems which are not translationally invariant (for example when frozen atoms are present). :vartype Momentum: BoolType | BoolKey """ def __post_init__(self): self.AngularMomentum: BoolType | BoolKey = BoolKey(name='AngularMomentum', comment='Remove overall angular momentum of the system. This option is ignored for 2D and 3D-periodic systems, and disabled by default for systems which are not translationally invariant (for example when frozen atoms are present).', gui_name=': Angular momentum', default=True) self.CenterOfMass: BoolType | BoolKey = BoolKey(name='CenterOfMass', comment='Translate the system to keep its center of mass at the coordinate origin. This option is not very useful for 3D-periodic systems.', gui_name=': Center of mass', default=False) self.Momentum: BoolType | BoolKey = BoolKey(name='Momentum', comment='Remove overall (linear) momentum of the system. This is disabled by default for systems which are not translationally invariant (for example when frozen atoms are present).', gui_name='Preserve: Total momentum', default=True)
[docs] class _Print(FixedBlock): r""" This block controls the printing of additional information to stdout. :ivar System: Print the chemical system before and after the simulation. :vartype System: BoolType | BoolKey :ivar Velocities: Print the atomic velocities before and after the simulation. :vartype Velocities: BoolType | BoolKey """ def __post_init__(self): self.System: BoolType | BoolKey = BoolKey(name='System', comment='Print the chemical system before and after the simulation.', default=False) self.Velocities: BoolType | BoolKey = BoolKey(name='Velocities', comment='Print the atomic velocities before and after the simulation.', default=False)
[docs] class _ReactionBoost(FixedBlock): r""" Define a series of transitions between different states of the system. Each transition is defined by a TargetSystem and by a set of restraints that force the transition. :ivar Change: Select what to change during dynamics. By default, once the restraints are switched on, AMS will change the restraint's target coordinate towards its final value. If the [Force] or [LogForce] option is selected then the target coordinate is set to its final value immediately and instead the restraint force is gradually scaled from 0 to 1. The scaling is either linear (Force) or logarithmic (LogForce). :vartype Change: Literal["TargetCoordinate", "Force", "LogForce"] :ivar InitialFraction: Initial fraction of the boost variable. At the first boosting step, the restraint's target value (or force or log(force)) is equal to InitialFraction + 1/NSteps. :vartype InitialFraction: float | FloatKey :ivar InterEquilibrationSteps: Number of equilibration steps after reaching a target before setting up restraints for the next one. :vartype InterEquilibrationSteps: int | IntKey :ivar MinBondChange: Minimal change in the distance for an individual restraint to be considered bond-breaking/making vs bonded. :vartype MinBondChange: float | FloatKey :ivar MinBondStrength: Minimum strength (usually ranges from 0 to 1) for a bond to be considered. :vartype MinBondStrength: float | FloatKey :ivar NSteps: Number of steps per target the restraints should be active for. :vartype NSteps: int | IntKey :ivar PreEquilibrationSteps: Number of steps before enabling the first set of restraints. :vartype PreEquilibrationSteps: int | IntKey :ivar Region: Region to which the restraints should be limited. :vartype Region: str | StringKey :ivar TargetSystem: The target system's name for this transition. Multiple targets can be specified to request multiple transitions in one simulation. Note that only the lattice and the atomic coordinates of the target system are used and other properties (bonds, charge, etc.) are ignored. The target system's lattice is used only to determine connections and it cannot be restrained. :vartype TargetSystem: str | StringKey :ivar Type: Reaction Boost uses a series of transitions between different states of the system. Each transition is defined by a TargetSystem and by a set of restraints that force the transition. Select the type of the restraint set: -None: no Reaction Boost - Pair: use pair restraints - RMSD: use RMSD restraints. Pair restraints are defined per atom pair while the RMSD defines one collective restraint for all atoms and is thus suitable for very large systems. The pair restraints are further divided into four sub-types: bonding, non-bonding, bond-breaking and bond-making. The sub-type of restraints for each pair is determined automatically depending on whether the two atoms are bonded in the initial/final state. Parameters of the pair restraints are defined by [NonBondedRestraints], [BondedRestraints], [BondBreakingRestraints] and [BondMakingRestraints] blocks, while those of the RMSD restraint by the [RMSDRestraint] block. :vartype Type: Literal["None", "Pair", "RMSD"] :ivar BondBreakingRestraints: Define parameters for moving restraints that are added for pairs of atoms that become disconnected during the transition. It is intended to make sure the corresponding bonds get broken, although this may not always be required because forming other bonds will likely get these bonds broken. :vartype BondBreakingRestraints: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints :ivar BondMakingRestraints: Define parameters for moving restraints that are added for pairs of atoms that become connected during the transition. It is intended to make sure the bonds are created as required. :vartype BondMakingRestraints: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints :ivar BondedRestraints: Define parameters for bonded restraints. A bonded restraint is added for each pair of atoms that are bonded both in the current and in the final state. It is intended to make sure they remain bonded during simulation. :vartype BondedRestraints: AMS._MolecularDynamics._ReactionBoost._BondedRestraints :ivar NonBondedRestraints: Define parameters for non-bonded restraints. A non-bonded restraint is added for each pair of atoms that are bonded neither in the current nor in the final state. It is intended to keep them from forming a bond unintentionally. They are represented by a repulsive potential :vartype NonBondedRestraints: AMS._MolecularDynamics._ReactionBoost._NonBondedRestraints :ivar RMSDRestraint: Define a static restraint that pulls each atom to its position in the target system, but in contrast to the individual restraints, the force for this one depends on the total mass-weighted root-mean-squared distance (RMSD) between the two structures. :vartype RMSDRestraint: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint """
[docs] class _BondBreakingRestraints(FixedBlock): r""" Define parameters for moving restraints that are added for pairs of atoms that become disconnected during the transition. It is intended to make sure the corresponding bonds get broken, although this may not always be required because forming other bonds will likely get these bonds broken. :ivar Type: Select type of the moving restraint profile. Harmonic: V=0.5*FC*(r-r0)^2 Hyperbolic: V=alpha*(sqrt(1 + beta*x^2) - 1) Erf: V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)) GaussianWell: V=WellDepth*(1-exp(-Sigma*(r-r0)^2)) Here beta=ForceConstant/MaxForce, alpha=MaxForce/beta. The force for Hyperbolic and Erf is bounded by a user-defined value, the latter converging to it faster than the former. The GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable. Moving restraints are added for pairs of atoms that become disconnected during the transition. It is intended to make sure the corresponding bonds get broken, although this may not always be required because forming other bonds will likely get these bonds broken. :vartype Type: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] :ivar Erf: Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :vartype Erf: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Erf :ivar GaussianWell: Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :vartype GaussianWell: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._GaussianWell :ivar Harmonic: Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :vartype Harmonic: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Harmonic :ivar Hyperbolic: Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :vartype Hyperbolic: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Hyperbolic :ivar Taper: :vartype Taper: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Taper """
[docs] class _Erf(FixedBlock): r""" Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', default=0.05, unit='Hartree/Bohr')
[docs] class _GaussianWell(FixedBlock): r""" Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :ivar Sigma: Sigma parameter in the potential expression. :vartype Sigma: float | FloatKey :ivar WellDepth: WellDepth parameter in the potential expression. :vartype WellDepth: float | FloatKey """ def __post_init__(self): self.Sigma: float | FloatKey = FloatKey(name='Sigma', comment='Sigma parameter in the potential expression.', default=1.0, unit='1/Bohr^2') self.WellDepth: float | FloatKey = FloatKey(name='WellDepth', comment='WellDepth parameter in the potential expression.', default=1.0, unit='Hartree')
[docs] class _Harmonic(FixedBlock): r""" Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :ivar ForceConstant: The FC parameter of the harmonic potential. :vartype ForceConstant: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The FC parameter of the harmonic potential.', default=0.5, unit='Hartree/Bohr^2')
[docs] class _Hyperbolic(FixedBlock): r""" Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', default=0.05, unit='Hartree/Bohr')
[docs] class _Taper(FixedBlock): r""" :ivar Enabled: Enable tapering of the restraint potential and force between the given range of bond distances. A 7-th order tapering function on the actual (not target!) distance will be used. The MaxDistance must be greater than MinDistance. :vartype Enabled: BoolType | BoolKey :ivar MaxDistance: Bond length at which the restraint potential and force decays to zero. :vartype MaxDistance: float | FloatKey :ivar MinDistance: Bond length at which the restraint potential and force will start decaying to zero. :vartype MinDistance: float | FloatKey """ def __post_init__(self): self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Enable tapering of the restraint potential and force between the given range of bond distances. A 7-th order tapering function on the actual (not target!) distance will be used. The MaxDistance must be greater than MinDistance.', gui_name='Tapering:', default=False) self.MaxDistance: float | FloatKey = FloatKey(name='MaxDistance', comment='Bond length at which the restraint potential and force decays to zero.', gui_name='End tapering at:', default=0.0, unit='Angstrom') self.MinDistance: float | FloatKey = FloatKey(name='MinDistance', comment='Bond length at which the restraint potential and force will start decaying to zero.', gui_name='Start tapering at:', default=0.0, unit='Angstrom')
def __post_init__(self): self.Type: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] = MultipleChoiceKey(name='Type', comment='Select type of the moving restraint profile.\n\nHarmonic: V=0.5*FC*(r-r0)^2\n\nHyperbolic: V=alpha*(sqrt(1 + beta*x^2) - 1)\n\nErf: V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI))\n\nGaussianWell: V=WellDepth*(1-exp(-Sigma*(r-r0)^2))\n\nHere beta=ForceConstant/MaxForce, alpha=MaxForce/beta.\n\nThe force for Hyperbolic and Erf is bounded by a user-defined value, the latter converging to it faster than the former.\nThe GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable.\n\nMoving restraints are added for pairs of atoms that become disconnected during the transition.\n\nIt is intended to make sure the corresponding bonds get broken, although this may not always be required because forming other bonds will likely get these bonds broken.', gui_name='Bond breaking restraints:', default='Erf', choices=['None', 'Harmonic', 'Hyperbolic', 'Erf', 'GaussianWell']) self.Erf: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Erf = self._Erf(name='Erf', comment='Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce.') self.GaussianWell: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._GaussianWell = self._GaussianWell(name='GaussianWell', comment='Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2).') self.Harmonic: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Harmonic = self._Harmonic(name='Harmonic', comment='Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2.') self.Hyperbolic: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Hyperbolic = self._Hyperbolic(name='Hyperbolic', comment='Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta') self.Taper: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints._Taper = self._Taper(name='Taper')
[docs] class _BondMakingRestraints(FixedBlock): r""" Define parameters for moving restraints that are added for pairs of atoms that become connected during the transition. It is intended to make sure the bonds are created as required. :ivar Type: Select type of the moving restraint profile. Harmonic: V=0.5*FC*(r-r0)^2 Hyperbolic: V=alpha*(sqrt(1 + beta*x^2) - 1) Erf: V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)) GaussianWell: V=-WellDepth*exp(-Sigma*(r-r0)^2) Here beta=ForceConstant/MaxForce, alpha=MaxForce/beta. The force for Hyperbolic and Erf is bounded by a user-defined value. The GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable. Moving restraints are added for pairs of atoms that become connected during the transition. It is intended to make sure the bonds are created as required. :vartype Type: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] :ivar Erf: Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :vartype Erf: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._Erf :ivar GaussianWell: Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :vartype GaussianWell: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._GaussianWell :ivar Harmonic: Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :vartype Harmonic: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._Harmonic :ivar Hyperbolic: Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :vartype Hyperbolic: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._Hyperbolic """
[docs] class _Erf(FixedBlock): r""" Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', default=0.05, unit='Hartree/Bohr')
[docs] class _GaussianWell(FixedBlock): r""" Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :ivar Sigma: Sigma parameter in the potential expression. :vartype Sigma: float | FloatKey :ivar WellDepth: WellDepth parameter in the potential expression. :vartype WellDepth: float | FloatKey """ def __post_init__(self): self.Sigma: float | FloatKey = FloatKey(name='Sigma', comment='Sigma parameter in the potential expression.', default=1.0, unit='1/Bohr^2') self.WellDepth: float | FloatKey = FloatKey(name='WellDepth', comment='WellDepth parameter in the potential expression.', default=1.0, unit='Hartree')
[docs] class _Harmonic(FixedBlock): r""" Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :ivar ForceConstant: The FC parameter of the harmonic potential. :vartype ForceConstant: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The FC parameter of the harmonic potential.', default=0.5, unit='Hartree/Bohr^2')
[docs] class _Hyperbolic(FixedBlock): r""" Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', default=0.05, unit='Hartree/Bohr')
def __post_init__(self): self.Type: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] = MultipleChoiceKey(name='Type', comment='Select type of the moving restraint profile.\n\nHarmonic: V=0.5*FC*(r-r0)^2\n\nHyperbolic: V=alpha*(sqrt(1 + beta*x^2) - 1)\n\nErf: V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI))\n\nGaussianWell: V=-WellDepth*exp(-Sigma*(r-r0)^2)\n\nHere beta=ForceConstant/MaxForce, alpha=MaxForce/beta.\n\nThe force for Hyperbolic and Erf is bounded by a user-defined value.\nThe GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable.\n\nMoving restraints are added for pairs of atoms that become connected during the transition.\n\nIt is intended to make sure the bonds are created as required.', gui_name='Bond making restraints:', default='Erf', choices=['None', 'Harmonic', 'Hyperbolic', 'Erf', 'GaussianWell']) self.Erf: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._Erf = self._Erf(name='Erf', comment='Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce.') self.GaussianWell: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._GaussianWell = self._GaussianWell(name='GaussianWell', comment='Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2).') self.Harmonic: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._Harmonic = self._Harmonic(name='Harmonic', comment='Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2.') self.Hyperbolic: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints._Hyperbolic = self._Hyperbolic(name='Hyperbolic', comment='Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta')
[docs] class _BondedRestraints(FixedBlock): r""" Define parameters for bonded restraints. A bonded restraint is added for each pair of atoms that are bonded both in the current and in the final state. It is intended to make sure they remain bonded during simulation. :ivar Type: Select type of the bonded restraints: Harmonic: V=0.5*FC*(r-r0)^2 A bonded restraint is added for each pair of atoms that are bonded both in the current and in the final state. It is intended to make sure they remain bonded during simulation. :vartype Type: Literal["None", "Harmonic"] :ivar Harmonic: Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :vartype Harmonic: AMS._MolecularDynamics._ReactionBoost._BondedRestraints._Harmonic """
[docs] class _Harmonic(FixedBlock): r""" Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :ivar ForceConstant: The FC parameter of the harmonic potential. :vartype ForceConstant: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The FC parameter of the harmonic potential.', default=0.5, unit='Hartree/Bohr^2')
def __post_init__(self): self.Type: Literal["None", "Harmonic"] = MultipleChoiceKey(name='Type', comment='Select type of the bonded restraints:\n\nHarmonic: V=0.5*FC*(r-r0)^2\n\nA bonded restraint is added for each pair of atoms that are bonded both in the current and in the final state.\n\nIt is intended to make sure they remain bonded during simulation.', gui_name='Bonded restraints:', default='None', choices=['None', 'Harmonic']) self.Harmonic: AMS._MolecularDynamics._ReactionBoost._BondedRestraints._Harmonic = self._Harmonic(name='Harmonic', comment='Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2.')
[docs] class _NonBondedRestraints(FixedBlock): r""" Define parameters for non-bonded restraints. A non-bonded restraint is added for each pair of atoms that are bonded neither in the current nor in the final state. It is intended to keep them from forming a bond unintentionally. They are represented by a repulsive potential :ivar Type: Select type of the non-bonded restraints: Exponential: V=Epsilon*exp(-Sigma*r) A non-bonded restraint is added for each pair of atoms that are bonded neither in the current nor in the final state. It is intended to keep them from forming a bond unintentionally. They are represented by a repulsive potential. :vartype Type: Literal["None", "Exponential"] :ivar Exponential: Define parameters for the repulsive potential V=Epsilon*exp(-Sigma*r). :vartype Exponential: AMS._MolecularDynamics._ReactionBoost._NonBondedRestraints._Exponential """
[docs] class _Exponential(FixedBlock): r""" Define parameters for the repulsive potential V=Epsilon*exp(-Sigma*r). :ivar Epsilon: Epsilon parameter in the repulsive potential expression. :vartype Epsilon: float | FloatKey :ivar Sigma: Sigma parameter in the repulsive potential expression. :vartype Sigma: float | FloatKey """ def __post_init__(self): self.Epsilon: float | FloatKey = FloatKey(name='Epsilon', comment='Epsilon parameter in the repulsive potential expression.', default=1.0, unit='Hartree') self.Sigma: float | FloatKey = FloatKey(name='Sigma', comment='Sigma parameter in the repulsive potential expression.', default=1.0, unit='1/Bohr')
def __post_init__(self): self.Type: Literal["None", "Exponential"] = MultipleChoiceKey(name='Type', comment='Select type of the non-bonded restraints:\n\nExponential: V=Epsilon*exp(-Sigma*r)\n\nA non-bonded restraint is added for each pair of atoms that are bonded neither in the current nor in the final state.\n\nIt is intended to keep them from forming a bond unintentionally. They are represented by a repulsive potential.', gui_name='Non-bonded restraints:', default='None', choices=['None', 'Exponential']) self.Exponential: AMS._MolecularDynamics._ReactionBoost._NonBondedRestraints._Exponential = self._Exponential(name='Exponential', comment='Define parameters for the repulsive potential V=Epsilon*exp(-Sigma*r).')
[docs] class _RMSDRestraint(FixedBlock): r""" Define a static restraint that pulls each atom to its position in the target system, but in contrast to the individual restraints, the force for this one depends on the total mass-weighted root-mean-squared distance (RMSD) between the two structures. :ivar Type: Select type of the RMSD restraint profile: Harmonic: V=0.5*FC*(r-r0)^2 Hyperbolic: V=alpha*(sqrt(1 + beta*x^2) - 1) Erf: V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI), GaussianWell: V=-WellDepth*exp(-Sigma*(r-r0)^2) Here beta=ForceConstant/MaxForce, alpha=MaxForce/beta. The Harmonic profile can be problematic at large deviations as it may result in large forces. The force for Hyperbolic and Erf is bounded by a user-defined value. The GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable. :vartype Type: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] :ivar Erf: Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :vartype Erf: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._Erf :ivar GaussianWell: Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :vartype GaussianWell: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._GaussianWell :ivar Harmonic: Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :vartype Harmonic: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._Harmonic :ivar Hyperbolic: Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :vartype Hyperbolic: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._Hyperbolic """
[docs] class _Erf(FixedBlock): r""" Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce. :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', default=0.05, unit='Hartree/Bohr')
[docs] class _GaussianWell(FixedBlock): r""" Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2). :ivar Sigma: Sigma parameter in the potential expression. :vartype Sigma: float | FloatKey :ivar WellDepth: WellDepth parameter in the potential expression. :vartype WellDepth: float | FloatKey """ def __post_init__(self): self.Sigma: float | FloatKey = FloatKey(name='Sigma', comment='Sigma parameter in the potential expression.', default=1.0, unit='1/Bohr^2') self.WellDepth: float | FloatKey = FloatKey(name='WellDepth', comment='WellDepth parameter in the potential expression.', default=1.0, unit='Hartree')
[docs] class _Harmonic(FixedBlock): r""" Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2. :ivar ForceConstant: The FC parameter of the harmonic potential. :vartype ForceConstant: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The FC parameter of the harmonic potential.', default=0.5, unit='Hartree/Bohr^2')
[docs] class _Hyperbolic(FixedBlock): r""" Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta :ivar ForceConstant: The force constant (second derivative of the potential) at the optimum point. :vartype ForceConstant: float | FloatKey :ivar MaxForce: Asymptotic value of the force at the infinity. :vartype MaxForce: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='The force constant (second derivative of the potential) at the optimum point.', default=0.5, unit='Hartree/Bohr^2') self.MaxForce: float | FloatKey = FloatKey(name='MaxForce', comment='Asymptotic value of the force at the infinity.', default=0.05, unit='Hartree/Bohr')
def __post_init__(self): self.Type: Literal["None", "Harmonic", "Hyperbolic", "Erf", "GaussianWell"] = MultipleChoiceKey(name='Type', comment='Select type of the RMSD restraint profile:\n\nHarmonic: V=0.5*FC*(r-r0)^2\n\nHyperbolic: V=alpha*(sqrt(1 + beta*x^2) - 1)\n\nErf: V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI),\n\nGaussianWell: V=-WellDepth*exp(-Sigma*(r-r0)^2)\n\nHere beta=ForceConstant/MaxForce, alpha=MaxForce/beta.\n\nThe Harmonic profile can be problematic at large deviations as it may result in large forces. The force for Hyperbolic and Erf is bounded by a user-defined value. The GaussianWell has a finite depth so it is suitable for cases when crossing a high reaction barrier is not desirable.', gui_name='Type:', default='None', choices=['None', 'Harmonic', 'Hyperbolic', 'Erf', 'GaussianWell']) self.Erf: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._Erf = self._Erf(name='Erf', comment='Define parameters for the Int(erf) potential V = alpha*(beta*x*erf(beta*x) + (exp(-(beta*x)**2) - 1)/sqrt(PI)). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce.') self.GaussianWell: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._GaussianWell = self._GaussianWell(name='GaussianWell', comment='Define parameters in the Gaussian well potential V=-WellDepth*exp(-Sigma*(r-r0)^2).') self.Harmonic: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._Harmonic = self._Harmonic(name='Harmonic', comment='Define parameters for the harmonic potential V=0.5*FC*(r-r0)^2.') self.Hyperbolic: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint._Hyperbolic = self._Hyperbolic(name='Hyperbolic', comment='Define parameters for the hyperbolic potential V=alpha*(sqrt(1 + beta*x^2) - 1). The alpha and beta parameters are computed from the user-defined ForceConstant and MaxForce: beta=ForceConstant/MaxForce, alpha=MaxForce/beta')
def __post_init__(self): self.Change: Literal["TargetCoordinate", "Force", "LogForce"] = MultipleChoiceKey(name='Change', comment="Select what to change during dynamics.\n\nBy default, once the restraints are switched on, AMS will change the restraint's target coordinate towards its final value.\n\nIf the [Force] or [LogForce] option is selected then the target coordinate is set to its final value immediately and instead the restraint force is gradually scaled from 0 to 1. The scaling is either linear (Force) or logarithmic (LogForce).", gui_name='Move type:', default='TargetCoordinate', choices=['TargetCoordinate', 'Force', 'LogForce']) self.InitialFraction: float | FloatKey = FloatKey(name='InitialFraction', comment="Initial fraction of the boost variable.\n\nAt the first boosting step, the restraint's target value (or force or log(force)) is equal to InitialFraction + 1/NSteps.", default=0.0) self.InterEquilibrationSteps: int | IntKey = IntKey(name='InterEquilibrationSteps', comment='Number of equilibration steps after reaching a target before setting up restraints for the next one.', default=0) self.MinBondChange: float | FloatKey = FloatKey(name='MinBondChange', comment='Minimal change in the distance for an individual restraint to be considered bond-breaking/making vs bonded.', default=1.0, unit='Bohr') self.MinBondStrength: float | FloatKey = FloatKey(name='MinBondStrength', comment='Minimum strength (usually ranges from 0 to 1) for a bond to be considered.', default=0.5) self.NSteps: int | IntKey = IntKey(name='NSteps', comment='Number of steps per target the restraints should be active for.', gui_name='Steps per target:', default=500) self.PreEquilibrationSteps: int | IntKey = IntKey(name='PreEquilibrationSteps', comment='Number of steps before enabling the first set of restraints.', default=0) self.Region: str | StringKey = StringKey(name='Region', comment='Region to which the restraints should be limited.', gui_name='Region:', default='*', gui_type='region') self.TargetSystem: str | StringKey = StringKey(name='TargetSystem', comment="The target system's name for this transition. Multiple targets can be specified to request multiple transitions in one simulation.\n\nNote that only the lattice and the atomic coordinates of the target system are used and other properties (bonds, charge, etc.) are ignored. The target system's lattice is used only to determine connections and it cannot be restrained.", unique=False, gui_name='Target system:', gui_type='molecule') self.Type: Literal["None", "Pair", "RMSD"] = MultipleChoiceKey(name='Type', comment='Reaction Boost uses a series of transitions between different states of the system.\nEach transition is defined by a TargetSystem and by a set of restraints that force the transition.\n\nSelect the type of the restraint set:\n-None: no Reaction Boost\n- Pair: use pair restraints\n- RMSD: use RMSD restraints.\n\nPair restraints are defined per atom pair while the RMSD defines one collective restraint for all atoms and is thus suitable for very large systems.\n\nThe pair restraints are further divided into four sub-types: bonding, non-bonding, bond-breaking and bond-making. The sub-type of restraints for each pair is determined automatically depending on whether the two atoms are bonded in the initial/final state.\n\nParameters of the pair restraints are defined by [NonBondedRestraints], [BondedRestraints], [BondBreakingRestraints] and [BondMakingRestraints] blocks, while those of the RMSD restraint by the [RMSDRestraint] block.', gui_name='Restraint set type:', default='None', choices=['None', 'Pair', 'RMSD']) self.BondBreakingRestraints: AMS._MolecularDynamics._ReactionBoost._BondBreakingRestraints = self._BondBreakingRestraints(name='BondBreakingRestraints', comment='Define parameters for moving restraints that are added for pairs of atoms that become disconnected during the transition.\n\nIt is intended to make sure the corresponding bonds get broken, although this may not always be required because forming other bonds will likely get these bonds broken.') self.BondMakingRestraints: AMS._MolecularDynamics._ReactionBoost._BondMakingRestraints = self._BondMakingRestraints(name='BondMakingRestraints', comment='Define parameters for moving restraints that are added for pairs of atoms that become connected during the transition.\n\nIt is intended to make sure the bonds are created as required.') self.BondedRestraints: AMS._MolecularDynamics._ReactionBoost._BondedRestraints = self._BondedRestraints(name='BondedRestraints', comment='Define parameters for bonded restraints. A bonded restraint is added for each pair of atoms that are bonded both in the current and in the final state.\n\nIt is intended to make sure they remain bonded during simulation.') self.NonBondedRestraints: AMS._MolecularDynamics._ReactionBoost._NonBondedRestraints = self._NonBondedRestraints(name='NonBondedRestraints', comment='Define parameters for non-bonded restraints. A non-bonded restraint is added for each pair of atoms that are bonded neither in the current nor in the final state.\n\nIt is intended to keep them from forming a bond unintentionally. They are represented by a repulsive potential') self.RMSDRestraint: AMS._MolecularDynamics._ReactionBoost._RMSDRestraint = self._RMSDRestraint(name='RMSDRestraint', comment='Define a static restraint that pulls each atom to its position in the target system, but in contrast to the individual restraints, the force for this one depends on the total mass-weighted root-mean-squared distance (RMSD) between the two structures.', gui_name='RMSD restraint:')
[docs] class _Reactor(FixedBlock): r""" Define one phase of the nanoreactor. A reactor is a region of space surrounded by an elastic wall. Atoms inside the region are not affected. Atoms outside it will be pushed back with force depending on the [ForceConstant] and the [MassScaled] flag. :ivar ForceConstant: Force constant of the reactor wall in Hartree/Bohr^2 (or Hartree/Bohr^2/Dalton if [MassScaled] is true). :vartype ForceConstant: float | FloatKey :ivar MassScaled: If this flag is disabled the force on an atom outside of the reactor depends only on the atomic coordinates and the force constant. Otherwise, the force is also multiplied by the mass of the atom. This means that atoms at the same distance from the wall will receive the same accelerate due to the wall potential. :vartype MassScaled: BoolType | BoolKey :ivar NSteps: Number of steps for which the reactor will remain active until disabled. The next reactor will be activated immediately after this. After the last reactor is disabled the cycle will repeat. :vartype NSteps: int | IntKey :ivar Radius: Radius of the reactor sphere. :vartype Radius: float | FloatKey """ def __post_init__(self): self.ForceConstant: float | FloatKey = FloatKey(name='ForceConstant', comment='Force constant of the reactor wall in Hartree/Bohr^2 (or Hartree/Bohr^2/Dalton if [MassScaled] is true).', gui_name='Reactor force constant:') self.MassScaled: BoolType | BoolKey = BoolKey(name='MassScaled', comment='If this flag is disabled the force on an atom outside of the reactor depends only on the atomic coordinates and the force constant. Otherwise, the force is also multiplied by the mass of the atom. This means that atoms at the same distance from the wall will receive the same accelerate due to the wall potential. ', gui_name='Scale force by mass:', default=True) self.NSteps: int | IntKey = IntKey(name='NSteps', comment='Number of steps for which the reactor will remain active until disabled. The next reactor will be activated immediately after this. After the last reactor is disabled the cycle will repeat.', gui_name='Reactor lifetime:') self.Radius: float | FloatKey = FloatKey(name='Radius', comment='Radius of the reactor sphere.', gui_name='Reactor radius:', unit='Angstrom')
[docs] class _ReflectiveWall(FixedBlock): r""" Apply a reflective wall in space :ivar Axis: Defines the normal vector perpendicular to the plane of the reflective wall. Any particle moving in this direction will be reflected back. :vartype Axis: Iterable[float] | FloatListKey :ivar Direction: Defines the direction of the reflective wall. under will keep the particles under the defined wall, and above will keep the particles above the defined wall :vartype Direction: Literal["under", "above"] :ivar Region: Apply the reflective wall to all atoms in this region. :vartype Region: str | StringKey :ivar Threshold: Defines the threshold value determining the position of the reflective wall. If the dot product of a position of a particle with Axis exceeds Threshold, the particle will be reflected. This means that the plane of the wall passes through a point given by Axis times Threshold. :vartype Threshold: float | FloatKey """ def __post_init__(self): self.Axis: Iterable[float] | FloatListKey = FloatListKey(name='Axis', comment='Defines the normal vector perpendicular to the plane of the reflective wall. Any particle moving in this direction will be reflected back.', unit='Angstrom', gui_type='nfloat 3') self.Direction: Literal["under", "above"] = MultipleChoiceKey(name='Direction', comment='Defines the direction of the reflective wall. under will keep the particles under the defined wall, and above will keep the particles above the defined wall', hidden=True, default='under', choices=['under', 'above']) self.Region: str | StringKey = StringKey(name='Region', comment='Apply the reflective wall to all atoms in this region.', unique=False, gui_type='region') self.Threshold: float | FloatKey = FloatKey(name='Threshold', comment='Defines the threshold value determining the position of the reflective wall. If the dot product of a position of a particle with Axis exceeds Threshold, the particle will be reflected. This means that the plane of the wall passes through a point given by Axis times Threshold.', unit='Angstrom')
[docs] class _Remap(FixedBlock): r""" Control periodic remapping (backtranslation) of atoms into the PBC box. :ivar Range: Select the range of fractional coordinates to which atoms are remapped. Auto: Use PlusMinusHalf if the geometrical center of the starting positions of all atoms lies between -0.25 and 0.25 in fractional coordinates in all periodic directions, ZeroToOne otherwise. PlusMinusHalf: Remap atoms to lie between -0.5 and 0.5 in fractional coordinates. ZeroToOne: Remap atoms to lie between 0 and 1 in fractional coordinates. AroundCenter: Remap atoms to lie within 0.5 in fractional coordinates around the geometrical center of the starting positions of all atoms. :vartype Range: Literal["Auto", "ZeroToOne", "PlusMinusHalf", "AroundCenter"] :ivar Type: Select the method used to remap atoms into the unit cell. None: Disable remapping completely. Atoms: Remap any atoms that leave the unit cell. :vartype Type: Literal["None", "Atoms"] """ def __post_init__(self): self.Range: Literal["Auto", "ZeroToOne", "PlusMinusHalf", "AroundCenter"] = MultipleChoiceKey(name='Range', comment='Select the range of fractional coordinates to which atoms are remapped.\n\nAuto: Use PlusMinusHalf if the geometrical center of the starting positions of all atoms lies between -0.25 and 0.25 in fractional coordinates in all periodic directions, ZeroToOne otherwise.\n\nPlusMinusHalf: Remap atoms to lie between -0.5 and 0.5 in fractional coordinates.\n\nZeroToOne: Remap atoms to lie between 0 and 1 in fractional coordinates.\n\nAroundCenter: Remap atoms to lie within 0.5 in fractional coordinates around the geometrical center of the starting positions of all atoms.', default='Auto', choices=['Auto', 'ZeroToOne', 'PlusMinusHalf', 'AroundCenter']) self.Type: Literal["None", "Atoms"] = MultipleChoiceKey(name='Type', comment='Select the method used to remap atoms into the unit cell.\n\nNone: Disable remapping completely.\n\nAtoms: Remap any atoms that leave the unit cell.', default='Atoms', choices=['None', 'Atoms'])
[docs] class _RemoveMolecules(FixedBlock): r""" This block controls removal of molecules from the system. Multiple occurrences of this block are possible. :ivar Formula: Molecular formula of the molecules that should be removed from the system. The order of elements in the formula is very important and the correct order is: C, H, all other elements in the strictly alphabetic order. Element names are case-sensitive, spaces in the formula are not allowed. Digit '1' must be omitted. Valid formula examples: C2H6O, H2O, O2S. Invalid formula examples: C2H5OH, H2O1, OH, SO2. Invalid formulas are silently ignored. Use * to remove any molecule, which must be combined with SinkBox or SafeBox. :vartype Formula: str | StringKey :ivar Frequency: The specified molecules are removed every so many steps after the StartStep. There is never a molecule removed at step 0. :vartype Frequency: int | IntKey :ivar StartStep: Step number when molecules are removed for the first time. After that, molecules are removed every [Frequency] steps. For example, if StartStep=99 and Frequency=100 then molecules will be removed at steps 99, 199, 299, etc... No molecule will be removed at step 0, so if StartStep=0 the first molecules are removed at the step number equal to [Frequency]. :vartype StartStep: int | IntKey :ivar StopStep: Do not remove the specified molecules after this step. :vartype StopStep: int | IntKey :ivar SafeBox: Part of the simulation box where molecules may not be removed. Only one of the SinkBox or SafeBox blocks may be present. If this block is present the molecule will not be removed if any of its atoms is within the box. For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom. :vartype SafeBox: AMS._MolecularDynamics._RemoveMolecules._SafeBox :ivar SinkBox: Part of the simulation box where matching molecules will be removed. By default, molecules matching the formula will be removed regardless of their location. If this block is present then such a molecule will only be removed if any of its atoms is within the box. For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom. :vartype SinkBox: AMS._MolecularDynamics._RemoveMolecules._SinkBox """
[docs] class _SafeBox(FixedBlock): r""" Part of the simulation box where molecules may not be removed. Only one of the SinkBox or SafeBox blocks may be present. If this block is present the molecule will not be removed if any of its atoms is within the box. For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom. :ivar Amax: Coordinate of the upper bound along the first axis. :vartype Amax: float | FloatKey :ivar Amin: Coordinate of the lower bound along the first axis. :vartype Amin: float | FloatKey :ivar Bmax: Coordinate of the upper bound along the second axis. :vartype Bmax: float | FloatKey :ivar Bmin: Coordinate of the lower bound along the second axis. :vartype Bmin: float | FloatKey :ivar Cmax: Coordinate of the upper bound along the third axis. :vartype Cmax: float | FloatKey :ivar Cmin: Coordinate of the lower bound along the third axis. :vartype Cmin: float | FloatKey :ivar FractionalCoordsBox: Do not remove molecules that are (partly) inside the safe box. Borders of the safe box specified as: Amin, Amax, Bmin, Bmax, Cmin, Cmax. For periodic dimensions fractional coordinates between 0 and 1 and for non-periodic dimensions Cartesian values in Angstrom are expected. :vartype FractionalCoordsBox: Iterable[float] | FloatListKey """ def __post_init__(self): self.Amax: float | FloatKey = FloatKey(name='Amax', comment='Coordinate of the upper bound along the first axis.') self.Amin: float | FloatKey = FloatKey(name='Amin', comment='Coordinate of the lower bound along the first axis.') self.Bmax: float | FloatKey = FloatKey(name='Bmax', comment='Coordinate of the upper bound along the second axis.') self.Bmin: float | FloatKey = FloatKey(name='Bmin', comment='Coordinate of the lower bound along the second axis.') self.Cmax: float | FloatKey = FloatKey(name='Cmax', comment='Coordinate of the upper bound along the third axis.') self.Cmin: float | FloatKey = FloatKey(name='Cmin', comment='Coordinate of the lower bound along the third axis.') self.FractionalCoordsBox: Iterable[float] | FloatListKey = FloatListKey(name='FractionalCoordsBox', comment='Do not remove molecules that are (partly) inside the safe box.\n\nBorders of the safe box specified as: Amin, Amax, Bmin, Bmax, Cmin, Cmax.\n\nFor periodic dimensions fractional coordinates between 0 and 1 and for non-periodic dimensions Cartesian values in Angstrom are expected.', gui_name='Safe box:', gui_type='nfloat 6')
[docs] class _SinkBox(FixedBlock): r""" Part of the simulation box where matching molecules will be removed. By default, molecules matching the formula will be removed regardless of their location. If this block is present then such a molecule will only be removed if any of its atoms is within the box. For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom. :ivar Amax: Coordinate of the upper bound along the first axis. :vartype Amax: float | FloatKey :ivar Amin: Coordinate of the lower bound along the first axis. :vartype Amin: float | FloatKey :ivar Bmax: Coordinate of the upper bound along the second axis. :vartype Bmax: float | FloatKey :ivar Bmin: Coordinate of the lower bound along the second axis. :vartype Bmin: float | FloatKey :ivar Cmax: Coordinate of the upper bound along the third axis. :vartype Cmax: float | FloatKey :ivar Cmin: Coordinate of the lower bound along the third axis. :vartype Cmin: float | FloatKey :ivar FractionalCoordsBox: Remove molecules that are (partly) inside the sink box. Borders of the sink box specified as: Amin, Amax, Bmin, Bmax, Cmin, Cmax. For periodic dimensions fractional coordinates between 0 and 1 and for non-periodic dimensions Cartesian values in Angstrom are expected. :vartype FractionalCoordsBox: Iterable[float] | FloatListKey """ def __post_init__(self): self.Amax: float | FloatKey = FloatKey(name='Amax', comment='Coordinate of the upper bound along the first axis.') self.Amin: float | FloatKey = FloatKey(name='Amin', comment='Coordinate of the lower bound along the first axis.') self.Bmax: float | FloatKey = FloatKey(name='Bmax', comment='Coordinate of the upper bound along the second axis.') self.Bmin: float | FloatKey = FloatKey(name='Bmin', comment='Coordinate of the lower bound along the second axis.') self.Cmax: float | FloatKey = FloatKey(name='Cmax', comment='Coordinate of the upper bound along the third axis.') self.Cmin: float | FloatKey = FloatKey(name='Cmin', comment='Coordinate of the lower bound along the third axis.') self.FractionalCoordsBox: Iterable[float] | FloatListKey = FloatListKey(name='FractionalCoordsBox', comment='Remove molecules that are (partly) inside the sink box.\n\nBorders of the sink box specified as: Amin, Amax, Bmin, Bmax, Cmin, Cmax.\n\nFor periodic dimensions fractional coordinates between 0 and 1 and for non-periodic dimensions Cartesian values in Angstrom are expected.', gui_name='Sink box:', gui_type='nfloat 6')
def __post_init__(self): self.Formula: str | StringKey = StringKey(name='Formula', comment="Molecular formula of the molecules that should be removed from the system. \n\nThe order of elements in the formula is very important and the correct order is: C, H, all other elements in the strictly alphabetic order. \nElement names are case-sensitive, spaces in the formula are not allowed. Digit '1' must be omitted. \n\nValid formula examples: C2H6O, H2O, O2S. Invalid formula examples: C2H5OH, H2O1, OH, SO2. Invalid formulas are silently ignored. \n\nUse * to remove any molecule, which must be combined with SinkBox or SafeBox.") self.Frequency: int | IntKey = IntKey(name='Frequency', comment='The specified molecules are removed every so many steps after the StartStep. There is never a molecule removed at step 0.', default=0) self.StartStep: int | IntKey = IntKey(name='StartStep', comment='Step number when molecules are removed for the first time. After that, molecules are removed every [Frequency] steps.\n\nFor example, if StartStep=99 and Frequency=100 then molecules will be removed at steps 99, 199, 299, etc...\n\nNo molecule will be removed at step 0, so if StartStep=0 the first molecules are removed at the step number equal to [Frequency].', default=0) self.StopStep: int | IntKey = IntKey(name='StopStep', comment='Do not remove the specified molecules after this step.') self.SafeBox: AMS._MolecularDynamics._RemoveMolecules._SafeBox = self._SafeBox(name='SafeBox', comment='Part of the simulation box where molecules may not be removed. Only one of the SinkBox or SafeBox blocks may be present. If this block is present the molecule will not be removed if any of its atoms is within the box. For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom.') self.SinkBox: AMS._MolecularDynamics._RemoveMolecules._SinkBox = self._SinkBox(name='SinkBox', comment='Part of the simulation box where matching molecules will be removed. By default, molecules matching the formula will be removed regardless of their location. If this block is present then such a molecule will only be removed if any of its atoms is within the box. For a periodic dimension it is given as a fraction of the simulation box (the full 0 to 1 range by default). For a non-periodic dimension it represents absolute Cartesian coordinates in Angstrom.')
[docs] class _ReplicaExchange(FixedBlock): r""" This block is used for (temperature) Replica Exchange MD (Parallel Tempering) simulations. :ivar AllowWrongResults: Allow combining Replica Exchange with other features when the combination is known to produce physically incorrect results. :vartype AllowWrongResults: BoolType | BoolKey :ivar EWMALength: Length of the exponentially weighted moving average used to smooth swap probabilities for monitoring. This value is equal to the inverse of the EWMA mixing factor. :vartype EWMALength: int | IntKey :ivar SwapFrequency: Attempt an exchange every N steps. :vartype SwapFrequency: int | IntKey :ivar TemperatureFactors: This is the ratio of the temperatures of two successive replicas. The first value sets the temperature of the second replica with respect to the first replica, the second value sets the temperature of the third replica with respect to the second one, and so on. If there are fewer values than nReplicas, the last value of TemperatureFactor is used for all the remaining replicas. :vartype TemperatureFactors: Iterable[float] | FloatListKey :ivar Temperatures: List of temperatures for all replicas except for the first one. This is mutually exclusive with TemperatureFactors. Exactly nReplicas-1 temperature values need to be specified, in increasing order. The temperature of the first replica is given by [Thermostat%Temperature]. :vartype Temperatures: Iterable[float] | FloatListKey :ivar nReplicas: Number of replicas to run in parallel. :vartype nReplicas: int | IntKey """ def __post_init__(self): self.AllowWrongResults: BoolType | BoolKey = BoolKey(name='AllowWrongResults', comment='Allow combining Replica Exchange with other features when the combination is known to produce physically incorrect results.', default=False) self.EWMALength: int | IntKey = IntKey(name='EWMALength', comment='Length of the exponentially weighted moving average used to smooth swap probabilities for monitoring.\n\nThis value is equal to the inverse of the EWMA mixing factor.', default=10) self.SwapFrequency: int | IntKey = IntKey(name='SwapFrequency', comment='Attempt an exchange every N steps.', default=100) self.TemperatureFactors: Iterable[float] | FloatListKey = FloatListKey(name='TemperatureFactors', comment='This is the ratio of the temperatures of two successive replicas. \n\nThe first value sets the temperature of the second replica with respect to the first replica, the second value sets the temperature of the third replica with respect to the second one, and so on. If there are fewer values than nReplicas, the last value of TemperatureFactor is used for all the remaining replicas.') self.Temperatures: Iterable[float] | FloatListKey = FloatListKey(name='Temperatures', comment='List of temperatures for all replicas except for the first one. \n\nThis is mutually exclusive with TemperatureFactors. Exactly nReplicas-1 temperature values need to be specified, in increasing order. The temperature of the first replica is given by [Thermostat%Temperature].') self.nReplicas: int | IntKey = IntKey(name='nReplicas', comment='Number of replicas to run in parallel.', gui_name='Number of replicas:', default=1)
[docs] class _Shake(FixedBlock): r""" Parameters of the Shake/Rattle algorithm. :ivar All: Constraint description in one the following formats: All [bondOrder] bonds at1 at2 [to distance] All triangles at1 at2 at3 The first option constrains all bonds between atoms at1 at2 to a certain length, while the second - bonds at1-at2 and at2-at3 and the angle between them. The [bondOrder] can be a number or a string such as single, double, triple or aromatic. If it's omitted then all bonds between specified atoms will be constrained. Atom names are case-sensitive and they must be as they are in the Atoms block, or an asterisk '*' denoting any atom. The distance, if present, must be in Angstrom. If it is omitted then the bond length from the initial geometry is used. Important: only the bonds present in the system at certain points of the simulation (at the start or right after adding/removing atoms) can be constrained, which means that the bonds may need to be specified in the System block. Warning: the triangles constraint should be used with care because each constrained bond or angle means removing one degree of freedom from the dynamics. When there are too many constraints (for example, "All triangles H C H" in methane) some of them may be linearly dependent, which will lead to an error in the temperature computation. Valid examples: All single bonds C C to 1.4 All bonds O H to 0.98 All bonds O H All bonds H * All triangles H * H :vartype All: str | StringKey :ivar ConvergeR2: Convergence criterion on the max squared difference, in atomic units. :vartype ConvergeR2: float | FloatKey :ivar ConvergeRV: Convergence criterion on the orthogonality of the constraint and the relative atomic velocity, in atomic units. :vartype ConvergeRV: float | FloatKey :ivar Iterations: Number of iterations. :vartype Iterations: int | IntKey :ivar ShakeInitialCoordinates: Apply constraints before computing the first energy and gradients. :vartype ShakeInitialCoordinates: BoolType | BoolKey """ def __post_init__(self): self.All: str | StringKey = StringKey(name='All', comment='Constraint description in one the following formats: \nAll [bondOrder] bonds at1 at2 [to distance]\nAll triangles at1 at2 at3\n\nThe first option constrains all bonds between atoms at1 at2 to a certain length, while the second - bonds at1-at2 and at2-at3 and the angle between them.\n\nThe [bondOrder] can be a number or a string such as single, double, triple or aromatic. If it\'s omitted then all bonds between specified atoms will be constrained. Atom names are case-sensitive and they must be as they are in the Atoms block, or an asterisk \'*\' denoting any atom. The distance, if present, must be in Angstrom. If it is omitted then the bond length from the initial geometry is used.\n\nImportant: only the bonds present in the system at certain points of the simulation (at the start or right after adding/removing atoms) can be constrained, which means that the bonds may need to be specified in the System block.\n\nWarning: the triangles constraint should be used with care because each constrained bond or angle means removing one degree of freedom from the dynamics. When there are too many constraints (for example, "All triangles H C H" in methane) some of them may be linearly dependent, which will lead to an error in the temperature computation. \n\nValid examples:\nAll single bonds C C to 1.4\nAll bonds O H to 0.98\nAll bonds O H\nAll bonds H *\nAll triangles H * H', unique=False, gui_name='Constrain all:') self.ConvergeR2: float | FloatKey = FloatKey(name='ConvergeR2', comment='Convergence criterion on the max squared difference, in atomic units.', default=1e-08) self.ConvergeRV: float | FloatKey = FloatKey(name='ConvergeRV', comment='Convergence criterion on the orthogonality of the constraint and the relative atomic velocity, in atomic units.', default=1e-08) self.Iterations: int | IntKey = IntKey(name='Iterations', comment='Number of iterations.', default=100) self.ShakeInitialCoordinates: BoolType | BoolKey = BoolKey(name='ShakeInitialCoordinates', comment='Apply constraints before computing the first energy and gradients.', default=True)
[docs] class _Thermostat(FixedBlock): r""" This block allows to specify the use of a thermostat during the simulation. Depending on the selected thermostat type, different additional options may be needed to characterize the specific thermostat's behavior. :ivar BerendsenApply: Select how to apply the scaling correction for the Berendsen thermostat: - per-atom-velocity (Local) - on the molecular system as a whole (Global). :vartype BerendsenApply: Literal["Local", "Global"] :ivar ChainLength: Number of individual thermostats forming the NHC thermostat :vartype ChainLength: int | IntKey :ivar Duration: Specifies how many steps should a transition from a particular temperature to the next one in sequence take. :vartype Duration: Iterable[int] | IntListKey :ivar ExcludedDirection: Exclude a component of the velocities from rescaling by the thermostat. For example in NEMD simulations, when a shear force/velocity is applied in the x direction, the x-direction is often excluded from thermostatting. This currently only works for the Nose-Hoover thermostat. :vartype ExcludedDirection: Literal["None", "X", "Y", "Z"] :ivar Friction: Friction coefficient used in langevin dynamics :vartype Friction: float | FloatKey :ivar Region: The identifier of the region to thermostat. The default `*` applies the thermostat to the entire system. The value can by a plain region name, or a region expression, e.g. `*-myregion` to thermostat all atoms that are not in myregion, or `regionA+regionB` to thermostat the union of the 'regionA' and 'regionB'. Note that if multiple thermostats are used, their regions may not overlap. :vartype Region: str | StringKey :ivar ScaleFrequency: Optional parameter used only by the Scale thermostat. If specified, the thermostat will be applied every N steps, using that step's ensemble temperature and the specified thermostat temperature to compute the scaling factor. If not specified, the thermostat will be applied at every step, using the mean temperature of the ensemble and the specified thermostat temperature to compute the scaling factor. :vartype ScaleFrequency: int | IntKey :ivar Tau: The time constant of the thermostat. :vartype Tau: float | FloatKey :ivar Temperature: The target temperature of the thermostat. You can specify multiple temperatures (separated by spaces). In that case the Duration field specifies how many steps to use for the transition from one T to the next T (using a linear ramp). For NHC thermostat, the temperature may not be zero. :vartype Temperature: Iterable[float] | FloatListKey :ivar Type: Selects the type of the thermostat. :vartype Type: Literal["None", "Scale", "Berendsen", "NHC", "Langevin"] """ def __post_init__(self): self.BerendsenApply: Literal["Local", "Global"] = MultipleChoiceKey(name='BerendsenApply', comment='Select how to apply the scaling correction for the Berendsen thermostat:\n\n- per-atom-velocity (Local)\n- on the molecular system as a whole (Global).', gui_name='Apply Berendsen:', default='Global', choices=['Local', 'Global']) self.ChainLength: int | IntKey = IntKey(name='ChainLength', comment='Number of individual thermostats forming the NHC thermostat', gui_name='NHC chain length:', default=10) self.Duration: Iterable[int] | IntListKey = IntListKey(name='Duration', comment='Specifies how many steps should a transition from a particular temperature to the next one in sequence take.', gui_name='Duration(s)') self.ExcludedDirection: Literal["None", "X", "Y", "Z"] = MultipleChoiceKey(name='ExcludedDirection', comment='Exclude a component of the velocities from rescaling by the thermostat. For example in NEMD simulations, when a shear force/velocity is applied in the x direction, the x-direction is often excluded from thermostatting. This currently only works for the Nose-Hoover thermostat.', hidden=True, default='None', choices=['None', 'X', 'Y', 'Z']) self.Friction: float | FloatKey = FloatKey(name='Friction', comment='Friction coefficient used in langevin dynamics', hidden=True, default=1.0) self.Region: str | StringKey = StringKey(name='Region', comment="The identifier of the region to thermostat. The default `*` applies the thermostat to the entire system. The value can by a plain region name, or a region expression, e.g. `*-myregion` to thermostat all atoms that are not in myregion, or `regionA+regionB` to thermostat the union of the 'regionA' and 'regionB'. Note that if multiple thermostats are used, their regions may not overlap.", default='*', gui_type='region') self.ScaleFrequency: int | IntKey = IntKey(name='ScaleFrequency', comment="Optional parameter used only by the Scale thermostat.\n\nIf specified, the thermostat will be applied every N steps, using that step's ensemble temperature and the specified thermostat temperature to compute the scaling factor.\n\nIf not specified, the thermostat will be applied at every step, using the mean temperature of the ensemble and the specified thermostat temperature to compute the scaling factor.", hidden=True) self.Tau: float | FloatKey = FloatKey(name='Tau', comment='The time constant of the thermostat.', gui_name='Damping constant:', unit='Femtoseconds') self.Temperature: Iterable[float] | FloatListKey = FloatListKey(name='Temperature', comment='The target temperature of the thermostat.\n\nYou can specify multiple temperatures (separated by spaces). In that case the Duration field specifies how many steps to use for the transition from one T to the next T (using a linear ramp). For NHC thermostat, the temperature may not be zero.', gui_name='Temperature(s)', unit='Kelvin') self.Type: Literal["None", "Scale", "Berendsen", "NHC", "Langevin"] = MultipleChoiceKey(name='Type', comment='Selects the type of the thermostat.', gui_name='Thermostat:', default='None', choices=['None', 'Scale', 'Berendsen', 'NHC', 'Langevin'], hiddenchoices=['Scale', 'Langevin'])
[docs] class _Trajectory(FixedBlock): r""" Sets the frequency for printing to stdout and storing the molecular configuration on the .rkf file. :ivar EngineResultsFreq: Write MDStep*.rkf files with engine-specific results once every N steps. Setting this to zero disables writing engine results files except for one file at the end of the simulation. If unset or negative, defaults to the value of Checkpoint%Frequency. :vartype EngineResultsFreq: int | IntKey :ivar ExitConditionFreq: Check the exit conditions every N steps. By default this is done every SamplingFreq steps. :vartype ExitConditionFreq: int | IntKey :ivar PrintFreq: Print current thermodynamic properties to the output every N steps. By default this is done every SamplingFreq steps. :vartype PrintFreq: int | IntKey :ivar SamplingFreq: Write the molecular geometry (and possibly other properties) to the ams.rkf file once every N steps. :vartype SamplingFreq: int | IntKey :ivar TProfileGridPoints: Number of points in the temperature profile. If TProfileGridPoints > 0, a temperature profile along each of the three lattice axes will be written to the .rkf file. The temperature at a given profile point is calculated as the total temperature of all atoms inside the corresponding slice of the simulation box, time-averaged over all MD steps since the previous snapshot.​ By default, no profile is generated. :vartype TProfileGridPoints: int | IntKey :ivar WriteBonds: Write detected bonds to the .rkf file. :vartype WriteBonds: BoolType | BoolKey :ivar WriteCharges: Write current atomic point charges (if available) to the .rkf file. Disable this to reduce trajectory size if you do not need to analyze charges. :vartype WriteCharges: BoolType | BoolKey :ivar WriteCoordinates: Write atomic coordinates to the .rkf file. :vartype WriteCoordinates: BoolType | BoolKey :ivar WriteEngineGradients: Write atomic gradients (negative of the atomic forces, as calculated by the engine) to the History section of ams.rkf. :vartype WriteEngineGradients: BoolType | BoolKey :ivar WriteMolecules: Write the results of molecule analysis to the .rkf file. :vartype WriteMolecules: BoolType | BoolKey :ivar WriteVelocities: Write velocities to the .rkf file. Disable this to reduce trajectory size if you do not need to analyze the velocities. :vartype WriteVelocities: BoolType | BoolKey """ def __post_init__(self): self.EngineResultsFreq: int | IntKey = IntKey(name='EngineResultsFreq', comment='Write MDStep*.rkf files with engine-specific results once every N steps. Setting this to zero disables writing engine results files except for one file at the end of the simulation. If unset or negative, defaults to the value of Checkpoint%Frequency.', gui_name='Engine results frequency:') self.ExitConditionFreq: int | IntKey = IntKey(name='ExitConditionFreq', comment='Check the exit conditions every N steps. By default this is done every SamplingFreq steps.', gui_name='Exit condition frequency:') self.PrintFreq: int | IntKey = IntKey(name='PrintFreq', comment='Print current thermodynamic properties to the output every N steps. By default this is done every SamplingFreq steps.', gui_name='Printing frequency:') self.SamplingFreq: int | IntKey = IntKey(name='SamplingFreq', comment='Write the molecular geometry (and possibly other properties) to the ams.rkf file once every N steps.', gui_name='Sample frequency:', default=100) self.TProfileGridPoints: int | IntKey = IntKey(name='TProfileGridPoints', comment='Number of points in the temperature profile. If TProfileGridPoints > 0, a temperature profile along each of the three lattice axes will be written to the .rkf file. The temperature at a given profile point is calculated as the total temperature of all atoms inside the corresponding slice of the simulation box, time-averaged over all MD steps since the previous snapshot.\u200b By default, no profile is generated.', default=0) self.WriteBonds: BoolType | BoolKey = BoolKey(name='WriteBonds', comment='Write detected bonds to the .rkf file.', default=True) self.WriteCharges: BoolType | BoolKey = BoolKey(name='WriteCharges', comment='Write current atomic point charges (if available) to the .rkf file. Disable this to reduce trajectory size if you do not need to analyze charges.', default=True) self.WriteCoordinates: BoolType | BoolKey = BoolKey(name='WriteCoordinates', comment='Write atomic coordinates to the .rkf file.', default=True) self.WriteEngineGradients: BoolType | BoolKey = BoolKey(name='WriteEngineGradients', comment='Write atomic gradients (negative of the atomic forces, as calculated by the engine) to the History section of ams.rkf.', default=False) self.WriteMolecules: BoolType | BoolKey = BoolKey(name='WriteMolecules', comment='Write the results of molecule analysis to the .rkf file.', default=True) self.WriteVelocities: BoolType | BoolKey = BoolKey(name='WriteVelocities', comment='Write velocities to the .rkf file. Disable this to reduce trajectory size if you do not need to analyze the velocities.', default=True)
[docs] class _fbMC(FixedBlock): r""" This block sets up force bias Monte Carlo interleaved with the molecular dynamics simulation. :ivar Frequency: Run the fbMC procedure every Frequency MD steps. :vartype Frequency: int | IntKey :ivar MassRoot: Inverse of the exponent used to mass-weight fbMC steps. :vartype MassRoot: float | FloatKey :ivar NSteps: Number of fbMC steps to perform on every invocation of the procedure. :vartype NSteps: int | IntKey :ivar PrintFreq: Print current thermodynamic properties to the output every N fbMC steps. This defaults to the PrintFreq set in the Trajectory block. Setting this to zero disables printing fbMC steps. :vartype PrintFreq: int | IntKey :ivar StartStep: First step at which the fbMC procedure may run. :vartype StartStep: int | IntKey :ivar StepLength: Maximum allowed displacement of the lightest atom in the system in each Cartesian coordinate in one fbMC step. :vartype StepLength: float | FloatKey :ivar StopStep: Last step at which the fbMC procedure may run. If unset or zero, there is no limit. :vartype StopStep: int | IntKey :ivar Temperature: Temperature used for fbMC. :vartype Temperature: float | FloatKey :ivar MolecularMoves: Move molecules as rigid bodies in addition to normal atomic moves. :vartype MolecularMoves: AMS._MolecularDynamics._fbMC._MolecularMoves """
[docs] class _MolecularMoves(FixedBlock): r""" Move molecules as rigid bodies in addition to normal atomic moves. :ivar Enabled: Enable moving molecules as rigid bodies based on net forces and torques. Ordinary per-atom displacements will then be based on residual atomic forces. :vartype Enabled: BoolType | BoolKey :ivar RotationMethod: Select the fbMC method used to generate molecular rotation moves. :vartype RotationMethod: Literal["Mees", "Rao"] :ivar RotationStepAngle: Maximum allowed angle of rotation of each molecule in one fbMC step. :vartype RotationStepAngle: float | FloatKey :ivar TranslationStepLength: Maximum allowed displacement of each molecule in each Cartesian coordinate in one fbMC step. :vartype TranslationStepLength: float | FloatKey """ def __post_init__(self): self.Enabled: BoolType | BoolKey = BoolKey(name='Enabled', comment='Enable moving molecules as rigid bodies based on net forces and torques. Ordinary per-atom displacements will then be based on residual atomic forces.', gui_name='Enable molecular moves', default=False) self.RotationMethod: Literal["Mees", "Rao"] = MultipleChoiceKey(name='RotationMethod', comment='Select the fbMC method used to generate molecular rotation moves.', hidden=True, default='Mees', choices=['Mees', 'Rao']) self.RotationStepAngle: float | FloatKey = FloatKey(name='RotationStepAngle', comment='Maximum allowed angle of rotation of each molecule in one fbMC step.', default=0.1, unit='Radian') self.TranslationStepLength: float | FloatKey = FloatKey(name='TranslationStepLength', comment='Maximum allowed displacement of each molecule in each Cartesian coordinate in one fbMC step.', default=0.1, unit='Angstrom')
def __post_init__(self): self.Frequency: int | IntKey = IntKey(name='Frequency', comment='Run the fbMC procedure every Frequency MD steps.', default=1) self.MassRoot: float | FloatKey = FloatKey(name='MassRoot', comment='Inverse of the exponent used to mass-weight fbMC steps.', default=2.0) self.NSteps: int | IntKey = IntKey(name='NSteps', comment='Number of fbMC steps to perform on every invocation of the procedure.', gui_name='Number of steps:') self.PrintFreq: int | IntKey = IntKey(name='PrintFreq', comment='Print current thermodynamic properties to the output every N fbMC steps. This defaults to the PrintFreq set in the Trajectory block. Setting this to zero disables printing fbMC steps.', gui_name='Printing frequency:') self.StartStep: int | IntKey = IntKey(name='StartStep', comment='First step at which the fbMC procedure may run.', default=1) self.StepLength: float | FloatKey = FloatKey(name='StepLength', comment='Maximum allowed displacement of the lightest atom in the system in each Cartesian coordinate in one fbMC step.', default=0.1, unit='Angstrom') self.StopStep: int | IntKey = IntKey(name='StopStep', comment='Last step at which the fbMC procedure may run. If unset or zero, there is no limit.', default=0) self.Temperature: float | FloatKey = FloatKey(name='Temperature', comment='Temperature used for fbMC.', unit='Kelvin') self.MolecularMoves: AMS._MolecularDynamics._fbMC._MolecularMoves = self._MolecularMoves(name='MolecularMoves', comment='Move molecules as rigid bodies in addition to normal atomic moves.')
def __post_init__(self): self.CalcPressure: BoolType | BoolKey = BoolKey(name='CalcPressure', comment='Calculate the pressure in periodic systems.\n\nThis may be computationally expensive for some engines that require numerical differentiation.\n\nSome other engines can calculate the pressure for negligible additional cost and will always do so, even if this option is disabled.', gui_name='Calculate pressure:', default=False) self.CopyRestartTrajectory: BoolType | BoolKey = BoolKey(name='CopyRestartTrajectory', comment='If the keyword Restart is present, the content of the restartfile is copied to the ams.rkf file.', default=False) self.NSteps: int | IntKey = IntKey(name='NSteps', comment='The number of steps to be taken in the MD simulation.', gui_name='Number of steps:', default=1000) self.Restart: str | Path | StringKey = PathStringKey(name='Restart', comment='The path to the ams.rkf file from which to restart the simulation.', gui_name='Restart from:', ispath=True, gui_type='.rkf {{{AMS result file} .rkf}}') self.TimeStep: float | FloatKey = FloatKey(name='TimeStep', comment='The time difference per step.', default=0.25, unit='Femtoseconds') self.AddMolecules: AMS._MolecularDynamics._AddMolecules = self._AddMolecules(name='AddMolecules', comment='This block controls adding molecules to the system (a.k.a. the Molecule Gun). Multiple occurrences of this block are possible.\n\nBy default, molecules are added at random positions in the simulation box with velocity matching the current system temperature. The initial position can be modified using one of the following keywords: Coords, CoordsBox, FractionalCoords, FractionalCoordsBox. The Coords and FractionalCoords keys can optionally be accompanied by CoordsSigma or FractionalCoordsSigma, respectively.', unique=False, gui_name='Add molecules') self.ApplyForce: AMS._MolecularDynamics._ApplyForce = self._ApplyForce(name='ApplyForce', comment='The ApplyForce keyword can be used to apply an arbitrary constant force to a certain (subgroups of) atoms in the system', unique=False) self.ApplyVelocity: AMS._MolecularDynamics._ApplyVelocity = self._ApplyVelocity(name='ApplyVelocity', comment='The ApplyVelocity keyword can be used to move an arbitrary group of atoms in the system with a constant net velocity', unique=False) self.Barostat: AMS._MolecularDynamics._Barostat = self._Barostat(name='Barostat', comment='This block allows to specify the use of a barostat during the simulation.') self.BinLog: AMS._MolecularDynamics._BinLog = self._BinLog(name='BinLog', comment='This block controls writing the BinLog section in ams.rkf, which contains the selected MD state scalars and tensors from every MD step. No per-atom data is written. If you need the per-atom data then you can set the sampling frequency to 1 and get the required data from the MDHistory section. The tensors are written per component, that is, the pressure tensor is written as six variables: PressureTensor_xx, PressureTensor_yy, etc.. To reduce the file size, all data is written in blocks.') self.BondBoost: AMS._MolecularDynamics._BondBoost = self._BondBoost(name='BondBoost', comment='Forced reaction (bond boost) definitions. Multiple BondBoost blocks may be specified, which will be treated independently. ', unique=False) self.CRESTMTD: AMS._MolecularDynamics._CRESTMTD = self._CRESTMTD(name='CRESTMTD', comment='Input for CREST metadynamics simulation. ', gui_name='CREST_MTD') self.CVHD: AMS._MolecularDynamics._CVHD = self._CVHD(name='CVHD', comment='Input for the Collective Variable-driven HyperDynamics (CVHD). ', unique=False, gui_name='CVHD') self.CheckTemperature: AMS._MolecularDynamics._CheckTemperature = self._CheckTemperature(name='CheckTemperature', comment='Check at every time step if the temperature has exceeded a threshold. If it has, it is assumed the system exploded, and the simulation will stop.') self.Checkpoint: AMS._MolecularDynamics._Checkpoint = self._Checkpoint(name='Checkpoint', comment='Sets the frequency for storing the entire MD state necessary for restarting the calculation.') self.CosineShear: AMS._MolecularDynamics._CosineShear = self._CosineShear(name='CosineShear', comment='Apply an external acceleration to all atoms of a fluid using a periodic (cosine) function along a selected coordinate axis. This induces a periodic shear flow profile which can be used to determine the viscosity.') self.Deformation: AMS._MolecularDynamics._Deformation = self._Deformation(name='Deformation', comment='Deform the periodic lattice of the system during the simulation.', unique=False) self.Gravity: AMS._MolecularDynamics._Gravity = self._Gravity(name='Gravity', comment='Apply a constant acceleration in -z.') self.HeatExchange: AMS._MolecularDynamics._HeatExchange = self._HeatExchange(name='HeatExchange', comment='Input for the heat-exchange non-equilibrium MD (T-NEMD).', unique=False, gui_name='Heat exchange') self.InitialVelocities: AMS._MolecularDynamics._InitialVelocities = self._InitialVelocities(name='InitialVelocities', comment='Sets the frequency for printing to stdout and storing the molecular configuration on the .rkf file.') self.MovingRestraints: AMS._MolecularDynamics._MovingRestraints = self._MovingRestraints(name='MovingRestraints', comment='Define a set of moving restraints.', unique=False) self.PRD: AMS._MolecularDynamics._PRD = self._PRD(name='PRD', comment='This block is used for Parallel Replica Dynamics simulations.', hidden=True) self.Plumed: AMS._MolecularDynamics._Plumed = self._Plumed(name='Plumed', comment='Input for PLUMED (version 2.5.0). The parallel option is still experimental.') self.Preserve: AMS._MolecularDynamics._Preserve = self._Preserve(name='Preserve', comment='Periodically remove numerical drift accumulated during the simulation to preserve different whole-system parameters.') self.Print: AMS._MolecularDynamics._Print = self._Print(name='Print', comment='This block controls the printing of additional information to stdout.') self.ReactionBoost: AMS._MolecularDynamics._ReactionBoost = self._ReactionBoost(name='ReactionBoost', comment='Define a series of transitions between different states of the system.\n\nEach transition is defined by a TargetSystem and by a set of restraints that force the transition.', gui_name='Reaction Boost') self.Reactor: AMS._MolecularDynamics._Reactor = self._Reactor(name='Reactor', comment='Define one phase of the nanoreactor. A reactor is a region of space surrounded by an elastic wall. Atoms inside the region are not affected. Atoms outside it will be pushed back with force depending on the [ForceConstant] and the [MassScaled] flag. ', unique=False) self.ReflectiveWall: AMS._MolecularDynamics._ReflectiveWall = self._ReflectiveWall(name='ReflectiveWall', comment='Apply a reflective wall in space', unique=False) self.Remap: AMS._MolecularDynamics._Remap = self._Remap(name='Remap', comment='Control periodic remapping (backtranslation) of atoms into the PBC box.') self.RemoveMolecules: AMS._MolecularDynamics._RemoveMolecules = self._RemoveMolecules(name='RemoveMolecules', comment='This block controls removal of molecules from the system. Multiple occurrences of this block are possible.', unique=False, gui_name='Remove molecules') self.ReplicaExchange: AMS._MolecularDynamics._ReplicaExchange = self._ReplicaExchange(name='ReplicaExchange', comment='This block is used for (temperature) Replica Exchange MD (Parallel Tempering) simulations.') self.Shake: AMS._MolecularDynamics._Shake = self._Shake(name='Shake', comment='Parameters of the Shake/Rattle algorithm.') self.Thermostat: AMS._MolecularDynamics._Thermostat = self._Thermostat(name='Thermostat', comment="This block allows to specify the use of a thermostat during the simulation. Depending on the selected thermostat type, different additional options may be needed to characterize the specific thermostat's behavior.", unique=False) self.Trajectory: AMS._MolecularDynamics._Trajectory = self._Trajectory(name='Trajectory', comment='Sets the frequency for printing to stdout and storing the molecular configuration on the .rkf file.') self.fbMC: AMS._MolecularDynamics._fbMC = self._fbMC(name='fbMC', comment='This block sets up force bias Monte Carlo interleaved with the molecular dynamics simulation.', unique=False, gui_name='fbMC:')
[docs] class _Molecules(FixedBlock): r""" Configures details of the molecular composition analysis enabled by the Properties%Molecules block. :ivar AdsorptionSupportRegion: Select region that will represent a support for adsorption analysis. Adsorbed molecules will receive an '(ads)' suffix after name of the element bonded to the support. Such elements will be listed separate from atoms of the same element not bonded to the support, for example, HOH(ads) for a water molecule bonded to a surface via one of its H atoms. :vartype AdsorptionSupportRegion: str | StringKey :ivar BondOrderCutoff: Bond order cutoff for analysis of the molecular composition. Bonds with bond order smaller than this value are neglected when determining the molecular composition. :vartype BondOrderCutoff: float | FloatKey """ def __post_init__(self): self.AdsorptionSupportRegion: str | StringKey = StringKey(name='AdsorptionSupportRegion', comment="Select region that will represent a support for adsorption analysis. Adsorbed molecules will receive an '(ads)' suffix after name of the element bonded to the support. Such elements will be listed separate from atoms of the same element not bonded to the support, for example, HOH(ads) for a water molecule bonded to a surface via one of its H atoms.", gui_name='Adsorption support region:', gui_type='region') self.BondOrderCutoff: float | FloatKey = FloatKey(name='BondOrderCutoff', comment='Bond order cutoff for analysis of the molecular composition. Bonds with bond order smaller than this value are neglected when determining the molecular composition.', default=0.5)
[docs] class _NEB(FixedBlock): r""" Configures details of the Nudged Elastic Band optimization. :ivar Climbing: Use the climbing image algorithm to drive the highest image to the transition state. :vartype Climbing: BoolType | BoolKey :ivar ClimbingThreshold: Climbing image force threshold. If ClimbingThreshold > 0 and the max perpendicular force component is above the threshold then no climbing is performed at this step. This entry can be used to get a better approximation for the reaction path before starting the search for the transition state. A typical value is 0.01 Hartree/Bohr. :vartype ClimbingThreshold: float | FloatKey :ivar DoubleNudge: Type of the double nudging method. :vartype DoubleNudge: Literal["None", "Henkelman", "Trygubenko"] :ivar Images: Number of NEB images (not counting the chain ends). Using more images will result in a smoother reaction path and can help with convergence problems, but it will also increase the computation time. :vartype Images: int | IntKey :ivar Intermediates: Define one or more intermediate systems. The molecule names are adjusted when saving so that the order of the intermediates is the order as they appear in the list here. If no intermediate systems are needed, select None :vartype Intermediates: str | StringKey :ivar InterpolateInternal: The initial NEB image geometries are calculated by interpolating between the initial and the final state. By default, for non-periodic systems the interpolation is performed in internal coordinates but the user can choose to do it in the Cartesian ones. For periodic systems the interpolation is always done in Cartesian coordinates. If PreOptimizeWithIDPP is set then the path may be further refined using the image-dependent pair potential (IDPP). :vartype InterpolateInternal: BoolType | BoolKey :ivar InterpolateShortest: Allow interpolation across periodic cell boundaries. Set to false if an atom is intended to move more than half across the simulation box during reaction. :vartype InterpolateShortest: BoolType | BoolKey :ivar InterpolationOption: Select which internal coordinates will be interpolated: 0 - automatic, 1 - only distances, 2 - distances and near-linear valence angles, 3 - distances and all valence angles, 4 - distances and dihedral angles, 99 - all coordinates :vartype InterpolationOption: int | IntKey :ivar Iterations: Maximum number of NEB iterations. The default value depends on the number of degrees of freedom (number of images, atoms, periodic dimensions). :vartype Iterations: int | IntKey :ivar Jacobian: Scaling factor used to convert the lattice strain to a NEB coordinate value. Default value: sqrt(N)*(V/N)^(1/d), where V - lattice volume (area for 2D, length for 1D), N - number of atoms, and d - number of periodic dimensions. :vartype Jacobian: float | FloatKey :ivar MapAtomsToCell: Translate atoms to the [-0.5,0.5] cell before every step. This option cannot be disabled for SS-NEB. :vartype MapAtomsToCell: BoolType | BoolKey :ivar OldTangent: Turn on the old central difference tangent. :vartype OldTangent: BoolType | BoolKey :ivar OptimizeEnds: Start the NEB with optimization of the reactant and product geometries. :vartype OptimizeEnds: BoolType | BoolKey :ivar OptimizeLattice: Turn on the solid-state NEB (SS-NEB). :vartype OptimizeLattice: BoolType | BoolKey :ivar PreOptimizeWithIDPP: (Experimental) When there is only initial and final system available, the image-dependent pair potential (IDPP, doi: 10.1063/1.4878664) can be used to determine the initial NEB path by interpolating all interatomic distances between the two points and optimizing intermediate images towards them. The optimization starts from the geometries obtained using the selected interpolation options. :vartype PreOptimizeWithIDPP: BoolType | BoolKey :ivar ReOptimizeEnds: Re-optimize reactant and product geometries upon restart. :vartype ReOptimizeEnds: BoolType | BoolKey :ivar Restart: Provide an ams.rkf file from a previous NEB calculation to restart from. It can be an unfinished NEB calculation or one performed with different engine parameters. :vartype Restart: str | Path | StringKey :ivar Skewness: Degree of how much images are shifted towards or away from the TS, which may help tackle problems with a long reaction path (for example involving a loose adsorption complex) without needing too many images. A value greater than 1 will make sure that images are concentrated near the transition state. The optimal value depends on the path length, the number of images (larger [Skewness] may be needed for a longer path and fewer images). Technically [Skewness] is equal to the ratio between the optimized distances to the lower and the higher neighbor image on the path. :vartype Skewness: float | FloatKey :ivar Spring: Spring force constant in atomic units. :vartype Spring: float | FloatKey :ivar LoadPath: Provide details about the trajectory to get the initial NEB path from. PESScan and NEB trajectories are supported. Only the last geometry for each point on the trajectory is considered. :vartype LoadPath: AMS._NEB._LoadPath :ivar Parallel: Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :vartype Parallel: AMS._NEB._Parallel """
[docs] class _LoadPath(FixedBlock): r""" Provide details about the trajectory to get the initial NEB path from. PESScan and NEB trajectories are supported. Only the last geometry for each point on the trajectory is considered. :ivar File: Provide an ams.rkf file to load the initial path from. All geometries of this calculation, including initial and final, will be taken from the History section of the file. Note that for a PESScan it should be a 1D path. :vartype File: str | Path | StringKey :ivar Geometries: Raw indices of the geometries from the History section. By default the last geometry of each path point is used. :vartype Geometries: Iterable[int] | IntListKey :ivar Points: By default the whole path is used, which may sometimes be not desirable. For example when a PESScan revealed multiple barriers. In this case one can specify indices of the path points to be used. The last geometry of the specified path point will be loaded. :vartype Points: Iterable[int] | IntListKey """ def __post_init__(self): self.File: str | Path | StringKey = PathStringKey(name='File', comment='Provide an ams.rkf file to load the initial path from. All geometries of this calculation, including initial and final, will be taken from the History section of the file.\n\nNote that for a PESScan it should be a 1D path.', gui_name='Initial path file:', ispath=True, gui_type='.rkf {{{AMS result file} .rkf}}') self.Geometries: Iterable[int] | IntListKey = IntListKey(name='Geometries', comment='Raw indices of the geometries from the History section. By default the last geometry of each path point is used.', gui_name='Raw geometry indices:') self.Points: Iterable[int] | IntListKey = IntListKey(name='Points', comment='By default the whole path is used, which may sometimes be not desirable. For example when a PESScan revealed multiple barriers. In this case one can specify indices of the path points to be used. The last geometry of the specified path point will be loaded.', gui_name='Path points:')
[docs] class _Parallel(FixedBlock): r""" Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :ivar nCoresPerGroup: Number of cores in each working group. :vartype nCoresPerGroup: int | IntKey :ivar nGroups: Total number of processor groups. This is the number of tasks that will be executed in parallel. :vartype nGroups: int | IntKey :ivar nNodesPerGroup: Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores. :vartype nNodesPerGroup: int | IntKey """ def __post_init__(self): self.nCoresPerGroup: int | IntKey = IntKey(name='nCoresPerGroup', comment='Number of cores in each working group.', gui_name='Cores per group:') self.nGroups: int | IntKey = IntKey(name='nGroups', comment='Total number of processor groups. This is the number of tasks that will be executed in parallel.', gui_name='Number of groups:') self.nNodesPerGroup: int | IntKey = IntKey(name='nNodesPerGroup', comment='Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores.', gui_name='Nodes per group:')
def __post_init__(self): self.Climbing: BoolType | BoolKey = BoolKey(name='Climbing', comment='Use the climbing image algorithm to drive the highest image to the transition state.', gui_name='Climb highest image to TS:', default=True) self.ClimbingThreshold: float | FloatKey = FloatKey(name='ClimbingThreshold', comment='Climbing image force threshold. If ClimbingThreshold > 0 and the max perpendicular force component is above the threshold then no climbing is performed at this step. This entry can be used to get a better approximation for the reaction path before starting the search for the transition state. A typical value is 0.01 Hartree/Bohr.', gui_name='CI force threshold:', default=0.0, unit='Hartree/Bohr') self.DoubleNudge: Literal["None", "Henkelman", "Trygubenko"] = MultipleChoiceKey(name='DoubleNudge', comment='Type of the double nudging method.', hidden=True, gui_name='Double nudging method:', default='None', choices=['None', 'Henkelman', 'Trygubenko']) self.Images: int | IntKey = IntKey(name='Images', comment='Number of NEB images (not counting the chain ends). Using more images will result in a smoother reaction path and can help with convergence problems, but it will also increase the computation time.', gui_name='Number of images:', default=8) self.Intermediates: str | StringKey = StringKey(name='Intermediates', comment='Define one or more intermediate systems.\n\nThe molecule names are adjusted when saving so that the order of the intermediates is the order as they appear in the list here.\n\nIf no intermediate systems are needed, select None', hidden=True, unique=False, default='', gui_type='molecule') self.InterpolateInternal: BoolType | BoolKey = BoolKey(name='InterpolateInternal', comment='The initial NEB image geometries are calculated by interpolating between the initial and the final state. By default, for non-periodic systems the interpolation is performed in internal coordinates but the user can choose to do it in the Cartesian ones. For periodic systems the interpolation is always done in Cartesian coordinates. If PreOptimizeWithIDPP is set then the path may be further refined using the image-dependent pair potential (IDPP).', gui_name='Interpolate in Internal coordinates:', default=True) self.InterpolateShortest: BoolType | BoolKey = BoolKey(name='InterpolateShortest', comment='Allow interpolation across periodic cell boundaries. Set to false if an atom is intended to move more than half across the simulation box during reaction.', gui_name='Interpolate across cell boundary:', default=True) self.InterpolationOption: int | IntKey = IntKey(name='InterpolationOption', comment='Select which internal coordinates will be interpolated: \n\n 0 - automatic, \n 1 - only distances, \n 2 - distances and near-linear valence angles, \n 3 - distances and all valence angles, \n 4 - distances and dihedral angles, \n 99 - all coordinates', hidden=True, gui_name='Interpolation option:', default=0) self.Iterations: int | IntKey = IntKey(name='Iterations', comment='Maximum number of NEB iterations. The default value depends on the number of degrees of freedom (number of images, atoms, periodic dimensions).', gui_name='Maximum number of iterations:') self.Jacobian: float | FloatKey = FloatKey(name='Jacobian', comment='Scaling factor used to convert the lattice strain to a NEB coordinate value. Default value: sqrt(N)*(V/N)^(1/d), where V - lattice volume (area for 2D, length for 1D), N - number of atoms, and d - number of periodic dimensions.', gui_name='Jacobian value:') self.MapAtomsToCell: BoolType | BoolKey = BoolKey(name='MapAtomsToCell', comment='Translate atoms to the [-0.5,0.5] cell before every step. This option cannot be disabled for SS-NEB.', gui_name='Map atoms to cell:', default=True) self.OldTangent: BoolType | BoolKey = BoolKey(name='OldTangent', comment='Turn on the old central difference tangent.', gui_name='Use old tangent:', default=False) self.OptimizeEnds: BoolType | BoolKey = BoolKey(name='OptimizeEnds', comment='Start the NEB with optimization of the reactant and product geometries.', gui_name='Optimize reactants/products:', default=True) self.OptimizeLattice: BoolType | BoolKey = BoolKey(name='OptimizeLattice', comment='Turn on the solid-state NEB (SS-NEB).', gui_name='Optimize lattice:', default=False) self.PreOptimizeWithIDPP: BoolType | BoolKey = BoolKey(name='PreOptimizeWithIDPP', comment='(Experimental)\nWhen there is only initial and final system available, the image-dependent pair potential (IDPP, doi: 10.1063/1.4878664) can be used to determine the initial NEB path by interpolating all interatomic distances between the two points and optimizing intermediate images towards them. The optimization starts from the geometries obtained using the selected interpolation options.', gui_name='Use IDPP:', default=False) self.ReOptimizeEnds: BoolType | BoolKey = BoolKey(name='ReOptimizeEnds', comment='Re-optimize reactant and product geometries upon restart.', gui_name='Re-optimize reactants/products:', default=False) self.Restart: str | Path | StringKey = PathStringKey(name='Restart', comment='Provide an ams.rkf file from a previous NEB calculation to restart from. It can be an unfinished NEB calculation or one performed with different engine parameters.', gui_name='Restart from:', ispath=True, gui_type='.rkf {{{AMS result file} .rkf}}') self.Skewness: float | FloatKey = FloatKey(name='Skewness', comment='Degree of how much images are shifted towards or away from the TS, which may help tackle problems with a long reaction path (for example involving a loose adsorption complex) without needing too many images. A value greater than 1 will make sure that images are concentrated near the transition state. The optimal value depends on the path length, the number of images (larger [Skewness] may be needed for a longer path and fewer images). Technically [Skewness] is equal to the ratio between the optimized distances to the lower and the higher neighbor image on the path.', gui_name='Skewness:', default=1.0) self.Spring: float | FloatKey = FloatKey(name='Spring', comment='Spring force constant in atomic units.', gui_name='Spring value:', default=1.0, unit='Hartree/Bohr^2') self.LoadPath: AMS._NEB._LoadPath = self._LoadPath(name='LoadPath', comment='Provide details about the trajectory to get the initial NEB path from. PESScan and NEB trajectories are supported. Only the last geometry for each point on the trajectory is considered.') self.Parallel: AMS._NEB._Parallel = self._Parallel(name='Parallel', comment='Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel.', extra_info='not_in_fragment', shared_id='AMSParallel')
[docs] class _NormalModes(FixedBlock): r""" Configures details of a normal modes calculation. :ivar Displacements: Type of displacements. In case of symmetric displacements it is possible to choose only the modes that have non-zero IR or Raman intensity. Block displacements take rigid blocks into account. :vartype Displacements: Literal["Cartesian", "Symmetric", "Block"] :ivar Hessian: Default Auto means that if possible by the engine the Hessian will be calculated analytically, else the Hessian will be calculated numerically by AMS. :vartype Hessian: Literal["Auto", "Analytical", "Numerical"] :ivar ReScanFreqRange: Specifies a frequency range within which all modes will be scanned. 2 numbers: an upper and a lower bound. :vartype ReScanFreqRange: Iterable[float] | FloatListKey :ivar ReScanModes: Whether or not to scan imaginary modes after normal modes calculation has concluded. :vartype ReScanModes: BoolType | BoolKey :ivar UseSymmetry: Whether or not to exploit the symmetry of the system in the normal modes calculation. :vartype UseSymmetry: BoolType | BoolKey :ivar BlockDisplacements: Configures details of a Block Normal Modes (a.k.a. Mobile Block Hessian, or MBH) calculation. :vartype BlockDisplacements: AMS._NormalModes._BlockDisplacements :ivar SymmetricDisplacements: Configures details of the calculation of the frequencies and normal modes of vibration in symmetric displacements. :vartype SymmetricDisplacements: AMS._NormalModes._SymmetricDisplacements """
[docs] class _BlockDisplacements(FixedBlock): r""" Configures details of a Block Normal Modes (a.k.a. Mobile Block Hessian, or MBH) calculation. :ivar AngularDisplacement: Relative step size for rotational degrees of freedom during Block Normal Modes finite difference calculations. It will be scaled with the characteristic block size. :vartype AngularDisplacement: float | FloatKey :ivar BlockAtoms: List of atoms belonging to a block. You can have multiple BlockAtoms. :vartype BlockAtoms: Iterable[int] | IntListKey :ivar BlockRegion: The region to to be considered a block. You can have multiple BlockRegions, also in combination with BlockAtoms. :vartype BlockRegion: str | StringKey :ivar RadialDisplacement: Step size for translational degrees of freedom during Block Normal Modes finite difference calculations. :vartype RadialDisplacement: float | FloatKey :ivar Parallel: Configuration for how the individual displacements are calculated in parallel. :vartype Parallel: AMS._NormalModes._BlockDisplacements._Parallel """
[docs] class _Parallel(FixedBlock): r""" Configuration for how the individual displacements are calculated in parallel. :ivar nCoresPerGroup: Number of cores in each working group. :vartype nCoresPerGroup: int | IntKey :ivar nGroups: Total number of processor groups. This is the number of tasks that will be executed in parallel. :vartype nGroups: int | IntKey :ivar nNodesPerGroup: Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores. :vartype nNodesPerGroup: int | IntKey """ def __post_init__(self): self.nCoresPerGroup: int | IntKey = IntKey(name='nCoresPerGroup', comment='Number of cores in each working group.') self.nGroups: int | IntKey = IntKey(name='nGroups', comment='Total number of processor groups. This is the number of tasks that will be executed in parallel.') self.nNodesPerGroup: int | IntKey = IntKey(name='nNodesPerGroup', comment='Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores.', gui_name='Cores per task:')
def __post_init__(self): self.AngularDisplacement: float | FloatKey = FloatKey(name='AngularDisplacement', comment='Relative step size for rotational degrees of freedom during Block Normal Modes finite difference calculations. It will be scaled with the characteristic block size.', default=0.5, unit='Degree') self.BlockAtoms: Iterable[int] | IntListKey = IntListKey(name='BlockAtoms', comment='List of atoms belonging to a block. You can have multiple BlockAtoms.', unique=False, gui_type='region') self.BlockRegion: str | StringKey = StringKey(name='BlockRegion', comment='The region to to be considered a block. You can have multiple BlockRegions, also in combination with BlockAtoms.', unique=False, gui_type='region') self.RadialDisplacement: float | FloatKey = FloatKey(name='RadialDisplacement', comment='Step size for translational degrees of freedom during Block Normal Modes finite difference calculations.', default=0.005, unit='Angstrom') self.Parallel: AMS._NormalModes._BlockDisplacements._Parallel = self._Parallel(name='Parallel', comment='Configuration for how the individual displacements are calculated in parallel.')
[docs] class _SymmetricDisplacements(FixedBlock): r""" Configures details of the calculation of the frequencies and normal modes of vibration in symmetric displacements. :ivar Type: For symmetric molecules it is possible to choose only the modes that have non-zero IR or Raman intensity (or either of them) by symmetry. In order to calculate the Raman intensities the Raman property must be requested. :vartype Type: Literal["All", "Infrared", "Raman", "InfraredAndRaman"] """ def __post_init__(self): self.Type: Literal["All", "Infrared", "Raman", "InfraredAndRaman"] = MultipleChoiceKey(name='Type', comment='For symmetric molecules it is possible to choose only the modes that have non-zero IR or Raman intensity (or either of them) by symmetry.\n\nIn order to calculate the Raman intensities the Raman property must be requested.', gui_name='Symm Frequencies:', default='All', choices=['All', 'Infrared', 'Raman', 'InfraredAndRaman'])
def __post_init__(self): self.Displacements: Literal["Cartesian", "Symmetric", "Block"] = MultipleChoiceKey(name='Displacements', comment='Type of displacements.\n\nIn case of symmetric displacements it is possible to choose only the modes that have non-zero IR or Raman intensity.\n\nBlock displacements take rigid blocks into account.', gui_name='Displacements:', default='Cartesian', choices=['Cartesian', 'Symmetric', 'Block']) self.Hessian: Literal["Auto", "Analytical", "Numerical"] = MultipleChoiceKey(name='Hessian', comment='Default Auto means that if possible by the engine the Hessian will be calculated analytically, else the Hessian will be calculated numerically by AMS.', default='Auto', choices=['Auto', 'Analytical', 'Numerical']) self.ReScanFreqRange: Iterable[float] | FloatListKey = FloatListKey(name='ReScanFreqRange', comment='Specifies a frequency range within which all modes will be scanned. 2 numbers: an upper and a lower bound.', unique=False, gui_name='Re-scan range:', default=[-10000000.0, 10.0], unit='cm-1', gui_type='nfloat 2') self.ReScanModes: BoolType | BoolKey = BoolKey(name='ReScanModes', comment='Whether or not to scan imaginary modes after normal modes calculation has concluded.', gui_name='Re-scan modes:', default=True) self.UseSymmetry: BoolType | BoolKey = BoolKey(name='UseSymmetry', comment='Whether or not to exploit the symmetry of the system in the normal modes calculation.', hidden=True, default=True) self.BlockDisplacements: AMS._NormalModes._BlockDisplacements = self._BlockDisplacements(name='BlockDisplacements', comment='Configures details of a Block Normal Modes (a.k.a. Mobile Block Hessian, or MBH) calculation.') self.SymmetricDisplacements: AMS._NormalModes._SymmetricDisplacements = self._SymmetricDisplacements(name='SymmetricDisplacements', comment='Configures details of the calculation of the frequencies and normal modes of vibration in symmetric displacements.')
[docs] class _NumericalDifferentiation(FixedBlock): r""" Define options for numerical differentiations, that is the numerical calculation of gradients, Hessian and the stress tensor for periodic systems. :ivar NuclearStepSize: Step size for numerical nuclear gradient calculation. :vartype NuclearStepSize: float | FloatKey :ivar StrainStepSize: Step size (relative) for numerical stress tensor calculation. :vartype StrainStepSize: float | FloatKey :ivar UseSymmetry: Whether or not to exploit the symmetry of the system for numerical differentiations. :vartype UseSymmetry: BoolType | BoolKey :ivar Parallel: Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :vartype Parallel: AMS._NumericalDifferentiation._Parallel """
[docs] class _Parallel(FixedBlock): r""" Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :ivar nCoresPerGroup: Number of cores in each working group. :vartype nCoresPerGroup: int | IntKey :ivar nGroups: Total number of processor groups. This is the number of tasks that will be executed in parallel. :vartype nGroups: int | IntKey :ivar nNodesPerGroup: Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores. :vartype nNodesPerGroup: int | IntKey """ def __post_init__(self): self.nCoresPerGroup: int | IntKey = IntKey(name='nCoresPerGroup', comment='Number of cores in each working group.', gui_name='Cores per group:') self.nGroups: int | IntKey = IntKey(name='nGroups', comment='Total number of processor groups. This is the number of tasks that will be executed in parallel.', gui_name='Number of groups:') self.nNodesPerGroup: int | IntKey = IntKey(name='nNodesPerGroup', comment='Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores.', gui_name='Nodes per group:')
def __post_init__(self): self.NuclearStepSize: float | FloatKey = FloatKey(name='NuclearStepSize', comment='Step size for numerical nuclear gradient calculation.', default=0.005, unit='Bohr') self.StrainStepSize: float | FloatKey = FloatKey(name='StrainStepSize', comment='Step size (relative) for numerical stress tensor calculation.', default=0.001) self.UseSymmetry: BoolType | BoolKey = BoolKey(name='UseSymmetry', comment='Whether or not to exploit the symmetry of the system for numerical differentiations.', hidden=True, default=True) self.Parallel: AMS._NumericalDifferentiation._Parallel = self._Parallel(name='Parallel', comment='Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel.', extra_info='not_in_fragment', shared_id='AMSParallel')
[docs] class _NumericalPhonons(FixedBlock): r""" Configures details of a numerical phonons calculation. :ivar AutomaticBZPath: If True, compute the phonon dispersion curve for the standard path through the Brillouin zone. If False, you must specify your custom path in the [BZPath] block. :vartype AutomaticBZPath: BoolType | BoolKey :ivar BornEffCharge: Input option to give the Born effective charges of the species. :vartype BornEffCharge: float | FloatKey :ivar DielectricConst: Input option to give the static dielectric constant of the species. :vartype DielectricConst: float | FloatKey :ivar DoubleSided: By default a two-sided (or quadratic) numerical differentiation of the nuclear gradients is used. Using a single-sided (or linear) numerical differentiation is computationally faster but much less accurate. Note: In older versions of the program only the single-sided option was available. :vartype DoubleSided: BoolType | BoolKey :ivar Interpolation: Use interpolation to generate smooth phonon plots. :vartype Interpolation: int | IntKey :ivar KPathFinderConvention: This option determines how the path through the Brillouin zone is generated when using the automatic k-point mode. Available options: • ``Setyawan-Curtarolo`` (default for 1D and 2D lattices): Uses our built-in KPath program to find a path through high-symmetry points based on the method by Setyawan and Curtarolo (https://doi.org/10.1016/j.commatsci.2010.05.010). For 2D lattices, the path is derived from the intersection of the 3D Brillouin zone with a plane. For 1D lattices, the path is simply Gamma-Z. • ``Hinuma``: Uses the external SeeKPath utility to generate the k-path (https://github.com/giovannipizzi/seekpath and https://doi.org/10.1016/j.commatsci.2016.10.015). :vartype KPathFinderConvention: Literal["Setyawan-Curtarolo", "Hinuma"] :ivar MaxTemperature: Maximum temperature for the thermodynamic properties calculation (Internal Energy, Free Energy, Specific Heat, and Entropy). This value sets the upper limit of the temperature range considered. It is used in conjunction with ``NTemperatures`` to define the temperature grid. The calculation of thermodynamic properties is performed only if the phonon density of states (DOS) is requested (i.e., ``Phonons%DOS`` is set to ``Yes``). :vartype MaxTemperature: float | FloatKey :ivar NDosEnergies: Nr. of energies used to calculate the phonon DOS used to integrate thermodynamic properties. For fast compute engines this may become time limiting and smaller values can be tried. :vartype NDosEnergies: int | IntKey :ivar NTemperatures: Number of temperature points to use in the thermodynamic properties calculation (Internal Energy, Free Energy, Specific Heat, and Entropy). This value, along with ``MaxTemperature``, determines the density of the temperature grid. The temperatures will be distributed evenly between 0 Kelvin and 'MaxTemperature'. The calculation of thermodynamic properties is performed only if the phonon density of states (DOS) is requested (i.e., ``Phonons%DOS`` is set to ``Yes``). :vartype NTemperatures: int | IntKey :ivar RequestContinuousPES: Whether or not the engine should be instructed to disable symmetry. AMS versions older than AMS2024 would use the the hard coded value false. :vartype RequestContinuousPES: BoolType | BoolKey :ivar StepSize: Step size to be taken to obtain the force constants (second derivative) from the analytical gradients numerically. :vartype StepSize: float | FloatKey :ivar UseSymmetry: Whether or not to exploit the symmetry of the system in the phonon calculation. :vartype UseSymmetry: BoolType | BoolKey :ivar BZPath: If [NumericalPhonons%AutomaticBZPath] is false, the phonon dispersion curve will be computed for the user-defined path in the [BZPath] block. You should define the vertices of your path in fractional coordinates (with respect to the reciprocal lattice vectors) in the [Path] sub-block. If you want to make a jump in your path (i.e. have a discontinuous path), you need to specify a new [Path] sub-block. :vartype BZPath: AMS._NumericalPhonons._BZPath :ivar Parallel: Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :vartype Parallel: AMS._NumericalPhonons._Parallel :ivar SuperCell: Used for the phonon run. The super lattice is expressed in the lattice vectors. Most people will find a diagonal matrix easiest to understand. :vartype SuperCell: str | Sequence[str] | FreeBlock """
[docs] class _BZPath(FixedBlock): r""" If [NumericalPhonons%AutomaticBZPath] is false, the phonon dispersion curve will be computed for the user-defined path in the [BZPath] block. You should define the vertices of your path in fractional coordinates (with respect to the reciprocal lattice vectors) in the [Path] sub-block. If you want to make a jump in your path (i.e. have a discontinuous path), you need to specify a new [Path] sub-block. :ivar Path: A section of a k space path. This block should contain multiple lines, and in each line you should specify one vertex of the path in fractional coordinates. Optionally, you can add text labels for your vertices at the end of each line. :vartype Path: str | Sequence[str] | FreeBlock """
[docs] class _Path(FreeBlock): r""" A section of a k space path. This block should contain multiple lines, and in each line you should specify one vertex of the path in fractional coordinates. Optionally, you can add text labels for your vertices at the end of each line. """ def __post_init__(self): pass
def __post_init__(self): self.Path: str | Sequence[str] | FreeBlock = self._Path(name='Path', comment='A section of a k space path. This block should contain multiple lines, and in each line you should specify one vertex of the path in fractional coordinates. Optionally, you can add text labels for your vertices at the end of each line.', unique=False)
[docs] class _Parallel(FixedBlock): r""" Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :ivar nCoresPerGroup: Number of cores in each working group. :vartype nCoresPerGroup: int | IntKey :ivar nGroups: Total number of processor groups. This is the number of tasks that will be executed in parallel. :vartype nGroups: int | IntKey :ivar nNodesPerGroup: Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores. :vartype nNodesPerGroup: int | IntKey """ def __post_init__(self): self.nCoresPerGroup: int | IntKey = IntKey(name='nCoresPerGroup', comment='Number of cores in each working group.', gui_name='Cores per group:') self.nGroups: int | IntKey = IntKey(name='nGroups', comment='Total number of processor groups. This is the number of tasks that will be executed in parallel.', gui_name='Number of groups:') self.nNodesPerGroup: int | IntKey = IntKey(name='nNodesPerGroup', comment='Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores.', gui_name='Nodes per group:')
[docs] class _SuperCell(FreeBlock): r""" Used for the phonon run. The super lattice is expressed in the lattice vectors. Most people will find a diagonal matrix easiest to understand. """ def __post_init__(self): pass
def __post_init__(self): self.AutomaticBZPath: BoolType | BoolKey = BoolKey(name='AutomaticBZPath', comment='If True, compute the phonon dispersion curve for the standard path through the Brillouin zone. If False, you must specify your custom path in the [BZPath] block.', gui_name='Automatic BZ path:', default=True) self.BornEffCharge: float | FloatKey = FloatKey(name='BornEffCharge', comment='Input option to give the Born effective charges of the species.', default=0.0) self.DielectricConst: float | FloatKey = FloatKey(name='DielectricConst', comment='Input option to give the static dielectric constant of the species.', default=1.0) self.DoubleSided: BoolType | BoolKey = BoolKey(name='DoubleSided', comment='By default a two-sided (or quadratic) numerical differentiation of the nuclear gradients is used. Using a single-sided (or linear) numerical differentiation is computationally faster but much less accurate. Note: In older versions of the program only the single-sided option was available.', default=True) self.Interpolation: int | IntKey = IntKey(name='Interpolation', comment='Use interpolation to generate smooth phonon plots.', default=100) self.KPathFinderConvention: Literal["Setyawan-Curtarolo", "Hinuma"] = MultipleChoiceKey(name='KPathFinderConvention', comment='This option determines how the path through the Brillouin zone is generated when using the automatic k-point mode.\n\nAvailable options:\n\n• ``Setyawan-Curtarolo`` (default for 1D and 2D lattices): Uses our built-in KPath program to find a path through high-symmetry points based on the method by Setyawan and Curtarolo (https://doi.org/10.1016/j.commatsci.2010.05.010). For 2D lattices, the path is derived from the intersection of the 3D Brillouin zone with a plane. For 1D lattices, the path is simply Gamma-Z.\n\n• ``Hinuma``: Uses the external SeeKPath utility to generate the k-path (https://github.com/giovannipizzi/seekpath and https://doi.org/10.1016/j.commatsci.2016.10.015).', default='Setyawan-Curtarolo', choices=['Setyawan-Curtarolo', 'Hinuma']) self.MaxTemperature: float | FloatKey = FloatKey(name='MaxTemperature', comment='Maximum temperature for the thermodynamic properties calculation (Internal Energy, Free Energy, Specific Heat, and Entropy). This value sets the upper limit of the temperature range considered. It is used in conjunction with ``NTemperatures`` to define the temperature grid. The calculation of thermodynamic properties is performed only if the phonon density of states (DOS) is requested (i.e., ``Phonons%DOS`` is set to ``Yes``).', hidden=True, default=1000.0, unit='Kelvin') self.NDosEnergies: int | IntKey = IntKey(name='NDosEnergies', comment='Nr. of energies used to calculate the phonon DOS used to integrate thermodynamic properties. For fast compute engines this may become time limiting and smaller values can be tried.', default=1000) self.NTemperatures: int | IntKey = IntKey(name='NTemperatures', comment="Number of temperature points to use in the thermodynamic properties calculation (Internal Energy, Free Energy, Specific Heat, and Entropy). This value, along with ``MaxTemperature``, determines the density of the temperature grid. The temperatures will be distributed evenly between 0 Kelvin and 'MaxTemperature'. The calculation of thermodynamic properties is performed only if the phonon density of states (DOS) is requested (i.e., ``Phonons%DOS`` is set to ``Yes``).", hidden=True, default=1000) self.RequestContinuousPES: BoolType | BoolKey = BoolKey(name='RequestContinuousPES', comment='Whether or not the engine should be instructed to disable symmetry. AMS versions older than AMS2024 would use the the hard coded value false.', hidden=True, default=True) self.StepSize: float | FloatKey = FloatKey(name='StepSize', comment='Step size to be taken to obtain the force constants (second derivative) from the analytical gradients numerically.', default=0.04, unit='Angstrom') self.UseSymmetry: BoolType | BoolKey = BoolKey(name='UseSymmetry', comment='Whether or not to exploit the symmetry of the system in the phonon calculation.', hidden=True, default=True) self.BZPath: AMS._NumericalPhonons._BZPath = self._BZPath(name='BZPath', comment='If [NumericalPhonons%AutomaticBZPath] is false, the phonon dispersion curve will be computed for the user-defined path in the [BZPath] block. You should define the vertices of your path in fractional coordinates (with respect to the reciprocal lattice vectors) in the [Path] sub-block. If you want to make a jump in your path (i.e. have a discontinuous path), you need to specify a new [Path] sub-block.') self.Parallel: AMS._NumericalPhonons._Parallel = self._Parallel(name='Parallel', comment='Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel.', extra_info='not_in_fragment', shared_id='AMSParallel') self.SuperCell: str | Sequence[str] | FreeBlock = self._SuperCell(name='SuperCell', comment='Used for the phonon run. The super lattice is expressed in the lattice vectors. Most people will find a diagonal matrix easiest to understand.')
[docs] class _PESExploration(FixedBlock): r""" Configures details of the automated PES exploration methods. :ivar CalculateEnergyReferences: Calculates the energy references. :vartype CalculateEnergyReferences: BoolType | BoolKey :ivar CalculateFragments: Must be used together with an adsorbent set as the StatesAlignment%ReferenceRegion. Runs a final calculation of the adsorbate and adsorbent (marked by the ReferenceRegion) individually. The fragmented state is included in the energy landscape. :vartype CalculateFragments: BoolType | BoolKey :ivar DynamicSeedStates: Whether subsequent expeditions may start from states discovered by previous expeditions. This should lead to a more comprehensive exploration of the potential energy surface. Disabling this will focus the PES exploration around the initial seed states. :vartype DynamicSeedStates: BoolType | BoolKey :ivar FiniteDifference: The finite difference distance to use for Dimer, Hessian, Lanczos, and optimization methods. :vartype FiniteDifference: float | FloatKey :ivar GenerateSymmetryImages: By activating this option, after concluding the energy landscape exploration process, it will create the complete set of symmetry-related copies by using the symmetry operators of the reference structure. SinglePoint calculations (including gradients and normal modes) are carried out for each new image structure obtained. :vartype GenerateSymmetryImages: BoolType | BoolKey :ivar Job: Specify the PES exploration job to perform. :vartype Job: Literal["ProcessSearch", "BasinHopping", "SaddleSearch", "LandscapeRefinement", "BindingSites", "NudgedElasticBand", "SystemMatching"] :ivar NegativeEigenvalueTolerance: The threshold in Hessian eigenvalue below which a mode is considered imaginary, i.e. indicating a transition state. This is a small negative number, as very small negative eigenvalues may be due to numerical noise on an essentially flat PES and do not indicate true transition states. We need a more flexible value for this parameter in PESExploration because the high computational cost of the task typically forces us to reduce the engine precision, which increases the noise in the vibrational frequencies evaluation. [PESPointCharacter%NegativeEigenvalueTolerance] is overridden by this parameter. :vartype NegativeEigenvalueTolerance: float | FloatKey :ivar NumExpeditions: Sets the number of subsequent expeditions our job will consist of. Larger values result in a more comprehensive exploration of the potential energy surface, but will take more computational time. :vartype NumExpeditions: int | IntKey :ivar NumExplorers: Sets the number of independent PES explorers dispatched as part of each expedition. Larger values will result in a more comprehensive exploration of the potential energy surface, but will take more computational time. By default an appropriate number of explorers are executed in parallel. :vartype NumExplorers: int | IntKey :ivar OptTSMethod: When the full set of states in the energy landscape are optimized (see PESExploration%Job = GeometryOptimization), transition states can be optimized using either SaddleSearch or NudgedElasticBand methods. SaddleSearch uses information only from the current geometry of the TS; contrary, NudgedElasticBand ignores the current geometry and runs a Nudged-Elastic-Band calculation trying to connect the associated reactants and products if they are available. :vartype OptTSMethod: Literal["SaddleSearch", "NudgedElasticBand"] :ivar Potential: The PES to be explored. The default is to use a callback into AMS to evaluate the energy and gradients using an AMS engine. This can be changed here to give access to one of the EON client's builtin potentials. This has not been well tested by SCM. :vartype Potential: str | StringKey :ivar RandomSeed: Number used to initialize both the EON clients random number generators as well as the AMS global RNG. The latter is normally initialized with the RNGSeed keyword at the root level. Should be used by developers only. May or may not help to make more reproducible regression tests ... :vartype RandomSeed: int | IntKey :ivar SelectedListedAtomsForPESPointCharacter: Uses the Hessian matrix elements only for the listed atoms to determine the PES point character of a located state during the exploration. If not specified, the full Hessian is used. :vartype SelectedListedAtomsForPESPointCharacter: str | StringKey :ivar SelectedRegionForPESPointCharacter: Uses the Hessian matrix elements only for the atoms in a particular region to determine the PES point character of a located state during the exploration. If not specified, the full Hessian is used. :vartype SelectedRegionForPESPointCharacter: str | StringKey :ivar Temperature: The temperature that the job will run at. This may be used in different ways depending on the job, e.g. acceptance probabilities for Monte-Carlo based jobs, thermostatting for dynamics based jobs, kinetic prefactors for jobs that find transition states. Some jobs may not use this temperature at all. :vartype Temperature: float | FloatKey :ivar WriteEngineGradients: Write atomic gradients (negative of the atomic forces, as calculated by the engine) to the History section of ams.rkf. :vartype WriteEngineGradients: BoolType | BoolKey :ivar WriteHistory: When to write the molecular geometry (and possibly other properties) to the history on the ams.rkf file. The default is to only write the converged geometries to the history. Can be changed to write no frames at all to the history, or write all frames (should only be used when testing because of the performance impact). Note that for parallel calculations, only the first group of processes writes to ams.rkf. :vartype WriteHistory: Literal["None", "Converged", "All"] :ivar BasinHopping: Configures the details of the Basin Hopping subtask. :vartype BasinHopping: AMS._PESExploration._BasinHopping :ivar BindingSites: Options related to the calculation of binding sites. :vartype BindingSites: AMS._PESExploration._BindingSites :ivar Debug: ???. :vartype Debug: AMS._PESExploration._Debug :ivar Dynamics: ???. :vartype Dynamics: AMS._PESExploration._Dynamics :ivar Hessian: ???. :vartype Hessian: AMS._PESExploration._Hessian :ivar LandscapeRefinement: Configures details of the energy landscape refinement job. :vartype LandscapeRefinement: AMS._PESExploration._LandscapeRefinement :ivar LoadEnergyLandscape: Options related to the loading of an Energy Landscape from a previous calculation. :vartype LoadEnergyLandscape: AMS._PESExploration._LoadEnergyLandscape :ivar LoadInitialSystems: Load initial systems from different sources. :vartype LoadInitialSystems: AMS._PESExploration._LoadInitialSystems :ivar NudgedElasticBand: Options for the Nudged Elastic Band (NEB) method. :vartype NudgedElasticBand: AMS._PESExploration._NudgedElasticBand :ivar Optimizer: Configures the details of the geometry optimizers used by the PES explorers. :vartype Optimizer: AMS._PESExploration._Optimizer :ivar Parallel: Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :vartype Parallel: AMS._PESExploration._Parallel :ivar ParallelReplica: ???. :vartype ParallelReplica: AMS._PESExploration._ParallelReplica :ivar Prefactor: ???. :vartype Prefactor: AMS._PESExploration._Prefactor :ivar ProcessSearch: Input options specific to the process search procedure. :vartype ProcessSearch: AMS._PESExploration._ProcessSearch :ivar SaddleSearch: Configuration for the Saddle Search procedure (used in SaddleSearch and ProcessSearch Jobs). :vartype SaddleSearch: AMS._PESExploration._SaddleSearch :ivar StatesAlignment: Configures details of how the energy landscape configurations are aligned respect to the main chemical system [System]. :vartype StatesAlignment: AMS._PESExploration._StatesAlignment :ivar StructureComparison: Settings for structure comparison. :vartype StructureComparison: AMS._PESExploration._StructureComparison """
[docs] class _BasinHopping(FixedBlock): r""" Configures the details of the Basin Hopping subtask. :ivar AdjustDisplacement: Automatically adjust the displacement size to meet the target acceptance ratio. :vartype AdjustDisplacement: BoolType | BoolKey :ivar AdjustFraction: The fraction by which to change the step size in order to meet the target acceptance ratio. :vartype AdjustFraction: float | FloatKey :ivar AdjustPeriod: The number of Monte Carlo steps between adjustments of the step size. :vartype AdjustPeriod: int | IntKey :ivar DisplaceAtomsInRegion: If you specify a region name here, only the atoms belonging to this region will be displaced during the basin hopping procedure. For more details on regions, see the documentation on the System definition. :vartype DisplaceAtomsInRegion: str | StringKey :ivar DisplaceListedAtoms: ???. :vartype DisplaceListedAtoms: str | StringKey :ivar DisplaceListedTypes: ???. :vartype DisplaceListedTypes: str | StringKey :ivar Displacement: Displacement in each degree of freedom. :vartype Displacement: float | FloatKey :ivar DisplacementAlgorithm: Undocumented in EON. :vartype DisplacementAlgorithm: Literal["Standard", "Linear", "Quadratic"] :ivar DisplacementDistribution: The distribution used for the displacement of each atom. • Gaussian: The value of the ``Displacement`` keyword serves as the standard deviation of a Gaussian distribution used to draw the nuclear displacements from. • A random number is selected uniformly between ``-Displacement`` and ``Displacement``. :vartype DisplacementDistribution: Literal["Uniform", "Gaussian"] :ivar InitialRandomStructureProbability: Probability to generate an entirely random structure to start the Basin Hopping from. :vartype InitialRandomStructureProbability: float | FloatKey :ivar JumpMax: The number of consecutive rejected steps after which jump steps should be taken. This serves to provide a more global search when the structure is stuck in a certain basin. The number of jump steps is assigned in jump_steps. See paper on the Basin Hopping with Occasional Jumping algorithm by Iwamatsu and Okabe: Chem. Phys. Lett. 399 396 (2004) :vartype JumpMax: int | IntKey :ivar JumpSteps: The number of jump steps to take after the ``JumpMax`` number of consecutive rejections have taken place. :vartype JumpSteps: int | IntKey :ivar MainSystemAsSeed: If true, only the main system will be used as a seed state. The main system is not added to the database. :vartype MainSystemAsSeed: BoolType | BoolKey :ivar PESPointCharacterization: If true, a PES point characterization based on a vibrational analysis is carried out to confirm each detected state is an actual local minimum (no imaginary frequencies). Conversely, if this option is false, the PES point characterization is avoided, which will assume that all located states are local minima (zero gradients). Enabling this option is very useful for large systems. It circumvents the need for computing and diagonalizing the Hessian matrix, a typically expensive computational process. :vartype PESPointCharacterization: BoolType | BoolKey :ivar PushApartDistance: Push atoms apart until no atoms are closer than this distance. This criterion is enforced for the initial structure and all those generated by random displacements. :vartype PushApartDistance: float | FloatKey :ivar QuenchingSteps: Undocumented in EON. :vartype QuenchingSteps: int | IntKey :ivar RotateNonListedAtoms: If true, each iteration randomly rotates all atoms as a rigid body, excluding those listed in [BasinHopping%DisplaceListedAtoms], [BasinHopping%DisplaceListedTypes], or [BasinHopping%DisplaceAtomsInRegion]. :vartype RotateNonListedAtoms: BoolType | BoolKey :ivar SignificantStructure: If true, the Significant Structure Basin Hopping (SSBH) variant instead of the Raw Structure Basin Hopping method (RSBH). In SSBH previously found structures are used as initial structures for further displacements, see Chem. Phys. Lett. 289, 463 (1998) for a comparison of the two approaches. :vartype SignificantStructure: BoolType | BoolKey :ivar SingleAtomDisplace: If true, only one atom is displaced per step. Otherwise all atoms of the structure are randomly displaced. :vartype SingleAtomDisplace: BoolType | BoolKey :ivar Steps: Number of displace & optimize Monte-Carlo steps to take. :vartype Steps: int | IntKey :ivar StopEnergy: Undocumented in EON. :vartype StopEnergy: float | FloatKey :ivar SwapProbability: The probability in range [0,1] that a swapping step takes place instead of a displacement step. The swap step selects two atoms of different elements and swaps their position. :vartype SwapProbability: float | FloatKey :ivar TargetRatio: The target acceptance ratio that will be used to determine whether to increase or decrease the step size. :vartype TargetRatio: float | FloatKey :ivar WriteUnique: If true, all unique states found will be included in the energy landscape, even the rejected ones. If false, only the lowest energy structure will be included in the energy landscape. :vartype WriteUnique: BoolType | BoolKey """ def __post_init__(self): self.AdjustDisplacement: BoolType | BoolKey = BoolKey(name='AdjustDisplacement', comment='Automatically adjust the displacement size to meet the target acceptance ratio.', hidden=True, default=True) self.AdjustFraction: float | FloatKey = FloatKey(name='AdjustFraction', comment='The fraction by which to change the step size in order to meet the target acceptance ratio.', hidden=True, default=0.05) self.AdjustPeriod: int | IntKey = IntKey(name='AdjustPeriod', comment='The number of Monte Carlo steps between adjustments of the step size.', hidden=True, default=10) self.DisplaceAtomsInRegion: str | StringKey = StringKey(name='DisplaceAtomsInRegion', comment='If you specify a region name here, only the atoms belonging to this region will be displaced during the basin hopping procedure. For more details on regions, see the documentation on the System definition.', default='', gui_type='region') self.DisplaceListedAtoms: str | StringKey = StringKey(name='DisplaceListedAtoms', comment='???.', hidden=True, default='') self.DisplaceListedTypes: str | StringKey = StringKey(name='DisplaceListedTypes', comment='???.', hidden=True, default='') self.Displacement: float | FloatKey = FloatKey(name='Displacement', comment='Displacement in each degree of freedom.', default=0.5, unit='Angstrom') self.DisplacementAlgorithm: Literal["Standard", "Linear", "Quadratic"] = MultipleChoiceKey(name='DisplacementAlgorithm', comment='Undocumented in EON.', hidden=True, default='Standard', choices=['Standard', 'Linear', 'Quadratic']) self.DisplacementDistribution: Literal["Uniform", "Gaussian"] = MultipleChoiceKey(name='DisplacementDistribution', comment='The distribution used for the displacement of each atom.\n\n• Gaussian: The value of the ``Displacement`` keyword serves as the standard deviation of a Gaussian distribution used to draw the nuclear displacements from.\n\n• A random number is selected uniformly between ``-Displacement`` and ``Displacement``.', hidden=True, default='Uniform', choices=['Uniform', 'Gaussian']) self.InitialRandomStructureProbability: float | FloatKey = FloatKey(name='InitialRandomStructureProbability', comment='Probability to generate an entirely random structure to start the Basin Hopping from.', hidden=True, default=0.0) self.JumpMax: int | IntKey = IntKey(name='JumpMax', comment='The number of consecutive rejected steps after which jump steps should be taken. This serves to provide a more global search when the structure is stuck in a certain basin. The number of jump steps is assigned in jump_steps. See paper on the Basin Hopping with Occasional Jumping algorithm by Iwamatsu and Okabe: Chem. Phys. Lett. 399 396 (2004)', hidden=True, default=0) self.JumpSteps: int | IntKey = IntKey(name='JumpSteps', comment='The number of jump steps to take after the ``JumpMax`` number of consecutive rejections have taken place.', hidden=True, default=0) self.MainSystemAsSeed: BoolType | BoolKey = BoolKey(name='MainSystemAsSeed', comment='If true, only the main system will be used as a seed state. The main system is not added to the database.', default=False) self.PESPointCharacterization: BoolType | BoolKey = BoolKey(name='PESPointCharacterization', comment='If true, a PES point characterization based on a vibrational analysis is carried out to confirm each detected state is an actual local minimum (no imaginary frequencies). Conversely, if this option is false, the PES point characterization is avoided, which will assume that all located states are local minima (zero gradients). Enabling this option is very useful for large systems. It circumvents the need for computing and diagonalizing the Hessian matrix, a typically expensive computational process.', default=True) self.PushApartDistance: float | FloatKey = FloatKey(name='PushApartDistance', comment='Push atoms apart until no atoms are closer than this distance. This criterion is enforced for the initial structure and all those generated by random displacements.', default=0.4, unit='Angstrom') self.QuenchingSteps: int | IntKey = IntKey(name='QuenchingSteps', comment='Undocumented in EON.', hidden=True, default=0) self.RotateNonListedAtoms: BoolType | BoolKey = BoolKey(name='RotateNonListedAtoms', comment='If true, each iteration randomly rotates all atoms as a rigid body, excluding those listed in [BasinHopping%DisplaceListedAtoms], [BasinHopping%DisplaceListedTypes], or [BasinHopping%DisplaceAtomsInRegion].', default=False) self.SignificantStructure: BoolType | BoolKey = BoolKey(name='SignificantStructure', comment='If true, the Significant Structure Basin Hopping (SSBH) variant instead of the Raw Structure Basin Hopping method (RSBH). In SSBH previously found structures are used as initial structures for further displacements, see Chem. Phys. Lett. 289, 463 (1998) for a comparison of the two approaches.', hidden=True, default=True) self.SingleAtomDisplace: BoolType | BoolKey = BoolKey(name='SingleAtomDisplace', comment='If true, only one atom is displaced per step. Otherwise all atoms of the structure are randomly displaced.', hidden=True, default=False) self.Steps: int | IntKey = IntKey(name='Steps', comment='Number of displace & optimize Monte-Carlo steps to take.', default=20) self.StopEnergy: float | FloatKey = FloatKey(name='StopEnergy', comment='Undocumented in EON.', hidden=True, default=-1e+32) self.SwapProbability: float | FloatKey = FloatKey(name='SwapProbability', comment='The probability in range [0,1] that a swapping step takes place instead of a displacement step. The swap step selects two atoms of different elements and swaps their position.', hidden=True, default=0.0) self.TargetRatio: float | FloatKey = FloatKey(name='TargetRatio', comment='The target acceptance ratio that will be used to determine whether to increase or decrease the step size.', hidden=True, default=0.5) self.WriteUnique: BoolType | BoolKey = BoolKey(name='WriteUnique', comment='If true, all unique states found will be included in the energy landscape, even the rejected ones. If false, only the lowest energy structure will be included in the energy landscape.', hidden=True, default=True)
[docs] class _BindingSites(FixedBlock): r""" Options related to the calculation of binding sites. :ivar Calculate: Calculate binding sites at the end of a job. Not needed for Binding Sites job. :vartype Calculate: BoolType | BoolKey :ivar DistanceDifference: If the distance between two mapped binding-sites is larger than this threshold, the binding-sites are considered different. If not specified, its value will set equal to [PESExploration%StructureComparison%DistanceDifference] :vartype DistanceDifference: float | FloatKey :ivar MaxCoordinationShellsForLabels: The binding site labels are given based on the coordination numbers of shells in the reference region, using the following format: N<int><int>..., e.g., the label 'N334' means 3 atoms in the first coordination shell, 3 in the second one, and 4 in the third one. This parameter controls the maximum number of shells to include. :vartype MaxCoordinationShellsForLabels: int | IntKey :ivar NeighborCutoff: Atoms within this distance of each other are considered neighbors for the calculation of the binding sites. If not specified, its value will set equal to [PESExploration%StructureComparison%NeighborCutoff] :vartype NeighborCutoff: float | FloatKey :ivar ReferenceRegion: Defines the region that is considered as the reference for binding sites detection. Binding sites are projected on this region using the geometry from the reference system. If not specified, its value will set equal to [PESExploration%StatesAlignment%ReferenceRegion] :vartype ReferenceRegion: str | StringKey """ def __post_init__(self): self.Calculate: BoolType | BoolKey = BoolKey(name='Calculate', comment='Calculate binding sites at the end of a job. Not needed for Binding Sites job.', default=False) self.DistanceDifference: float | FloatKey = FloatKey(name='DistanceDifference', comment='If the distance between two mapped binding-sites is larger than this threshold, the binding-sites are considered different. If not specified, its value will set equal to [PESExploration%StructureComparison%DistanceDifference]', default=-1.0, unit='Angstrom') self.MaxCoordinationShellsForLabels: int | IntKey = IntKey(name='MaxCoordinationShellsForLabels', comment="The binding site labels are given based on the coordination numbers of shells in the reference region, using the following format: N<int><int>..., e.g., the label 'N334' means 3 atoms in the first coordination shell, 3 in the second one, and 4 in the third one. This parameter controls the maximum number of shells to include.", default=3) self.NeighborCutoff: float | FloatKey = FloatKey(name='NeighborCutoff', comment='Atoms within this distance of each other are considered neighbors for the calculation of the binding sites. If not specified, its value will set equal to [PESExploration%StructureComparison%NeighborCutoff]', default=-1.0, unit='Angstrom') self.ReferenceRegion: str | StringKey = StringKey(name='ReferenceRegion', comment='Defines the region that is considered as the reference for binding sites detection. Binding sites are projected on this region using the geometry from the reference system. If not specified, its value will set equal to [PESExploration%StatesAlignment%ReferenceRegion]', default='', gui_type='region')
[docs] class _Debug(FixedBlock): r""" ???. :ivar CompareGeometries: Compares the two given molecules in XYZ format by using the parameters available in the block [PESExploration%StructureComparison] :vartype CompareGeometries: str | StringKey :ivar KeepBadSaddles: ???. :vartype KeepBadSaddles: BoolType | BoolKey """ def __post_init__(self): self.CompareGeometries: str | StringKey = StringKey(name='CompareGeometries', comment='Compares the two given molecules in XYZ format by using the parameters available in the block [PESExploration%StructureComparison]', hidden=True, default='') self.KeepBadSaddles: BoolType | BoolKey = BoolKey(name='KeepBadSaddles', comment='???.', hidden=True, default=False)
[docs] class _Dynamics(FixedBlock): r""" ???. :ivar Thermostat: ???. :vartype Thermostat: Literal["andersen", "nose_hoover", "langevin", "none"] :ivar Time: ???. :vartype Time: float | FloatKey :ivar TimeStep: ???. :vartype TimeStep: float | FloatKey :ivar Andersen: ???. :vartype Andersen: AMS._PESExploration._Dynamics._Andersen :ivar Langevin: ???. :vartype Langevin: AMS._PESExploration._Dynamics._Langevin :ivar Nose: ???. :vartype Nose: AMS._PESExploration._Dynamics._Nose """
[docs] class _Andersen(FixedBlock): r""" ???. :ivar Alpha: ???. :vartype Alpha: float | FloatKey :ivar CollisionPeriod: ???. :vartype CollisionPeriod: float | FloatKey """ def __post_init__(self): self.Alpha: float | FloatKey = FloatKey(name='Alpha', comment='???.', default=1.0) self.CollisionPeriod: float | FloatKey = FloatKey(name='CollisionPeriod', comment='???.', default=100.0)
[docs] class _Langevin(FixedBlock): r""" ???. :ivar Friction: ???. :vartype Friction: float | FloatKey """ def __post_init__(self): self.Friction: float | FloatKey = FloatKey(name='Friction', comment='???.', default=0.01)
[docs] class _Nose(FixedBlock): r""" ???. :ivar Mass: ???. :vartype Mass: float | FloatKey """ def __post_init__(self): self.Mass: float | FloatKey = FloatKey(name='Mass', comment='???.', default=1.0)
def __post_init__(self): self.Thermostat: Literal["andersen", "nose_hoover", "langevin", "none"] = MultipleChoiceKey(name='Thermostat', comment='???.', default='none', choices=['andersen', 'nose_hoover', 'langevin', 'none']) self.Time: float | FloatKey = FloatKey(name='Time', comment='???.', default=1000.0) self.TimeStep: float | FloatKey = FloatKey(name='TimeStep', comment='???.', default=1.0) self.Andersen: AMS._PESExploration._Dynamics._Andersen = self._Andersen(name='Andersen', comment='???.') self.Langevin: AMS._PESExploration._Dynamics._Langevin = self._Langevin(name='Langevin', comment='???.') self.Nose: AMS._PESExploration._Dynamics._Nose = self._Nose(name='Nose', comment='???.')
[docs] class _Hessian(FixedBlock): r""" ???. :ivar AtomList: ???. :vartype AtomList: str | StringKey :ivar ZeroFreqValue: ???. :vartype ZeroFreqValue: float | FloatKey """ def __post_init__(self): self.AtomList: str | StringKey = StringKey(name='AtomList', comment='???.', default='all') self.ZeroFreqValue: float | FloatKey = FloatKey(name='ZeroFreqValue', comment='???.', default=1e-06)
[docs] class _LandscapeRefinement(FixedBlock): r""" Configures details of the energy landscape refinement job. :ivar CalculateOnlyEnergies: If true, the states' geometry is not optimized, and the final PES point characterization is ignored [PESExploration%LandscapeRefinement%IgnoreFinalPESPointCharacter]. Only energy values are updated using the specified engine. Furthermore, normal modes and associated properties are copied from the previous calculation to avoid the typically high computational effort of the Hessian matrix calculation. Enabling this option implies that RunInitialSinglePoints='F', IgnoreFinalPESPointCharacter='T'. :vartype CalculateOnlyEnergies: BoolType | BoolKey :ivar IgnoreFinalPESPointCharacter: At the end of the energy landscape refinement job, each state is assigned a PES point character (MIN or TS) based on its vibrational frequencies before being included in the final database. States are only added if the PES point character after refinement remains unchanged. However, states are added without verifying if this option is ``true``. Nonetheless, vibrational frequencies are calculated and stored for future analysis. This option is especially useful when using computationally demanding engines. Because in those cases, precision and computational effort must be balanced, resulting in significant vibrational frequencies inaccuracies. :vartype IgnoreFinalPESPointCharacter: BoolType | BoolKey :ivar IgnoreFinalPESPointCharacterForFragments: Same as ``LandscapeRefinement%IgnoreFinalPESPointCharacter`` but regarding the Fragments calculations, see option ``LandscapeRefinement%CalculateFragments``. :vartype IgnoreFinalPESPointCharacterForFragments: BoolType | BoolKey :ivar RelaxFromSaddlePoint: Relaxes the saddle point geometries following the imaginary mode to get both reactants and products. :vartype RelaxFromSaddlePoint: BoolType | BoolKey :ivar RunInitialSinglePoints: If it is ``true``, just after loading the energy landscape to refine, the single energy point computations are disabled. Be aware that if you enable this, the output file's 'Initial Energy Landscape' section will display incorrect states' energy values. If the engine requires too much processing power, this option can help you save a small amount of time. :vartype RunInitialSinglePoints: BoolType | BoolKey :ivar TransitionStateSearchMethod: Sets the method to refine transition states. :vartype TransitionStateSearchMethod: Literal["Auto", "Dimer"] :ivar UseReactantsAndProductsForTSs: For the refinement of transition states, the reaction coordinate can be estimated using either the reactants or products (final system). By enabling this option, the difference between the initial and final geometries is utilized as the reaction coordinate. The final system with the lowest RMSD is chosen to determine this coordinate. For more details see the section [TransitionStateSearch]. :vartype UseReactantsAndProductsForTSs: BoolType | BoolKey """ def __post_init__(self): self.CalculateOnlyEnergies: BoolType | BoolKey = BoolKey(name='CalculateOnlyEnergies', comment="If true, the states' geometry is not optimized, and the final PES point characterization is ignored [PESExploration%LandscapeRefinement%IgnoreFinalPESPointCharacter]. Only energy values are updated using the specified engine. Furthermore, normal modes and associated properties are copied from the previous calculation to avoid the typically high computational effort of the Hessian matrix calculation. Enabling this option implies that RunInitialSinglePoints='F', IgnoreFinalPESPointCharacter='T'.", default=False) self.IgnoreFinalPESPointCharacter: BoolType | BoolKey = BoolKey(name='IgnoreFinalPESPointCharacter', comment='At the end of the energy landscape refinement job, each state is assigned a PES point character (MIN or TS) based on its vibrational frequencies before being included in the final database. States are only added if the PES point character after refinement remains unchanged. However, states are added without verifying if this option is ``true``. Nonetheless, vibrational frequencies are calculated and stored for future analysis. This option is especially useful when using computationally demanding engines. Because in those cases, precision and computational effort must be balanced, resulting in significant vibrational frequencies inaccuracies.', default=False) self.IgnoreFinalPESPointCharacterForFragments: BoolType | BoolKey = BoolKey(name='IgnoreFinalPESPointCharacterForFragments', comment='Same as ``LandscapeRefinement%IgnoreFinalPESPointCharacter`` but regarding the Fragments calculations, see option ``LandscapeRefinement%CalculateFragments``.', gui_name='... for fragments:', default=False) self.RelaxFromSaddlePoint: BoolType | BoolKey = BoolKey(name='RelaxFromSaddlePoint', comment='Relaxes the saddle point geometries following the imaginary mode to get both reactants and products.', default=False) self.RunInitialSinglePoints: BoolType | BoolKey = BoolKey(name='RunInitialSinglePoints', comment="If it is ``true``, just after loading the energy landscape to refine, the single energy point computations are disabled. Be aware that if you enable this, the output file's 'Initial Energy Landscape' section will display incorrect states' energy values. If the engine requires too much processing power, this option can help you save a small amount of time.", default=True) self.TransitionStateSearchMethod: Literal["Auto", "Dimer"] = MultipleChoiceKey(name='TransitionStateSearchMethod', comment='Sets the method to refine transition states.', default='Auto', choices=['Auto', 'Dimer']) self.UseReactantsAndProductsForTSs: BoolType | BoolKey = BoolKey(name='UseReactantsAndProductsForTSs', comment='For the refinement of transition states, the reaction coordinate can be estimated using either the reactants or products (final system). By enabling this option, the difference between the initial and final geometries is utilized as the reaction coordinate. The final system with the lowest RMSD is chosen to determine this coordinate. For more details see the section [TransitionStateSearch].', hidden=True, default=False)
[docs] class _LoadEnergyLandscape(FixedBlock): r""" Options related to the loading of an Energy Landscape from a previous calculation. :ivar GenerateSymmetryImages: By activating this option, after loading the energy landscape, it will create the complete set of symmetry-related copies by using the symmetry operators of the reference structure. Be aware that rkf result files of the generated symmetry images are copies from the parent structures but only atomic coordinates are updated. :vartype GenerateSymmetryImages: BoolType | BoolKey :ivar KeepOnly: Upon loading the Energy Landscape, only keep the states specified here. The states should be specified via a list of integers referring to the indices of the states you want to keep. :vartype KeepOnly: Iterable[int] | IntListKey :ivar Path: AMS results folder to load an energy landscape from. In the text input file, you may alternatively specify a ``.con`` file in the native EON format. :vartype Path: str | Path | StringKey :ivar Remove: Upon loading the Energy Landscape, remove (i.e. do not load) the states specified here. The states should be specified via a list of integers referring to the indices of the states you want to remove (i.e. the states you don't want to load). :vartype Remove: Iterable[int] | IntListKey :ivar RemoveWithNoBindingSites: Upon loading the Energy Landscape, it removes states with no associated binding sites. Associated transition states are also removed. This is an advantageous option to remove physisorbed states automatically. Notice that it requires that the previous calculation was executed, enabling the option [BindingSites%Calculate]. :vartype RemoveWithNoBindingSites: BoolType | BoolKey :ivar SeedStates: By default when you start a new PES Exploration from a loaded Energy Landscape, expeditions can start from any of the loaded minima. By using this input option, you can instruct the program to only use some of the states as 'expedition starting point'. The states that serve as 'expedition starting points' should be specified via a list of integers referring to the indices of the states. :vartype SeedStates: Iterable[int] | IntListKey """ def __post_init__(self): self.GenerateSymmetryImages: BoolType | BoolKey = BoolKey(name='GenerateSymmetryImages', comment='By activating this option, after loading the energy landscape, it will create the complete set of symmetry-related copies by using the symmetry operators of the reference structure. Be aware that rkf result files of the generated symmetry images are copies from the parent structures but only atomic coordinates are updated.', default=False) self.KeepOnly: Iterable[int] | IntListKey = IntListKey(name='KeepOnly', comment='Upon loading the Energy Landscape, only keep the states specified here. The states should be specified via a list of integers referring to the indices of the states you want to keep.', gui_name='List of states to keep:') self.Path: str | Path | StringKey = PathStringKey(name='Path', comment='AMS results folder to load an energy landscape from. In the text input file, you may alternatively specify a ``.con`` file in the native EON format.', gui_name='Load energy landscape from:', ispath=True, gui_type='directory') self.Remove: Iterable[int] | IntListKey = IntListKey(name='Remove', comment="Upon loading the Energy Landscape, remove (i.e. do not load) the states specified here. The states should be specified via a list of integers referring to the indices of the states you want to remove (i.e. the states you don't want to load).", gui_name='List of states to remove:') self.RemoveWithNoBindingSites: BoolType | BoolKey = BoolKey(name='RemoveWithNoBindingSites', comment='Upon loading the Energy Landscape, it removes states with no associated binding sites. Associated transition states are also removed. This is an advantageous option to remove physisorbed states automatically. Notice that it requires that the previous calculation was executed, enabling the option [BindingSites%Calculate].', default=False) self.SeedStates: Iterable[int] | IntListKey = IntListKey(name='SeedStates', comment="By default when you start a new PES Exploration from a loaded Energy Landscape, expeditions can start from any of the loaded minima. By using this input option, you can instruct the program to only use some of the states as 'expedition starting point'. The states that serve as 'expedition starting points' should be specified via a list of integers referring to the indices of the states.", gui_name='List of seed states:')
[docs] class _LoadInitialSystems(FixedBlock): r""" Load initial systems from different sources. :ivar FromKFHistory: Load initial systems from the History section of kf files. :vartype FromKFHistory: AMS._PESExploration._LoadInitialSystems._FromKFHistory """
[docs] class _FromKFHistory(FixedBlock): r""" Load initial systems from the History section of kf files. :ivar Path: AMS results folder to load the initial systems from. In the text input file, you may alternatively specify a ``.kf`` file. By default, the ``ams.kf`` file will be used. :vartype Path: str | Path | StringKey :ivar TargetPESPointCharacter: Selects the PES point character for all loaded systems. :vartype TargetPESPointCharacter: Literal["MIN", "TS"] """ def __post_init__(self): self.Path: str | Path | StringKey = PathStringKey(name='Path', comment='AMS results folder to load the initial systems from. In the text input file, you may alternatively specify a ``.kf`` file. By default, the ``ams.kf`` file will be used.', gui_name='Load initial systems from:', ispath=True, gui_type='directory') self.TargetPESPointCharacter: Literal["MIN", "TS"] = MultipleChoiceKey(name='TargetPESPointCharacter', comment='Selects the PES point character for all loaded systems.', default='MIN', choices=['MIN', 'TS'])
def __post_init__(self): self.FromKFHistory: AMS._PESExploration._LoadInitialSystems._FromKFHistory = self._FromKFHistory(name='FromKFHistory', comment='Load initial systems from the History section of kf files.', unique=False)
[docs] class _NudgedElasticBand(FixedBlock): r""" Options for the Nudged Elastic Band (NEB) method. :ivar ClimbingImageConvergedOnly: ???. :vartype ClimbingImageConvergedOnly: BoolType | BoolKey :ivar ClimbingImageMethod: Use the climbing image algorithm to drive the highest image to the transition state. :vartype ClimbingImageMethod: BoolType | BoolKey :ivar ConvergedForce: Convergence threshold for nuclear gradients. Note: Special value of -1.0 means using the same convergence criterion as the PES explorer's geometry optimizer. :vartype ConvergedForce: float | FloatKey :ivar DoublyNudged: ???. :vartype DoublyNudged: BoolType | BoolKey :ivar DoublyNudgedSwitching: ???. :vartype DoublyNudgedSwitching: BoolType | BoolKey :ivar ElasticBand: ???. :vartype ElasticBand: BoolType | BoolKey :ivar Images: Number of NEB images between the two endpoints. :vartype Images: int | IntKey :ivar MaxIterations: Maximum number of NEB iterations. :vartype MaxIterations: int | IntKey :ivar OldTangent: Use the old central difference tangent. :vartype OldTangent: BoolType | BoolKey :ivar OptMethod: ???. :vartype OptMethod: str | StringKey :ivar Spring: Spring force constant. :vartype Spring: float | FloatKey """ def __post_init__(self): self.ClimbingImageConvergedOnly: BoolType | BoolKey = BoolKey(name='ClimbingImageConvergedOnly', comment='???.', hidden=True, default=True) self.ClimbingImageMethod: BoolType | BoolKey = BoolKey(name='ClimbingImageMethod', comment='Use the climbing image algorithm to drive the highest image to the transition state.', default=True) self.ConvergedForce: float | FloatKey = FloatKey(name='ConvergedForce', comment="Convergence threshold for nuclear gradients. Note: Special value of -1.0 means using the same convergence criterion as the PES explorer's geometry optimizer.", default=-1.0, unit='eV/Angstrom') self.DoublyNudged: BoolType | BoolKey = BoolKey(name='DoublyNudged', comment='???.', hidden=True, default=False) self.DoublyNudgedSwitching: BoolType | BoolKey = BoolKey(name='DoublyNudgedSwitching', comment='???.', hidden=True, default=False) self.ElasticBand: BoolType | BoolKey = BoolKey(name='ElasticBand', comment='???.', hidden=True, default=False) self.Images: int | IntKey = IntKey(name='Images', comment='Number of NEB images between the two endpoints.', default=5) self.MaxIterations: int | IntKey = IntKey(name='MaxIterations', comment='Maximum number of NEB iterations.', default=500) self.OldTangent: BoolType | BoolKey = BoolKey(name='OldTangent', comment='Use the old central difference tangent.', default=False) self.OptMethod: str | StringKey = StringKey(name='OptMethod', comment='???.', hidden=True, default='') self.Spring: float | FloatKey = FloatKey(name='Spring', comment='Spring force constant.', default=5.0, unit='eV/Ang^2')
[docs] class _Optimizer(FixedBlock): r""" Configures the details of the geometry optimizers used by the PES explorers. :ivar ConvergedForce: Convergence threshold for nuclear gradients. :vartype ConvergedForce: float | FloatKey :ivar ConvergenceMetric: Determines how the EON client checks the convergence of the forces. ``norm`` uses the Frobenius norm of the (3,nFreeAtoms) forces array. ``max_atom`` takes the maximum norm2 of the nFreeAtoms individual force vectors on the free atoms. ``max_component`` just takes the maximum of all elements in the array. Don't change this at the moment, as it will break snapshot writing to the history section of ams.rkf. :vartype ConvergenceMetric: Literal["norm", "max_atom", "max_component"] :ivar MaxIterations: Maximum number of iterations allowed for optimizations. :vartype MaxIterations: int | IntKey :ivar MaxMove: ???. :vartype MaxMove: float | FloatKey :ivar MaxTimeStep: ???. :vartype MaxTimeStep: float | FloatKey :ivar Method: Select the method for geometry optimizations. :vartype Method: Literal["CG", "QM", "LBFGS", "FIRE", "SD"] :ivar TimeStep: ???. :vartype TimeStep: float | FloatKey :ivar CG: ???. :vartype CG: AMS._PESExploration._Optimizer._CG :ivar LBFGS: ???. :vartype LBFGS: AMS._PESExploration._Optimizer._LBFGS :ivar QM: ???. :vartype QM: AMS._PESExploration._Optimizer._QM :ivar SD: ???. :vartype SD: AMS._PESExploration._Optimizer._SD """
[docs] class _CG(FixedBlock): r""" ???. :ivar KnockOutMaxMove: ???. :vartype KnockOutMaxMove: BoolType | BoolKey :ivar LineConverged: ???. :vartype LineConverged: float | FloatKey :ivar LineSearch: ???. :vartype LineSearch: BoolType | BoolKey :ivar LineSearchMaxIter: ???. :vartype LineSearchMaxIter: int | IntKey :ivar MaxIterBeforeReset: ???. :vartype MaxIterBeforeReset: int | IntKey :ivar NoOvershooting: ???. :vartype NoOvershooting: BoolType | BoolKey """ def __post_init__(self): self.KnockOutMaxMove: BoolType | BoolKey = BoolKey(name='KnockOutMaxMove', comment='???.', default=False) self.LineConverged: float | FloatKey = FloatKey(name='LineConverged', comment='???.', default=0.1) self.LineSearch: BoolType | BoolKey = BoolKey(name='LineSearch', comment='???.', default=False) self.LineSearchMaxIter: int | IntKey = IntKey(name='LineSearchMaxIter', comment='???.', default=10) self.MaxIterBeforeReset: int | IntKey = IntKey(name='MaxIterBeforeReset', comment='???.', default=0) self.NoOvershooting: BoolType | BoolKey = BoolKey(name='NoOvershooting', comment='???.', default=False)
[docs] class _LBFGS(FixedBlock): r""" ???. :ivar AngleReset: ???. :vartype AngleReset: BoolType | BoolKey :ivar AutoScale: ???. :vartype AutoScale: BoolType | BoolKey :ivar DistanceReset: ???. :vartype DistanceReset: BoolType | BoolKey :ivar InverseCurvature: ???. :vartype InverseCurvature: float | FloatKey :ivar Memory: ???. :vartype Memory: int | IntKey """ def __post_init__(self): self.AngleReset: BoolType | BoolKey = BoolKey(name='AngleReset', comment='???.', default=True) self.AutoScale: BoolType | BoolKey = BoolKey(name='AutoScale', comment='???.', default=True) self.DistanceReset: BoolType | BoolKey = BoolKey(name='DistanceReset', comment='???.', default=True) self.InverseCurvature: float | FloatKey = FloatKey(name='InverseCurvature', comment='???.', default=0.01) self.Memory: int | IntKey = IntKey(name='Memory', comment='???.', default=20)
[docs] class _QM(FixedBlock): r""" ???. :ivar SteepestDecent: ???. :vartype SteepestDecent: BoolType | BoolKey """ def __post_init__(self): self.SteepestDecent: BoolType | BoolKey = BoolKey(name='SteepestDecent', comment='???.', default=False)
[docs] class _SD(FixedBlock): r""" ???. :ivar Alpha: ???. :vartype Alpha: float | FloatKey :ivar TwoPoint: ???. :vartype TwoPoint: BoolType | BoolKey """ def __post_init__(self): self.Alpha: float | FloatKey = FloatKey(name='Alpha', comment='???.', default=0.1) self.TwoPoint: BoolType | BoolKey = BoolKey(name='TwoPoint', comment='???.', default=False)
def __post_init__(self): self.ConvergedForce: float | FloatKey = FloatKey(name='ConvergedForce', comment='Convergence threshold for nuclear gradients.', default=0.005, unit='eV/Angstrom') self.ConvergenceMetric: Literal["norm", "max_atom", "max_component"] = MultipleChoiceKey(name='ConvergenceMetric', comment="Determines how the EON client checks the convergence of the forces. ``norm`` uses the Frobenius norm of the (3,nFreeAtoms) forces array. ``max_atom`` takes the maximum norm2 of the nFreeAtoms individual force vectors on the free atoms. ``max_component`` just takes the maximum of all elements in the array. Don't change this at the moment, as it will break snapshot writing to the history section of ams.rkf.", hidden=True, default='max_atom', choices=['norm', 'max_atom', 'max_component']) self.MaxIterations: int | IntKey = IntKey(name='MaxIterations', comment='Maximum number of iterations allowed for optimizations.', default=400) self.MaxMove: float | FloatKey = FloatKey(name='MaxMove', comment='???.', hidden=True, default=0.2) self.MaxTimeStep: float | FloatKey = FloatKey(name='MaxTimeStep', comment='???.', hidden=True, default=2.5) self.Method: Literal["CG", "QM", "LBFGS", "FIRE", "SD"] = MultipleChoiceKey(name='Method', comment='Select the method for geometry optimizations.', default='CG', choices=['CG', 'QM', 'LBFGS', 'FIRE', 'SD']) self.TimeStep: float | FloatKey = FloatKey(name='TimeStep', comment='???.', hidden=True, default=1.0) self.CG: AMS._PESExploration._Optimizer._CG = self._CG(name='CG', comment='???.', hidden=True) self.LBFGS: AMS._PESExploration._Optimizer._LBFGS = self._LBFGS(name='LBFGS', comment='???.', hidden=True) self.QM: AMS._PESExploration._Optimizer._QM = self._QM(name='QM', comment='???.', hidden=True) self.SD: AMS._PESExploration._Optimizer._SD = self._SD(name='SD', comment='???.', hidden=True)
[docs] class _Parallel(FixedBlock): r""" Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel. :ivar nCoresPerGroup: Number of cores in each working group. :vartype nCoresPerGroup: int | IntKey :ivar nGroups: Total number of processor groups. This is the number of tasks that will be executed in parallel. :vartype nGroups: int | IntKey :ivar nNodesPerGroup: Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores. :vartype nNodesPerGroup: int | IntKey """ def __post_init__(self): self.nCoresPerGroup: int | IntKey = IntKey(name='nCoresPerGroup', comment='Number of cores in each working group.', gui_name='Cores per group:') self.nGroups: int | IntKey = IntKey(name='nGroups', comment='Total number of processor groups. This is the number of tasks that will be executed in parallel.', gui_name='Number of groups:') self.nNodesPerGroup: int | IntKey = IntKey(name='nNodesPerGroup', comment='Number of nodes in each group. This option should only be used on homogeneous compute clusters, where all used compute nodes have the same number of processor cores.', gui_name='Nodes per group:')
[docs] class _ParallelReplica(FixedBlock): r""" ???. :ivar DephaseLoopMax: ???. :vartype DephaseLoopMax: int | IntKey :ivar DephaseLoopStop: ???. :vartype DephaseLoopStop: BoolType | BoolKey :ivar DephaseTime: ???. :vartype DephaseTime: float | FloatKey :ivar PostTransitionTime: ???. :vartype PostTransitionTime: float | FloatKey :ivar RefineTransition: ???. :vartype RefineTransition: BoolType | BoolKey :ivar StateCheckInterval: ???. :vartype StateCheckInterval: float | FloatKey :ivar StateSaveInterval: ???. :vartype StateSaveInterval: float | FloatKey :ivar StopAfterTransition: ???. :vartype StopAfterTransition: BoolType | BoolKey """ def __post_init__(self): self.DephaseLoopMax: int | IntKey = IntKey(name='DephaseLoopMax', comment='???.', default=5) self.DephaseLoopStop: BoolType | BoolKey = BoolKey(name='DephaseLoopStop', comment='???.', default=False) self.DephaseTime: float | FloatKey = FloatKey(name='DephaseTime', comment='???.', default=1000.0) self.PostTransitionTime: float | FloatKey = FloatKey(name='PostTransitionTime', comment='???.', default=1000.0) self.RefineTransition: BoolType | BoolKey = BoolKey(name='RefineTransition', comment='???.', default=True) self.StateCheckInterval: float | FloatKey = FloatKey(name='StateCheckInterval', comment='???.', default=1000.0) self.StateSaveInterval: float | FloatKey = FloatKey(name='StateSaveInterval', comment='???.', default=-1.0) self.StopAfterTransition: BoolType | BoolKey = BoolKey(name='StopAfterTransition', comment='???.', default=False)
[docs] class _Prefactor(FixedBlock): r""" ???. :ivar Rate: Calculates reaction rate pre-exponential factors via: HTST (Harmonic Transition State Theory), QQHTST (quasi-quantum HTST), or None (disable calculation). :vartype Rate: Literal["HTST", "QQHTST", "None"] """ def __post_init__(self): self.Rate: Literal["HTST", "QQHTST", "None"] = MultipleChoiceKey(name='Rate', comment='Calculates reaction rate pre-exponential factors via: HTST (Harmonic Transition State Theory), QQHTST (quasi-quantum HTST), or None (disable calculation).', default='HTST', choices=['HTST', 'QQHTST', 'None'])
[docs] class _ProcessSearch(FixedBlock): r""" Input options specific to the process search procedure. :ivar MinimizationOffset: After a saddle is found, images are placed on either side of the saddle along the mode and minimized to ensure that the saddle is connected to the original minimum and to locate the product state. MinimizationOffset is the distance those images are displaced from the saddle. :vartype MinimizationOffset: float | FloatKey :ivar MinimizeFirst: If true, every time a process search is run by a client the reactant will be minimized first before doing any saddle searches. :vartype MinimizeFirst: BoolType | BoolKey """ def __post_init__(self): self.MinimizationOffset: float | FloatKey = FloatKey(name='MinimizationOffset', comment='After a saddle is found, images are placed on either side of the saddle along the mode and minimized to ensure that the saddle is connected to the original minimum and to locate the product state. MinimizationOffset is the distance those images are displaced from the saddle.', default=0.2) self.MinimizeFirst: BoolType | BoolKey = BoolKey(name='MinimizeFirst', comment='If true, every time a process search is run by a client the reactant will be minimized first before doing any saddle searches.', hidden=True, default=True)
[docs] class _SaddleSearch(FixedBlock): r""" Configuration for the Saddle Search procedure (used in SaddleSearch and ProcessSearch Jobs). :ivar ConvergedForce: Convergence threshold for nuclear gradients. Note: Special value of -1.0 means using the same convergence criterion as the PES explorer's geometry optimizer. :vartype ConvergedForce: float | FloatKey :ivar DisplaceAllAtoms: ???. :vartype DisplaceAllAtoms: BoolType | BoolKey :ivar DisplaceAllListed: ???. :vartype DisplaceAllListed: BoolType | BoolKey :ivar DisplaceAlongNormalModesActiveModes: Sets the active modes to be used when the option [SaddleSearch%DisplaceAlongNormalModesWeight] is enabled. e.g. 1,2,3,5. By default, all normal modes are considered active. :vartype DisplaceAlongNormalModesActiveModes: str | StringKey :ivar DisplaceAlongNormalModesWeight: The probability of generating a displacement resulting in a random linear combination of the normal modes specified in [SaddleSearch%DisplaceAlongNormalModesActiveModes]. This parameter is a numeric value that should fall within the interval [0.0, 1.0]. :vartype DisplaceAlongNormalModesWeight: float | FloatKey :ivar DisplaceAtomsInRegion: A string corresponding to the name of a region. When performing the initial random displacement, only displace atoms in the specified region. :vartype DisplaceAtomsInRegion: str | StringKey :ivar DisplaceAtomsInRegionWeight: The probability of generating a displacement involving only atoms from the region specified in [SaddleSearch%DisplaceAtomsInRegion]. This parameter is a numeric value that should fall within the interval [0.0, 1.0]. :vartype DisplaceAtomsInRegionWeight: float | FloatKey :ivar DisplaceLeastCoordinatedWeight: Relative probability to displace with an epicenter that has a coordination number equal to the least-coordinated atom in the configuration. :vartype DisplaceLeastCoordinatedWeight: float | FloatKey :ivar DisplaceListedAtomWeight: Relative probability to displace with an epicenter listed in displace_atomlist. :vartype DisplaceListedAtomWeight: float | FloatKey :ivar DisplaceListedAtoms: Sets the active atoms to be used when the option [SaddleSearch%DisplaceAlongNormalModesWeight] is enabled. e.g. 1,2,3,5. By default, all normal modes are considered active. :vartype DisplaceListedAtoms: str | StringKey :ivar DisplaceListedTypeWeight: Relative probability to displace with an epicenter listed in displace_typelist. :vartype DisplaceListedTypeWeight: float | FloatKey :ivar DisplaceListedTypes: ???. :vartype DisplaceListedTypes: str | StringKey :ivar DisplaceMagnitude: The standard deviation of the Gaussian displacement in each degree of freedom for the selected atoms. :vartype DisplaceMagnitude: float | FloatKey :ivar DisplaceMaxCoordination: ???. :vartype DisplaceMaxCoordination: int | IntKey :ivar DisplaceMinNorm: ???. :vartype DisplaceMinNorm: float | FloatKey :ivar DisplaceNotFCCHCPWeight: Relative probability to displace with an epicenter that is not FCC or HCP coordinated. :vartype DisplaceNotFCCHCPWeight: float | FloatKey :ivar DisplaceNotTCPBCCWeight: ???. :vartype DisplaceNotTCPBCCWeight: float | FloatKey :ivar DisplaceNotTCPWeight: ???. :vartype DisplaceNotTCPWeight: float | FloatKey :ivar DisplaceRadius: Atoms within this distance of the epicenter will be displaced. :vartype DisplaceRadius: float | FloatKey :ivar DisplaceRandomWeight: Relative probability to displace with a random epicenter. :vartype DisplaceRandomWeight: float | FloatKey :ivar DisplaceUnderCoordinatedWeight: Relative probability to displace with an epicenter with a coordination equal to or less than displace_max_coordination. :vartype DisplaceUnderCoordinatedWeight: float | FloatKey :ivar DisplaceWaterWeight: ???. :vartype DisplaceWaterWeight: float | FloatKey :ivar MaxEnergy: The energy (relative to the starting point of the saddle search) at which a saddle search explorer considers the search bad and terminates it. :vartype MaxEnergy: float | FloatKey :ivar MaxIterations: Maximum number of iterations for each saddle search run. :vartype MaxIterations: int | IntKey :ivar Method: Which saddle search method to use. :vartype Method: Literal["min_mode", "dynamics", "basin_hopping", "bgsd"] :ivar MinEnergyBarrier: Minimum energy barrier to accept a new transition state. :vartype MinEnergyBarrier: float | FloatKey :ivar MinModeMethod: The minimum-mode following method to use. :vartype MinModeMethod: Literal["dimer", "lanczos"] :ivar RandomMode: ???. :vartype RandomMode: BoolType | BoolKey :ivar RelaxFromSaddlePoint: Relaxes the saddle point geometries following the imaginary mode to get both reactants and products. :vartype RelaxFromSaddlePoint: BoolType | BoolKey :ivar RemoveRotation: ???. :vartype RemoveRotation: BoolType | BoolKey :ivar ZeroModeAbortCurvature: The threshold in the frequency below which the minimum mode is considered zero. The calculation is aborted if the negative mode becomes zero. :vartype ZeroModeAbortCurvature: float | FloatKey """ def __post_init__(self): self.ConvergedForce: float | FloatKey = FloatKey(name='ConvergedForce', comment="Convergence threshold for nuclear gradients. Note: Special value of -1.0 means using the same convergence criterion as the PES explorer's geometry optimizer.", default=-1.0, unit='eV/Angstrom') self.DisplaceAllAtoms: BoolType | BoolKey = BoolKey(name='DisplaceAllAtoms', comment='???.', hidden=True, default=False) self.DisplaceAllListed: BoolType | BoolKey = BoolKey(name='DisplaceAllListed', comment='???.', hidden=True, default=False) self.DisplaceAlongNormalModesActiveModes: str | StringKey = StringKey(name='DisplaceAlongNormalModesActiveModes', comment='Sets the active modes to be used when the option [SaddleSearch%DisplaceAlongNormalModesWeight] is enabled. e.g. 1,2,3,5. By default, all normal modes are considered active.', gui_name='Displace active modes:', default='') self.DisplaceAlongNormalModesWeight: float | FloatKey = FloatKey(name='DisplaceAlongNormalModesWeight', comment='The probability of generating a displacement resulting in a random linear combination of the normal modes specified in [SaddleSearch%DisplaceAlongNormalModesActiveModes]. This parameter is a numeric value that should fall within the interval [0.0, 1.0].', gui_name='Displace modes weight:', default=0.0) self.DisplaceAtomsInRegion: str | StringKey = StringKey(name='DisplaceAtomsInRegion', comment='A string corresponding to the name of a region. When performing the initial random displacement, only displace atoms in the specified region.', default='', gui_type='region') self.DisplaceAtomsInRegionWeight: float | FloatKey = FloatKey(name='DisplaceAtomsInRegionWeight', comment='The probability of generating a displacement involving only atoms from the region specified in [SaddleSearch%DisplaceAtomsInRegion]. This parameter is a numeric value that should fall within the interval [0.0, 1.0].', default=0.0) self.DisplaceLeastCoordinatedWeight: float | FloatKey = FloatKey(name='DisplaceLeastCoordinatedWeight', comment='Relative probability to displace with an epicenter that has a coordination number equal to the least-coordinated atom in the configuration.', hidden=True, default=0.0) self.DisplaceListedAtomWeight: float | FloatKey = FloatKey(name='DisplaceListedAtomWeight', comment='Relative probability to displace with an epicenter listed in displace_atomlist.', hidden=True, default=0.0) self.DisplaceListedAtoms: str | StringKey = StringKey(name='DisplaceListedAtoms', comment='Sets the active atoms to be used when the option [SaddleSearch%DisplaceAlongNormalModesWeight] is enabled. e.g. 1,2,3,5. By default, all normal modes are considered active.', default='') self.DisplaceListedTypeWeight: float | FloatKey = FloatKey(name='DisplaceListedTypeWeight', comment='Relative probability to displace with an epicenter listed in displace_typelist.', hidden=True, default=0.0) self.DisplaceListedTypes: str | StringKey = StringKey(name='DisplaceListedTypes', comment='???.', default='') self.DisplaceMagnitude: float | FloatKey = FloatKey(name='DisplaceMagnitude', comment='The standard deviation of the Gaussian displacement in each degree of freedom for the selected atoms.', default=0.1, unit='Angstrom') self.DisplaceMaxCoordination: int | IntKey = IntKey(name='DisplaceMaxCoordination', comment='???.', hidden=True, default=11) self.DisplaceMinNorm: float | FloatKey = FloatKey(name='DisplaceMinNorm', comment='???.', hidden=True, default=0.0) self.DisplaceNotFCCHCPWeight: float | FloatKey = FloatKey(name='DisplaceNotFCCHCPWeight', comment='Relative probability to displace with an epicenter that is not FCC or HCP coordinated.', hidden=True, default=0.0) self.DisplaceNotTCPBCCWeight: float | FloatKey = FloatKey(name='DisplaceNotTCPBCCWeight', comment='???.', hidden=True, default=0.0) self.DisplaceNotTCPWeight: float | FloatKey = FloatKey(name='DisplaceNotTCPWeight', comment='???.', hidden=True, default=0.0) self.DisplaceRadius: float | FloatKey = FloatKey(name='DisplaceRadius', comment='Atoms within this distance of the epicenter will be displaced.', default=4.0, unit='Angstrom') self.DisplaceRandomWeight: float | FloatKey = FloatKey(name='DisplaceRandomWeight', comment='Relative probability to displace with a random epicenter.', hidden=True, default=0.0) self.DisplaceUnderCoordinatedWeight: float | FloatKey = FloatKey(name='DisplaceUnderCoordinatedWeight', comment='Relative probability to displace with an epicenter with a coordination equal to or less than displace_max_coordination.', hidden=True, default=0.0) self.DisplaceWaterWeight: float | FloatKey = FloatKey(name='DisplaceWaterWeight', comment='???.', hidden=True, default=0.0) self.MaxEnergy: float | FloatKey = FloatKey(name='MaxEnergy', comment='The energy (relative to the starting point of the saddle search) at which a saddle search explorer considers the search bad and terminates it.', default=20.0, unit='eV') self.MaxIterations: int | IntKey = IntKey(name='MaxIterations', comment='Maximum number of iterations for each saddle search run.', default=400) self.Method: Literal["min_mode", "dynamics", "basin_hopping", "bgsd"] = MultipleChoiceKey(name='Method', comment='Which saddle search method to use.', hidden=True, default='min_mode', choices=['min_mode', 'dynamics', 'basin_hopping', 'bgsd']) self.MinEnergyBarrier: float | FloatKey = FloatKey(name='MinEnergyBarrier', comment='Minimum energy barrier to accept a new transition state.', default=0.001, unit='eV') self.MinModeMethod: Literal["dimer", "lanczos"] = MultipleChoiceKey(name='MinModeMethod', comment='The minimum-mode following method to use.', default='dimer', choices=['dimer', 'lanczos']) self.RandomMode: BoolType | BoolKey = BoolKey(name='RandomMode', comment='???.', hidden=True, default=True) self.RelaxFromSaddlePoint: BoolType | BoolKey = BoolKey(name='RelaxFromSaddlePoint', comment='Relaxes the saddle point geometries following the imaginary mode to get both reactants and products.', default=False) self.RemoveRotation: BoolType | BoolKey = BoolKey(name='RemoveRotation', comment='???.', hidden=True, default=False) self.ZeroModeAbortCurvature: float | FloatKey = FloatKey(name='ZeroModeAbortCurvature', comment='The threshold in the frequency below which the minimum mode is considered zero. The calculation is aborted if the negative mode becomes zero.', default=0.01, unit='eV/Angstrom^2')
[docs] class _StatesAlignment(FixedBlock): r""" Configures details of how the energy landscape configurations are aligned respect to the main chemical system [System]. :ivar DistanceDifference: If the distance between two mapped atoms is larger than this threshold, the configuration is considered not aligned. If not specified, its value will set equal to [PESExploration%StructureComparison%DistanceDifference] :vartype DistanceDifference: float | FloatKey :ivar ReferenceRegion: Defines the region that is considered as the reference for alignments. Atoms outside this region are ignored in the alignments. :vartype ReferenceRegion: str | StringKey :ivar RemoveUnaligned: ???. :vartype RemoveUnaligned: BoolType | BoolKey """ def __post_init__(self): self.DistanceDifference: float | FloatKey = FloatKey(name='DistanceDifference', comment='If the distance between two mapped atoms is larger than this threshold, the configuration is considered not aligned. If not specified, its value will set equal to [PESExploration%StructureComparison%DistanceDifference]', default=-1.0, unit='Angstrom') self.ReferenceRegion: str | StringKey = StringKey(name='ReferenceRegion', comment='Defines the region that is considered as the reference for alignments. Atoms outside this region are ignored in the alignments.', default='', gui_type='region') self.RemoveUnaligned: BoolType | BoolKey = BoolKey(name='RemoveUnaligned', comment='???.', hidden=True, default=False)
[docs] class _StructureComparison(FixedBlock): r""" Settings for structure comparison. :ivar CheckRotation: Rotates the system optimally before comparing structures. The default is to do this only for molecular systems when there are no fixed atom constraints. :vartype CheckRotation: BoolType | BoolKey :ivar CheckSymmetry: Considers that two systems are equal if they are equivalent by symmetry. :vartype CheckSymmetry: BoolType | BoolKey :ivar CovalentScale: Scale factor for the covalent distances used in the neighboring detection. Only used if [StructureComparison%UseCovalent] is enabled. This is an experimental feature! :vartype CovalentScale: float | FloatKey :ivar DistanceDifference: If the distance between two mapped atoms is larger than this threshold, the two configurations are considered different structures. :vartype DistanceDifference: float | FloatKey :ivar EnergyDifference: If the energy difference between two configurations is larger than this threshold, the two configurations are considered to be different structures. :vartype EnergyDifference: float | FloatKey :ivar IndistinguishableAtoms: If yes, the order of the atoms does not affect the structural comparison. Atoms of the same element are then indistinguishable. :vartype IndistinguishableAtoms: BoolType | BoolKey :ivar NeighborCutoff: Atoms within this distance of each other are considered neighbors. :vartype NeighborCutoff: float | FloatKey :ivar RemoveTranslation: Translates the system optimally before comparing structures. The default is to do this only when there are no fixed atom constraints. :vartype RemoveTranslation: BoolType | BoolKey :ivar UseCovalent: Atoms are considered neighbors if the distance between them is lower than [StructureComparison%CovalentScale] times the covalent distance calculated following M. O'Keeffe and N.E. Brese, J. Am. Chem.Soc. 113 (1991) 3226. This is an experimental feature! :vartype UseCovalent: BoolType | BoolKey """ def __post_init__(self): self.CheckRotation: BoolType | BoolKey = BoolKey(name='CheckRotation', comment='Rotates the system optimally before comparing structures. The default is to do this only for molecular systems when there are no fixed atom constraints.') self.CheckSymmetry: BoolType | BoolKey = BoolKey(name='CheckSymmetry', comment='Considers that two systems are equal if they are equivalent by symmetry.', default=False) self.CovalentScale: float | FloatKey = FloatKey(name='CovalentScale', comment='Scale factor for the covalent distances used in the neighboring detection. Only used if [StructureComparison%UseCovalent] is enabled. This is an experimental feature!', hidden=True, default=1.3) self.DistanceDifference: float | FloatKey = FloatKey(name='DistanceDifference', comment='If the distance between two mapped atoms is larger than this threshold, the two configurations are considered different structures.', default=0.1, unit='Angstrom') self.EnergyDifference: float | FloatKey = FloatKey(name='EnergyDifference', comment='If the energy difference between two configurations is larger than this threshold, the two configurations are considered to be different structures.', default=0.01, unit='eV') self.IndistinguishableAtoms: BoolType | BoolKey = BoolKey(name='IndistinguishableAtoms', comment='If yes, the order of the atoms does not affect the structural comparison. Atoms of the same element are then indistinguishable.', default=True) self.NeighborCutoff: float | FloatKey = FloatKey(name='NeighborCutoff', comment='Atoms within this distance of each other are considered neighbors.', default=3.3, unit='Angstrom') self.RemoveTranslation: BoolType | BoolKey = BoolKey(name='RemoveTranslation', comment='Translates the system optimally before comparing structures. The default is to do this only when there are no fixed atom constraints.') self.UseCovalent: BoolType | BoolKey = BoolKey(name='UseCovalent', comment="Atoms are considered neighbors if the distance between them is lower than [StructureComparison%CovalentScale] times the covalent distance calculated following M. O'Keeffe and N.E. Brese, J. Am. Chem.Soc. 113 (1991) 3226. This is an experimental feature!", hidden=True, default=False)
def __post_init__(self): self.CalculateEnergyReferences: BoolType | BoolKey = BoolKey(name='CalculateEnergyReferences', comment='Calculates the energy references.', default=False) self.CalculateFragments: BoolType | BoolKey = BoolKey(name='CalculateFragments', comment='Must be used together with an adsorbent set as the StatesAlignment%ReferenceRegion. Runs a final calculation of the adsorbate and adsorbent (marked by the ReferenceRegion) individually. The fragmented state is included in the energy landscape.', default=False) self.DynamicSeedStates: BoolType | BoolKey = BoolKey(name='DynamicSeedStates', comment='Whether subsequent expeditions may start from states discovered by previous expeditions. This should lead to a more comprehensive exploration of the potential energy surface. Disabling this will focus the PES exploration around the initial seed states.', default=True) self.FiniteDifference: float | FloatKey = FloatKey(name='FiniteDifference', comment='The finite difference distance to use for Dimer, Hessian, Lanczos, and optimization methods.', default=0.0026458861, unit='Angstrom') self.GenerateSymmetryImages: BoolType | BoolKey = BoolKey(name='GenerateSymmetryImages', comment='By activating this option, after concluding the energy landscape exploration process, it will create the complete set of symmetry-related copies by using the symmetry operators of the reference structure. SinglePoint calculations (including gradients and normal modes) are carried out for each new image structure obtained.', hidden=True, default=False) self.Job: Literal["ProcessSearch", "BasinHopping", "SaddleSearch", "LandscapeRefinement", "BindingSites", "NudgedElasticBand", "SystemMatching"] = MultipleChoiceKey(name='Job', comment='Specify the PES exploration job to perform.', choices=['ProcessSearch', 'BasinHopping', 'SaddleSearch', 'LandscapeRefinement', 'BindingSites', 'NudgedElasticBand', 'SystemMatching'], hiddenchoices=['NudgedElasticBand', 'SystemMatching']) self.NegativeEigenvalueTolerance: float | FloatKey = FloatKey(name='NegativeEigenvalueTolerance', comment='The threshold in Hessian eigenvalue below which a mode is considered imaginary, i.e. indicating a transition state. This is a small negative number, as very small negative eigenvalues may be due to numerical noise on an essentially flat PES and do not indicate true transition states. We need a more flexible value for this parameter in PESExploration because the high computational cost of the task typically forces us to reduce the engine precision, which increases the noise in the vibrational frequencies evaluation. [PESPointCharacter%NegativeEigenvalueTolerance] is overridden by this parameter.', default=-0.0005, unit='Hartree/Bohr^2') self.NumExpeditions: int | IntKey = IntKey(name='NumExpeditions', comment='Sets the number of subsequent expeditions our job will consist of. Larger values result in a more comprehensive exploration of the potential energy surface, but will take more computational time.', default=1) self.NumExplorers: int | IntKey = IntKey(name='NumExplorers', comment='Sets the number of independent PES explorers dispatched as part of each expedition. Larger values will result in a more comprehensive exploration of the potential energy surface, but will take more computational time. By default an appropriate number of explorers are executed in parallel.', default=1) self.OptTSMethod: Literal["SaddleSearch", "NudgedElasticBand"] = MultipleChoiceKey(name='OptTSMethod', comment='When the full set of states in the energy landscape are optimized (see PESExploration%Job = GeometryOptimization), transition states can be optimized using either SaddleSearch or NudgedElasticBand methods. SaddleSearch uses information only from the current geometry of the TS; contrary, NudgedElasticBand ignores the current geometry and runs a Nudged-Elastic-Band calculation trying to connect the associated reactants and products if they are available.', default='SaddleSearch', choices=['SaddleSearch', 'NudgedElasticBand']) self.Potential: str | StringKey = StringKey(name='Potential', comment="The PES to be explored. The default is to use a callback into AMS to evaluate the energy and gradients using an AMS engine. This can be changed here to give access to one of the EON client's builtin potentials. This has not been well tested by SCM.", hidden=True, default='ams-engine') self.RandomSeed: int | IntKey = IntKey(name='RandomSeed', comment='Number used to initialize both the EON clients random number generators as well as the AMS global RNG. The latter is normally initialized with the RNGSeed keyword at the root level. Should be used by developers only. May or may not help to make more reproducible regression tests ...') self.SelectedListedAtomsForPESPointCharacter: str | StringKey = StringKey(name='SelectedListedAtomsForPESPointCharacter', comment='Uses the Hessian matrix elements only for the listed atoms to determine the PES point character of a located state during the exploration. If not specified, the full Hessian is used.', gui_name='PESPoint character for atoms:', default='') self.SelectedRegionForPESPointCharacter: str | StringKey = StringKey(name='SelectedRegionForPESPointCharacter', comment='Uses the Hessian matrix elements only for the atoms in a particular region to determine the PES point character of a located state during the exploration. If not specified, the full Hessian is used.', gui_name='PESPoint character for region:', default='', gui_type='region') self.Temperature: float | FloatKey = FloatKey(name='Temperature', comment='The temperature that the job will run at. This may be used in different ways depending on the job, e.g. acceptance probabilities for Monte-Carlo based jobs, thermostatting for dynamics based jobs, kinetic prefactors for jobs that find transition states. Some jobs may not use this temperature at all.', default=300.0, unit='Kelvin') self.WriteEngineGradients: BoolType | BoolKey = BoolKey(name='WriteEngineGradients', comment='Write atomic gradients (negative of the atomic forces, as calculated by the engine) to the History section of ams.rkf.', default=False) self.WriteHistory: Literal["None", "Converged", "All"] = MultipleChoiceKey(name='WriteHistory', comment='When to write the molecular geometry (and possibly other properties) to the history on the ams.rkf file. The default is to only write the converged geometries to the history. Can be changed to write no frames at all to the history, or write all frames (should only be used when testing because of the performance impact). Note that for parallel calculations, only the first group of processes writes to ams.rkf.', default='Converged', choices=['None', 'Converged', 'All']) self.BasinHopping: AMS._PESExploration._BasinHopping = self._BasinHopping(name='BasinHopping', comment='Configures the details of the Basin Hopping subtask.') self.BindingSites: AMS._PESExploration._BindingSites = self._BindingSites(name='BindingSites', comment='Options related to the calculation of binding sites.') self.Debug: AMS._PESExploration._Debug = self._Debug(name='Debug', comment='???.') self.Dynamics: AMS._PESExploration._Dynamics = self._Dynamics(name='Dynamics', comment='???.') self.Hessian: AMS._PESExploration._Hessian = self._Hessian(name='Hessian', comment='???.') self.LandscapeRefinement: AMS._PESExploration._LandscapeRefinement = self._LandscapeRefinement(name='LandscapeRefinement', comment='Configures details of the energy landscape refinement job.') self.LoadEnergyLandscape: AMS._PESExploration._LoadEnergyLandscape = self._LoadEnergyLandscape(name='LoadEnergyLandscape', comment='Options related to the loading of an Energy Landscape from a previous calculation.') self.LoadInitialSystems: AMS._PESExploration._LoadInitialSystems = self._LoadInitialSystems(name='LoadInitialSystems', comment='Load initial systems from different sources.') self.NudgedElasticBand: AMS._PESExploration._NudgedElasticBand = self._NudgedElasticBand(name='NudgedElasticBand', comment='Options for the Nudged Elastic Band (NEB) method.') self.Optimizer: AMS._PESExploration._Optimizer = self._Optimizer(name='Optimizer', comment='Configures the details of the geometry optimizers used by the PES explorers.') self.Parallel: AMS._PESExploration._Parallel = self._Parallel(name='Parallel', comment='Options for double parallelization, which allows to split the available processor cores into groups working through all the available tasks in parallel, resulting in a better parallel performance. The keys in this block determine how to split the available processor cores into groups working in parallel.', extra_info='not_in_fragment', shared_id='AMSParallel') self.ParallelReplica: AMS._PESExploration._ParallelReplica = self._ParallelReplica(name='ParallelReplica', comment='???.') self.Prefactor: AMS._PESExploration._Prefactor = self._Prefactor(name='Prefactor', comment='???.') self.ProcessSearch: AMS._PESExploration._ProcessSearch = self._ProcessSearch(name='ProcessSearch', comment='Input options specific to the process search procedure.') self.SaddleSearch: AMS._PESExploration._SaddleSearch = self._SaddleSearch(name='SaddleSearch', comment='Configuration for the Saddle Search procedure (used in SaddleSearch and ProcessSearch Jobs).') self.StatesAlignment: AMS._PESExploration._StatesAlignment = self._StatesAlignment(name='StatesAlignment', comment='Configures details of how the energy landscape configurations are aligned respect to the main chemical system [System].') self.StructureComparison: AMS._PESExploration._StructureComparison = self._StructureComparison(name='StructureComparison', comment='Settings for structure comparison.')
[docs] class _PESPointCharacter(FixedBlock): r""" Options for the characterization of PES points. :ivar Displacement: Controls the size of the displacements used for numerical differentiation: The displaced geometries are calculated by taking the original coordinates and adding the mass-weighted mode times the reduced mass of the mode times the value of this keyword. :vartype Displacement: float | FloatKey :ivar NegativeEigenvalueTolerance: The threshold in Hessian eigenvalue below which a mode is considered imaginary, i.e. indicating a transition state. This is a small negative number, as very small negative eigenvalues may be due to numerical noise on an essentially flat PES and do not indicate true transition states. :vartype NegativeEigenvalueTolerance: float | FloatKey :ivar NegativeFrequenciesTolerance: The threshold in frequencies below which a mode is considered imaginary, i.e. indicating a transition state. Deprecated. Use NegativeEigenvalueTolerance instead. :vartype NegativeFrequenciesTolerance: float | FloatKey :ivar NumberOfModes: The number of (lowest) eigenvalues that should be checked. :vartype NumberOfModes: int | IntKey :ivar Tolerance: Convergence tolerance for residual in iterative Davidson diagonalization. :vartype Tolerance: float | FloatKey """ def __post_init__(self): self.Displacement: float | FloatKey = FloatKey(name='Displacement', comment='Controls the size of the displacements used for numerical differentiation: The displaced geometries are calculated by taking the original coordinates and adding the mass-weighted mode times the reduced mass of the mode times the value of this keyword.', default=0.04) self.NegativeEigenvalueTolerance: float | FloatKey = FloatKey(name='NegativeEigenvalueTolerance', comment='The threshold in Hessian eigenvalue below which a mode is considered imaginary, i.e. indicating a transition state. This is a small negative number, as very small negative eigenvalues may be due to numerical noise on an essentially flat PES and do not indicate true transition states.', default=-0.0001, unit='Hartree/Bohr^2') self.NegativeFrequenciesTolerance: float | FloatKey = FloatKey(name='NegativeFrequenciesTolerance', comment='The threshold in frequencies below which a mode is considered imaginary, i.e. indicating a transition state. Deprecated. Use NegativeEigenvalueTolerance instead.', hidden=True, default=-10.0, unit='cm-1') self.NumberOfModes: int | IntKey = IntKey(name='NumberOfModes', comment='The number of (lowest) eigenvalues that should be checked.', default=2) self.Tolerance: float | FloatKey = FloatKey(name='Tolerance', comment='Convergence tolerance for residual in iterative Davidson diagonalization.', default=0.016)
[docs] class _PESScan(FixedBlock): r""" Configures the details of the potential energy surface scanning task. :ivar CalcPropertiesAtPESPoints: Whether to perform an additional calculation with properties on all the sampled points of the PES. If this option is enabled AMS will produce a separate engine output file for every sampled PES point. :vartype CalcPropertiesAtPESPoints: BoolType | BoolKey :ivar FillUnconvergedGaps: After the initial pass over the PES, restart the unconverged points from converged neighboring points. :vartype FillUnconvergedGaps: BoolType | BoolKey :ivar ScanCoordinate: Specifies a coordinate along which the potential energy surface is scanned. If this block contains multiple entries, these coordinates will be varied and scanned together as if they were one. Note that there can be only one ScanCoordinate containing a lattice scan in any PES scan job. :vartype ScanCoordinate: AMS._PESScan._ScanCoordinate """
[docs] class _ScanCoordinate(FixedBlock): r""" Specifies a coordinate along which the potential energy surface is scanned. If this block contains multiple entries, these coordinates will be varied and scanned together as if they were one. Note that there can be only one ScanCoordinate containing a lattice scan in any PES scan job. :ivar Angle: Scan the angle between three atoms. Three atom indices followed by two real numbers delimiting the transit range in degrees. :vartype Angle: str | StringKey :ivar CellVolumeRange: Two numbers for the initial and final cell volume. The cell is scaled isotropically between these values. Can not be used together with any other coordinate within the same ScanCoordinate block. :vartype CellVolumeRange: Iterable[float] | FloatListKey :ivar CellVolumeScalingRange: Two scaling factors for the initial and final cell volume. A value of '0.9 1.1' would result in an isotropic scaling between 90% and 110% of the cell volume of the input system. Can not be used together with any other coordinate within the same ScanCoordinate block. :vartype CellVolumeScalingRange: Iterable[float] | FloatListKey :ivar Coordinate: Scan a particular coordinate of an atom. Atom index followed by (x|y|z) followed by two real numbers delimiting the transit range. :vartype Coordinate: str | StringKey :ivar DifDist: Scan the difference distance between two pairs of atoms, R(12)-R(34). Four atom indices followed by two real numbers delimiting the transit range in Angstrom. :vartype DifDist: str | StringKey :ivar Dihedral: Scan the dihedral angle between four atoms. Four atom indices followed by two real numbers delimiting the transit angle in degrees. :vartype Dihedral: str | StringKey :ivar Distance: Scan the distance between two atoms. Two atom indices followed by two real numbers delimiting the transit distance in Angstrom. :vartype Distance: str | StringKey :ivar FromStrainVoigt: The elements of the initial lattice strain in Voigt notation. One should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems. Has to be used in combination with the ToStrainVoigt keyword and no other coordinate within the same ScanCoordinate block. :vartype FromStrainVoigt: Iterable[float] | FloatListKey :ivar LatticeARange: Scans the length of the first lattice vector. Can be combined with the LatticeBRange and LatticeCRange keywords, but no other coordinates within the same ScanCoordinate. :vartype LatticeARange: Iterable[float] | FloatListKey :ivar LatticeBRange: Scans the length of the second lattice vector. Can be combined with the LatticeARange and LatticeCRange keyword, but no other coordinates within the same ScanCoordinate.. :vartype LatticeBRange: Iterable[float] | FloatListKey :ivar LatticeCRange: Scans the length of the third lattice vector. Can be combined with the LatticeARange and LatticeBRange keyword, but no other coordinates within the same ScanCoordinate.. :vartype LatticeCRange: Iterable[float] | FloatListKey :ivar SumDist: Scan the sum of distances between two pairs of atoms, R(12)+R(34). Four atom indices followed by two real numbers delimiting the transit range in Angstrom. :vartype SumDist: str | StringKey :ivar ToStrainVoigt: The elements of the final lattice strain in Voigt notation. One should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems. :vartype ToStrainVoigt: Iterable[float] | FloatListKey :ivar nPoints: The number of points along the scanned coordinate. Must be greater or equal 2. :vartype nPoints: int | IntKey :ivar FromLattice: Up to three lattice vectors to start the scan at. Has to be used in combination with the ToLattice keyword and no other coordinate within the same ScanCoordinate block. Unit can be specified in the header. Default unit is Angstrom. :vartype FromLattice: str | Sequence[str] | FreeBlock :ivar ToLattice: Up to three lattice vectors to end the scan at. Unit can be specified in the header. Default unit is Angstrom. :vartype ToLattice: str | Sequence[str] | FreeBlock """
[docs] class _FromLattice(FreeBlock): r""" Up to three lattice vectors to start the scan at. Has to be used in combination with the ToLattice keyword and no other coordinate within the same ScanCoordinate block. Unit can be specified in the header. Default unit is Angstrom. """ def __post_init__(self): pass
[docs] class _ToLattice(FreeBlock): r""" Up to three lattice vectors to end the scan at. Unit can be specified in the header. Default unit is Angstrom. """ def __post_init__(self): pass
def __post_init__(self): self.Angle: str | StringKey = StringKey(name='Angle', comment='Scan the angle between three atoms. Three atom indices followed by two real numbers delimiting the transit range in degrees.', unique=False) self.CellVolumeRange: Iterable[float] | FloatListKey = FloatListKey(name='CellVolumeRange', comment='Two numbers for the initial and final cell volume. The cell is scaled isotropically between these values. Can not be used together with any other coordinate within the same ScanCoordinate block.', unit='Angstrom^3') self.CellVolumeScalingRange: Iterable[float] | FloatListKey = FloatListKey(name='CellVolumeScalingRange', comment="Two scaling factors for the initial and final cell volume. A value of '0.9 1.1' would result in an isotropic scaling between 90% and 110% of the cell volume of the input system. Can not be used together with any other coordinate within the same ScanCoordinate block.") self.Coordinate: str | StringKey = StringKey(name='Coordinate', comment='Scan a particular coordinate of an atom. Atom index followed by (x|y|z) followed by two real numbers delimiting the transit range.', unique=False) self.DifDist: str | StringKey = StringKey(name='DifDist', comment='Scan the difference distance between two pairs of atoms, R(12)-R(34). Four atom indices followed by two real numbers delimiting the transit range in Angstrom.', unique=False) self.Dihedral: str | StringKey = StringKey(name='Dihedral', comment='Scan the dihedral angle between four atoms. Four atom indices followed by two real numbers delimiting the transit angle in degrees.', unique=False) self.Distance: str | StringKey = StringKey(name='Distance', comment='Scan the distance between two atoms. Two atom indices followed by two real numbers delimiting the transit distance in Angstrom.', unique=False) self.FromStrainVoigt: Iterable[float] | FloatListKey = FloatListKey(name='FromStrainVoigt', comment='The elements of the initial lattice strain in Voigt notation. One should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems. Has to be used in combination with the ToStrainVoigt keyword and no other coordinate within the same ScanCoordinate block.') self.LatticeARange: Iterable[float] | FloatListKey = FloatListKey(name='LatticeARange', comment='Scans the length of the first lattice vector. Can be combined with the LatticeBRange and LatticeCRange keywords, but no other coordinates within the same ScanCoordinate.', unit='Angstrom') self.LatticeBRange: Iterable[float] | FloatListKey = FloatListKey(name='LatticeBRange', comment='Scans the length of the second lattice vector. Can be combined with the LatticeARange and LatticeCRange keyword, but no other coordinates within the same ScanCoordinate..', unit='Angstrom') self.LatticeCRange: Iterable[float] | FloatListKey = FloatListKey(name='LatticeCRange', comment='Scans the length of the third lattice vector. Can be combined with the LatticeARange and LatticeBRange keyword, but no other coordinates within the same ScanCoordinate..', unit='Angstrom') self.SumDist: str | StringKey = StringKey(name='SumDist', comment='Scan the sum of distances between two pairs of atoms, R(12)+R(34). Four atom indices followed by two real numbers delimiting the transit range in Angstrom.', unique=False) self.ToStrainVoigt: Iterable[float] | FloatListKey = FloatListKey(name='ToStrainVoigt', comment='The elements of the final lattice strain in Voigt notation. One should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems.') self.nPoints: int | IntKey = IntKey(name='nPoints', comment='The number of points along the scanned coordinate. Must be greater or equal 2.', default=10) self.FromLattice: str | Sequence[str] | FreeBlock = self._FromLattice(name='FromLattice', comment='Up to three lattice vectors to start the scan at. Has to be used in combination with the ToLattice keyword and no other coordinate within the same ScanCoordinate block. Unit can be specified in the header. Default unit is Angstrom.', header=True) self.ToLattice: str | Sequence[str] | FreeBlock = self._ToLattice(name='ToLattice', comment='Up to three lattice vectors to end the scan at. Unit can be specified in the header. Default unit is Angstrom.', header=True)
def __post_init__(self): self.CalcPropertiesAtPESPoints: BoolType | BoolKey = BoolKey(name='CalcPropertiesAtPESPoints', comment='Whether to perform an additional calculation with properties on all the sampled points of the PES. If this option is enabled AMS will produce a separate engine output file for every sampled PES point.', default=False) self.FillUnconvergedGaps: BoolType | BoolKey = BoolKey(name='FillUnconvergedGaps', comment='After the initial pass over the PES, restart the unconverged points from converged neighboring points.', default=True) self.ScanCoordinate: AMS._PESScan._ScanCoordinate = self._ScanCoordinate(name='ScanCoordinate', comment='Specifies a coordinate along which the potential energy surface is scanned. If this block contains multiple entries, these coordinates will be varied and scanned together as if they were one. Note that there can be only one ScanCoordinate containing a lattice scan in any PES scan job.', unique=False)
[docs] class _Phonons(FixedBlock): r""" Configures the phonons calculation. :ivar BandStructure: Calculates and saves the phonon band structure for visualization. Further configuration options for analytical calculations may be available in the engine-specific settings (``Phonons%BandStructure``). :vartype BandStructure: BoolType | BoolKey :ivar DOS: Calculates and saves the phonon density of states (DOS) for visualization. Further configuration options for analytical calculations may be available in the engine-specific settings (``Phonons%DOS``). :vartype DOS: BoolType | BoolKey :ivar Method: Determines how phonons are calculated. ``Auto`` selects the analytical method if supported by the engine, otherwise it defaults to numerical calculation. Configure numerical parameters in the ``NumericalPhonons`` section. Engine-specific options for analytical phonon calculations may be available in ``Engine%Phonons``. :vartype Method: Literal["Auto", "Analytical", "Numerical"] """ def __post_init__(self): self.BandStructure: BoolType | BoolKey = BoolKey(name='BandStructure', comment='Calculates and saves the phonon band structure for visualization. Further configuration options for analytical calculations may be available in the engine-specific settings (``Phonons%BandStructure``).', gui_name='Calculate phonons band structure:', default=True) self.DOS: BoolType | BoolKey = BoolKey(name='DOS', comment='Calculates and saves the phonon density of states (DOS) for visualization. Further configuration options for analytical calculations may be available in the engine-specific settings (``Phonons%DOS``).', gui_name='Calculate phonon DOS:', default=True) self.Method: Literal["Auto", "Analytical", "Numerical"] = MultipleChoiceKey(name='Method', comment='Determines how phonons are calculated. ``Auto`` selects the analytical method if supported by the engine, otherwise it defaults to numerical calculation. Configure numerical parameters in the ``NumericalPhonons`` section. Engine-specific options for analytical phonon calculations may be available in ``Engine%Phonons``.', default='Auto', choices=['Auto', 'Analytical', 'Numerical'])
[docs] class _Print(FixedBlock): r""" This block controls the printing of additional information to stdout. :ivar Timers: Printing timing details to see how much time is spend in which part of the code. :vartype Timers: Literal["None", "Normal", "Detail", "TooMuchDetail"] """ def __post_init__(self): self.Timers: Literal["None", "Normal", "Detail", "TooMuchDetail"] = MultipleChoiceKey(name='Timers', comment='Printing timing details to see how much time is spend in which part of the code.', default='None', choices=['None', 'Normal', 'Detail', 'TooMuchDetail'])
[docs] class _Properties(FixedBlock): r""" Configures which AMS level properties to calculate for SinglePoint calculations or other important geometries (e.g. at the end of an optimization). :ivar BondOrders: Requests the engine to calculate bond orders. For MM engines these might just be the defined bond orders that go into the force-field, while for QM engines, this might trigger a bond order analysis based on the electronic structure. For engines that do not have a bond order analysis method, a bond guessing algorithm will be used. See also the input options in the BondOrders block. :vartype BondOrders: BoolType | BoolKey :ivar Charges: Requests the engine to calculate the atomic charges. :vartype Charges: BoolType | BoolKey :ivar DipoleGradients: Requests the engine to calculate the nuclear gradients of the electric dipole moment of the molecule. This can only be requested for non-periodic systems. :vartype DipoleGradients: BoolType | BoolKey :ivar DipoleMoment: Requests the engine to calculate the electric dipole moment of the molecule. This can only be requested for non-periodic systems. :vartype DipoleMoment: BoolType | BoolKey :ivar ElasticTensor: Calculate the elastic tensor. :vartype ElasticTensor: BoolType | BoolKey :ivar GSES: Requests the engine to calculate the gradients of ground to excited state properties. :vartype GSES: BoolType | BoolKey :ivar Gradients: Calculate the nuclear gradients. :vartype Gradients: BoolType | BoolKey :ivar Hessian: Whether or not to calculate the Hessian. :vartype Hessian: BoolType | BoolKey :ivar Molecules: Requests an analysis of the molecular components of a system, based on the bond orders calculated by the engine. :vartype Molecules: BoolType | BoolKey :ivar NormalModes: Calculate the frequencies and normal modes of vibration, as well as the corresponding IR intensities, if the engine supports these calculations natively or can calculate dipole moments. :vartype NormalModes: BoolType | BoolKey :ivar OrbitalsInfo: Basic molecular orbitals information: orbital energies, occupations, HOMO, LUMO and HOMO-LUMO gap. :vartype OrbitalsInfo: BoolType | BoolKey :ivar Other: Other (engine specific) properties. Details are configured in the engine block. :vartype Other: BoolType | BoolKey :ivar PESPointCharacter: Determine whether the sampled PES point is a minimum or saddle point. Note that for large systems this does not entail the calculation of the full Hessian and can therefore be used to quickly confirm the success of a geometry optimization or transition state search. :vartype PESPointCharacter: BoolType | BoolKey :ivar Phonons: Calculate the phonons (for periodic systems). :vartype Phonons: BoolType | BoolKey :ivar Polarizability: Requests the engine to calculate the polarizability tensor of the system. :vartype Polarizability: BoolType | BoolKey :ivar Raman: Requests calculation of Raman intensities for vibrational normal modes. :vartype Raman: BoolType | BoolKey :ivar SelectedRegionForHessian: Compute the Hessian matrix elements only for the atoms in a particular region. If not specified, the Hessian will be computed for all atoms. :vartype SelectedRegionForHessian: str | StringKey :ivar StressTensor: Calculate the stress tensor. :vartype StressTensor: BoolType | BoolKey :ivar UncertaintyScore: Request the engine to state how (un)certain it is about its results. Higher number means less certain but specific implementation depends on engine. :vartype UncertaintyScore: BoolType | BoolKey :ivar VCD: Requests calculation of VCD for vibrational normal modes. :vartype VCD: BoolType | BoolKey :ivar VROA: Requests calculation of VROA for vibrational normal modes. :vartype VROA: BoolType | BoolKey """ def __post_init__(self): self.BondOrders: BoolType | BoolKey = BoolKey(name='BondOrders', comment='Requests the engine to calculate bond orders.\n\nFor MM engines these might just be the defined bond orders that go into the force-field, while for QM engines, this might trigger a bond order analysis based on the electronic structure. For engines that do not have a bond order analysis method, a bond guessing algorithm will be used. See also the input options in the BondOrders block.', default=False) self.Charges: BoolType | BoolKey = BoolKey(name='Charges', comment='Requests the engine to calculate the atomic charges.', default=False) self.DipoleGradients: BoolType | BoolKey = BoolKey(name='DipoleGradients', comment='Requests the engine to calculate the nuclear gradients of the electric dipole moment of the molecule. This can only be requested for non-periodic systems.', default=False, engines='-mlpotential') self.DipoleMoment: BoolType | BoolKey = BoolKey(name='DipoleMoment', comment='Requests the engine to calculate the electric dipole moment of the molecule. This can only be requested for non-periodic systems.', default=False, engines='-mlpotential') self.ElasticTensor: BoolType | BoolKey = BoolKey(name='ElasticTensor', comment='Calculate the elastic tensor.', default=False) self.GSES: BoolType | BoolKey = BoolKey(name='GSES', comment='Requests the engine to calculate the gradients of ground to excited state properties.', default=False, engines='-mlpotential') self.Gradients: BoolType | BoolKey = BoolKey(name='Gradients', comment='Calculate the nuclear gradients.', gui_name='Nuclear gradients:', default=False) self.Hessian: BoolType | BoolKey = BoolKey(name='Hessian', comment='Whether or not to calculate the Hessian.', default=False) self.Molecules: BoolType | BoolKey = BoolKey(name='Molecules', comment='Requests an analysis of the molecular components of a system, based on the bond orders calculated by the engine.', default=False) self.NormalModes: BoolType | BoolKey = BoolKey(name='NormalModes', comment='Calculate the frequencies and normal modes of vibration, as well as the corresponding IR intensities, if the engine supports these calculations natively or can calculate dipole moments.', gui_name='Frequencies:', default=False) self.OrbitalsInfo: BoolType | BoolKey = BoolKey(name='OrbitalsInfo', comment='Basic molecular orbitals information: orbital energies, occupations, HOMO, LUMO and HOMO-LUMO gap.', default=False) self.Other: BoolType | BoolKey = BoolKey(name='Other', comment='Other (engine specific) properties. Details are configured in the engine block.', default=True) self.PESPointCharacter: BoolType | BoolKey = BoolKey(name='PESPointCharacter', comment='Determine whether the sampled PES point is a minimum or saddle point. Note that for large systems this does not entail the calculation of the full Hessian and can therefore be used to quickly confirm the success of a geometry optimization or transition state search.', gui_name='Characterize PES point:', default=False) self.Phonons: BoolType | BoolKey = BoolKey(name='Phonons', comment='Calculate the phonons (for periodic systems).', default=False) self.Polarizability: BoolType | BoolKey = BoolKey(name='Polarizability', comment='Requests the engine to calculate the polarizability tensor of the system.', default=False, engines='-mlpotential') self.Raman: BoolType | BoolKey = BoolKey(name='Raman', comment='Requests calculation of Raman intensities for vibrational normal modes.', default=False, engines='adf') self.SelectedRegionForHessian: str | StringKey = StringKey(name='SelectedRegionForHessian', comment='Compute the Hessian matrix elements only for the atoms in a particular region. If not specified, the Hessian will be computed for all atoms.', gui_name='Hessian only for:', gui_type='region') self.StressTensor: BoolType | BoolKey = BoolKey(name='StressTensor', comment='Calculate the stress tensor.', gui_name='Stress tensor:', default=False) self.UncertaintyScore: BoolType | BoolKey = BoolKey(name='UncertaintyScore', comment='Request the engine to state how (un)certain it is about its results. Higher number means less certain but specific implementation depends on engine.', hidden=True, default=False) self.VCD: BoolType | BoolKey = BoolKey(name='VCD', comment='Requests calculation of VCD for vibrational normal modes.', default=False) self.VROA: BoolType | BoolKey = BoolKey(name='VROA', comment='Requests calculation of VROA for vibrational normal modes.', default=False, engines='adf')
[docs] class _Raman(FixedBlock): r""" Configures details of the Raman or VROA calculation. :ivar FreqRange: Specifies a frequency range within which all modes will be scanned. 2 numbers: an upper and a lower bound. :vartype FreqRange: Iterable[float] | FloatListKey :ivar IncidentFrequency: Frequency of incident light. :vartype IncidentFrequency: float | FloatKey :ivar LifeTime: Specify the resonance peak width (damping) in Hartree units. Typically the lifetime of the excited states is approximated with a common phenomenological damping parameter. Values are best obtained by fitting absorption data for the molecule, however, the values do not vary a lot between similar molecules, so it is not hard to estimate values. A typical value is 0.004 Hartree. :vartype LifeTime: float | FloatKey """ def __post_init__(self): self.FreqRange: Iterable[float] | FloatListKey = FloatListKey(name='FreqRange', comment='Specifies a frequency range within which all modes will be scanned. 2 numbers: an upper and a lower bound.', unique=False, gui_name='Frequency range:', unit='cm-1', gui_type='nfloat 2') self.IncidentFrequency: float | FloatKey = FloatKey(name='IncidentFrequency', comment='Frequency of incident light.', default=0.0, unit='eV') self.LifeTime: float | FloatKey = FloatKey(name='LifeTime', comment='Specify the resonance peak width (damping) in Hartree units. Typically the lifetime of the excited states is approximated with a common phenomenological damping parameter. Values are best obtained by fitting absorption data for the molecule, however, the values do not vary a lot between similar molecules, so it is not hard to estimate values. A typical value is 0.004 Hartree.', default=0.0, unit='hartree')
[docs] class _Replay(FixedBlock): r""" Configures the details of the Replay task. :ivar Atoms: List of atom indices to include in the replay. All other atoms will be removed before the calculation of energy (and possible other properties). If this keyword is not specified, all atoms will be used for the replay. This keyword can currently not be used for trajectory with a changing number of atoms between frames, e.g. MD trajectories with molecule guns and sinks. :vartype Atoms: Iterable[int] | IntListKey :ivar File: Provide an ams.rkf file (or a .results folder) from a previously run job to replay. The file needs to contain a History section. :vartype File: str | Path | StringKey :ivar Frames: List of frames from the History section to recompute. If not specified the recomputed frames are determined automatically based on the task of the job that is being replayed: PES scans and NEB calculations will only have the converged points replayed, while all other tasks will have all frames recomputed. Specifying the frames to recompute in the input is probably only useful when replaying trajectories from MolecularDynamics calculations. :vartype Frames: Iterable[int] | IntListKey :ivar StoreAllResultFiles: If this option is enabled AMS will produce a separate engine output file for every replayed frame. While basic properties like energy, gradients, stress tensor, etc. are stored anyway on the History section in the AMS driver output file (if they were requested in the Properties block), engine specific properties (e.g. excitations energies from ADF) will only be available if the full result files are stored. :vartype StoreAllResultFiles: BoolType | BoolKey """ def __post_init__(self): self.Atoms: Iterable[int] | IntListKey = IntListKey(name='Atoms', comment='List of atom indices to include in the replay. All other atoms will be removed before the calculation of energy (and possible other properties). If this keyword is not specified, all atoms will be used for the replay. This keyword can currently not be used for trajectory with a changing number of atoms between frames, e.g. MD trajectories with molecule guns and sinks.', hidden=True) self.File: str | Path | StringKey = PathStringKey(name='File', comment='Provide an ams.rkf file (or a .results folder) from a previously run job to replay. The file needs to contain a History section.', gui_name='Restart from:', ispath=True, gui_type='.rkf {{{AMS result file} .rkf}}') self.Frames: Iterable[int] | IntListKey = IntListKey(name='Frames', comment='List of frames from the History section to recompute.\n\nIf not specified the recomputed frames are determined automatically based on the task of the job that is being replayed: PES scans and NEB calculations will only have the converged points replayed, while all other tasks will have all frames recomputed.\n\nSpecifying the frames to recompute in the input is probably only useful when replaying trajectories from MolecularDynamics calculations.') self.StoreAllResultFiles: BoolType | BoolKey = BoolKey(name='StoreAllResultFiles', comment='If this option is enabled AMS will produce a separate engine output file for every replayed frame.\n\nWhile basic properties like energy, gradients, stress tensor, etc. are stored anyway on the History section in the AMS driver output file (if they were requested in the Properties block), engine specific properties (e.g. excitations energies from ADF) will only be available if the full result files are stored.', default=False)
[docs] class _Restraints(FixedBlock): r""" The Restraints block allows to add soft constraints to the system. A restraint is a potential energy function (a spring) attached to a certain coordinate, for example, an interatomic distance, with its minimum at the specified optimal value. A restraint is defined using one or two parameters: the ForceConstant and, for some types, the F(Inf) value. The ForceConstant parameter corresponds to second derivative of the restraint potential energy d2V(x)/dx^2 for any x (harmonic restraints) or only at at x=0 (other restraints). Here, x is a deviation from the restraint's optimal value. :ivar Angle: Specify three atom indices i j k followed by an angle in degrees and, optionally, by the ForceConstant (default is 0.3 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the i-j-k angle at the given value. For periodic systems this restraint follows the minimum image convention. :vartype Angle: str | StringKey :ivar DifDist: Specify four atom indices i j k l followed by the distance in Angstrom and, optionally, by the ForceConstant (default is 1.0 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the difference R(ij)-R(kl) at the given value. For periodic systems this restraint follows the minimum image convention. :vartype DifDist: str | StringKey :ivar Dihedral: Specify four atom indices i j k l followed by an angle in degrees and, optionally, by the ForceConstant (default is 0.1 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the i-j-k-l dihedral angle at the given value. For periodic systems this restraint follows the minimum image convention. :vartype Dihedral: str | StringKey :ivar Distance: Specify two atom indices followed by the distance in Angstrom and, optionally, by the ForceConstant (default is 1.0 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the distance between the two specified atoms at the given value. For periodic systems this restraint follows the minimum image convention. :vartype Distance: str | StringKey :ivar FInfinity: Specify the default asymptotic value for the restraint force for the Hyperbolic and Erf profiles, in Hartree/Bohr or Hartree/radian. A per-restraint value can be specified after the profile type on the corresponding restraint line. :vartype FInfinity: float | FloatKey :ivar Profile: Select the default type of restraint profile. The harmonic profile is most suitable for geometry optimizations but may result is very large forces that can be problematic in molecular dynamic. For MD simulations the Hyperbolic or Erf may be more suitable because the restraint force is bounded by a user-defined value. A per-restraint profile type can be specified after the ForceConstant value on the corresponding restraint line. :vartype Profile: Literal["Harmonic", "Hyperbolic", "Erf", "GaussianWell"] :ivar SumDist: Specify four atom indices i j k l followed by the distance in Angstrom and, optionally, by the ForceConstant (default is 1.0 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the sum R(ij)+R(kl) at the given value. For periodic systems this restraint follows the minimum image convention. :vartype SumDist: str | StringKey :ivar Units: Change units for energy, force and force constant values from the default (atomic units) to those often used in the MD community (based on kcal/mol and Angstrom). Units for the optimal distances are not affected and are always Angstrom. :vartype Units: Literal["Default", "MD"] """ def __post_init__(self): self.Angle: str | StringKey = StringKey(name='Angle', comment='Specify three atom indices i j k followed by an angle in degrees and, optionally, by the ForceConstant (default is 0.3 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the i-j-k angle at the given value. For periodic systems this restraint follows the minimum image convention.', unique=False) self.DifDist: str | StringKey = StringKey(name='DifDist', comment='Specify four atom indices i j k l followed by the distance in Angstrom and, optionally, by the ForceConstant (default is 1.0 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the difference R(ij)-R(kl) at the given value. For periodic systems this restraint follows the minimum image convention.', unique=False) self.Dihedral: str | StringKey = StringKey(name='Dihedral', comment='Specify four atom indices i j k l followed by an angle in degrees and, optionally, by the ForceConstant (default is 0.1 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the i-j-k-l dihedral angle at the given value. For periodic systems this restraint follows the minimum image convention.', unique=False) self.Distance: str | StringKey = StringKey(name='Distance', comment='Specify two atom indices followed by the distance in Angstrom and, optionally, by the ForceConstant (default is 1.0 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the distance between the two specified atoms at the given value. For periodic systems this restraint follows the minimum image convention.', unique=False) self.FInfinity: float | FloatKey = FloatKey(name='FInfinity', comment='Specify the default asymptotic value for the restraint force for the Hyperbolic and Erf profiles, in Hartree/Bohr or Hartree/radian.\n\nA per-restraint value can be specified after the profile type on the corresponding restraint line.', gui_name='Default F(inf):', default=1.0) self.Profile: Literal["Harmonic", "Hyperbolic", "Erf", "GaussianWell"] = MultipleChoiceKey(name='Profile', comment='Select the default type of restraint profile.\n\nThe harmonic profile is most suitable for geometry optimizations but may result is very large forces that can be problematic in molecular dynamic.\n\nFor MD simulations the Hyperbolic or Erf may be more suitable because the restraint force is bounded by a user-defined value.\n\nA per-restraint profile type can be specified after the ForceConstant value on the corresponding restraint line.', gui_name='Default restraint profile:', default='Harmonic', choices=['Harmonic', 'Hyperbolic', 'Erf', 'GaussianWell']) self.SumDist: str | StringKey = StringKey(name='SumDist', comment='Specify four atom indices i j k l followed by the distance in Angstrom and, optionally, by the ForceConstant (default is 1.0 in a.u.), profile type and F(Inf) (in a.u.). This restraint will try to keep the sum R(ij)+R(kl) at the given value. For periodic systems this restraint follows the minimum image convention.', unique=False) self.Units: Literal["Default", "MD"] = MultipleChoiceKey(name='Units', comment='Change units for energy, force and force constant values from the default (atomic units) to those often used in the MD community (based on kcal/mol and Angstrom). Units for the optimal distances are not affected and are always Angstrom.', gui_name='Units:', default='Default', choices=['Default', 'MD'])
[docs] class _RigidMotions(FixedBlock): r""" Specify which rigid motions of the total system are allowed. An external field is not considered part of the system. Normally the automatic option is doing what you want. However this feature can be used as a means of geometry constraint. :ivar AllowRotations: Which overall rotations of the system are allowed :vartype AllowRotations: Literal["Auto", "None", "All", "X", "Y", "Z", "XY", "XZ", "YZ"] :ivar AllowTranslations: Which overall transitions of the system are allowed :vartype AllowTranslations: Literal["Auto", "None", "All", "X", "Y", "Z", "XY", "XZ", "YZ"] :ivar Tolerance: Tolerance for detecting linear molecules. A large value means larger deviation from linearity is permitted. :vartype Tolerance: float | FloatKey """ def __post_init__(self): self.AllowRotations: Literal["Auto", "None", "All", "X", "Y", "Z", "XY", "XZ", "YZ"] = MultipleChoiceKey(name='AllowRotations', comment='Which overall rotations of the system are allowed', default='Auto', choices=['Auto', 'None', 'All', 'X', 'Y', 'Z', 'XY', 'XZ', 'YZ']) self.AllowTranslations: Literal["Auto", "None", "All", "X", "Y", "Z", "XY", "XZ", "YZ"] = MultipleChoiceKey(name='AllowTranslations', comment='Which overall transitions of the system are allowed', default='Auto', choices=['Auto', 'None', 'All', 'X', 'Y', 'Z', 'XY', 'XZ', 'YZ']) self.Tolerance: float | FloatKey = FloatKey(name='Tolerance', comment='Tolerance for detecting linear molecules. A large value means larger deviation from linearity is permitted.', default=1e-06)
[docs] class _SCMLibrary(FixedBlock): r""" Technical settings affecting src/lib :ivar ShellBasedNAFS: Assume that the NAFS are ordered by shell, this allows for a faster evaluation. :vartype ShellBasedNAFS: BoolType | BoolKey """ def __post_init__(self): self.ShellBasedNAFS: BoolType | BoolKey = BoolKey(name='ShellBasedNAFS', comment='Assume that the NAFS are ordered by shell, this allows for a faster evaluation.', default=False)
[docs] class _SCMMatrix(FixedBlock): r""" Technical settings for programs using the AMT matrix system. Currently this is only used by DFTB :ivar Type: Determines which implementation is used to support the AbstractMatrixType. :vartype Type: Literal["Auto", "Reference", "ScaLapack", "Elpa"] :ivar DistributedMatrix: Technical settings for Distributed matrices :vartype DistributedMatrix: AMS._SCMMatrix._DistributedMatrix """
[docs] class _DistributedMatrix(FixedBlock): r""" Technical settings for Distributed matrices :ivar ColBlockSize: See comment of RowBlockSize. :vartype ColBlockSize: int | IntKey :ivar RowBlockSize: The matrix is divided into blocks of size RowBlockSize x ColBlockSize. The smaller the blocks the better the distribution, but at the expense of increased communication overhead :vartype RowBlockSize: int | IntKey """ def __post_init__(self): self.ColBlockSize: int | IntKey = IntKey(name='ColBlockSize', comment='See comment of RowBlockSize.', default=64) self.RowBlockSize: int | IntKey = IntKey(name='RowBlockSize', comment='The matrix is divided into blocks of size RowBlockSize x ColBlockSize. The smaller the blocks the better the distribution, but at the expense of increased communication overhead', default=64)
def __post_init__(self): self.Type: Literal["Auto", "Reference", "ScaLapack", "Elpa"] = MultipleChoiceKey(name='Type', comment='Determines which implementation is used to support the AbstractMatrixType.', default='Elpa', choices=['Auto', 'Reference', 'ScaLapack', 'Elpa']) self.DistributedMatrix: AMS._SCMMatrix._DistributedMatrix = self._DistributedMatrix(name='DistributedMatrix', comment='Technical settings for Distributed matrices')
[docs] class _SerializedTensors(FixedBlock): r""" Technical settings affecting the SerializedTensors module, currently only used for HartreeFock :ivar AllowZeroSize: When the data is blocked, can the size be zero? :vartype AllowZeroSize: BoolType | BoolKey :ivar IntegerDataBlockSize: Integer (meta) data per tensor may be aligned by using a blockSize, only relevant when sparseness is used. :vartype IntegerDataBlockSize: int | IntKey :ivar RealDataBlockSize: Real data per tensor may be aligned by using a blockSize :vartype RealDataBlockSize: int | IntKey :ivar SparseDataImplementation: 1) use three ftlDynArrays per tensor. 2) use one big shared array. :vartype SparseDataImplementation: int | IntKey """ def __post_init__(self): self.AllowZeroSize: BoolType | BoolKey = BoolKey(name='AllowZeroSize', comment='When the data is blocked, can the size be zero?', default=True) self.IntegerDataBlockSize: int | IntKey = IntKey(name='IntegerDataBlockSize', comment='Integer (meta) data per tensor may be aligned by using a blockSize, only relevant when sparseness is used.') self.RealDataBlockSize: int | IntKey = IntKey(name='RealDataBlockSize', comment='Real data per tensor may be aligned by using a blockSize') self.SparseDataImplementation: int | IntKey = IntKey(name='SparseDataImplementation', comment='1) use three ftlDynArrays per tensor. 2) use one big shared array.')
[docs] class _SteepestDescent(FixedBlock): r""" Configures details of the steepest descent task. :ivar GradientConvergence: :vartype GradientConvergence: float | FloatKey :ivar StepSize: Controls the size of the step to take. This number is multiplied with the force and added to the gradient. :vartype StepSize: float | FloatKey """ def __post_init__(self): self.GradientConvergence: float | FloatKey = FloatKey(name='GradientConvergence', default=0.001, unit='Hartree/Bohr') self.StepSize: float | FloatKey = FloatKey(name='StepSize', comment='Controls the size of the step to take. This number is multiplied with the force and added to the gradient.', default=1.0, unit='Bohr^2/Hartree')
[docs] class _Symmetry(FixedBlock): r""" Specifying details about the details of symmetry detection and usage. :ivar SymmetrizeTolerance: Tolerance used to detect symmetry in case symmetrize is requested. :vartype SymmetrizeTolerance: float | FloatKey :ivar Tolerance: Tolerance used to detect symmetry in the system. :vartype Tolerance: float | FloatKey """ def __post_init__(self): self.SymmetrizeTolerance: float | FloatKey = FloatKey(name='SymmetrizeTolerance', comment='Tolerance used to detect symmetry in case symmetrize is requested.', default=0.05) self.Tolerance: float | FloatKey = FloatKey(name='Tolerance', comment='Tolerance used to detect symmetry in the system.', default=1e-07)
[docs] class _System(FixedBlock): r""" Specification of the chemical system. For some applications more than one system may be present in the input. In this case, all systems except one must have a non-empty string ID specified after the System keyword. The system without an ID is considered the main one. :ivar AllowCloseAtoms: No longer functional. Just here for backwards compatibility. :vartype AllowCloseAtoms: BoolType | BoolKey :ivar Charge: The system's total charge in atomic units. :vartype Charge: float | FloatKey :ivar FractionalCoords: Whether the atomic coordinates in the Atoms block are given in fractional coordinates of the lattice vectors. Requires the presence of the Lattice block. :vartype FractionalCoords: BoolType | BoolKey :ivar GeometryFile: Read the geometry from a file (instead of from Atoms and Lattice blocks). Supported formats: .xyz :vartype GeometryFile: str | Path | StringKey :ivar GuessBonds: Equivalent to 'Modify%GuessBonds'. Please update input file to use 'Modify' block instead. :vartype GuessBonds: BoolType | BoolKey :ivar LatticeStrain: Equivalent to 'Modify%LatticeStrain'. Please update input file to use 'Modify' block instead. :vartype LatticeStrain: Iterable[float] | FloatListKey :ivar MapAtomsToUnitCell: Equivalent to 'Modify%MapAtomsToUnitCell'. Please update input file to use 'Modify' block instead. :vartype MapAtomsToUnitCell: BoolType | BoolKey :ivar PerturbCoordinates: Equivalent to 'Modify%PerturbCoordinates'. Please update input file to use 'Modify' block instead. :vartype PerturbCoordinates: float | FloatKey :ivar PerturbLattice: Equivalent to 'Modify%PerturbLattice'. Please update input file to use 'Modify' block instead. :vartype PerturbLattice: float | FloatKey :ivar ShiftCoordinates: Equivalent to 'Modify%Translate', but in the unit of bohr by default. Please update input file to use 'Modify' block instead. :vartype ShiftCoordinates: Iterable[float] | FloatListKey :ivar SuperCell: Equivalent to 'Modify%SuperCell'. Please update input file to use 'Modify' block instead. :vartype SuperCell: Iterable[int] | IntListKey :ivar SuperCellTrafo: Equivalent to 'Modify%SuperCellTrafo'. Please update input file to use 'Modify' block instead. :vartype SuperCellTrafo: Iterable[int] | IntListKey :ivar Symmetrize: Equivalent to 'Modify%Symmetrize'. Please update input file to use 'Modify' block instead. :vartype Symmetrize: BoolType | BoolKey :ivar Atoms: The atom types and coordinates. Unit can be specified in the header. Default unit is Angstrom. :vartype Atoms: str | Sequence[str] | FreeBlock :ivar BondOrders: Defined bond orders. Each line should contain two atom indices, followed by the bond order (1, 1.5, 2, 3 for single, aromatic, double and triple bonds) and (optionally) the cell shifts for periodic systems. May be used by MM engines and for defining constraints. If the system is periodic and none of the bonds have the cell shift defined then AMS will attempt to determine them following the minimum image convention. :vartype BondOrders: str | Sequence[str] | FreeBlock :ivar ElectrostaticEmbedding: Container for electrostatic embedding options, which can be combined. :vartype ElectrostaticEmbedding: AMS._System._ElectrostaticEmbedding :ivar Lattice: Up to three lattice vectors. Unit can be specified in the header. Default unit is Angstrom. :vartype Lattice: str | Sequence[str] | FreeBlock :ivar Modify: Modifications to make to the chemical system after construction. This block is read like a script and the modifications applied top to bottom. :vartype Modify: AMS._System._Modify """
[docs] class _Atoms(FreeBlock): r""" The atom types and coordinates. Unit can be specified in the header. Default unit is Angstrom. """ def __post_init__(self): pass
[docs] class _BondOrders(FreeBlock): r""" Defined bond orders. Each line should contain two atom indices, followed by the bond order (1, 1.5, 2, 3 for single, aromatic, double and triple bonds) and (optionally) the cell shifts for periodic systems. May be used by MM engines and for defining constraints. If the system is periodic and none of the bonds have the cell shift defined then AMS will attempt to determine them following the minimum image convention. """ def __post_init__(self): pass
[docs] class _ElectrostaticEmbedding(FixedBlock): r""" Container for electrostatic embedding options, which can be combined. :ivar ElectricField: External homogeneous electric field with three Cartesian components: ex, ey, ez, the default unit being V/Å. In atomic units: Hartree/(e bohr) = 51.422 V/Angstrom; the relation to SI units is: 1 Hartree/(e bohr) = 5.14 ... e11 V/m. Supported by the engines adf, band, dftb and mopac. For periodic systems the field may only have nonzero components orthogonal to the direction(s) of periodicity (i.e. for 1D periodic system the x-component of the electric field should be zero, while for 2D periodic systems both the x and y components should be zero. This options cannot be used for 3D periodic systems. :vartype ElectricField: Iterable[float] | FloatListKey :ivar MultipolePotential: External point charges (and dipoles). :vartype MultipolePotential: AMS._System._ElectrostaticEmbedding._MultipolePotential """
[docs] class _MultipolePotential(FixedBlock): r""" External point charges (and dipoles). :ivar ChargeModel: A multipole may be represented by a point (with a singular potential at its location) or by a spherical Gaussian distribution. :vartype ChargeModel: Literal["Point", "Gaussian"] :ivar ChargeWidth: The width parameter in a.u. in case a Gaussian charge model is chosen. A negative value means that the width will be chosen automatically. :vartype ChargeWidth: float | FloatKey :ivar Coordinates: Positions and values of the multipoles, one per line. Each line has the following format: x y z q, or x y z q µx µy µz. Here x, y, z are the coordinates in Å, q is the charge (in atomic units of charge) and µx, µy, µz are the (optional) dipole moment components (in atomic units, i.e. e*Bohr). Periodic systems are not supported. :vartype Coordinates: str | Sequence[str] | FreeBlock """
[docs] class _Coordinates(FreeBlock): r""" Positions and values of the multipoles, one per line. Each line has the following format: x y z q, or x y z q µx µy µz. Here x, y, z are the coordinates in Å, q is the charge (in atomic units of charge) and µx, µy, µz are the (optional) dipole moment components (in atomic units, i.e. e*Bohr). Periodic systems are not supported. """ def __post_init__(self): pass
def __post_init__(self): self.ChargeModel: Literal["Point", "Gaussian"] = MultipleChoiceKey(name='ChargeModel', comment='A multipole may be represented by a point (with a singular potential at its location) or by a spherical Gaussian distribution.', default='Point', choices=['Point', 'Gaussian']) self.ChargeWidth: float | FloatKey = FloatKey(name='ChargeWidth', comment='The width parameter in a.u. in case a Gaussian charge model is chosen. A negative value means that the width will be chosen automatically.', default=-1.0) self.Coordinates: str | Sequence[str] | FreeBlock = self._Coordinates(name='Coordinates', comment='Positions and values of the multipoles, one per line. Each line has the following format:\n\nx y z q, or\nx y z q µx µy µz.\n\nHere x, y, z are the coordinates in Å, q is the charge (in atomic units of charge) and µx, µy, µz are the (optional) dipole moment components (in atomic units, i.e. e*Bohr). \n\nPeriodic systems are not supported.', header=True)
def __post_init__(self): self.ElectricField: Iterable[float] | FloatListKey = FloatListKey(name='ElectricField', comment='External homogeneous electric field with three Cartesian components: ex, ey, ez, the default unit being V/Å.\n\nIn atomic units: Hartree/(e bohr) = 51.422 V/Angstrom; the relation to SI units is: 1 Hartree/(e bohr) = 5.14 ... e11 V/m.\n\nSupported by the engines adf, band, dftb and mopac.\n\nFor periodic systems the field may only have nonzero components orthogonal to the direction(s) of periodicity (i.e. for 1D periodic system the x-component of the electric field should be zero, while for 2D periodic systems both the x and y components should be zero. This options cannot be used for 3D periodic systems.', unit='V/Angstrom') self.MultipolePotential: AMS._System._ElectrostaticEmbedding._MultipolePotential = self._MultipolePotential(name='MultipolePotential', comment='External point charges (and dipoles).')
[docs] class _Lattice(FreeBlock): r""" Up to three lattice vectors. Unit can be specified in the header. Default unit is Angstrom. """ def __post_init__(self): pass
[docs] class _Modify(FixedBlock): r""" Modifications to make to the chemical system after construction. This block is read like a script and the modifications applied top to bottom. :ivar EnableAtomicProperties: Enables an atomic property group. This is only necessary if you want a group enabled, but no atom in the input is using any property from that group. :vartype EnableAtomicProperties: Literal["gui", "adf", "band", "forcefield", "dftb", "reaxff", "qe"] :ivar GuessBonds: Guesses bonds based on the atomic elements and the geometry. Keeps existing bonds. :vartype GuessBonds: BoolType | BoolKey :ivar LatticeStrain: Deform the input system by the specified strain. The strain elements are in Voigt notation, so one should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems. :vartype LatticeStrain: Iterable[float] | FloatListKey :ivar MapAtomsToUnitCell: For periodic systems the atoms will be moved to the central unit cell where all their fractional coordinates are in the range [start_range,start_range+1). No mapping will take place along non-periodic directions. If just a single number is given, it corresponds to start_range. If multiple numbers are given, they should match the number of lattice vectors and will be used as start ranges along the individual lattice vectors. If no number is given at all, the mapping will be done to the [-0.5:0.5) cell. :vartype MapAtomsToUnitCell: Iterable[float] | FloatListKey :ivar PerturbCoordinates: Perturb the atomic coordinates by adding random numbers between [-PerturbCoordinates,PerturbCoordinates] to each Cartesian component. This can be useful if you want to break the symmetry of your system (e.g. for a geometry optimization). :vartype PerturbCoordinates: float | FloatKey :ivar PerturbLattice: Perturb the lattice vectors by applying random strain with matrix elements between [-PerturbLattice,PerturbLattice]. This can be useful if you want to deviate from an ideal symmetric geometry, for example if you look for a phase change due to high pressure. :vartype PerturbLattice: float | FloatKey :ivar SuperCell: Create a supercell of the input system (only possible for periodic systems). The integer numbers represent the diagonal elements of the supercell transformation; you should specify as many numbers as lattice vectors (i.e. 1 number for 1D, 2 numbers for 2D and 3 numbers for 3D periodic systems). :vartype SuperCell: Iterable[int] | IntListKey :ivar SuperCellTrafo: Create a supercell of the input system (only possible for periodic systems) :math:`\vec{a}_i' = \sum_j T_{ij} \vec{a}_j`. The integer numbers represent the supercell transformation :math:`T_{ij}`: 1 number for 1D PBC, 4 numbers for 2D PBC corresponding to a 2x2 matrix (order: (1,1),(1,2),(2,1),(2,2)) and 9 numbers for 3D PBC corresponding to a 3x3 matrix (order: (1,1),(1,2),(1,3),(2,1),(2,2),(2,3),(3,1),(3,2),(3,3)). :vartype SuperCellTrafo: Iterable[int] | IntListKey :ivar Symmetrize: Symmetrizes the atomic coordinates to machine precision and rototranslates the molecule to the AMS standard orientation. This allows optimal use of the system's symmetry for calculations with the AMS driver and its engines. :vartype Symmetrize: BoolType | BoolKey :ivar Translate: Translate all atoms by a vector. :vartype Translate: Iterable[float] | FloatListKey """ def __post_init__(self): self.EnableAtomicProperties: Literal["gui", "adf", "band", "forcefield", "dftb", "reaxff", "qe"] = MultipleChoiceKey(name='EnableAtomicProperties', comment='Enables an atomic property group. This is only necessary if you want a group enabled, but no atom in the input is using any property from that group.', unique=False, choices=['gui', 'adf', 'band', 'forcefield', 'dftb', 'reaxff', 'qe']) self.GuessBonds: BoolType | BoolKey = BoolKey(name='GuessBonds', comment='Guesses bonds based on the atomic elements and the geometry. Keeps existing bonds.', unique=False) self.LatticeStrain: Iterable[float] | FloatListKey = FloatListKey(name='LatticeStrain', comment='Deform the input system by the specified strain. The strain elements are in Voigt notation, so one should specify 6 numbers for 3D periodic system (order: xx,yy,zz,yz,xz,xy), 3 numbers for 2D periodic systems (order: xx,yy,xy) or 1 number for 1D periodic systems.', unique=False) self.MapAtomsToUnitCell: Iterable[float] | FloatListKey = FloatListKey(name='MapAtomsToUnitCell', comment='For periodic systems the atoms will be moved to the central unit cell where all their fractional coordinates are in the range [start_range,start_range+1). No mapping will take place along non-periodic directions. If just a single number is given, it corresponds to start_range. If multiple numbers are given, they should match the number of lattice vectors and will be used as start ranges along the individual lattice vectors. If no number is given at all, the mapping will be done to the [-0.5:0.5) cell.', unique=False) self.PerturbCoordinates: float | FloatKey = FloatKey(name='PerturbCoordinates', comment='Perturb the atomic coordinates by adding random numbers between [-PerturbCoordinates,PerturbCoordinates] to each Cartesian component. This can be useful if you want to break the symmetry of your system (e.g. for a geometry optimization).', unique=False, unit='angstrom') self.PerturbLattice: float | FloatKey = FloatKey(name='PerturbLattice', comment='Perturb the lattice vectors by applying random strain with matrix elements between [-PerturbLattice,PerturbLattice]. This can be useful if you want to deviate from an ideal symmetric geometry, for example if you look for a phase change due to high pressure.', unique=False) self.SuperCell: Iterable[int] | IntListKey = IntListKey(name='SuperCell', comment='Create a supercell of the input system (only possible for periodic systems). The integer numbers represent the diagonal elements of the supercell transformation; you should specify as many numbers as lattice vectors (i.e. 1 number for 1D, 2 numbers for 2D and 3 numbers for 3D periodic systems).', unique=False) self.SuperCellTrafo: Iterable[int] | IntListKey = IntListKey(name='SuperCellTrafo', comment="Create a supercell of the input system (only possible for periodic systems) :math:`\\vec{a}_i' = \\sum_j T_{ij} \\vec{a}_j`. The integer numbers represent the supercell transformation :math:`T_{ij}`: 1 number for 1D PBC, 4 numbers for 2D PBC corresponding to a 2x2 matrix (order: (1,1),(1,2),(2,1),(2,2)) and 9 numbers for 3D PBC corresponding to a 3x3 matrix (order: (1,1),(1,2),(1,3),(2,1),(2,2),(2,3),(3,1),(3,2),(3,3)).", unique=False) self.Symmetrize: BoolType | BoolKey = BoolKey(name='Symmetrize', comment="Symmetrizes the atomic coordinates to machine precision and rototranslates the molecule to the AMS standard orientation. This allows optimal use of the system's symmetry for calculations with the AMS driver and its engines.", unique=False, default=False) self.Translate: Iterable[float] | FloatListKey = FloatListKey(name='Translate', comment='Translate all atoms by a vector.', unique=False, unit='angstrom')
def __post_init__(self): self.AllowCloseAtoms: BoolType | BoolKey = BoolKey(name='AllowCloseAtoms', comment='No longer functional. Just here for backwards compatibility.', hidden=True, default=True) self.Charge: float | FloatKey = FloatKey(name='Charge', comment="The system's total charge in atomic units.", gui_name='Total charge:', default=0.0, engines='-forcefield') self.FractionalCoords: BoolType | BoolKey = BoolKey(name='FractionalCoords', comment='Whether the atomic coordinates in the Atoms block are given in fractional coordinates of the lattice vectors. Requires the presence of the Lattice block.', default=False) self.GeometryFile: str | Path | StringKey = PathStringKey(name='GeometryFile', comment='Read the geometry from a file (instead of from Atoms and Lattice blocks). Supported formats: .xyz', ispath=True) self.GuessBonds: BoolType | BoolKey = BoolKey(name='GuessBonds', comment="Equivalent to 'Modify%GuessBonds'. Please update input file to use 'Modify' block instead.", hidden=True) self.LatticeStrain: Iterable[float] | FloatListKey = FloatListKey(name='LatticeStrain', comment="Equivalent to 'Modify%LatticeStrain'. Please update input file to use 'Modify' block instead.", hidden=True) self.MapAtomsToUnitCell: BoolType | BoolKey = BoolKey(name='MapAtomsToUnitCell', comment="Equivalent to 'Modify%MapAtomsToUnitCell'. Please update input file to use 'Modify' block instead.", hidden=True) self.PerturbCoordinates: float | FloatKey = FloatKey(name='PerturbCoordinates', comment="Equivalent to 'Modify%PerturbCoordinates'. Please update input file to use 'Modify' block instead.", hidden=True, unit='angstrom') self.PerturbLattice: float | FloatKey = FloatKey(name='PerturbLattice', comment="Equivalent to 'Modify%PerturbLattice'. Please update input file to use 'Modify' block instead.", hidden=True) self.ShiftCoordinates: Iterable[float] | FloatListKey = FloatListKey(name='ShiftCoordinates', comment="Equivalent to 'Modify%Translate', but in the unit of bohr by default. Please update input file to use 'Modify' block instead.", hidden=True, unit='bohr') self.SuperCell: Iterable[int] | IntListKey = IntListKey(name='SuperCell', comment="Equivalent to 'Modify%SuperCell'. Please update input file to use 'Modify' block instead.", hidden=True) self.SuperCellTrafo: Iterable[int] | IntListKey = IntListKey(name='SuperCellTrafo', comment="Equivalent to 'Modify%SuperCellTrafo'. Please update input file to use 'Modify' block instead.", hidden=True) self.Symmetrize: BoolType | BoolKey = BoolKey(name='Symmetrize', comment="Equivalent to 'Modify%Symmetrize'. Please update input file to use 'Modify' block instead.", hidden=True, default=False) self.Atoms: str | Sequence[str] | FreeBlock = self._Atoms(name='Atoms', comment='The atom types and coordinates. Unit can be specified in the header. Default unit is Angstrom.', header=True) self.BondOrders: str | Sequence[str] | FreeBlock = self._BondOrders(name='BondOrders', comment='Defined bond orders. Each line should contain two atom indices, followed by the bond order (1, 1.5, 2, 3 for single, aromatic, double and triple bonds) and (optionally) the cell shifts for periodic systems. May be used by MM engines and for defining constraints. If the system is periodic and none of the bonds have the cell shift defined then AMS will attempt to determine them following the minimum image convention.') self.ElectrostaticEmbedding: AMS._System._ElectrostaticEmbedding = self._ElectrostaticEmbedding(name='ElectrostaticEmbedding', comment='Container for electrostatic embedding options, which can be combined.') self.Lattice: str | Sequence[str] | FreeBlock = self._Lattice(name='Lattice', comment='Up to three lattice vectors. Unit can be specified in the header. Default unit is Angstrom.', header=True) self.Modify: AMS._System._Modify = self._Modify(name='Modify', comment='Modifications to make to the chemical system after construction. This block is read like a script and the modifications applied top to bottom.', ordered=True)
[docs] class _Thermo(FixedBlock): r""" Options for thermodynamic properties (assuming an ideal gas). The properties are computed for all specified temperatures. :ivar Pressure: The pressure at which the thermodynamic properties are computed. :vartype Pressure: float | FloatKey :ivar Temperatures: List of temperatures at which the thermodynamic properties will be calculated. :vartype Temperatures: Iterable[float] | FloatListKey :ivar UseSymmetryForEntropy: Use symmetry for the calculation of rotational entropy. :vartype UseSymmetryForEntropy: BoolType | BoolKey :ivar LowFrequencyCorrector: Options for the dampener-powered free rotor interpolator that corrects thermodynamic quantities for low frequencies. See DOI:10.1021/jp509921r and DOI:10.1002/chem.201200497. :vartype LowFrequencyCorrector: AMS._Thermo._LowFrequencyCorrector """
[docs] class _LowFrequencyCorrector(FixedBlock): r""" Options for the dampener-powered free rotor interpolator that corrects thermodynamic quantities for low frequencies. See DOI:10.1021/jp509921r and DOI:10.1002/chem.201200497. :ivar Alpha: The exponent term used in the dampener. :vartype Alpha: float | FloatKey :ivar Frequency: The frequency around which the dampener interpolates between harmonic oscillator and free rotor quantities. :vartype Frequency: float | FloatKey :ivar MomentOfInertia: The moment of inertia used to restrict entropy results for very small frequencies (generally around less than 1 cm-1). :vartype MomentOfInertia: float | FloatKey """ def __post_init__(self): self.Alpha: float | FloatKey = FloatKey(name='Alpha', comment='The exponent term used in the dampener.', default=4.0) self.Frequency: float | FloatKey = FloatKey(name='Frequency', comment='The frequency around which the dampener interpolates between harmonic oscillator and free rotor quantities.', default=100.0, unit='cm-1') self.MomentOfInertia: float | FloatKey = FloatKey(name='MomentOfInertia', comment='The moment of inertia used to restrict entropy results for very small frequencies (generally around less than 1 cm-1).', gui_name='Averaging Moment of Inertia:', default=1e-44, unit='kg m^2')
def __post_init__(self): self.Pressure: float | FloatKey = FloatKey(name='Pressure', comment='The pressure at which the thermodynamic properties are computed.', default=1.0, unit='atm') self.Temperatures: Iterable[float] | FloatListKey = FloatListKey(name='Temperatures', comment='List of temperatures at which the thermodynamic properties will be calculated.', default=[298.15], unit='Kelvin', range='value >= 0') self.UseSymmetryForEntropy: BoolType | BoolKey = BoolKey(name='UseSymmetryForEntropy', comment='Use symmetry for the calculation of rotational entropy.', hidden=True, default=True) self.LowFrequencyCorrector: AMS._Thermo._LowFrequencyCorrector = self._LowFrequencyCorrector(name='LowFrequencyCorrector', comment='Options for the dampener-powered free rotor interpolator that corrects thermodynamic quantities for low frequencies. See DOI:10.1021/jp509921r and DOI:10.1002/chem.201200497.')
[docs] class _TransitionStateSearch(FixedBlock): r""" Configures some details of the transition state search. :ivar ModeToFollow: In case of Transition State Search, here you can specify the index of the normal mode to follow (1 is the mode with the lowest frequency). :vartype ModeToFollow: int | IntKey :ivar ReactionCoordinate: Specify components of the transition state reaction coordinate (TSRC) as a linear combination of internal coordinates (distances or angles). :vartype ReactionCoordinate: AMS._TransitionStateSearch._ReactionCoordinate """
[docs] class _ReactionCoordinate(FixedBlock): r""" Specify components of the transition state reaction coordinate (TSRC) as a linear combination of internal coordinates (distances or angles). :ivar All: Dummy. :vartype All: str | StringKey :ivar Angle: The TSRC contains the valence angle between the given atoms. Three atom indices followed by the weight. :vartype Angle: str | StringKey :ivar Atom: Dummy. :vartype Atom: str | StringKey :ivar AtomList: Dummy. :vartype AtomList: str | StringKey :ivar Block: Name of the region. Only atoms of the region will be included in the TSRC. It is useful when computing the reaction coordinate from the initial Hessian, in which case only part of the Hessian will be analyzed. :vartype Block: str | StringKey :ivar BlockAtoms: List of atom indices. Only the listed atoms will be included in the TSRC. It is useful when computing the reaction coordinate from the initial Hessian, in which case only part of the Hessian will be analyzed. :vartype BlockAtoms: Iterable[int] | IntListKey :ivar Coordinate: The TSRC contains Cartesian displacement of an atom: atom index followed by [x|y|z] and the weight. :vartype Coordinate: str | StringKey :ivar DifDist: Dummy. :vartype DifDist: str | StringKey :ivar Dihedral: The TSRC contains the dihedral angle between the given atoms. Four atom indices followed by the weight. :vartype Dihedral: str | StringKey :ivar Distance: The TSRC contains the distance between the given atoms. Two atom indices followed by the weight. :vartype Distance: str | StringKey :ivar EqualStrain: Dummy. :vartype EqualStrain: str | StringKey :ivar FixedRegion: Dummy. :vartype FixedRegion: str | StringKey :ivar FreezeStrain: Dummy. :vartype FreezeStrain: str | StringKey :ivar SumDist: Dummy. :vartype SumDist: str | StringKey """ def __post_init__(self): self.All: str | StringKey = StringKey(name='All', comment='Dummy.', hidden=True, unique=False) self.Angle: str | StringKey = StringKey(name='Angle', comment='The TSRC contains the valence angle between the given atoms. Three atom indices followed by the weight.', unique=False) self.Atom: str | StringKey = StringKey(name='Atom', comment='Dummy.', hidden=True, unique=False) self.AtomList: str | StringKey = StringKey(name='AtomList', comment='Dummy.', hidden=True, unique=False) self.Block: str | StringKey = StringKey(name='Block', comment='Name of the region. Only atoms of the region will be included in the TSRC. It is useful when computing the reaction coordinate from the initial Hessian, in which case only part of the Hessian will be analyzed.', unique=False, gui_type='region') self.BlockAtoms: Iterable[int] | IntListKey = IntListKey(name='BlockAtoms', comment='List of atom indices. Only the listed atoms will be included in the TSRC. It is useful when computing the reaction coordinate from the initial Hessian, in which case only part of the Hessian will be analyzed.', unique=False, range='value > 0') self.Coordinate: str | StringKey = StringKey(name='Coordinate', comment='The TSRC contains Cartesian displacement of an atom: atom index followed by [x|y|z] and the weight.', unique=False) self.DifDist: str | StringKey = StringKey(name='DifDist', comment='Dummy.', hidden=True, unique=False) self.Dihedral: str | StringKey = StringKey(name='Dihedral', comment='The TSRC contains the dihedral angle between the given atoms. Four atom indices followed by the weight.', unique=False) self.Distance: str | StringKey = StringKey(name='Distance', comment='The TSRC contains the distance between the given atoms. Two atom indices followed by the weight.', unique=False) self.EqualStrain: str | StringKey = StringKey(name='EqualStrain', comment='Dummy.', hidden=True) self.FixedRegion: str | StringKey = StringKey(name='FixedRegion', comment='Dummy.', hidden=True, unique=False) self.FreezeStrain: str | StringKey = StringKey(name='FreezeStrain', comment='Dummy.', hidden=True) self.SumDist: str | StringKey = StringKey(name='SumDist', comment='Dummy.', hidden=True, unique=False)
def __post_init__(self): self.ModeToFollow: int | IntKey = IntKey(name='ModeToFollow', comment='In case of Transition State Search, here you can specify the index of the normal mode to follow (1 is the mode with the lowest frequency).', default=1) self.ReactionCoordinate: AMS._TransitionStateSearch._ReactionCoordinate = self._ReactionCoordinate(name='ReactionCoordinate', comment='Specify components of the transition state reaction coordinate (TSRC) as a linear combination of internal coordinates (distances or angles).')
[docs] class _VibrationalAnalysis(FixedBlock): r""" Input data for all vibrational analysis utilities in the AMS driver. :ivar Displacement: Step size for finite difference calculations. :vartype Displacement: float | FloatKey :ivar Quiet: Suppress run-time output :vartype Quiet: BoolType | BoolKey :ivar Type: Specifies the type of vibrational analysis that should be performed :vartype Type: Literal["ModeScanning", "ModeTracking", "ModeRefinement", "VibronicStructure", "VibronicStructureTracking", "VibronicStructureRefinement", "ResonanceRaman"] :ivar VSTRestartFile: Path to a .rkf file containing restart information for VST. :vartype VSTRestartFile: str | Path | StringKey :ivar AbsorptionSpectrum: Settings related to the integration of the spectrum for vibronic tasks. :vartype AbsorptionSpectrum: AMS._VibrationalAnalysis._AbsorptionSpectrum :ivar ExcitationSettings: Block that contains settings related to the excitation for vibronic tasks. :vartype ExcitationSettings: AMS._VibrationalAnalysis._ExcitationSettings :ivar ModeTracking: Input data for Mode Tracking. :vartype ModeTracking: AMS._VibrationalAnalysis._ModeTracking :ivar NormalModes: All input related to processing of normal modes. Not available for vibronic structure tracking (as no modes are required there). :vartype NormalModes: AMS._VibrationalAnalysis._NormalModes :ivar ResonanceRaman: Block that contains settings for the calculation of Resonance Raman calculations :vartype ResonanceRaman: AMS._VibrationalAnalysis._ResonanceRaman """
[docs] class _AbsorptionSpectrum(FixedBlock): r""" Settings related to the integration of the spectrum for vibronic tasks. :ivar AbsorptionRange: Specifies frequency range of the vibronic absorption spectrum to compute. 2 numbers: an upper and a lower bound. :vartype AbsorptionRange: Iterable[float] | FloatListKey :ivar FrequencyGridPoints: Number of grid points to use for the spectrum :vartype FrequencyGridPoints: int | IntKey :ivar IntegrationThreshold: Value of exponential damping in absorption cross-section used to define upper integration limit. :vartype IntegrationThreshold: float | FloatKey :ivar LineWidth: Lorentzian line-width. :vartype LineWidth: float | FloatKey :ivar SpectrumOffset: Specifies whether provided frequency range are absolute frequencies or frequencies relative to computed 0-0 excitation energy. :vartype SpectrumOffset: Literal["absolute", "relative"] :ivar TimeStep: Value of time step for spectrum integration. :vartype TimeStep: float | FloatKey """ def __post_init__(self): self.AbsorptionRange: Iterable[float] | FloatListKey = FloatListKey(name='AbsorptionRange', comment='Specifies frequency range of the vibronic absorption spectrum to compute. 2 numbers: an upper and a lower bound.', unique=False, default=[-200.0, 4000.0], unit='cm-1') self.FrequencyGridPoints: int | IntKey = IntKey(name='FrequencyGridPoints', comment='Number of grid points to use for the spectrum', default=400) self.IntegrationThreshold: float | FloatKey = FloatKey(name='IntegrationThreshold', comment='Value of exponential damping in absorption cross-section used to define upper integration limit.', hidden=True, default=1e-05) self.LineWidth: float | FloatKey = FloatKey(name='LineWidth', comment='Lorentzian line-width.', default=200.0, unit='cm-1') self.SpectrumOffset: Literal["absolute", "relative"] = MultipleChoiceKey(name='SpectrumOffset', comment='Specifies whether provided frequency range are absolute frequencies or frequencies relative to computed 0-0 excitation energy.', default='relative', choices=['absolute', 'relative']) self.TimeStep: float | FloatKey = FloatKey(name='TimeStep', comment='Value of time step for spectrum integration.', hidden=True)
[docs] class _ExcitationSettings(FixedBlock): r""" Block that contains settings related to the excitation for vibronic tasks. :ivar EnergyInline: Vertical excitation energy, used when [ExcitationInfo] = [Inline]. :vartype EnergyInline: float | FloatKey :ivar ExcitationFile: Path to a .rkf/.t21 file containing the excited state information (gradients, transition dipoles and energies). :vartype ExcitationFile: str | Path | StringKey :ivar ExcitationInputFormat: Select how the application should retrieve the excited state information (energy, gradient). :vartype ExcitationInputFormat: Literal["File", "Inline"] :ivar GradientInline: Excited state gradient at ground state equilibrium geometry, used when [ExcitationInfo] = [Inline]. :vartype GradientInline: str | Sequence[str] | FreeBlock :ivar Singlet: Symmetry labels + integer indices of desired singlet transitions (VG-FC absorption spectra support only 1 at a time) :vartype Singlet: str | Sequence[str] | FreeBlock :ivar Triplet: Symmetry labels + integer indices of desired triplet transitions (VG-FC absorption spectra support only 1 at a time) :vartype Triplet: str | Sequence[str] | FreeBlock """
[docs] class _GradientInline(FreeBlock): r""" Excited state gradient at ground state equilibrium geometry, used when [ExcitationInfo] = [Inline]. """ def __post_init__(self): pass
[docs] class _Singlet(FreeBlock): r""" Symmetry labels + integer indices of desired singlet transitions (VG-FC absorption spectra support only 1 at a time) """ def __post_init__(self): pass
[docs] class _Triplet(FreeBlock): r""" Symmetry labels + integer indices of desired triplet transitions (VG-FC absorption spectra support only 1 at a time) """ def __post_init__(self): pass
def __post_init__(self): self.EnergyInline: float | FloatKey = FloatKey(name='EnergyInline', comment='Vertical excitation energy, used when [ExcitationInfo] = [Inline].', unit='hartree') self.ExcitationFile: str | Path | StringKey = PathStringKey(name='ExcitationFile', comment='Path to a .rkf/.t21 file containing the excited state information (gradients, transition dipoles and energies).', ispath=True, gui_type='.rkf {{{Result Files} .rkf} {{Result Files} .t21} {{Any Files} *}}') self.ExcitationInputFormat: Literal["File", "Inline"] = MultipleChoiceKey(name='ExcitationInputFormat', comment='Select how the application should retrieve the excited state information (energy, gradient).', default='File', choices=['File', 'Inline']) self.GradientInline: str | Sequence[str] | FreeBlock = self._GradientInline(name='GradientInline', comment='Excited state gradient at ground state equilibrium geometry, used when [ExcitationInfo] = [Inline].') self.Singlet: str | Sequence[str] | FreeBlock = self._Singlet(name='Singlet', comment='Symmetry labels + integer indices of desired singlet transitions (VG-FC absorption spectra support only 1 at a time)') self.Triplet: str | Sequence[str] | FreeBlock = self._Triplet(name='Triplet', comment='Symmetry labels + integer indices of desired triplet transitions (VG-FC absorption spectra support only 1 at a time)')
[docs] class _ModeTracking(FixedBlock): r""" Input data for Mode Tracking. :ivar GramSchmidt: Turn on/off gram-schmidt orthogonalization of new vectors to alter convergence. :vartype GramSchmidt: BoolType | BoolKey :ivar GramSchmidtIterations: Maximum number of gram-schmidt orthogonalization steps per iteration. :vartype GramSchmidtIterations: int | IntKey :ivar GramSchmidtTolerance: Tolerance for checking orthogonality when expanding the basis. :vartype GramSchmidtTolerance: float | FloatKey :ivar HessianGuess: Sets how to obtain the guess for the Hessian used in the preconditioner (if one is to be used). :vartype HessianGuess: Literal["Unit", "File", "CalculateWithFastEngine", "Inline"] :ivar HessianPath: Path to a .rkf file containing the initial guess for the Hessian, used when [HessianGuess] = [File]. It may also be the name of the results folder containing the engine file. :vartype HessianPath: str | Path | StringKey :ivar MaxIterations: Maximum number of allowed iterations. :vartype MaxIterations: int | IntKey :ivar RemoveRigids: Orthogonalize tracked vectors against rigid modes :vartype RemoveRigids: BoolType | BoolKey :ivar ToleranceForBasis: Convergence tolerance for the contribution of the newest basis vector to the tracked mode. :vartype ToleranceForBasis: float | FloatKey :ivar ToleranceForNorm: Convergence tolerance for residual RMS value. :vartype ToleranceForNorm: float | FloatKey :ivar ToleranceForResidual: Convergence tolerance for the maximum component of the residual vector. :vartype ToleranceForResidual: float | FloatKey :ivar ToleranceForSpectrum: Convergence tolerance for the spectrum in Vibronic Structure Tracking. :vartype ToleranceForSpectrum: float | FloatKey :ivar TrackingMethod: Set the tracking method that will be used. Vibronic Structure Tracking uses Largest Displacement. :vartype TrackingMethod: Literal["OverlapInitial", "DifferenceInitial", "FreqInitial", "IRInitial", "OverlapPrevious", "DifferencePrevious", "FreqPrevious", "IRPrevious", "HighestFreq", "HighestIR", "LowestFreq", "LowestResidual"] :ivar UpdateMethod: Chooses the method for expanding the Krylov subspace: (I) No preconditioner (VST default), (D) Davidson or (JD) vdVorst-Sleijpen variant of Jacobi-Davidson (Mode tracking default). :vartype UpdateMethod: Literal["JD", "D", "I"] :ivar HessianInline: Initial guess for the (non-mass-weighted) Hessian in a 3N x 3N block, used when [HessianGuess] = [Inline]. :vartype HessianInline: str | Sequence[str] | FreeBlock """
[docs] class _HessianInline(FreeBlock): r""" Initial guess for the (non-mass-weighted) Hessian in a 3N x 3N block, used when [HessianGuess] = [Inline]. """ def __post_init__(self): pass
def __post_init__(self): self.GramSchmidt: BoolType | BoolKey = BoolKey(name='GramSchmidt', comment='Turn on/off gram-schmidt orthogonalization of new vectors to alter convergence.', hidden=True, default=True) self.GramSchmidtIterations: int | IntKey = IntKey(name='GramSchmidtIterations', comment='Maximum number of gram-schmidt orthogonalization steps per iteration.', hidden=True, default=8) self.GramSchmidtTolerance: float | FloatKey = FloatKey(name='GramSchmidtTolerance', comment='Tolerance for checking orthogonality when expanding the basis.', hidden=True, default=0.001) self.HessianGuess: Literal["Unit", "File", "CalculateWithFastEngine", "Inline"] = MultipleChoiceKey(name='HessianGuess', comment='Sets how to obtain the guess for the Hessian used in the preconditioner (if one is to be used).', gui_name='Guess Hessian:', default='CalculateWithFastEngine', choices=['Unit', 'File', 'CalculateWithFastEngine', 'Inline'], hiddenchoices=['Inline']) self.HessianPath: str | Path | StringKey = PathStringKey(name='HessianPath', comment='Path to a .rkf file containing the initial guess for the Hessian, used when [HessianGuess] = [File]. It may also be the name of the results folder containing the engine file.', ispath=True, gui_type='.rkf {{{RKF Result Files} .rkf} {{Any Files} *}}') self.MaxIterations: int | IntKey = IntKey(name='MaxIterations', comment='Maximum number of allowed iterations.', hidden=True) self.RemoveRigids: BoolType | BoolKey = BoolKey(name='RemoveRigids', comment='Orthogonalize tracked vectors against rigid modes', hidden=True, default=False) self.ToleranceForBasis: float | FloatKey = FloatKey(name='ToleranceForBasis', comment='Convergence tolerance for the contribution of the newest basis vector to the tracked mode.', default=0.0001) self.ToleranceForNorm: float | FloatKey = FloatKey(name='ToleranceForNorm', comment='Convergence tolerance for residual RMS value.', default=0.0005) self.ToleranceForResidual: float | FloatKey = FloatKey(name='ToleranceForResidual', comment='Convergence tolerance for the maximum component of the residual vector.', default=0.0005) self.ToleranceForSpectrum: float | FloatKey = FloatKey(name='ToleranceForSpectrum', comment='Convergence tolerance for the spectrum in Vibronic Structure Tracking.', default=0.01) self.TrackingMethod: Literal["OverlapInitial", "DifferenceInitial", "FreqInitial", "IRInitial", "OverlapPrevious", "DifferencePrevious", "FreqPrevious", "IRPrevious", "HighestFreq", "HighestIR", "LowestFreq", "LowestResidual"] = MultipleChoiceKey(name='TrackingMethod', comment='Set the tracking method that will be used. Vibronic Structure Tracking uses Largest Displacement.', default='OverlapInitial', choices=['OverlapInitial', 'DifferenceInitial', 'FreqInitial', 'IRInitial', 'OverlapPrevious', 'DifferencePrevious', 'FreqPrevious', 'IRPrevious', 'HighestFreq', 'HighestIR', 'LowestFreq', 'LowestResidual']) self.UpdateMethod: Literal["JD", "D", "I"] = MultipleChoiceKey(name='UpdateMethod', comment='Chooses the method for expanding the Krylov subspace: (I) No preconditioner (VST default), (D) Davidson or (JD) vdVorst-Sleijpen variant of Jacobi-Davidson (Mode tracking default).', choices=['JD', 'D', 'I']) self.HessianInline: str | Sequence[str] | FreeBlock = self._HessianInline(name='HessianInline', comment='Initial guess for the (non-mass-weighted) Hessian in a 3N x 3N block, used when [HessianGuess] = [Inline].')
[docs] class _NormalModes(FixedBlock): r""" All input related to processing of normal modes. Not available for vibronic structure tracking (as no modes are required there). :ivar MassWeightInlineMode: MODE TRACKING ONLY: The supplied modes must be mass-weighted. This tells the program to mass-weight the supplied modes in case this has not yet been done. (True means the supplied modes will be mass-weighted by the program, e.g. the supplied modes are non-mass-weighted.) :vartype MassWeightInlineMode: BoolType | BoolKey :ivar ModeFile: Path to a .rkf or .t21 file containing the modes which are to be scanned. Which modes will be scanned is selected using the criteria from the [ModeSelect] block.) This key is optional for Resonance Raman and Vibronic Structure. These methods can also calculate the modes using the engine. :vartype ModeFile: str | Path | StringKey :ivar ModeInputFormat: Set how the initial guesses for the modes are supplied. Only mode tracking supports the Inline and Hessian options. :vartype ModeInputFormat: Literal["File", "Inline", "Hessian"] :ivar ScanModes: Supported by: Mode Tracking, Mode Refinement, Vibronic Structure Refinement: If enabled an additional displacement will be performed along the new modes at the end of the calculation to obtain refined frequencies and IR intensities. Equivalent to running the output file of the mode tracking calculation through the AMS ModeScanning task. :vartype ScanModes: BoolType | BoolKey :ivar ModeInline: MODE TRACKING ONLY: Coordinates of the mode which will be tracked in a N x 3 block (same as for atoms), used when [ModeInputFormat] = [Inline]. Rows must be ordered in the same way as in the [System%Atoms] block. Mode Tracking only. :vartype ModeInline: str | Sequence[str] | FreeBlock :ivar ModeSelect: Pick which modes to read from file. :vartype ModeSelect: AMS._VibrationalAnalysis._NormalModes._ModeSelect """
[docs] class _ModeInline(FreeBlock): r""" MODE TRACKING ONLY: Coordinates of the mode which will be tracked in a N x 3 block (same as for atoms), used when [ModeInputFormat] = [Inline]. Rows must be ordered in the same way as in the [System%Atoms] block. Mode Tracking only. """ def __post_init__(self): pass
[docs] class _ModeSelect(FixedBlock): r""" Pick which modes to read from file. :ivar DisplacementBound: Vibronic Structure (Refinement), Resonance Raman: Select all modes with a dimensionless oscillator displacement greater than the specified value. :vartype DisplacementBound: float | FloatKey :ivar FreqAndIRRange: Specifies a combined frequency and IR intensity range within which all modes will be selected. First 2 numbers are the frequency range in cm-1, last 2 numbers are the IR intensity range in km/mol. :vartype FreqAndIRRange: Iterable[float] | FloatListKey :ivar FreqRange: Specifies a frequency range within which all modes will be selected. 2 numbers: an upper and a lower bound. Calculating all modes higher than some frequency can be achieved by making the upper bound very large. :vartype FreqRange: Iterable[float] | FloatListKey :ivar Full: Select all modes. This only make sense for Mode Scanning calculations. :vartype Full: BoolType | BoolKey :ivar HighFreq: Select the N modes with the highest frequencies. :vartype HighFreq: int | IntKey :ivar HighIR: Select the N modes with the largest IR intensities. :vartype HighIR: int | IntKey :ivar IRRange: Specifies an IR intensity range within which all modes will be selected. 2 numbers: an upper and a lower bound. :vartype IRRange: Iterable[float] | FloatListKey :ivar ImFreq: Select all modes with imaginary frequencies. :vartype ImFreq: BoolType | BoolKey :ivar LargestDisplacement: Vibronic Structure (Refinement), Resonance Raman: Select the N modes with the largest VG-FC displacement. :vartype LargestDisplacement: int | IntKey :ivar LowFreq: Select the N modes with the lowest frequencies. Includes imaginary modes which are recorded with negative frequencies. :vartype LowFreq: int | IntKey :ivar LowFreqNoIm: Select the N modes with the lowest non-negative frequencies. Imaginary modes have negative frequencies and are thus omitted here. :vartype LowFreqNoIm: int | IntKey :ivar LowIR: Select the N modes with the smallest IR intensities. :vartype LowIR: int | IntKey :ivar ModeNumber: Indices of the modes to select. :vartype ModeNumber: Iterable[int] | IntListKey """ def __post_init__(self): self.DisplacementBound: float | FloatKey = FloatKey(name='DisplacementBound', comment='Vibronic Structure (Refinement), Resonance Raman: Select all modes with a dimensionless oscillator displacement greater than the specified value.') self.FreqAndIRRange: Iterable[float] | FloatListKey = FloatListKey(name='FreqAndIRRange', comment='Specifies a combined frequency and IR intensity range within which all modes will be selected. First 2 numbers are the frequency range in cm-1, last 2 numbers are the IR intensity range in km/mol.', unique=False) self.FreqRange: Iterable[float] | FloatListKey = FloatListKey(name='FreqRange', comment='Specifies a frequency range within which all modes will be selected. 2 numbers: an upper and a lower bound. Calculating all modes higher than some frequency can be achieved by making the upper bound very large.', unique=False, unit='cm-1') self.Full: BoolType | BoolKey = BoolKey(name='Full', comment='Select all modes. This only make sense for Mode Scanning calculations.', gui_name='All modes:', default=False) self.HighFreq: int | IntKey = IntKey(name='HighFreq', comment='Select the N modes with the highest frequencies.', gui_name='# High frequencies:') self.HighIR: int | IntKey = IntKey(name='HighIR', comment='Select the N modes with the largest IR intensities.', gui_name='# High IR:') self.IRRange: Iterable[float] | FloatListKey = FloatListKey(name='IRRange', comment='Specifies an IR intensity range within which all modes will be selected. 2 numbers: an upper and a lower bound.', unique=False, unit='km/mol') self.ImFreq: BoolType | BoolKey = BoolKey(name='ImFreq', comment='Select all modes with imaginary frequencies.', gui_name='All imaginary frequencies:', default=False) self.LargestDisplacement: int | IntKey = IntKey(name='LargestDisplacement', comment='Vibronic Structure (Refinement), Resonance Raman: Select the N modes with the largest VG-FC displacement.') self.LowFreq: int | IntKey = IntKey(name='LowFreq', comment='Select the N modes with the lowest frequencies. Includes imaginary modes which are recorded with negative frequencies.', gui_name='# Low frequencies:') self.LowFreqNoIm: int | IntKey = IntKey(name='LowFreqNoIm', comment='Select the N modes with the lowest non-negative frequencies. Imaginary modes have negative frequencies and are thus omitted here.', gui_name='# Low positive frequencies:') self.LowIR: int | IntKey = IntKey(name='LowIR', comment='Select the N modes with the smallest IR intensities.', gui_name='# Low IR:') self.ModeNumber: Iterable[int] | IntListKey = IntListKey(name='ModeNumber', comment='Indices of the modes to select.', gui_name='Mode numbers:')
def __post_init__(self): self.MassWeightInlineMode: BoolType | BoolKey = BoolKey(name='MassWeightInlineMode', comment='MODE TRACKING ONLY: The supplied modes must be mass-weighted. This tells the program to mass-weight the supplied modes in case this has not yet been done. (True means the supplied modes will be mass-weighted by the program, e.g. the supplied modes are non-mass-weighted.)', default=True) self.ModeFile: str | Path | StringKey = PathStringKey(name='ModeFile', comment='Path to a .rkf or .t21 file containing the modes which are to be scanned. Which modes will be scanned is selected using the criteria from the [ModeSelect] block.) This key is optional for Resonance Raman and Vibronic Structure. These methods can also calculate the modes using the engine.', ispath=True, gui_type='.rkf {{{Result Files} .rkf} {{Result Files} .t21} {{Any Files} *}}') self.ModeInputFormat: Literal["File", "Inline", "Hessian"] = MultipleChoiceKey(name='ModeInputFormat', comment='Set how the initial guesses for the modes are supplied. Only mode tracking supports the Inline and Hessian options.', gui_name='Tracked mode source:', default='File', choices=['File', 'Inline', 'Hessian']) self.ScanModes: BoolType | BoolKey = BoolKey(name='ScanModes', comment='Supported by: Mode Tracking, Mode Refinement, Vibronic Structure Refinement: If enabled an additional displacement will be performed along the new modes at the end of the calculation to obtain refined frequencies and IR intensities. Equivalent to running the output file of the mode tracking calculation through the AMS ModeScanning task.', gui_name='Scan after refining:', default=False) self.ModeInline: str | Sequence[str] | FreeBlock = self._ModeInline(name='ModeInline', comment='MODE TRACKING ONLY: Coordinates of the mode which will be tracked in a N x 3 block (same as for atoms), used when [ModeInputFormat] = [Inline]. Rows must be ordered in the same way as in the [System%Atoms] block. Mode Tracking only.', unique=False) self.ModeSelect: AMS._VibrationalAnalysis._NormalModes._ModeSelect = self._ModeSelect(name='ModeSelect', comment='Pick which modes to read from file.')
[docs] class _ResonanceRaman(FixedBlock): r""" Block that contains settings for the calculation of Resonance Raman calculations :ivar IncidentFrequency: Frequency of incident light. Also used to determine most important excitation in case more than one is provided. :vartype IncidentFrequency: float | FloatKey :ivar LifeTime: Lifetime of Raman excited state. :vartype LifeTime: float | FloatKey :ivar MaximumStates: Maximum number of final states included in the spectrum. :vartype MaximumStates: int | IntKey :ivar RamanOrder: Order up to which to compute Raman transitions :vartype RamanOrder: int | IntKey :ivar RamanRange: Specifies frequency range of the Raman spectrum to compute. 2 numbers: an upper and a lower bound. :vartype RamanRange: Iterable[float] | FloatListKey """ def __post_init__(self): self.IncidentFrequency: float | FloatKey = FloatKey(name='IncidentFrequency', comment='Frequency of incident light. Also used to determine most important excitation in case more than one is provided.', unit='cm-1') self.LifeTime: float | FloatKey = FloatKey(name='LifeTime', comment='Lifetime of Raman excited state.', default=0.00045, unit='hartree') self.MaximumStates: int | IntKey = IntKey(name='MaximumStates', comment='Maximum number of final states included in the spectrum.', hidden=True, default=250000) self.RamanOrder: int | IntKey = IntKey(name='RamanOrder', comment='Order up to which to compute Raman transitions', default=2) self.RamanRange: Iterable[float] | FloatListKey = FloatListKey(name='RamanRange', comment='Specifies frequency range of the Raman spectrum to compute. 2 numbers: an upper and a lower bound.', unique=False, default=[0.0, 2000.0], unit='cm-1')
def __post_init__(self): self.Displacement: float | FloatKey = FloatKey(name='Displacement', comment='Step size for finite difference calculations.', unit='Bohr') self.Quiet: BoolType | BoolKey = BoolKey(name='Quiet', comment='Suppress run-time output', hidden=True, default=False) self.Type: Literal["ModeScanning", "ModeTracking", "ModeRefinement", "VibronicStructure", "VibronicStructureTracking", "VibronicStructureRefinement", "ResonanceRaman"] = MultipleChoiceKey(name='Type', comment='Specifies the type of vibrational analysis that should be performed', choices=['ModeScanning', 'ModeTracking', 'ModeRefinement', 'VibronicStructure', 'VibronicStructureTracking', 'VibronicStructureRefinement', 'ResonanceRaman']) self.VSTRestartFile: str | Path | StringKey = PathStringKey(name='VSTRestartFile', comment='Path to a .rkf file containing restart information for VST.', ispath=True) self.AbsorptionSpectrum: AMS._VibrationalAnalysis._AbsorptionSpectrum = self._AbsorptionSpectrum(name='AbsorptionSpectrum', comment='Settings related to the integration of the spectrum for vibronic tasks.') self.ExcitationSettings: AMS._VibrationalAnalysis._ExcitationSettings = self._ExcitationSettings(name='ExcitationSettings', comment='Block that contains settings related to the excitation for vibronic tasks.') self.ModeTracking: AMS._VibrationalAnalysis._ModeTracking = self._ModeTracking(name='ModeTracking', comment='Input data for Mode Tracking.') self.NormalModes: AMS._VibrationalAnalysis._NormalModes = self._NormalModes(name='NormalModes', comment='All input related to processing of normal modes. Not available for vibronic structure tracking (as no modes are required there).') self.ResonanceRaman: AMS._VibrationalAnalysis._ResonanceRaman = self._ResonanceRaman(name='ResonanceRaman', comment='Block that contains settings for the calculation of Resonance Raman calculations')
def __post_init__(self): self.EngineRestart: str | Path | StringKey = PathStringKey(name='EngineRestart', comment='The path to the file from which to restart the engine.\n\nShould be a proper engine result file (like adf.rkf, band.rkf etc), or the name of the results directory containing it.', ispath=True) self.FallbackSolveAfterEngineFailure: BoolType | BoolKey = BoolKey(name='FallbackSolveAfterEngineFailure', comment='If the engine fails to Solve, try to re-run the Solve without restarting the engine from the previous results. This generally decreases the engine failure rate. Only relevant certain tasks, such as GeometryOptimization, MolecularDynamics, Replay, IRC.', default=True) self.LoadEngine: str | Path | StringKey = PathStringKey(name='LoadEngine', comment='The path to the file from which to load the engine configuration. Replaces the Engine block.', ispath=True) self.RNGSeed: Iterable[int] | IntListKey = IntListKey(name='RNGSeed', comment='Initial seed for the (pseudo)random number generator. This should be omitted in most calculations to avoid introducing bias into the results. If this is unset, the generator will be seeded randomly from external sources of entropy. If you want to exactly reproduce an older calculation, set this to the numbers printed in its output.') self.Task: Literal["GCMC", "GeometryOptimization", "Idle", "IRC", "MolecularDynamics", "NEB", "PESExploration", "PESScan", "Pipe", "Replay", "SinglePoint", "SteepestDescent", "TestEngine", "TestSymmetry", "TransitionStateSearch", "VibrationalAnalysis"] = MultipleChoiceKey(name='Task', comment='Specify the computational task to perform:\n\n• Single Point: keep geometry as is\n• Geometry Optimization: minimize energy\n• Transition State: search for a transition state\n• IRC: intrinsic reaction coordinate\n• PES Scan: scan the potential energy surface\n• NEB: Nudged elastic band for reaction path optimization\n• Vibrational Analysis: perform one of the analysis types selected on the options page\n• Molecular Dynamics: perform MD simulation\n• GCMC: Grand Canonical Monte Carlo simulation\n• PES Exploration: automated potential energy surface exploration\n• Replay: recompute frames from the trajectory of a previously run job', choices=['GCMC', 'GeometryOptimization', 'Idle', 'IRC', 'MolecularDynamics', 'NEB', 'PESExploration', 'PESScan', 'Pipe', 'Replay', 'SinglePoint', 'SteepestDescent', 'TestEngine', 'TestSymmetry', 'TransitionStateSearch', 'VibrationalAnalysis'], hiddenchoices=['Idle', 'SteepestDescent', 'TestEngine', 'TestSymmetry', 'Pipe']) self.Test: Literal["Symmetry", "BareSymmetry", "Bonds", "SecondOrderBonds", "AtomTyping", "SystemMatching"] = MultipleChoiceKey(name='Test', comment='various technical tests that will be done for the system', hidden=True, default='Symmetry', choices=['Symmetry', 'BareSymmetry', 'Bonds', 'SecondOrderBonds', 'AtomTyping', 'SystemMatching']) self.UseSymmetry: BoolType | BoolKey = BoolKey(name='UseSymmetry', comment="Whether to use the system's symmetry in AMS. Symmetry is recognized within a tolerance as given in the Symmetry key.", default=True) self.BondOrders: AMS._BondOrders = self._BondOrders(name='BondOrders', comment="Configures details regarding the calculation/guessing of bond orders. To request the calculation of bond orders, use the 'Properties%BondOrders' key.") self.Constraints: AMS._Constraints = self._Constraints(name='Constraints', comment='The Constraints block allows geometry optimizations and potential energy surface scans with constraints. The constraints do not have to be satisfied at the start of the calculation.', extra_info='not_in_fragment', shared_id='AMSConstraints') self.ElasticTensor: AMS._ElasticTensor = self._ElasticTensor(name='ElasticTensor', comment='Options for numerical evaluation of the elastic tensor.') self.Engine: EngineBlock = self._Engine(name='Engine', comment='The input for the computational engine. The header of the block determines the type of the engine.', header=True) self.EngineAddons: AMS._EngineAddons = self._EngineAddons(name='EngineAddons', comment='This block configures all the engine add-ons.') self.EngineDebugging: AMS._EngineDebugging = self._EngineDebugging(name='EngineDebugging', comment='This block contains some options useful for debugging the computational engines.') self.ExitCondition: AMS._ExitCondition = self._ExitCondition(name='ExitCondition', comment='If any of the specified exitconditions are met, the AMS driver will exit cleanly.', unique=False) self.GCMC: AMS._GCMC = self._GCMC(name='GCMC', comment='This block controls the Grand Canonical Monte Carlo (GCMC) task. \n\n By default, molecules are added at random positions in the simulation box. The initial position is controlled by ') self.GeometryOptimization: AMS._GeometryOptimization = self._GeometryOptimization(name='GeometryOptimization', comment='Configures details of the geometry optimization and transition state searches.') self.IEEEExceptions: AMS._IEEEExceptions = self._IEEEExceptions(name='IEEEExceptions', comment='Whether this works or not depends on the way the program is compiled (compiler and settings). Only useful for developers debugging some numerical issue.', hidden=True) self.IRC: AMS._IRC = self._IRC(name='IRC', comment='Configures details of the Intrinsic Reaction Coordinate optimization.') self.Idle: AMS._Idle = self._Idle(name='Idle', comment='Configures details of the idle task, which does nothing for a specified amount of time.', hidden=True) self.LoadSystem: AMS._LoadSystem = self._LoadSystem(name='LoadSystem', comment='Block that controls reading the chemical system from a KF file instead of the [System] block.', unique=False, header=True, extra_info='not_in_fragment', shared_id='AMSLoadSystem') self.Log: str | Sequence[str] | FreeBlock = self._Log(name='Log', comment="Configures the debugging loggers. Syntax: 'Level LoggerName'. Possible Levels: All, Debug, Info, Warning, Error, Fatal.") self.MolecularDynamics: AMS._MolecularDynamics = self._MolecularDynamics(name='MolecularDynamics', comment='Configures molecular dynamics (with the velocity-Verlet algorithm) with and without thermostats. This block allows to specify the details of the molecular dynamics calculation.') self.Molecules: AMS._Molecules = self._Molecules(name='Molecules', comment='Configures details of the molecular composition analysis enabled by the Properties%Molecules block.') self.NEB: AMS._NEB = self._NEB(name='NEB', comment='Configures details of the Nudged Elastic Band optimization.') self.NormalModes: AMS._NormalModes = self._NormalModes(name='NormalModes', comment='Configures details of a normal modes calculation.') self.NumericalDifferentiation: AMS._NumericalDifferentiation = self._NumericalDifferentiation(name='NumericalDifferentiation', comment='Define options for numerical differentiations, that is the numerical calculation of gradients, Hessian and the stress tensor for periodic systems.') self.NumericalPhonons: AMS._NumericalPhonons = self._NumericalPhonons(name='NumericalPhonons', comment='Configures details of a numerical phonons calculation.') self.PESExploration: AMS._PESExploration = self._PESExploration(name='PESExploration', comment='Configures details of the automated PES exploration methods.') self.PESPointCharacter: AMS._PESPointCharacter = self._PESPointCharacter(name='PESPointCharacter', comment='Options for the characterization of PES points.') self.PESScan: AMS._PESScan = self._PESScan(name='PESScan', comment='Configures the details of the potential energy surface scanning task.') self.Phonons: AMS._Phonons = self._Phonons(name='Phonons', comment='Configures the phonons calculation.') self.Print: AMS._Print = self._Print(name='Print', comment='This block controls the printing of additional information to stdout.') self.Properties: AMS._Properties = self._Properties(name='Properties', comment='Configures which AMS level properties to calculate for SinglePoint calculations or other important geometries (e.g. at the end of an optimization).') self.Raman: AMS._Raman = self._Raman(name='Raman', comment='Configures details of the Raman or VROA calculation.') self.Replay: AMS._Replay = self._Replay(name='Replay', comment='Configures the details of the Replay task.') self.Restraints: AMS._Restraints = self._Restraints(name='Restraints', comment="The Restraints block allows to add soft constraints to the system. A restraint is a potential energy function (a spring) attached to a certain coordinate, for example, an interatomic distance, with its minimum at the specified optimal value. A restraint is defined using one or two parameters: the ForceConstant and, for some types, the F(Inf) value. The ForceConstant parameter corresponds to second derivative of the restraint potential energy d2V(x)/dx^2 for any x (harmonic restraints) or only at at x=0 (other restraints). Here, x is a deviation from the restraint's optimal value.") self.RigidMotions: AMS._RigidMotions = self._RigidMotions(name='RigidMotions', comment='Specify which rigid motions of the total system are allowed. An external field is not considered part of the system. Normally the automatic option is doing what you want. However this feature can be used as a means of geometry constraint.') self.SCMLibrary: AMS._SCMLibrary = self._SCMLibrary(name='SCMLibrary', comment='Technical settings affecting src/lib', hidden=True) self.SCMMatrix: AMS._SCMMatrix = self._SCMMatrix(name='SCMMatrix', comment='Technical settings for programs using the AMT matrix system. Currently this is only used by DFTB') self.SerializedTensors: AMS._SerializedTensors = self._SerializedTensors(name='SerializedTensors', comment='Technical settings affecting the SerializedTensors module, currently only used for HartreeFock', hidden=True) self.SteepestDescent: AMS._SteepestDescent = self._SteepestDescent(name='SteepestDescent', comment='Configures details of the steepest descent task.', hidden=True) self.Symmetry: AMS._Symmetry = self._Symmetry(name='Symmetry', comment='Specifying details about the details of symmetry detection and usage.', shared_id='AMSSymmetry') self.System: AMS._System = self._System(name='System', comment='Specification of the chemical system. For some applications more than one system may be present in the input. In this case, all systems except one must have a non-empty string ID specified after the System keyword. The system without an ID is considered the main one.', unique=False, header=True, gui_type='Repeat at least once', shared_id='AMSSystem') self.Thermo: AMS._Thermo = self._Thermo(name='Thermo', comment='Options for thermodynamic properties (assuming an ideal gas). The properties are computed for all specified temperatures.') self.TransitionStateSearch: AMS._TransitionStateSearch = self._TransitionStateSearch(name='TransitionStateSearch', comment='Configures some details of the transition state search.') self.VibrationalAnalysis: AMS._VibrationalAnalysis = self._VibrationalAnalysis(name='VibrationalAnalysis', comment='Input data for all vibrational analysis utilities in the AMS driver.')