Model Extended KIM ID = === Verification check vc-unit-conversion start (2021-08-05 18:42:52) === !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!! !!!!! !!!!! VERIFICATION CHECK: vc-unit-conversion !!!!! !!!!! !!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Description: This verification check ensures that a model can properly convert units of length and energy. Working in one unit system, a random cluster of atoms is generated based on the smallest cutoff of the model such that the energy and/or forces (depending on what the model actually reports) are sizeable. Next, the model is reinitialized with a different set of registered units. The coordinates of the atoms in the cluster are rescaled to correspond to the new length units and the energy and/or forces are requested from the model once again. The energy and/or force returned by the model are then compared to a manual conversion of those originally returned (in the first set of units). Author: Daniel S. Karls Checking if model properly converts its cutoffs from Angstrom to Bohr SUCCESS: Absolute difference in smallest cutoff is 1.7763568394002505e-15 Bohr, which is below tolerance 1e-06. Creating Model object with Angstrom and eV as simulator registered units ------------------------------------------------------------------------------------------------------------------------ Results for KIM Model : EAM_Dynamo_BonnyPasianotMalerba_2009_FeNi__MO_267721408934_005 Supported species : Fe Ni Model computes energy : True Model computes forces : True Model native length unit : A Model native energy unit : eV Influence distance : 5.6 Angstroms Model cutoffs : [5.6] Angstroms Smallest model cutoff : 5.6 Angstroms Parameters for random cluster generation Random seed: 11 Min. distance between atoms (dmin) : 5.5999999999999994e-01 Angstroms ------------------------------------------------------------------------------------------------------------------------ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ STEP I: Cluster generation Attempting to find a species supported by the Model for which a random cluster can be generated that has significant energy and/or forces (depending on what the Model is able to compute). We construct the cluster by first placing a single atom at the origin and then generating additional atom positions that fall within a distance 'rball' of the origin; no atoms are allowed to fall within a distance of 'dmin' of one another. Note that 'rball' is chosen to be 0.9 * the smallest cutoff reported by the Model in Angstroms. In the event that the Model's native length unit is not Angstroms and the cutoffs it reports are improperly converted to Angstroms, it's possible that the cluster generated may actually be far too large for atomic interactions to occur. Accordingly, if the energy and/or forces are not sizable using the initial value of 'rball', we regenerate the cluster positions iteratively using smaller and smaller values of 'rball' (while keeping 'dmin' fixed); if the energy and/or forces still aren't sizeable when generating a cluster using rball = 0.2 * the smallest cutoff reported by the Model, that species is skipped and the process is repeated for the next species. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Creating random cluster of 5 Fe atoms with a diameter 5.040000 Angstroms and a minimum separation of 0.560000 Angstroms between all atoms Cluster positions (Angstroms): [[-4.4191470168997862e+00 1.3631688650903155e+00 5.5684210022730607e-01] [-2.8913810784994247e+00 6.3391153784399024e-01 4.6426915943325840e-02] [ 1.2666447347596148e+00 2.9099889849328791e+00 7.5610543213622899e-02] [ 2.3822384467075236e-01 -8.6065948404174497e-01 -1.2412860349653145e+00] [ 2.3106964418658182e+00 1.4801052446962883e+00 2.1643719152707428e+00]] Calling Model compute... Model returned energy of -4.4815401810937141e+00 eV Model returned forces (eV/Angstrom): [[-8.8697811788719072e+00 4.2338638093584802e+00 2.9633276152973651e+00] [ 9.4827509406020596e+00 -4.5206539303430233e+00 -3.2131163779989378e+00] [ 6.6870630611373827e-01 -1.0391212761414179e+00 1.3654280437198849e+00] [-5.8019702484366265e-01 3.7694825689274342e-01 2.8608077173626095e-01] [-7.0147904300022779e-01 9.4896314023321782e-01 -1.4017200527545730e+00]] Cumulative norm of all forces: 1.5276525925855193e+01 eV/Angstrom SUCCESS: Absolute value of energy exceeds tolerance 0.001 eV and cumulative norm of forces on all atoms exceeds tolerance 0.001 eV/Angstrom. Proceeding with unit conversion... ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ STEP II: Convert units and ask model to recompute energy and/or forces Take the set of coordinates that was found to have sizeable energy/forces from Step I and change the units from Angstroms to Bohr ourselves. Next, create a new Model object wherein we've registered Bohr and Hartree as the unit set. Ask the model for its neighbor list cutoffs and influence once more and use them to create a new neighbor list using the coordinates we converted to Bohr. Finally, have the Model compute the energy and/or forces once more and compare the results to our own conversion of the energy and/or forces the model returned in Step I. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Creating Model object with Bohr and Hartree as simulator registered units Cluster positions converted to Bohr: [[-8.3509775661021894e+00 2.5760158165465170e+00 1.0522790640538024e+00] [-5.4639183600957377e+00 1.1979191937231153e+00 8.7734155940804345e-02] [ 2.3936116458102608e+00 5.4990822070063841e+00 1.4288321880287511e-01] [ 4.5017782276718937e-01 -1.6264107113430950e+00 -2.3456906483241244e+00] [ 4.3665834321192021e+00 2.7969935479992638e+00 4.0900701515487699e+00]] Calling Model compute... Model returned energy of -1.6469357553758587e-01 Hartree Model returned forces (Hartree/Bohr): [[-1.7248979354816246e-01 8.2335548043380613e-02 5.7627551150390428e-02] [ 1.8441015838240971e-01 -8.7912728332575130e-02 -6.2485169533544500e-02] [ 1.3004268127905977e-02 -2.0207692927089654e-02 2.6553349695606694e-02] [-1.1283036527544038e-02 7.3304770093588585e-03 5.5633856416240418e-03] [-1.3641596434609190e-02 1.8454396206925312e-02 -2.7259116954076665e-02]] Cumulative norm of all forces: 2.9708115115180733e-01 Hartree/Bohr Converting energy and forces returned by model back to Angstroms and eV... Converted energy is -4.4815401806351360e+00 eV Converted forces (eV/Angstrom): [[-8.8697811779648905e+00 4.2338638089255296e+00 2.9633276149943377e+00] [ 9.4827509396323180e+00 -4.5206539298807256e+00 -3.2131163776703495e+00] [ 6.6870630604530590e-01 -1.0391212760350799e+00 1.3654280435801531e+00] [-5.8019702478429092e-01 3.7694825685417038e-01 2.8608077170698620e-01] [-7.0147904292844199e-01 9.4896314013610550e-01 -1.4017200526111278e+00]] Cumulative norm of converted forces: 1.5276525924292956e+01 eV/Angstrom ======================================================================================================================== To pass this verification check, the Model must be able to compute the energy and/or forces for a random cluster of atoms in two different sets of units. If energies are computed, the results must match within 1e-06 eV. If forces are computed, the cumulative norm of the difference between the forces computed in one set of units and the other must be less than 1e-06 eV/Angstrom. Absolute difference between initial energy and converted energy: 4.5857806441063076e-10 eV Cumulative norm of difference in initial forces and converted forces: 1.562237338682434e-09 eV/Angstrom SUCCESS: Absolute difference in energy is below tolerance 1e-06 and cumulative norm of difference in forces on all atoms is below tolerance 1e-06. Grade: P Comment: Unit conversion successful === Verification check vc-unit-conversion end (2021-08-05 18:42:52) ===