Re: [Wien] berryphase
Dear Shahrbano, Do you think that the intermediate is necessary? By transition I meant transition between lambda0 as the centrosymmetric phase and lambda1 as the noncentrosymmetic phase. You do not have to calculate intermediate structures, but Eq. (2) in Phys. Rev. B, 1993, 47, 1651-1654 implies that they exist. Thank you Oleg ___ Wien mailing list Wien@zeus.theochem.tuwien.ac.at http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien SEARCH the MAILING-LIST at: http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
Re: [Wien] berryphase
Dear Shahrbano, ... Although we could reproduce the SP of the sample, P_s= P_z(lambda1)- P_z(lambda0) = 0.312113863793- 1.52399256575e-11 = 0.31211386360 C/m^2 which is very close to the readme file (but not exactly the same as it P_s= P_z(lambda1)- P_z(lambda0)= 0.31140111708550217-1.4486341471349937e-11= 0.3114011170710158 C/m^2), there are some things which are not clear for us. This difference is not material. Tutorials were done with an earlier version of Wien2k and a default SCF convergence. Possibly, a tighter convergence will lead to the same result in both cases. Why would not define the P_s just as P_z(lambda1)? In general, P(lambda0) = 0 may not always be true due to pi rapping. So it will be a very slippery assumption. This is why I would insist on doing both calculations (lambda0, lambda1) even though you might expect zero. We examined these two structures by calculating the exerted forces on the atoms of them to check whether they are in their relaxed positions or not. We found that the displaced atoms in lambda1.strcut were under tension--:FOR002 and :FGL002 are not zero. Are there total or partial forces? What are the values? In the way as discussed in tutorial1, the SP certainly will depend on the displacements. If we increase the amount of displacement, then we will obtain larger SP. In any case, you are need a well converged atomic positions. In our calculations we try to optimize structure to better than 2 mRy/Bohr. (Sheikh can probably comment more.) So, unlike Boron effective charge calculations it appears that the SP calculations cannot give a unique result? Indeed, the SP should be unique. There should be only one well converged structure. Of course, it will be sensitive to the choice of XC functional. 3) And, why we should not fully initialize the centrosymmetric one? We do not want Wien2k to realize its higher symmetry. Therefore, the initialization is done for low-symmetry lambda1 case only. Both structures should have identical symmetry operations in order to ensure consistency and comparability of the results. In summary, according to the definition of SP, a transient from a centrosymmetry to a noncentrosymmetry seems to be necessary. But, here both of the phases are tetragonal, while in the paper one of them is considered to be cubic. Strictly speaking, you are right. We would need a cubic structure for lambda0 and you can try it. What you will find in this case that it does not matter for P(lambda0). Where is the transition in this tutorial? You can make a transition by choosing an intermediate structure (say lambda05). I am not aware of unique way to define the intermediate state: we know for sure only lambda0 and lambda1. But you can imagine lambda1 as a distorted case of lambda0. For lambda05 you need half of the distortions. Of course, NO optimization of atomic positions should be performed for lambda05. Otherwise you will end up with lambda1 again. What will be the criterion to move up the atoms? Zero force and stress for lambda1. What is the difference between SP and total polarization? It is the essence of the modern polarization theory that the total polarization does not make sense. Only a difference matters, i.e. SP. Would you discuss how we can find the centrosymmetric and noncentrosymmetric ones for any cases? This part I am not sure, especially for GaN. The thinking should start with analysis of measurable quantities/effects, which you would like to model. Thank you Oleg ___ Wien mailing list Wien@zeus.theochem.tuwien.ac.at http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien SEARCH the MAILING-LIST at: http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
Re: [Wien] berryphase
Hello Shahrbano, I also agree with Dr. Rubel that this fraction of discrepancy that you are getting is probably due to the fact we made this tutorial on Wien2k version 11.0. Regarding the forces for optimizing the structure, I always try to optimize my structure to a much lower value (0.2 mRy/bohr) of forces. However, this doesn't make much of a difference to the final result though. Compared to the optimized structure with default force tolerance (2 mRy/bohr), the atomic positions varies only in fourth or fifth decimal places which might change your polarization by 0.1 to 1 % (like you are getting). This is negligible if you are consistent when comparing properties between two calculations. Either use 2 mRy/bohr for both the cases or 0.2 mRy/bohr. Also you can try to understand more about modern theory of polarization from here http://www.physics.rutgers.edu/~dhv/pubs/local_preprint/dv_fchap.pdf Hope that helps. Sheikh On Thu, Dec 5, 2013 at 11:56 AM, Oleg Rubel oru...@lakeheadu.ca wrote: Dear Shahrbano, ... Although we could reproduce the SP of the sample, P_s= P_z(lambda1)- P_z(lambda0) = 0.312113863793- 1.52399256575e-11 = 0.31211386360 C/m^2 which is very close to the readme file (but not exactly the same as it P_s= P_z(lambda1)- P_z(lambda0)= 0.31140111708550217-1.4486341471349937e-11= 0.3114011170710158 C/m^2), there are some things which are not clear for us. This difference is not material. Tutorials were done with an earlier version of Wien2k and a default SCF convergence. Possibly, a tighter convergence will lead to the same result in both cases. Why would not define the P_s just as P_z(lambda1)? In general, P(lambda0) = 0 may not always be true due to pi rapping. So it will be a very slippery assumption. This is why I would insist on doing both calculations (lambda0, lambda1) even though you might expect zero. We examined these two structures by calculating the exerted forces on the atoms of them to check whether they are in their relaxed positions or not. We found that the displaced atoms in lambda1.strcut were under tension--:FOR002 and :FGL002 are not zero. Are there total or partial forces? What are the values? In the way as discussed in tutorial1, the SP certainly will depend on the displacements. If we increase the amount of displacement, then we will obtain larger SP. In any case, you are need a well converged atomic positions. In our calculations we try to optimize structure to better than 2 mRy/Bohr. (Sheikh can probably comment more.) So, unlike Boron effective charge calculations it appears that the SP calculations cannot give a unique result? Indeed, the SP should be unique. There should be only one well converged structure. Of course, it will be sensitive to the choice of XC functional. 3) And, why we should not fully initialize the centrosymmetric one? We do not want Wien2k to realize its higher symmetry. Therefore, the initialization is done for low-symmetry lambda1 case only. Both structures should have identical symmetry operations in order to ensure consistency and comparability of the results. In summary, according to the definition of SP, a transient from a centrosymmetry to a noncentrosymmetry seems to be necessary. But, here both of the phases are tetragonal, while in the paper one of them is considered to be cubic. Strictly speaking, you are right. We would need a cubic structure for lambda0 and you can try it. What you will find in this case that it does not matter for P(lambda0). Where is the transition in this tutorial? You can make a transition by choosing an intermediate structure (say lambda05). I am not aware of unique way to define the intermediate state: we know for sure only lambda0 and lambda1. But you can imagine lambda1 as a distorted case of lambda0. For lambda05 you need half of the distortions. Of course, NO optimization of atomic positions should be performed for lambda05. Otherwise you will end up with lambda1 again. What will be the criterion to move up the atoms? Zero force and stress for lambda1. What is the difference between SP and total polarization? It is the essence of the modern polarization theory that the total polarization does not make sense. Only a difference matters, i.e. SP. Would you discuss how we can find the centrosymmetric and noncentrosymmetric ones for any cases? This part I am not sure, especially for GaN. The thinking should start with analysis of measurable quantities/effects, which you would like to model. Thank you Oleg ___ Wien mailing list Wien@zeus.theochem.tuwien.ac.at http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien SEARCH the MAILING-LIST at: http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html ___ Wien mailing list Wien@zeus.theochem.tuwien.ac.at
Re: [Wien] berryphase
Dear Shahrbano ... But, we still do not know what is the role of * in tmp=$(grep lapw1 *-c $SEEDNAME.dayfile). As far as I know –c flag is necessary when inversion symmetry is break down and complex calculations are needed to be performed by the WIEN2k code. I am not aware about *-c flag. The star was need to account for an arbitrary number of spaces proceeding '-c' flag. Please, check 'grep' manual for details. The newer version of W2W uses even more robust check for '-c' flag. We are also not sure whether it is referred to the relaxed and unrelaxed structures. Thus, we tried to check it out. To do this, we selected the unrelaxed structure for lambda1and the relaxed one for lambda0. Our result is as follows: 3.16596720935 - 3.17586420101 = -0.00989699166 But, this result is far from reported value in the literature, i.e., SP was reported to be -0.02 [PRB86, 081302(R) and PRB56, R10024]. A quick glance at these references shows that they are discussing zinc blende structure as a zero-polarization reference. So you probably need to make a zinc blende GaN is the same fashion as wurtzite structure. Fig. 12 in [Physics Reports, Volume 428, Issue 1, May 2006, Pages 1-52] will be a good starting point, but still not exactly what you need. At the end both structures should have identical symmetry and the same # of atoms. Does this mean that one has to try by changing the displacement reproduce the experimental value? In this case our result depends on the displacement. Can it be (in this case) an ab initio prediction? No... please disregard this for now. Yes, NUMPY 1.4.1 works as fine as NUMPY 1.6.2. Good to know. Thank you Oleg ___ Wien mailing list Wien@zeus.theochem.tuwien.ac.at http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien SEARCH the MAILING-LIST at: http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
Re: [Wien] berryphase
Dear Shahrbano, it's good to hear that everything worked with the fresh install. I am also interested to trace the origin of your previous problems, but I cannot reproduce the error. If you still have an access to the previous installation and can reproduce both correct and incorrect results, try to switch packages one-by-one, e.g. replace only BerryPI and see whether it makes a difference. Then do the same with W2W, WIEN2K. This way you can narrow down the reason. Would you give me some clue to reach the goal sooner? As far as I know, there is an internal relaxation in GaN wurtzite, which leads to slightly different Ga-N bond lengths (in c-direction and off-axis). Maybe the spontaneous polarization (Ps) is referred to a difference in polarization between two structures with relaxed and unrelaxed internal degrees of freedom? But I do not know for sure. How big is the value of Ps reported in the literature? By looking at the change of polarization when doing the effective charge calculations, you can guess how large the displacement should be to produce Ps. In any case, I would think what is the *measurable* quantity related to change of polarization in GaN and try to calculate that. PS: We detected that init.sh ha a bug. If the version of the installed numpy is 1.6.2, the init.sh works fine. But, if the version is different depending on the linux version, e.g., numpy 1.4.1, then init.sh script tries to install numpy 1.6.2 on .local directory. This is not necessary, as already bumpy 1.4.1 is installed. Although the installation on .local directory is successful by init.sh, but init.sh cannot uses it, because it is not installed in the default path. So, for such a case, we changed 1.6.2 to 1.4.1 in init.sh to prevent its stop in changing the .bashrc automatically. We just thought that you maybe in next version would like to fix this small bug. We suspected that BerryPI may not be compatible with earlier versions of numpy (before 1.6.2), but I don't think we actually tested it against numpy 1.4.1. The is the reason why init.sh is so picky. If you confirm that it works for you with numpy 1.4.1, we can loosen this requirement. Thank you Oleg ___ Wien mailing list Wien@zeus.theochem.tuwien.ac.at http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien SEARCH the MAILING-LIST at: http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
Re: [Wien] berryphase
Hello Shahrbano, If check the refereed post you find the following about the compatibility issue of WIEN2k v12 or later with WIEN2WANNIER v0.96 or older We came across a minor compatibility issue between WIEN2WANNIER and a newer version Wien2k (v12 and above). Apparently, the complex calculation is not resolved properly by w2w. The following line in 'w2w' script searches for a pattern lapw1 -c in a dayfile tmp=$(grep lapw1 -c $SEEDNAME.dayfile) However, the number of spaces between 'lapw1' and '-c' has changes in wien2k while going from v11 to v12 and higher. As a result, the complex calculation is not identified properly. I suggest to change the line to the following (note the space between 1 and *) tmp=$(grep lapw1 *-c $SEEDNAME.dayfile) This code is compatible with any number of spaces. The modification is absolutely critical for proper calculation of polarization with BerryPi. = That was the compatibility issue taken from http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/msg09119.html Another source of error could be from the older version of BerryPI which was using a different phase wrapping method. That was causing some issues to bring the phases between 0 to 2*pi or -pi to +pi range when some of the phases were close to 0 (may be positive or negative). The method was completely ignoring those smaller values instead of unwarpping all the phases to same range. As a result, you would have phase values like 1.999*pi 1.6*pi 1.9994*pi *-0.0001*pi* instead of 1.999*pi 1.6*pi 1.9994*pi *1.*pi.* This would have messed up your average phase value and polarization. Also regarding the Numpy version, We actually haven't tested BerryPI any Numpy older than v1.6.2. This is why the init.sh tries to ignore the older versions. Hope this will help. Sheikh On Wed, Nov 27, 2013 at 2:14 PM, Shahrbano Raheme sbh6...@yahoo.com wrote: Dear Prof. Rubel and Prof. Sheikh, 1) Take the structure files enclosed (I assume they are not different from yours). I used your stature file and found that it is identical to my structure. Please, make sure that you have the latest version of WIEN2WANNIER (see the post http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/msg09119.htmlhttps://mail.google.com/mail/%22 ). My computed effective charge seems to almost the same as computed by Dr. Rubel. I think you are using older versions of either BerryPI or Wien2Wannier or both. Please use the latest version of BerryPI (v1.0) https://github.com/spichardo/BerryPIhttps://github.com/spichardo/BerryPI%22%20%5Ct%20%22_blank and Wien2Wannier (v0.97) http://www.wien2k.at/reg_user/unsupported/wien2wannier/http://www.wien2k.at/reg_user/unsupported/wien2wannier/%22%20%5Ct%20%22_blank .The older version of BerryPI (v0.1) had some problem in wrapping of phases which has been fixed in version 1.0. Also, the older versions of Wien2wannier was having an issue in identifying the complex calculation (see the post http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/msg09119.htmlhttp://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/msg09119.html%22%20%5Ct%20%22_blank ) I installed the latest version of BerriPI, WIEN2WANNIER, WANNIER90, NUMPHY, and could reproduce the results of Prof. Rubel in agreement with reported values in literature. But, we still do not know what was the source of problem of the BerryPI or WIEN2WANNIER old version which resulted in an unsatisfactory result. We are interested in realizing the bug(s) of the old version(s). 2) create directories 'lambda1' and 'lambda2'. In both cases I displace the Ga atom by +0.01 and -0.01 along z-axis. There is nothing specific about the choice of displacements. In fact 0.005 should work too. I encourage you to test the convergence and plot Z as a function of displacement. I do not recommend to go for displacements larger than 0.01 I did it, and the results which nicely confirm your prediction, do not depend on the Z. Now I am working on your following comments: In order to address the spontaneous polarization, we need two cases: (a) the initial reference structure and (b) your relaxed structure. The spontaneous polarization is the difference between them. Please, look in the literature what is used as a reference structure. The choice of structure (a) for GaN is not obvious to me. Once you determine that, I can help you to move on. Would you give me some clue to reach the goal sooner? PS: We detected that init.sh ha a bug. If the version of the installed numpy is 1.6.2, the init.sh works fine. But, if the version is different depending on the linux version, e.g., numpy 1.4.1, then init.sh script tries to install numpy 1.6.2 on .local directory. This is not necessary, as already bumpy 1.4.1 is installed. Although the installation on .local directory is