orex / supercell

The program allows you to create regular structure supercell from cif file with partial occupancy and/or substitutions.
GNU General Public License v2.0
96 stars 56 forks source link

Question about Coulomb Energy Calculation #27

Closed Gitdowski closed 4 years ago

Gitdowski commented 4 years ago

First, thank you for the effort! For me the supercell code is really helpful, it does exactly what it should. However, I came along a question concerning the Coulomb Energy Calculation.

In my case, I have a big structure that contains: i) Several atomic sites with different occupancy factors for the same atomic species A. These sites are either occupied or empty. ii) Some other sites that are shared by two species B and C. The sites are always occupied with one or the other.

All of that cannot be done in a single run due to an overflow of possibilities. I went step by step and generated some structures by first occupying only a part of the species while fixing the rest. Finally, I arrived at some reasonable starting structures for further electronic structure calculations.

For the analysis of the material I want to see whether some structural changes can be correlated to the disorder of the B/C site. I thought I could get some first hints from a purely electrostatic point of view and looked at the Coulomb Energy. Therefore, I wanted to clarify how the Coulomb Energy is calculated if some partially occupied sites are kept fix via the -p "A:fixed" switch.

To be more concrete, let's look at the following three examples:

1.) I attributed an oxidation state of +2 to species A. There are 20 A sites in the cell which are only occupied a probability of 30%. Will the Coulomb calculation then use an average oxidation state of +2*0.3 = +0.6 for all 20 sites if -p "A:fixed" is used?

2.) For the mixed B/C sites i attributed an oxidation state of -1 to B and -2 to C. If those sites would be occupied with 25% of B and 75% of C, would the Coulomb Energy calculation use (-1*0.25) + (-2*0.75) = -1.75 for all these sites if I would fix them?

3.) Hypothetical case, similar to the previous point: If there were sites that would be occupied by 50% of a species with oxidation state +2 and with 50% of a species with oxidation state -2, would the Coulomb Energy calculation take a oxidation state of zero if those are fixed during program execution?

I hope you can clarify this issue to me.

Best regards, Marcel

orex commented 4 years ago

Dear Marcel,

Thank you very much for such detailed question. I can confirm, that the charges in all positions of fixed group are the same and they are equal to (sorry for ugly formula) \sum_{k} O_k * C_k, where sum goes over all atoms, which belong to the fixed group. C_k - charge, O_k - occupation after correction. (https://github.com/orex/supercell/blob/master/src/core/d2o_main_class.cpp#L492).

Therefore answers to your question are: 1) It is not like this totally. First of all, occupancy correction algorithm will be applied. Please see Stage 3 in the supercell paper https://jcheminf.biomedcentral.com/articles/10.1186/s13321-016-0129-3 for details. Therefore with the example the charge will be 0.6, but in case of, for example, 32% occupation the charge will be also exactly 0.6 due to the correction first. If you switch on charge balancing, the result can be significantly different. 2) Yes, but correction. 3) Yes, but correction.

Feel free to ask any other questions. If the result is different, when I described, please treat it like a bug and don't hesitate to submit a report.

Sincerely yours, Kirill.

Gitdowski commented 4 years ago

Dear Kirill,

Thank you for the fast answer!

Good that you mention the occupancy correction, that makes perfect sense. Until now I didn't run into strange situations. Usually, I first tweak the experimentally obtained occupancy factors to give nice integer number of atoms.

For now, all questions are solved. Thank you again!

Best regards, Marcel