When working with protein systems, especially in coarse-grained (CG) simulations using force fields like MARTINI, it’s common to use multiple copies of a protein within a simulation box. But as many molecular modelers have experienced, creating replicas can easily lead to issues related to overlapping residue and chain IDs. These conflicts might seem harmless during model building, but they can cause serious errors during topology generation and downstream molecular dynamics simulations.
If you’ve ever encountered file parsing errors or inexplicable issues when generating topologies for systems with several identical proteins, chances are the underlying cause relates to duplicated residue or chain IDs. Fortunately, using SAMSON and the Martinize2 SAMSON Extension, there’s a straightforward way to renumber and rename chains to avoid these headaches.
Why Renumbering Matters
Many tools that generate MD simulation input files assume residue and chain identifiers are unique. When creating multiple replicas of a protein (e.g., using manual duplication in SAMSON or scripts), these identifiers are often copied as-is. This means all chains might be named “A” and residue IDs might start at 1 repeatedly — which is problematic when exporting the system as a PDB or generating topology (.itp) files. Some MD engines or preprocessing tools simply can’t handle these ID conflicts.
How to Renumber Chains and Residues in SAMSON
Once you’ve created your replicas — whether manually or using tools like the Molecular Box Builder — follow these steps to ensure everything is labeled appropriately for the topology pipeline:
1. Renumber Residue IDs
Right-click on the structural model and choose:
Structural model > Renumber residues and structural groups

In the dialog that appears, leave the start number at 1 and click OK.

2. Renumber Chain IDs
Next, right-click on the same structural model and choose:
Structural model > Renumber chain IDs

In the dialog, use the default start value 0 and confirm with OK.

3. Rename Chains to Ensure Unique Names
Even after ID renumbering, it’s good practice to give each chain a unique name. You can do this directly in the document view: select a chain, press F2, and type the new name. Alternatively, you can use the Inspector to rename them.


When Should You Do This?
Any time you’re creating multiple replicas of the same biological macromolecule — whether for coarse-graining or all-atom simulations — renumbering and renaming is a necessary step. It ensures clean and conflict-free input files for tools like Martinize2 or GROMACS.
Tips for Workflow Integration
- Apply renumbering right after generating replicas — it keeps things organized from the start.
- Save your system once renumbering is done. That way, you preserve a clean, reusable state.
- Always preview the chain names and residue order in the document view or Inspector before exporting or generating topologies.
For more details, see the full SAMSON tutorial on Martinize2: https://documentation.samson-connect.net/tutorials/martinize2/martinize2/
SAMSON and all SAMSON Extensions are free for non-commercial use. You can get SAMSON at https://www.samson-connect.net.
