[Feature Request] Add compute/dump functionality to identify defects
Summary
Add compute/dump functionality to identify, count, and output point defects (see [1,2]).
Detailed Description
When simulating a primary knock-on atom (PKA) coming from a collision by a high energy particle, the resulting damage cascade is typically composed of point defects, such as vacancies and interstitials. The large simulation boxes required can lead to large data dumps that need to be post-processed in order to extract the point defects, a process that can be expensive. This problem has been addressed in [1,2] through a new compute/dump style, and the question here is whether that approach can added to LAMMPS, rather than used as an add-on.
Greetings @hammondkd! Would it be possible to incorporate your add-on directly into LAMMPS?
Further Information, Files, and Links
[1] https://doi.org/10.1016/j.cpc.2019.106862 [2] https://data.mendeley.com/datasets/p39kb4fshj/1
It would be a simple matter to include it in a package, I suppose, but that also commits people to maintain it. The creation of the sites does some things that are probably non-kosher for proper packages (e.g., creating atoms and then deleting them again without telling the user), and there are some features that don't quite work right (e.g., using a file to read the sites if they cannot also be generated by the lattice command).
There are a couple of tweaks I have added since that was published (one is required, as LAMMPS has changed since then), but I do have a "working" version. I say "working" because one of my students managed to find a situation in which it doesn't do what it's supposed to do, which is one of the reasons I haven't suggested including it in the main distribution yet.
I may work on this in the next few weeks to try to fix the problems I encountered last summer and to re-encode some of the features that may not be desirable so they work better with LAMMPS and its existing code base and feature set. Stay tuned.
If you need the new files with the slight modifications so they compile with current versions, see https://github.com/hammondkd/lammps/tree/da11c278dfb8394f00d220ea2d681a0dee81da7b (new files are in the src/FRENKEL directory). These only differ from the originals in terms of how they access LAMMPS internals due to changes in LAMMPS that have taken place since the paper was written.
Thank you @hammondkd! It seems that this could be a great addition to LAMMPS. And thanks for pointing me to your fork. Will take some time to check out the source and see if I can get the package built on my end.