I was following up on the suggestion to try some NLO calculations with a simper system so I decided to review the NLO tutorials from the abinit website (nonlinear - abinit). These tutorials apply the PEAD and DFPT methods to determine the non-linear susceptibility of AlP. I note that the tutorial files are online on the abinit web site, but don’t seem to be included with the 9.10.1 distribution of abinit. When I attempted to run the PEAD example (tnlo_2.abi), the calculation proceeded without error to the end. There were some warnings about parallelization being inefficient (some processors may have been idle), but nothing that would appear to affect the calculated results. Before running the calculation, I changed the ecut value to a more realistic value (30 Rd from 8) and increased the number of allowed SCF loops to 100.
The tutorial calculation gives errors stating that
" dfptnl_doutput: WARNING -matrix of third-order energies incomplete,
non-linear optical coefficients may be wrong."
The input file is included here for reference (I don’t have the ability to upload files yet)
Note that all of the susceptibility values reported are zero. As I would like to calculate the nonlinear supsceptability for an even more complicated (but still cubic) system, I am would like to know what is wrong with the tutorial file input. It probably should be fixed so that it can be used as an example for others trying to understand how to use the nonlinear optical calculations features of abinit. Thanks for any help that can be offered.
# Linear and nonlinear response calculation for AlP
# Perturbations: electric fields & atomic displacements
ndtset 5
#DATASET1 : scf calculation: GS WF in the IBZ
#********************************************
prtden1 1 # save density on disk, will be used in other datasets
prtwf1 1 # save WF on disk, will be used in other datasets
kptopt1 1 # use Irreducible Brillouin Zone (all symmetry taken into account)
toldfe1 1.0d-12 # SCF convergence criteria (could be tolwfr or tolvrs)
#DATASET2 : non scf calculation: GS WF in half BZ
#*****************************************************
getden2 1 # use density from dataset 1
kptopt2 2 # use Half Brillouin Zone (only time-reversal symmetry taken into account)
getwfk2 1 # use GS WF from dataset 1 (as input)
iscf2 -2 # non-self-consistent calculation
tolwfr2 1.0d-22 # convergence criteria on WF, need high precision for response
prtwf2 1 # save WF on disk, will be used in other datasets
#DATASET3 : derivative of WF with respect to k points (d/dk)
#**********************************************************
getwfk3 2 # use GS WF from dataset 2
kptopt3 2 # use Half Brillouin Zone (only time-reversal symmetry taken into account)
rfelfd3 2 # compute 1st-order WF derivatives (d/dk)
tolwfr3 1.0d-22 # convergence criteria on 1st-order WF
prtwf3 1 # save 1st-order WF on disk, will be used in other datasets
#DATASET4 : response functions (2nd derivatives of E)
# and corresponding 1st order WF derivatives
# phonons, electric fields, and strains are all done
#**************************************************************
getwfk4 2 # use GS WF from dataset 2
kptopt4 2 # use Half Brillouin Zone (only time-reversal symmetry taken into account)
getddk4 3 # use ddk WF from dataset 3 (needed for electric field)
rfphon4 1 # compute 1st-order WF derivatives with respect to atomic displacements...
rfelfd4 3 # compute 1st-order WF derivatives with respect to electric field
rfstrs4 3 # compute 1st-order WF derivatives with respect to strains
tolvrs4 1.0d-12 # SCF convergence criteria (could be tolwfr)
prepanl4 1 # make sure that response functions are correctly prepared for a non-linear computation
prtwf4 1 # save 1st-order WF on disk, will be used in other datasets
prtden4 1 # save 1st-order density on disk, will be used in other datasets
#DATASET5 : 3rd derivatives of E
#*********************************
getwfk5 2 # use GS WF from dataset 2
get1den5 4 # use 1st-order densities from dataset 4
get1wf5 4 # use 1st-order WFs from dataset 4
kptopt5 2 # use Half Brillouin Zone (only time-reversal symmetry taken into account)
optdriver5 5 # compute 3rd order derivatives of the energy
d3e_pert1_elfd5 1 # activate electric field for 1st perturbation...
d3e_pert1_phon5 1 # ...and also atomic displacements...
d3e_pert1_atpol5 1 2 # ...for all atoms (so here only 1 and 2)...
d3e_pert2_elfd5 1 # activate electric field for 2nd perturbation...
d3e_pert3_elfd5 1 # activate electric field for 3rd perturbation...
#Definition of the unit cell
# these cell parameters were derived from a relaxation run done with the
# current ecut and kpt values. The current ecut value used is very low but
# is done to speed the calculations.
# acell 7.2728565836E+00 7.2728565836E+00 7.2728565836E+00 Bohr # ecut 5
# acell 7.2511099467E+00 7.2511099467E+00 7.2511099467E+00 Bohr # ecut 30
acell 7.1391127387E+00 7.1391127387E+00 7.1391127387E+00 Bohr # ecut 2.8
rprim 0.0000000000E+00 7.0710678119E-01 7.0710678119E-01
7.0710678119E-01 0.0000000000E+00 7.0710678119E-01
7.0710678119E-01 7.0710678119E-01 0.0000000000E+00
#Definition of the atom types and pseudopotentials
ntypat 2 # two types of atoms
znucl 15 13 # the atom types are Phosphorous and Aluminum
# the following norm-conserving pseudopotentials are stored in the abinit distribution, but are freely
# available through www.pseudo-dojo.org
# this set uses the Perdew-Wang parameterization of LDA for the xc model
pp_dirpath "$ABI_PSPDIR"
pseudos "Pseudodojo_nc_sr_04_pw_standard_psp8/P.psp8, Pseudodojo_nc_sr_04_pw_standard_psp8/Al.psp8"
#Definition of the atoms
natom 2 # two atoms in the cell
typat 1 2 # type 1 is Phosphorous, type 2 is Aluminum (order defined by znucl above and pseudos list)
nband 4 # nband is restricted here to the number of filled bands only, no empty bands.
nbdbuf 0
# atomic positions in units of cell vectors
xred
1/4 1/4 1/4
0 0 0
#Numerical parameters of the calculation : planewave basis set and k point grid
ecut 30.0 # this value is very low but is used here to achieve very low calculation times.
# in a production environment this should be checked carefully for convergence and
# a more reasonable value is probably around 30
ecutsm 0.5
dilatmx 1.05
ngkpt 6 6 6 # must be checked carefully for convergence, Raman calculations converge slowly with kpt
nshiftk 4 # this Monkhorst-Pack shift pattern is used so that the symmetry of the shifted grid
# is correct. A gamma-centered grid would also have the correct symmetry but would be
# less efficient.
shiftk 0.5 0.5 0.5
0.5 0.0 0.0
0.0 0.5 0.0
0.0 0.0 0.5
# scf parameters
nstep 100 # limit number of steps for the tutorial, in general this should be set to its
# default (30) or higher
# suppress printing of density, wavefunctions, etc except what is
# explicitly requested above in the ndtset section
prtwf 0
prtden 0
prteig 0
Output :
Matrix of third-order derivatives (reduced coordinates)
before computing the permutations of the perturbations
j1 j2 j3 matrix element
dir pert dir pert dir pert real part imaginary part
Non-linear optical susceptibility tensor d (pm/V)
in cartesian coordinates
i1dir i2dir i3dir d
1 1 1 0.000000000
1 1 2 0.000000000
1 1 3 0.000000000
1 2 1 0.000000000
1 2 2 0.000000000
1 2 3 0.000000000
1 3 1 0.000000000
1 3 2 0.000000000
1 3 3 0.000000000
2 1 1 0.000000000
2 1 2 0.000000000
2 1 3 0.000000000
2 2 1 0.000000000
2 2 2 0.000000000
2 2 3 0.000000000
2 3 1 0.000000000
2 3 2 0.000000000
2 3 3 0.000000000
3 1 1 0.000000000
3 1 2 0.000000000
3 1 3 0.000000000
3 2 1 0.000000000
3 2 2 0.000000000
3 2 3 0.000000000
3 3 1 0.000000000
3 3 2 0.000000000
3 3 3 0.000000000
dfptnl_doutput: WARNING -
matrix of third-order energies incomplete,
non-linear optical coefficients may be wrong.
First-order change in the electronic dielectric
susceptibility tensor (Bohr^-1)
induced by an atomic displacement
atom displacement
1 1 0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
1 2 0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
1 3 0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
2 1 0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
2 2 0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
2 3 0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
0.000000000 0.000000000 0.000000000
dfptnl_doutput: WARNING -
matrix of third-order energies incomplete,
changes in the dielectric susceptibility may be wrong.