Trjorder error

GROMACS version: 5.1.2
GROMACS modification: No

I receive the following error when executing trjorder:

Number of atoms in the molecule group (22) is not a multiple of na (3)

I am trying to find the coordination number of ions within a specified radius of two atoms on my molecule. I’m able to do this exact task in the same way for waters.

What causes this error and how may I resolve it?

na is number of atoms in a molecule, by default is 3. I guess group 22 does not contains molecules made by 3 atoms. You wrote that you got no error when you use the same command for waters, indeed water is composed by 3 atoms.

You can try to the appropriate values for -na for group 22

In general it is better to provide more information regarding the error one encounter. e.i. for the command line you use with gmx trjorder, what is containts group 22 (solvent?). That will promote and facilitate others to help you.

Best regards