Value of q in the alignment terms

148 views
Skip to first unread message

yaz...@gmail.com

unread,
Nov 20, 2019, 8:13:39 AM11/20/19
to CoFFEE code forum
Hi Mit

Thanks a lot for your past clarifications, they have been most helpful. I think (hope) this should be the last issue I need to clarify with you with regards to the COFFEE code.

In the alignment term dV_0p which is calculated by the corresponding python script dV_0p.py, I see that the sign and magnitude of the charges are taken into account. For example, in the 2D MoS2 example, the PA_0p term calculated with the script PotentialAlignment/dV_0p.py using charge = -1 is 0.04 eV, which is the same as if one calculates using the plot_DV0p.py in the MoS2 example folder, which has the factor "-1" in line 8.

However, I am confused by the following lines in the MoS2/README file, which tells me how the different correction terms are put together:
E_corr = E^{lat} + (-\Delta V_{q/0}) + (-q\Delta V_{0/p})
E_corr = 0.172 + 0.0 + 0.04 eV 
E_corr = 0.212 eV


I understand that this relationship is as presented in the COFFEE paper and the q\Delta V_{0/p} term is deducted from the right hand side of eq 2, therefore the negative sign in front of q. In this case, if for q = -1. the q\Delta V_{0/p} obtained using the abovementioned scripts is 0.04 eV; then shouldn't (-q\Delta V_{0/p}) term be (- 0.04) eV instead?

I am not sure if I am missing something here with regards to the signs. Could you enlighten me on the details?

Thanks a lot for the clarification.

Best wishes
Yaze




Mit Naik

unread,
Nov 21, 2019, 4:11:43 PM11/21/19
to CoFFEE code forum
Hi Yaze,

This is indeed a confusing issue. 

We needed to consistently use an extra negative sign while subtracting DFT potentials in all our examples. This has to do with the convention in DFT codes to not take into account the charge of the electrons -- the potential is negative at the position of the ions. We hence add an additional negative sign to overcome this. 

The \Delta V_{0/p} is not too large for the case of MoS2. But if you were to look at the Diamond example you can see that it would lead to a large error if this sign convention was not taken into account.

Best,
Mit

yaz...@gmail.com

unread,
Nov 21, 2019, 8:20:32 PM11/21/19
to CoFFEE code forum
Hi Mit

Thanks a lot for the reply!

So let me present my understanding of the issue so far and can you help me see if this is indeed correct:

The + (-q\Delta V_{0/p}) term in the README file, presented in the format of eq 2 will be "- (-1) (-\Delta V_{0/p})", where the first negative sign means to deduct the value from the RHS of eq 2, the (-1) is the value of q for the S vacancy, and (-\Delta V_{0/p}) is the value calculated by dV_0p.py, which takes care of the sign issue you mentioned and has the value of 0.04 eV?

I have noticed that this sign convention seems to be also used in Examples/2D\MoS2/PA_q0/plot_DVq0.py line 9. May I double check with you if the -1 on line 9 is also to address this sign convention issue? So does it mean that the value of q has not been taken into account here yet and that we need to multiply it to the value of (-\Delta V_{q/0}) obtained by plot_DVq0.py during our final calculation?

I think the answers to the above mentioned questions are all yes, but just putting them all here to double confirm.

Thanks a lot Mit.

Best wishes
Yaze

Mit Naik

unread,
Nov 28, 2019, 9:38:06 PM11/28/19
to coffee-c...@googlegroups.com
Hi Yaze,

Yes, that is correct.

Best,
Mit

yaz...@gmail.com

unread,
Nov 29, 2019, 10:00:45 AM11/29/19
to CoFFEE code forum
Hi Mit

Great!

with thanks
Yaze

Samar Fawzy

unread,
Oct 23, 2022, 11:39:25 AM10/23/22
to CoFFEE code forum
  Hi,

Thank you for the useful discussions. I sorry I am a bit confused. I have two questions.

I am using VASP,  I do take into account the change in the total number of electrons introduced by making a defect.
So does this statement still apply?
"This has to do with the convention in DFT codes to not take into account the charge of the electrons -- the potential is negative at the position of the ions"

Another question is what if I am simulating a positive defect (Oxygen vacancy for example in a metal oxide), does this mean that the -1 in the plot_DV0p.py would be replaced with a +1? Then the gaussian shape would be upside down?

Thank you,
Samar
Reply all
Reply to author
Forward
0 new messages