Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Glue #1

Merged
merged 22 commits into from
Mar 20, 2021
Merged

Glue #1

merged 22 commits into from
Mar 20, 2021

Conversation

eschmidt42
Copy link
Owner

Glue

Main Change

Note: The "glue" is a scalar pre-computed for each atom and is a required quantity to compute energies and forces. So simply iterating over atom pairs to compute energy and force contributions is insufficient, without having pre-computed the glue values. Hence, in a few places, the MD code needed to be adjusted to allow for this extra step.

Minor Changes

  • added a notebook fs.ipynb to document the usage of the added interaction type
  • modified accelerations in src/forces.jl: to enable glue calculation before pair contributions to the forces
  • modified potential_energy in src/analysis.jl to enable the use of a potential_energy function for the glue interaction type
  • modified src/loggers.jl by adding new loggers which proved useful for debugging: GlueDensityLogger, VelocityLogger, ForceLogger
  • modified Simulation in src/types.jl by adding glue_densities as an array where per-atom glue values are stored for the glue potential
  • added test/glue.jl as a new test to run to verify the correctness of the predicitons of potential energies, forces using reference values from the Finnis and Sinclair paper linked above as well as testing the behavior of the glue scalar values.

Note: A peculiarity of the Finnis-Sinclair potential is that the potential energy of an atom depends on the scalar glue value of that atom by taking the square root. Hence, cases in which the glue value, for whatever reason, becomes negative, will crash a simulation, since it is not defined in the model how to handle complex potential energy values.

To dos

There are probably more things to be done. The immediately relevant steps would be to:

  • add shifted force / potential version of the glue potential
  • add parallelism for the glue computation
  • add other types of glue potentials, like the Embedded Atom method and
  • verify the correctness of the implementation for systems with more than one type of element (the implemented Finnis-Sinclair paper only dealt with single element systems).

…on of glue forces using the general_inters loop
…ivates with FordwardDiff.derivate to re-use the non-derivative forms also used to successfully test ground state energies
@eschmidt42 eschmidt42 merged commit b472fd9 into master Mar 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant