Electric field mdp parsing using options
authorTeemu Murtola <teemu.murtola@gmail.com>
Fri, 30 Sep 2016 19:17:22 +0000 (22:17 +0300)
committerDavid van der Spoel <davidvanderspoel@gmail.com>
Mon, 24 Oct 2016 21:30:27 +0000 (23:30 +0200)
commit4aac8fa29bafb39f05b71c8f587eea7020917483
tree2d64d5c6753079e481b1496a5cdf483ac7db1601
parent208605d29a51eef28fcbf75948245abfc5567fe8
Electric field mdp parsing using options

Make the module declare a structured set of options, as well as a
transform from a flat mdp structure to this set of options.
Use these for assigning the input values, instead of passing t_inpfile
directly.

There is one regression introduced here: values not specified in the mdp
file are no longer automatically inserted with defaults, and comments
related to the electric field input values are lost.  With just the
electric field affected, this should not be a big deal, but that can
limit adoption of this approach until we can solve it (preferably, by
changing the mdp format to something where it is easier).

Change-Id: Ic71275f3533f06ce6fee64983c7e1686b782fb9b
src/gromacs/applied-forces/electricfield.cpp
src/gromacs/applied-forces/tests/electricfield.cpp
src/gromacs/fileio/readinp.cpp
src/gromacs/fileio/readinp.h
src/gromacs/gmxpreprocess/readir.cpp
src/gromacs/mdtypes/inputrec.h