Gmx cluster and ions

GROMACS version: 2022.0
GROMACS modification: Yes/No

Hi,

My system contains polymer chains and ions. I want the polymer chains to appear as whole molecules (i.e., remove the periodic boundary condition (PBC) effects) while keeping the ions positioned correctly relative to the PBC-corrected polymer chains.

To achieve this, I ran:

gmx trjconv -f run.xtc -s run.tpr -pbc cluster -o structure.gro -dump 100000

However, I observe that the ions are not handled correctly with respect to the PBC removal. In the resulting structure.gro file, some ions appear in regions of space where the polymer is not present, suggesting that the ions were not repositioned consistently with the clustered polymer chains.

Is there another method in GROMACS to remove PBC effects from the polymer chains while keeping the ions in their correct relative positions?

Thank you.