[gmx-developers] Adding a boolean mdp option

Kutzner, Carsten ckutzne at gwdg.de
Tue Nov 10 22:24:51 CET 2015


Hi,

You also need to write the value of the variable to .tpr file. Look for do_inputrec() in tpxio. cpp

Carsten




> Am 10.11.2015 um 21:11 schrieb Vedran Miletić <rivanvx at gmail.com>:
> 
> Hello,
> 
> I'm trying to add a boolean mdp option. I added the following:
> 
> * in src/gromacs/gmxpreprocess/readir.cpp:
> 
> EETYPE("my-option", ir->bMyOption, yesno_names);
> 
> *in src/gromacs/legacyheaders/types/inputrec.h in typedef struct t_inputrec
> 
> gmx_bool bMyOption;
> 
> * in src/gromacs/gmxlib/txtdump.cpp
> 
> PS("my-option", EBOOL(ir->bMyOption));
> 
> When I put my-option = yes in .mdp, and subserquently run grompp and
> mdrun, ir->bMyOption is 0 in gmx::do_md(). I'm printing the value of
> ir->bMyOption in while loop. Am I missing something?
> 
> Regards,
> Vedran
> 
> -- 
> Vedran Miletić
> http://vedranmileti.ch/
> -- 
> Gromacs Developers mailing list
> 
> * Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List before posting!
> 
> * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
> 
> * For (un)subscribe requests visit
> https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers or send a mail to gmx-developers-request at gromacs.org.


More information about the gromacs.org_gmx-developers mailing list