5. Equilibrium molecular dynamics¶
5.1. Set up the production run¶
As usual, we must tell Gromacs what it will be doing using gmx grompp before we can perform our production simulation. Since we want to start our run where we left off (after doing equilibration), we prepare the TPR input file based on the last frame of the Position-restrained equilibration with gmx grompp:
cd ../MD
cp ../templates/md.mdp .
gmx grompp -f md.mdp -p ../top/4ake.top -c ../posres/posres.pdb -o md.tpr -maxwarn 3
The md.mdp
file uses different algorithms from the
Position-restrained equilibration for the temperature and pressure coupling,
which are known to reproduce the exact NPT ensemble distribution.
5.2. Run the simulation¶
Run the simulation as usual with gmx mdrun:
gmx mdrun -v -stepout 10 -s md.tpr -deffnm md -cpi
This will automatically utilize all available cores and GPUs if
available. The -cpi
flag indicates that you want Gromacs to
continue from a previous run. You can kill the job with
CONTROL-C, look at the output, then continue with exactly the
same command line
gmx mdrun -v -stepout 10 -s md.tpr -deffnm md -cpi
(Try it out!). The -cpi
flag can be used on the first run
without harm. For a continuation to occur, Gromacs needs to find the
checkpoint file md.cpt
and all output files (md.xtc
,
md.edr
, md.log
) in the current directory.