The invisible boundary that can distort a molecular simulation

A simulation box can look like a simple container around a molecule. But with periodic boundary conditions, the box is repeated in every direction: a molecule can effectively interact with copies of itself. If the box is too small, those periodic images may influence the forces in your simulation. Getting the box right is therefore an important preparation step—not just a matter of making the structure fit.

In GROMACS Wizard, the practical goal is to include the entire selected system and leave enough space between the solute and the box boundaries. The documentation recommends at least 1 nm of clearance. This corresponds to at least 2 nm between periodic images of a protein or another non-solvent molecule. The appropriate choice can depend on how the system changes shape and on the cutoff scheme used, so check the force-field guidance when using a custom force field.

Choose a box-fitting approach that matches your project

GROMACS Wizard provides two ways to fit the initial box:

  • Solute-box distance: Set the distance between the system and the box. This is a convenient way to specify the clearance directly. For a batch project, each conformation or trajectory frame can have a different box size.
  • Box lengths: Specify the box dimensions. The initial fit is tight around the system, so increase the dimensions to create the space required for periodic boundary conditions. For a batch project, the initial size is determined from all conformations or the full path, making this option useful when you want the same box size throughout the batch.

In other words, the choice is not simply about which setting is easier. Consider what needs to stay consistent across your project. If each conformation can have its own box, a solute-box distance makes the clearance explicit. If comparable box dimensions across a batch are important, box lengths may be more suitable—but remember to enlarge the fitted box.

Choosing a unit-cell type in GROMACS Wizard
Select the unit-cell type before fitting the box.

A practical box-preparation workflow

  1. Select the structures you intend to prepare. The box must include all structures selected for preparation. If you are working with multiple models or conformations, make sure your selection reflects the full set you mean to simulate.
  2. Choose a unit cell. Supported options include cubic, orthorhombic, triclinic, rhombic dodecahedron, and truncated octahedron. The tutorial’s example uses an orthorhombic cell; your choice should suit your system and workflow.
  3. Compute the fitted box. Use Compute fitted box to generate a box based on the system’s dimensions. With the solute-box distance option, specify the desired clearance; with box lengths, review and increase the resulting dimensions as needed.
  4. Check the clearance and coverage. Confirm that the entire selected system is inside the box and that the solute is not too close to its boundaries. A box that encloses the coordinates is not necessarily large enough for a simulation.
  5. Revisit the box if the project is a batch. Decide whether a common box size or per-conformation box sizes better fit the project before proceeding.
A fitted periodic box around the selected molecular system
The fitted box is based on the dimensions of the selected system; verify that it also provides sufficient clearance.

Why this step is worth checking

A box that is too tight can undermine the assumptions behind periodic boundary conditions: the system may interact with its periodic images when it should not. A box that is larger than necessary also changes the amount of space to be filled when explicit solvent is added. The useful habit is to treat box fitting as a deliberate modeling decision: check coverage, choose a clearance, and consider how conformational changes affect the whole system—not just the initial structure.

Once the box is defined, you can continue preparing the system, including adding solvent and, if needed, ions. Ions replace water molecules, so solvent must be added if you plan to add ions. When preparation finishes, GROMACS Wizard can import the prepared structure into SAMSON for inspection before the next step, energy minimization.

For the full preparation workflow and additional details, see the GROMACS Wizard preparation tutorial.

Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.

Comments are closed.