Page 1 of 1

repfn calculation crashes because ngfftdg doesnt match

Posted: Mon Aug 10, 2020 9:00 pm
by tyst3273
Hi Abinit users,

I am doing some phonon calculations with version 9.0.4 and have been running into a problem regarding ngfftdg.


Here is a short summary:

First, I do a ground state calculation to generate wavefunction and density files.
Then, I do an nscf calculation with iscf = -2 and nqpt = 1 at the desired qpoint.
Then I do the response calculation (rfphon = 1) reading the wavefunctions (WFK and WFQ) from the groundstate and nscf runs.

I keep ecut, pawecutdg, acell, and rprim the same for all calculations.

The problem I am having is, after reading the ground state density in the nscf run, Abinit determines a different ngfftdg value than the groundstate run and then crashes with a message that the ngfftdg number doesn't match the density file.

--- !ERROR
src_file: m_hdr.F90
src_line: 3964
mpi_rank: 0
message: |
fft grids must be the same for restart from a density file.
Action: change your fft grid or your restart file.
...



If I go look at the .abo file from the groundstate run and manually set the ngfftdg values in the nscf calculation, it runs without crashing. This is an okay hack, but it disrupts my workflow and I would like to not have to manually read the groundstate output file and set this manually.


I have attached the groundstate and an example phonon dfpt input file. The value ngfftdg in the .abo file from the response run is:
ngfft 36 36 100
ngfftdg1 45 45 135
ngfftdg2 48 48 135
In the ground state run, ngfftdg = 48 48 144.


I am not sure if this is some sort of bug or if I have made some error, so any advice is appreciated!

Thanks a lot,

Ty

Re: repfn calculation crashes because ngfftdg doesnt match  [SOLVED]

Posted: Wed Aug 12, 2020 12:07 pm
by ebousquet
Dear Ty,
This problem usually happens when a cell relaxation is done in the ground state (the fft grid is in real space and is calculated w.r.t. cell parameters), is it the case here, I do not see a relaxation of the cell in your gs input?
Otherwise you can enforce the fft grids by setting them in the input file of the DFPT calculation.
Best wishes,
Eric

Re: repfn calculation crashes because ngfftdg doesnt match

Posted: Wed Aug 12, 2020 3:37 pm
by tyst3273
Hi Eric,
Thanks a lot for the reply!
There is no relaxation in the ground state calculation, and the cell parameters are identical in all runs (gs and all pert). Enforcing ngfft and ngfftdg works, thanks a lot.
Ty