Special bond

Dears
hope you are doing well
I have a question and I appreciate if some body answer me. The question is when I use molecule command I got this error (ERROR: Cannot auto-generate special bonds before simulation box is defined (src/molecule.cpp:650)) and I didn’t find this error in lammps documentation
PDMS.mol (1.7 KB)

The error message is rather self-explanatory.

The remainder of the explanation is in the documentation for the molecule command — LAMMPS documentation

In summary, if you have a molecule file with bonds, angles etc. you also need to have the information about excluded non-bonded interactions. Under normal circumstances, LAMMPS can auto-generate this (as it does when reading a data file). But unlike a data file, which also defines the box, the molecule file can be loaded early when related settings are not yet locked in, and in that case the corresponding information must be provided in the molecule file as Special Bond Counts and Special Bonds sections.

The simple workaround to take note of the error message and load the molecule file after the box has been defined.

many thanks

Dear Axel
Many thanks for your help. one question more is there any software to create molecular data file including special bond counts and special bond or I should create manually?
Note: I know topotool is used for creating lammps data file and I used it but I don’t know if it can be used for creating special bond

Best wishes

Manually. It is not difficult once you get the hang of it.

I find moltemplate very handy to create data files for molecular systems.

Many thanks

many thanks