reax/c/bonds and atom_modify

Hi Manana,

Please see if these work for you.


Sorry, here are the attachements.

If they work, I will send them to Steve.

fix_reaxc_bonds.cpp (9.1 KB)

pair_reax_c.cpp (21.9 KB)

Hello Ray,

Thank you very much for the files. I’m getting the same, however, i did some more tests and it seems that the issue arises when I start calculation form the restart file. If geometry is inside the script ‘atom_modify’ doesn’t affect the connection table. But if I start from the restart the same happens as in my previous post.

i.e. like:
atom_modify map array sort 0 2.0
read_restart test.

Thank you again,

Hi Manana,

It is normal that using the atom_modify map changes the connection table, but it only changes the order the atoms are listed, not the actual connection. You can verify it with mol_fra.c.

I can’t reproduce your error with the example files. Did you really see this error with the new files? A bond order cutoff of 0.000?

Hi again Ray,

I’m attaching the simple script that I’ve been using for testing. I was outputting the bond info from reax/c/bonds into file test.bonds. That’s where I was checking the information. I have never used mol_fra.c. I’ll try to test with that too if it makes any difference. Hope nothing wrong with that simple script that I’ve been blind to notice and make up the mess :).

Best wishes,

in.test (620 Bytes)


The script looks fine, and I generated the same connection table with all four scenarios: with and without atom_modify, and with create_atoms and restart file. I can not reproduce what you described in the first email with the corrected source files. I suggest you do a make clean, followed by a re-compile.

By the way, the header of the outputs are all the same as the following:

Number of particles 256

Ray, many thanks, now it seems to work and also the cutoff corresponds to the default value. I have one more question though, what is the path of the default control file when using NULL. Ofc, I could use the one from examples dir and modify but still wonder.

Best wishes,


Great. So when NULL is used pair_style reax/c uses the hard-coded default values and does not need the control file.