Issue reading IOPT in opt.F (also question about VTST website)
Posted: Fri Aug 14, 2015 7:48 pm
I was recompiling VASP 5.3.5 today using the latest vtstcode 158 (as well as the latest VASPsol and some custom patches of my own), and I encountered an issue wherein VASP would not correctly parse the IOPT value in the INCAR. Specifically, the IOPT parameter was defaulting to 0 regardless of the value supplied to the INCAR. After some debugging I found that the RDATAB function called on line 98 to parse the IOPT setting was returning an IERR of 3, which indicates that the keyword was not found in the file. The POTIM and IBRION settings (which are gathered immediately after IOPT) were being parsed correctly.
I found that putting the IOPT setting into a separate file and changing the RDATAB command to read from that file worked as expected. Additionally, I found that changing the command from "RDATAB(.TRUE.,'INCAR',..." to "RDATAB(.FALSE.,'INCAR'..." resulted in the IOPT value being read properly. I notice that in most of the places that RDATAB is called in the VASP source code, it is called with .FALSE. in the first argument place. My understanding is that using .FALSE. causes VASP to rewind the already-open INCAR file, rather than re-open it.
EDIT: It looks like I also needed to make that change in chain.F. Strangely, it seems like the only keyword to have this issue is IOPT.
EDIT 2: Apparently changing the .TRUE. to .FALSE. in chain.F doesn't solve the issue. The OUTCAR indicates that the LBFGS method is being used (as printed in opt.F), but the atoms are essentially not moving and the energy and forces do not change from step to step. I haven't quite yet figured out how to solve this.
Also, though this is completely off topic, I've been meaning to ask about the VTST download page. Specifically, the download page says that a snapshot of the VTST code can be downloaded from the SVN repository at http://theory.cm.utexas.edu/svn/vtsttools. However, as far as I can tell, this repository contains the actual VTST website, rather than any of the code. Am I correct in thinking that this link should be to http://theory.cm.utexas.edu/svn/vtstcode/ instead? If so, how is this any different than the vtstcode.tgz that is distributed, as both have the same revision number?
I found that putting the IOPT setting into a separate file and changing the RDATAB command to read from that file worked as expected. Additionally, I found that changing the command from "RDATAB(.TRUE.,'INCAR',..." to "RDATAB(.FALSE.,'INCAR'..." resulted in the IOPT value being read properly. I notice that in most of the places that RDATAB is called in the VASP source code, it is called with .FALSE. in the first argument place. My understanding is that using .FALSE. causes VASP to rewind the already-open INCAR file, rather than re-open it.
EDIT: It looks like I also needed to make that change in chain.F. Strangely, it seems like the only keyword to have this issue is IOPT.
EDIT 2: Apparently changing the .TRUE. to .FALSE. in chain.F doesn't solve the issue. The OUTCAR indicates that the LBFGS method is being used (as printed in opt.F), but the atoms are essentially not moving and the energy and forces do not change from step to step. I haven't quite yet figured out how to solve this.
Also, though this is completely off topic, I've been meaning to ask about the VTST download page. Specifically, the download page says that a snapshot of the VTST code can be downloaded from the SVN repository at http://theory.cm.utexas.edu/svn/vtsttools. However, as far as I can tell, this repository contains the actual VTST website, rather than any of the code. Am I correct in thinking that this link should be to http://theory.cm.utexas.edu/svn/vtstcode/ instead? If so, how is this any different than the vtstcode.tgz that is distributed, as both have the same revision number?