Simulation box size?

GROMACS version: gromacs/2024.2
GROMACS modification: No

Beginner MD user here with a beginner question.

I’m setting up a simulation of a globular soluble protein with a longest axis of ~5.5 nm. I’ve tried generating boxes using several different conditions:

  • Cubic box with -d = 1.2 and 2.0
  • Dodecahedron box with -d = 2.0 and 5.0

However, in all cases it appears that the protein is still “seeing” its own periodic image. I checked this using the non-centred trajectory with gmx mindist -pi, and quite a few distances are below my non-bonded cutoff.

My questions are:

  1. Is gmx mindist -pi an appropriate/valid way to assess whether the box size is sufficient?
  2. What would be considered an appropriate box size for this kind of system?

Thanks in advance!

Hi! To answer your questions briefly, I would say 1. yes and 2. the values you mention are actually pretty safe choices in most cases. However, like you say, that depends on your cutoff. What value are you using? Could you share what commands you used to create your system?

Hi! My cutoff is 1.4

And here follow the commands to set up my system

  1. gmx pdb2gmx -f input.cif -o 1_sim_protein.gro -p sim_protein.top -heavyh -merge all -ignh -missing -ter
  2. gmx editconf -f 01_sim_protein.gro -o 02_sim_protein.gro -c -d 2.0 -bt dodecahedron (Here I have played around with different parameters for -d and -bt, with no success)
  3. gmx solvate -cp 02_sim_protein.gro -cs spc216 -p sim_protein.top -o 03_sim_protein.gro
  4. Energy minimise
  5. gmx grompp -f minimise_soluble.mdp -c 04_sim_protein.gro -r 04_sim_protein.gro -p sim_protein.top -o 05_sim_protein.tpr
  6. gmx genion -s 05_sim_protein.tpr -p sim_protein.top -o 05_sim_protein.gro -nname CL -pname NA -conc 0.150 -neutral
  7. Energy minimise followed by index file creation and equilibration of protein with reducing restraints

Thansk for your help!

Okay. Your steps look completely fine to me, and using -d 2.0 with a cutoff of 1.4 should also be enough. I don’t know why mindist still reports periodic distances below the cutoff. I might also be wrong, but I would say if you don’t see any obvious artifacts in your simulation, you’re probably fine.

One thing I would say though is that you can probably save yourself the extra minimization step before adding ions. Also I don’t know if that’s clear, but just gmx grompp by itself does not perform minimization, you do have to run e.g. gmx mdrun -deffnm 05_sim_protein.tpr as well.

Thank you! I have a quick question about artefacts. When I examine the mindist output, I notice that for some frames where the minimum distance is below my cutoff threshold, the corresponding frame in VMD visualisation shows the protein crossing the periodic boundary condition and directly clashing with its periodic image. Is this the type of artefact I should monitor, or is there something else I should be looking for?

Screenshots of the mindist output and VMD visualisation are below. The frame in question is underlined in blue in the mindist output and corresponds to the VMD image shown.

Okay, I noticed now you said you were using a non-centered trajectory. I’m assuming that’s also what your visualizing with VMD here. Have you tried centering first, e.g. with gmx trjconv -f md.xtc -s md.tpr -center -ur compact -pbc mol -o md_center.xtc? This should fix both your visualization and mindist issues.

I think this is where my basic understanding is apparent… I have recentered the trajectory and yes this does fix these issues. But should we not determine the appropriateness of our box size and whether our protein is ‘seeing itself’ (and calculate mindist) using the non-centered trajectory? as this is a representation of the calculations etc performed during the simulations?

Glad that solved your issue! Have a look at this manual page, which explains how GROMACS uses PBC. Basically, trajectories aren’t stored wrapped to the unit cell in the “correct” shape just because it’s more efficient not to do so. I wouldn’t say this is necessary a lack of basic understanding though, I find it a bit counter-intuitive myself.