sw/intel with special_bond

Dear all,

I am trying to use sw/intel with special bond for long chain alkanes. In the sw potential I made lamda=0 to turn off the three-body potential. No matter I use special bond= 1 or special bond =0, the sw/intel uses special_bond=1. I also test sw with special_bond and found that it takes whatever I specified in the special_bond.

I did the same set of test for lj and lj/intel with special_bond, both of them works fine.

I had a system with lj for alkanes and sw for water. But the intel package, to my knowledge, does not support hybrid potentials, so I tried to switch lj to sw to make a set of sw potential and apply intel package, which seems not working with special_bond.

The lammps version I used is Feb/16/2016.
Please let me know if there is something I am not aware of or there is some way to apply intel package in this case. Thank you so much for your kind help. I really appreciate it.


Hi Yuqing,

I am not sure that I understand what you mean here. sw won’t use special bond settings. Are you saying that you modified sw to use these in an lj term you have added into the sw 2-body term? If so, is the problem that the index into the special bonds array is not correct or that the value in the special bonds array is not correct?

You can use hybrid styles with the intel package, but currently only one of the styles can use the intel package. So you can, for example, do:

suffix off

pair_style hybrid sw/intel … lj/omp …

suffix on

in the input script.

Unfortunately, I will be out of access to e-mail for a week. But I will respond to you when I get back.

Best, - Mike

and if you mean that you just parameterized sw to get LJ without modifying the code, are you sure sw without Intel is handling special bonds correctly? Stillinger-Weber wasn’t originally designed for explicit bonds and I didn’t think the logic for this was in there. But, I don’t think that I wouldn’t recommend this anyway if you need a longer cutoff for the LJ interactions.

Best, - Mike

sorry this is taking 3 e-mails (and delaying the start of my vacation J). I remembered that there will be a difference between sw and sw/intel only if the special bond factor is set to 0. This is because the Intel package will still add neighbors to the list if this factor is zero and (and the result is normally the same because it is zeroed during force calculation from the special_bond factor in supported styles). Non-zero settings <1 will not work in either.

I will think about how best to reconcile this, but hybrid is probably the way to go if that works.

  • Mike

Thank you so much, Michael. I think using lj/sw hybrid should be my best option. I try to apply intel to hybrid pair style as you suggest above, with the following lines

suffix off

pair_style hybrid sw/intel lj/cut/omp 12.0

bond_style harmonic/omp

angle_style harmonic/omp

dihedral_style opls/omp

improper_style none

kspace_style none

suffix on

It still gives me ERROR: Cannot yet use hybrid styles with Intel package. (…/fix_intel.cpp:471). I used Feb-16-16 version. Should I compile a new version of lammps to make it work? Thank you so much for all your help!



Sorry about this; there is another issue that is complicating hybrid here. I will have to modify some code for this and can give you something to test next week. If you want to send me a sample script/data directly, I can test with that. Best, - Mike