[gpaw-users] The dipole-layer correction with plane wave mode
Chang Liu
chang.liu at fysik.su.se
Mon Nov 13 18:55:23 CET 2017
Dear Sir,
For a slab model, I tested 3 cases all with plane wave mode: a) pbc=(1,1,0) with no dipole layer correction b) pbc= (1,1,1) with no dipole layer correction c) pbc=(1,1,0) with dipole layer correction
I found that a) and b) give identical results and c) gives the corrected result.?
Thank you very much!
Best wishes,
Chang Liu
----------------------------------------------------------
Chang Liu
PhD student
Fysikum, Albanova, Stockholm University
S-106 91 Stockholm, Sweden
+46 767159891
http://xsolasgroup.fysik.su.se/
________________________________
From: gpaw-users-bounces at listserv.fysik.dtu.dk <gpaw-users-bounces at listserv.fysik.dtu.dk> on behalf of Georg Kastlunger via gpaw-users <gpaw-users at listserv.fysik.dtu.dk>
Sent: Monday, November 13, 2017 6:20 PM
To: gpaw-users at listserv.fysik.dtu.dk
Subject: Re: [gpaw-users] The dipole-layer correction with plane wave mode
Dear Chang,
you are right, this seems to be an inconsistency I encountered as well. There are, however, to simple ways to counter this issue:
1) You can turn the pbc in the specific direction of. This might sound counterintuitive, but it will not affect the results. The only thing that changes is the reference for the electrostatic potential, which will not alter any result.
2) You can add one line in dipole_correction.py: In the function "check_direction" after "if pbc_c[self.c]:" you can add the if statement "if isinstance(dens, np.ndarray):". Doing so the dipole correction will not check for the pbc in PW mode.
I hope that helped and let me know if I am mistaking in any way.
Best wishes,
Georg
On 11/10/2017 04:37 AM, Chang Liu via gpaw-users wrote:
Hi,
With GPAW 1.3.0, it seems that if I set slab.pbc = (1,1,1) for a slab with a 7 Å vacuum on both sides, when I try to use the dipole correction poissonsolver={'dipolelayer': 'xy'} with mode=PW(500), the program returns an error
File "/hpc2n/eb/software/MPI/GCC/6.4.0-2.28/OpenMPI/2.1.1/GPAW/1.3.0-Python-2.7.14/lib/python2.7/site-packages/gpaw/dipole_correction.py", line 54, in check_direction
ValueError: System must be non-periodic perpendicular to dipole-layer.
However, it works without problem with GPAW 0.11.0. Besides, on https://wiki.fysik.dtu.dk/gpaw/tutorials/dipole_correction/dipole.html it is stated that "In PW-mode, the potential must be periodic and in that case".
Is it a bug or intended change? Thanks.
Best wishes,
Chang Liu
----------------------------------------------------------
Chang Liu
PhD student
Fysikum, Albanova, Stockholm University
S-106 91 Stockholm, Sweden
+46 767159891
http://xsolasgroup.fysik.su.se/
_______________________________________________
gpaw-users mailing list
gpaw-users at listserv.fysik.dtu.dk<mailto:gpaw-users at listserv.fysik.dtu.dk>
https://listserv.fysik.dtu.dk/mailman/listinfo/gpaw-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listserv.fysik.dtu.dk/pipermail/gpaw-users/attachments/20171113/4acf6446/attachment.html>
More information about the gpaw-users
mailing list