Closed lauramurgatroyd closed 11 months ago
Currently we are attempting, it seems incorrectly, to set the mass of the muon for a geometry optimisation calculation. I believe that the mass isn't actually used in the geometry optimisation so can we just remove this from being set altogether here?
I notice that the mass and the charge are both not set for a dftb spinpol calculation. Is this the correct behaviour?
The incorrect SCC cycles setting has been resolved in the above PR which has been merged.
To summarise where we are at with this:
The mass is not needed for any of the calculations we run at the moment, but we may need it in future.
The structure of setting it like this:
Masses = {
Mass = {
Atoms = -1
MassPerAtom [amu] = 0.1134289259
}
}
is correct, but the Driver section is not the correct section for it to be placed in. The section it should go in will depend on which calculation we want to do that will make use of the mass.
We will not be using DFTB+ in the near future. No need to dela with this now.
Note: this is not an issue with the recent refactoring into ReadWrite classes, and is a completely separate issue to https://github.com/muon-spectroscopy-computational-project/pymuon-suite/issues/12. This seems to be an issue that existed before then.
When creating a DFTB+ input file, pymuonsuite sets the mass of the muon and the max number of scc cycles within the 'driver' input section. For example:
However, when you run this with DFTB+, you get the following errors:
DFTB+ can't read the Masses, or the MaxSccIterations when they are defined in this way. This means that the DFTB+ runs always default to the standard number of scc iterations (100) and also seems that they don't make use of the muon mass.
Looking at the DFTB+ manual: https://dftbplus.org/fileadmin/DFTBPLUS/public/dftbplus/latest/manual.pdf Page 16 defines the Driver section, and pg 26 defines the Hamiltonian section.
Moving the MaxSccIterations setting into the Hamiltonian section fixes this problem. We need to update this here: https://github.com/muon-spectroscopy-computational-project/pymuon-suite/blob/1b461892d2d4fd1330d2854e97e952c8603880aa/pymuonsuite/io/dftb.py#L287
We also need to work out how to fix setting the muon mass