[Pw_forum] reusing wfc/charge density for nscf calculation with different total charge

Alexey Akimov aakimov_guest at z.rochester.edu
Sat Jun 1 03:32:04 CEST 2013


Dear Paolo,

First of all, thank you for your reply - i though that my message haven't got to the forum.  Yes, you are right - if i set the same tot_charge for nscf calculation as that for scf - everything works fine. But the idea is to use different charges for nscf (+0.25) and scf (0.0) calculations, and at the same time use the same wavefunction (obtained from the scf calculation). So when i try to do that, i get the errors below. I think this is because one is not supposed to do this kind of trick, normally. So would it be possible to do this without digging much into the code and rather using more standard options?

CRASH:
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     task #         0
     from potinit : error #         1
     starting and expected charges differ
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


portion of the nscf output (i run on several CPUs):

     The potential is recalculated from file :
     ./x.save/charge-density.dat


 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     Error in routine potinit (1):
     starting and expected charges differ
     Error in routine potinit (1):
     starting and expected charges differ
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

     stopping ...

 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     Error in routine potinit (1):
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

     stopping ...




Below are the relevant portions of the scf and nscf input files:

SCF input:

&CONTROL
  calculation = 'scf',
  pseudo_dir = <my path>
  outdir = './',
  prefix = 'x',
/

&SYSTEM
  ibrav = 0,
  celldm(1) = 1.89,
  nat = 6,
  ntyp = 1,
  nbnd = 50,
  tot_charge = 0.25,
  occupations = 'smearing',
  starting_magnetization(1) = 0.0,
  smearing = 'gaussian',
  degauss = 0.005,
  ecutwfc = 40,
  ecutrho = 400,
  nspin = 2,
  nosym = .true.,
/


NSCF input:

&CONTROL
  calculation = 'nscf',
  pseudo_dir = <my path>
  outdir = './',
  prefix = 'x',
/

&SYSTEM
  ibrav = 0,
  celldm(1) = 1.89,
  nat = 6,
  ntyp = 1,
  nbnd = 50,
  tot_charge = 0.0,
  starting_magnetization(1) = 0.0,
  occupations = 'smearing',
  smearing = 'gaussian',
  degauss = 0.005,
  ecutwfc = 40,
  ecutrho = 400,
  nspin = 2,
  nosym = .true.,
/





----- Original Message -----
From: "Paolo Giannozzi" <paolo.giannozzi at uniud.it>
To: "PWSCF Forum" <pw_forum at pwscf.org>
Sent: Thursday, May 30, 2013 4:59:18 AM
Subject: Re: [Pw_forum] reusing wfc/charge density for nscf calculation with different total charge

On Tue, 2013-05-21 at 21:34 -0400, Alexey Akimov wrote:

> when PW (with the input for nscf calculations for neutral system)
> tries to read the wavefunction/charge density for the charged system
> it crashes, because the expected charge is different from the one
> deduced from the wfc files

I am not sure but if you set a charge (tot_charge) for the nscf as well,
the calculation should succeed. Note that nothing changes in the nscf
if you set a nonzero charge: only occupancies should change, not
eigenvalues, since these depend only upon the potential

P.
-- 
Paolo Giannozzi, Dept. Chemistry&Physics&Environment, 
Univ. Udine, via delle Scienze 208, 33100 Udine, Italy
Phone +39-0432-558216, fax +39-0432-558222 

_______________________________________________
Pw_forum mailing list
Pw_forum at pwscf.org
http://pwscf.org/mailman/listinfo/pw_forum

-- 
Dr. Alexey V. Akimov

Postdoctoral Research Associate
Department of Chemistry
University of Rochester

aakimov_guest at z.rochester.edu 



More information about the users mailing list