| SeqQuest Home |
Input Manual |
Cluster Tutorial |
Slab Tutorial |
NEB Tutorial |
|---|
Important: While a calculation with this input file will run to completion, this input file is flawed and would not be a viable production calculation because of an incorrect use of the Brillouin Zone sampling, which will be discussed in the next example.
The "dimension" statement is the first required data in the input. We are doing a 3-dimensional bulk problem. If we were doing a molecular problem, we would enter a "0", or if we were doing a surface problem using a 2-dimensional slab, we would have entered a "2" here.
The next required input is "primitive lattice" - supercell vectors. Here, we define a unit cell that is hexagonal in the x-y plane with a lattice parameter a=6.13 bohr (=3.24 A), and an orthogonal repeat vector in the z-direction with c=6.13*c/a.
The next required input is "grid dimensions". The code evaluates many of its integrals on a regular space (fft) grid. This regular grid is defined by taking the primitive lattice vectors, and dividing them into grid intervals. Here we use a 24x24 grid in the hexagonal plane, and put 36 grid intervals along the z-direction. The more grid intervals, the more accurately the integrals are evaluated, but, also, the more expensive the calculation. A general rule of thumb: you want spacing between points of 0.30-0.40 bohr for most systems, and 0.20-0.30 for finer accuracy in systems containing "hard" atoms. Hard atoms include late first row atoms like N, O, F, or late 3d atoms. We have nitrogen in our system, and this example has a spacing of slightly less than 0.3 bohr. This can be tuned to the problem. If I wanted to compute an energy, a coarser grid might suffice. If I wished to evaluate a force or stress, a finer grid might be required. For a hexagonal system, it is a good idea to use a grid dimension in the plane that is divisible by three, so that the various high-symmetry points in the surface (i.e.), atop, hcp and fcc hollows) are at the same position with respect to the grid.
The next required input is number of "atom types". Here, we have only two (Ga and N), and the code requires input to specify the "atom file" to be used to obtain the atomic potential and basis information for each atom type. Here, we will read from files "n.atm" and "ga.atm" for nitrogen and gallium, respectively.
Next, the input requires the number of atoms in the unit cell (4), and then a list of each "atom, type, and position". The arguments for an atom input are the atom index (the order of the atom in the list, #1-#4 here), which type (in the order in which the types were listed above), and the positions of the atoms in Cartesian coordinates (in bohr). Atom 1 is of the first atom type (i.e., from "n.atm"), and is at (3.539,0.0,0.0257), and then next atom is the second atom type (i.e., from "ga.atm"), etc.
The final required input in the setup section (for a periodic calculation) is definition of the Brillouin Zone sampling. For molecular calculations this is unnecessary - one has only real integrals, or the "gamma-point", to worry about. In a (periodic) bulk calculation, the Schroedinger equation generally needs to be solved for a sampling of points in reciprocal space. It is possible to input the k-point sampling as an explicit list of k-vectors and their weights (using a different keyword/data sequence than shown here), but this example takes advantage of an optional feature to automatically generate a simple k-point sample. The "kgrid " keyword tells the code to generate a regular mesh in reciprocal space, and here we specify a 4x4x2 grid in the BZ. A k-sample with just the gamma-point would be specified as 0x0x0. The kgrid command generates this grid, and offsets this grid from the reciprocal space origin (i.e., the gamma point) by (1/2,1/2,1/2) in the reciprocal space mesh, i.e., the body-centered position.
The final, required statement in the setup phase section is the "end setup phase" line.
do setup do iters no force no relax setup data title GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 dimension of system (0=cluster ... 3=bulk) 3 primitive lattice vectors 5.308735725 -3.0650 0.000000000 0.000000000 6.1300 0.000000000 0.000000000 0.0000 9.996279726 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 3.539157150 0.0000 0.025788046 2 2 1.769578575 3.0650 1.268818179 3 1 1.769578575 3.0650 5.023927909 4 2 3.539157150 0.0000 6.266958042 kgrid 4 4 2 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
In addition, note that we have expanded our input notes on this system by changing the "title " keyword near the beginning of the file to "title2", and we have added a second line of notes. This method can be used to have up to 9 lines of notes.
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: hex cell needs special hex Brillouin Zone sample: "kgrid2" dimension of system (0=cluster ... 3=bulk) 3 primitive lattice vectors 5.308735725 -3.0650 0.000000000 0.000000000 6.1300 0.000000000 0.000000000 0.0000 9.996279726 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 3.539157150 0.0000 0.025788046 2 2 1.769578575 3.0650 1.268818179 3 1 1.769578575 3.0650 5.023927909 4 2 3.539157150 0.0000 6.266958042 kgrid2 4 4 2 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
Spin polarization is not appropriate for this GaN example, but in the general case, to invoke spin, one specifies a spin-polarized functional. All current DFT functionals are spin-capable. The valid choices include: LDA-SP, CAPZSP, PBE-SP, PW91SP, etc. If one specifies a spin polarized functional, additional input is *required* immediately following the functional. The keyword "spin polarization" with the net spin polarization must be given. The spin polarization is in units of excess electrons of majority spin, must be non-negative (it can be zero), but need not be an integer. For example, an LDA hydrogen atom (or a molecule with a single dangling bond)
functional LDA-SP spin polarization 1.0000will have a polarization of exactly one, i.e., one more electron of majority spin than minority spin.
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: change functional to PBE flavor of GGA functional PBE dimension of system (0=cluster ... 3=bulk) 3 primitive lattice vectors 5.308735725 -3.0650 0.000000000 0.000000000 6.1300 0.000000000 0.000000000 0.0000 9.996279726 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 3.539157150 0.0000 0.025788046 2 2 1.769578575 3.0650 1.268818179 3 1 1.769578575 3.0650 5.023927909 4 2 3.539157150 0.0000 6.266958042 kgrid2 4 4 2 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
2, 3, 4, 6 = an N-fold rotation -2,-3,-4,-6 = an N-fold rotation followed by inversion -1 = an inversionNote that a reflection is equivalent to "-2", or a two-fold rotation plus inversion. The definitions in our example:
3 0.0 0.0 1.0 0.0 0.0 0.0 -2 0.0 1.0 0.0 0.0 0.0 0.0specify a three-fold rotation around (0,0,1), i.e., the z-axis, and a rotation around the y-axis plus inversion, which is equivalent to a reflection through the x-z plane. The code will internally take these symmetry elements and generate a full symmetry group. Further examples of symmetry construction can be found on another page.
The code takes advantage of symmetry in two ways. First, it eliminates redundant symmetry-equivalent k-points in the Brillouin Zone sample, and reduces the sample to be in the irreducible BZ. This makes the size of the calculation smaller, and therefore faster. Second, if the calculation does forces and a relaxation, it will symmetrize the force calculation (in a grid-based calculation, numerical noise may cause the calculation to artificially break symmetry) and conserves symmetry in geometry updates during an energy minimization calculation/relaxation.
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: take advantage of trigonal symmetry about 001 axis (symops). dimension of system (0=cluster ... 3=bulk) 3 primitive lattice vectors 5.308735725 -3.0650 0.000000000 0.000000000 6.1300 0.000000000 0.000000000 0.0000 9.996279726 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 3.539157150 0.0000 0.025788046 2 2 1.769578575 3.0650 1.268818179 3 1 1.769578575 3.0650 5.023927909 4 2 3.539157150 0.0000 6.266958042 kgrid2 4 4 2 symops 2 definitions sym ops (3-fold rotate around 001, reflection plane normal 010) 3 0.0 0.0 1.0 0.0 0.0 0.0 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: insert global scaling factor (a=6.13), and scale coordinates dimension of system (0=cluster ... 3=bulk) 3 scale 6.13 primitive lattice vectors 0.86602540378 -0.5000 0.000000000 0.00000000000 1.0000 0.000000000 0.00000000000 0.0000 1.630714474 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.57735026918 0.0000 0.004206859 2 2 0.28867513459 0.5000 0.206985021 3 1 0.28867513459 0.5000 0.819564096 4 2 0.57735026918 0.0000 1.022342258 kgrid2 4 4 2 symops 2 definitions sym ops (3-fold rotate around 001, reflection plane normal 010) 3 0.0 0.0 1.0 0.0 0.0 0.0 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: insert global z-scaling factor (c/a), and scale z-coordinates dimension of system (0=cluster ... 3=bulk) 3 scale 6.13 scalez 1.630714474 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.57735026918 0.0000 0.002579764 2 2 0.28867513459 0.5000 0.126929039 3 1 0.28867513459 0.5000 0.502579764 4 2 0.57735026918 0.0000 0.626929039 kgrid2 4 4 2 symops 2 definitions sym ops (3-fold rotate around 001, reflection plane normal 010) 3 0.0 0.0 1.0 0.0 0.0 0.0 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: translate atoms to make additional symmetry more apparent dimension of system (0=cluster ... 3=bulk) 3 scale 6.13 scalez 1.630714474 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.57735026918 0.0000 0.000000000 2 1 0.28867513459 0.5000 0.500000000 3 2 0.28867513459 0.5000 0.124349275 4 2 0.57735026918 0.0000 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (3-fold rotate around 001, reflection plane normal 010) 3 0.0 0.0 1.0 0.0 0.0 0.0 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: incorporate non-symmorphic (translation) symmetry: N1->2 Ga3->4 dimension of system (0=cluster ... 3=bulk) 3 scale 6.13 scalez 1.630714474 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.57735026918 0.0000 0.000000000 2 1 0.28867513459 0.5000 0.500000000 3 2 0.28867513459 0.5000 0.124349275 4 2 0.57735026918 0.0000 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift, reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data convergence criterion 0.000500 end run phase dataReturn to Top
do setup do iters no force no relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: add various interesting scf options dimension of system (0=cluster ... 3=bulk) 3 scale 6.13 scalez 1.630714474 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.57735026918 0.0000 0.000000000 2 1 0.28867513459 0.5000 0.500000000 3 2 0.28867513459 0.5000 0.124349275 4 2 0.57735026918 0.0000 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift,reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data iterations - maximum number of scf iterations allowed 35 temperature for occupations (Ry) 0.0030 blend ratio - initial blend of input/output potential in scf 0.30 convergence criterion 0.000500 end run phase dataReturn to Top
do setup do iters do force do relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: set commands to do a full relaxation dimension of system (0=cluster ... 3=bulk) 3 scale 6.13 scalez 1.630714474 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.57735026918 0.0000 0.000000000 2 1 0.28867513459 0.5000 0.500000000 3 2 0.28867513459 0.5000 0.124349275 4 2 0.57735026918 0.0000 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift,reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data iterations 35 temperature for occupations (Ry) 0.0030 blend ratio 0.30 convergence criterion 0.000500 end run phase dataReturn to Top
I choose to relax tha galliums atoms rather than the nitrogen atoms for numerical reasons. Nitrogen is the "harder" atom, and therefore the numerical evaluations of the forces on the nitrogen atom will be less accurate. The code evaluates integrals on a regular space grid and the spatially more rapidly varying orbitals on nitrogen lead to more inaccurate grid integrals for the orbitals on the nitrogen atom. We therefore choose to fix the nitrogen and allow the atoms whose forces are more accurately evaluated to relax.
do setup do iters do force do relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: modify relaxation optimization parameters dimension of system (0=cluster ... 3=bulk) 3 scale 6.13 scalez 1.630714474 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.57735026918 0.0000 0.000000000 2 1 0.28867513459 0.5000 0.500000000 3 2 0.28867513459 0.5000 0.124349275 4 2 0.57735026918 0.0000 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift,reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data iterations 35 temperature for occupations (Ry) 0.0030 blend ratio 0.30 convergence criterion 0.000500 geometry relaxation gsteps - restrict the number of geometries to relax 5 gconv - max force convergence criterion 0.0010 only relax last - N are fixed by symmetries, move only Ga -2 end geometry relaxation end run phase dataReturn to Top
do setup do iters do force do relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: transform coordinates into lattice units dimension of system (0=cluster ... 3=bulk) 3 coordinates LATTICE scale 6.13 scalez 1.630714474 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.66666666667 0.33333333333 0.000000000 2 1 0.33333333333 0.66666666667 0.500000000 3 2 0.33333333333 0.66666666667 0.124349275 4 2 0.66666666667 0.33333333333 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift,reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data iterations 35 temperature for occupations (Ry) 0.0030 blend ratio 0.30 convergence criterion 0.000500 geometry relaxation gsteps - restrict the number of geometries to relax 5 gconv - max force convergence criterion 0.0010 only relax last - N are fixed by symmetries, move only Ga -2 end geometry relaxation end run phase dataReturn to Top
Notes: The "strain" keyword can only be invoked if the atomic coordinates are specified in LATTICE units. The strain matrix must be symmetric (of course), and is specified without the identity, i.e., the code interally adds the identity matrix to the specified input. The net result of the example given below is a +0.2% strain along the z-direction.
do setup do iters do force do relax setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: strain dimension of system (0=cluster ... 3=bulk) 3 coordinates LATTICE scale 6.13 scalez 1.630714474 strain 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 1.00 strfac 0.002 primitive lattice vectors 0.86602540378 -0.5000 0.0000 0.00000000000 1.0000 0.0000 0.00000000000 0.0000 1.0000 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.66666666667 0.33333333333 0.000000000 2 1 0.33333333333 0.66666666667 0.500000000 3 2 0.33333333333 0.66666666667 0.124349275 4 2 0.66666666667 0.33333333333 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift,reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data iterations 35 temperature for occupations (Ry) 0.0030 blend ratio 0.30 convergence criterion 0.000500 geometry relaxation gsteps - restrict the number of geometries to relax 5 gconv - max force convergence criterion 0.0010 only relax last - N are fixed by symmetries, move only Ga -2 end geometry relaxation end run phase dataReturn to Top
To invoke cell optimization, add "do cell" to the instructions at the beginning of the input. The optional cell section , beginning with "cell optimization" and ending with "end cell", allows some control over cell optimization. This is illustrated here by setting the unit cell convergence threshold (uc_conv) to a maximum stress of 0.01 GPa. To apply an external pressure, use the keyword "pressure" and give the desired pressure in units of GPa.
Important: Cell optimization requires:
do setup do iters do force do relax do cell setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: turn on 3D cell optimization dimension of system (0=cluster ... 3=bulk) 3 coordinates LATTICE primitive lattice vectors 5.308735725 -3.0650 0.000000000 0.000000000 6.1300 0.000000000 0.000000000 0.0000 9.996279726 grid dimensions 24 24 36 atom types 2 atom file n.atm atom file ga.atm number of atoms in unit cell 4 atom, type, position vector 1 1 0.66666666667 0.33333333333 0.000000000 2 1 0.33333333333 0.66666666667 0.500000000 3 2 0.33333333333 0.66666666667 0.124349275 4 2 0.66666666667 0.33333333333 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift,reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data iterations 35 temperature for occupations (Ry) 0.0030 blend ratio 0.30 convergence criterion 0.000500 geometry relaxation gsteps - restrict the number of geometries to relax 5 gconv - max force convergence criterion 0.0010 only relax last - N are fixed by symmetries, move only Ga -2 end geometry relaxation cell optimization uc_conv - stress convergence (in GPa, default=0.002 ) 0.01 pressure - external pressure (GPa for 3D) 10.0 end cell end run phase dataReturn to Top
do setup do iters do force do relax do cell setup data title2 GaN bulk wurzite: a=6.13 bohr, c/a=1.630714474, GaN(Z)=3.755109729 Example: aliasing atom types dimension of system (0=cluster ... 3=bulk) 3 coordinates LATTICE primitive lattice vectors 5.308735725 -3.0650 0.000000000 0.000000000 6.1300 0.000000000 0.000000000 0.0000 9.996279726 grid dimensions 24 24 36 atom types 2 atom file N = n.atm atom file /library/lda/Ga.atm number of atoms in unit cell 4 atom, type, position vector 1 N 0.66666666667 0.33333333333 0.000000000 2 N 0.33333333333 0.66666666667 0.500000000 3 Ga 0.33333333333 0.66666666667 0.124349275 4 Ga 0.66666666667 0.33333333333 0.624349275 kgrid2 4 4 2 symops 2 definitions sym ops (6-fold rotate+1/2Lz shift,reflection plane normal 010) 6 0.0 0.0 1.0 0.0 0.0 0.5 -2 0.0 1.0 0.0 0.0 0.0 0.0 end setup phase data run phase input data iterations 35 temperature for occupations (Ry) 0.0030 blend ratio 0.30 convergence criterion 0.000500 geometry relaxation gsteps - restrict the number of geometries to relax 5 gconv - max force convergence criterion 0.0010 only relax last - N are fixed by symmetries, move only Ga -2 end geometry relaxation cell optimization uc_conv - stress convergence (in GPa, default=0.002 ) 0.01 pressure - external pressure (GPa for 3D) 10.0 end cell end run phase dataReturn to Top