Coordinate error with grompp

GROMACS version:gromacs-5.1.5
GROMACS modification: Yes
Here post your question
Hi dear gromacs users,
I want to set up a simulation of nanoparticle and ligand molecules.
When I run “gmx grompp -f ions.mdp -c solv+Au_lig.gro -p topol.top -o ions.tpr”
I get this error: number of coordinates in coordinate file (solv+Au_lig.gro, 32781)
does not match topology (topol.top, 34564)
Since I run grompp with ligand and water without nanoparticle, there is not any problem, I understood the error is related to nanoparticle. I modified my gro and top files, But I could not corrected the error.
I upload top file. I believe anyone help me, please.

topol.top (37.9 KB)

Hi Khatti,

Looking at the topology, you can see what [ molecules ] you are supposed to have in your system, then you would have to match them against your .gro file, so uploading a gro file is definitely useful. Antother thing you can check is the number of hydrogens, if you rely on pdb2gmx to add the correct number.

Thanks so much for the reply. I think molecules in my topology and gro files are matched. In my case, the gold nanoparticle has no hydrogen and I combined ligand and nanoparticle with “gmx insert-molecules”.
This attachment is my gro file.
Best regards.
Khatti

(Attachment solv+Au_lig.gro is missing)

unable to send gro file by this email. How can I send it to you?

The error message says that the molecules in the topology do not match what is contained in the coordinate file. The topology says that there are 34,564 atoms and the coordinate file says there are 32,781 atoms. You need to go back through your process and determine where you lost count.

Thanks a lot for the response. I understood my error message, but I could not find lost atoms.
I have one ligand and one Au molecule and 10615 water molecules that have 32781 atoms corresponding to the initial pdb file of the molecules.
How is topology file included in these extra atoms?

Because you have told it to. Computer scripts aren’t smart, they do exactly what you tell them to do. You need to go through your topology file(s) and find where your counting error is exactly. First place to look is the [ molecules ] section, ensure that the number of molecules there matches what you think it is, and what it actually is in the coordinate file. Your ligand appears to be 937 atoms, and the difference is just short of 2x this number, so it isn’t something as simple as having 2 LIGAND in the molecules section.

Thanks so much for the reply.
this is last lines of my topology file:
[ molecules ]
; Compound nmols
NP1 1
MOL 1
SOL 10615
NP1=887atoms and MOL=49atoms. When I set zero for NP1, Iget this error: number of coordinates in coordinate file (solv.gro, 32781)
does not match topology (topol.top, 31894) and difference between (32781-31894=887) them equal to NP1 atoms.

But when I set one for NP1, difference between number of coordinates is very high:(34564-32781=1783)
error:number of coordinates in coordinate file (solv.gro, 32781) does not match topology (topol.top, 34564)

I am confused by topology file.

You need to check the individual topologies for NP1 and MOL, because often when those are written by external programs they are assumed to be standalone topologies and may have [molecules] blocks of their own, which mean you’re duplicating the coordinates somewhere.

Thanks so much.

The topology of MOL has no problem, because I tested it alone without error.
But I could not understand what is the problem of NP1 topology file.How can I check it?

Upload your files somewhere and provide us a link to them.

Thank you for your attention.
https://drive.google.com/file/d/1lP9t_GyCfpN2QF0srmTfWVpHbo8__C4J/view?usp=sharing
https://drive.google.com/file/d/1xg23oWjYrSyaurmGeEBQIs7jzUMBI01z/view?usp=sharing
https://drive.google.com/file/d/1_35OQfGCyZKfm9k0QsJ3zyyguHNbbGnP/view?usp=sharing
https://drive.google.com/file/d/1vDP6K5jjOOkBNhz1N6N1HVrR67kG9pPd/view?usp=sharing

All those links/files are locked. You need to change the share settings to allow others to view them.

I think the restriction has been removed.

https://drive.google.com/file/d/1_35OQfGCyZKfm9k0QsJ3zyyguHNbbGnP/view?usp=sharing
https://drive.google.com/file/d/1xg23oWjYrSyaurmGeEBQIs7jzUMBI01z/view?usp=sharing
https://drive.google.com/file/d/1vDP6K5jjOOkBNhz1N6N1HVrR67kG9pPd/view?usp=sharing
https://drive.google.com/file/d/1lP9t_GyCfpN2QF0srmTfWVpHbo8__C4J/view?usp=sharing

NP1 contains 2670 atoms, not 887. Look at nanoparticle.itp

The .itp is inconsistent with what you added to the coordinate file.

Thanks so much. I completely realized my mistake.
I downloaded and applied charmm36 force field due to using nanoparticle.itp, but it is correspond to its own Au.gro file as you say.

How can I create itp file of my .gro file with charmm36.ff? I tested x2top, but there is no .n2t file in charmm36.ff.
Could I have your help? please.

You will have to write a suitable .n2t file for generating such a species if you want to use x2top.

Thank you for your response.