bugfixes for pair/hbond/dreiding styles

I've been struggling with really bad dynamics when using
hbond/dreiding/morse for a while, and I think I found the source:

1) There is a bug in pair_style hbond/dreiding/morse which
accidentally erases the angular component of the force. I attached an
animated gif I made which shows the problem
(dreiding_morse_beforefix.gif. The hydrogen and donor were
immobilized during the simulation.) The new version of
pair_hbond_dreiding_morse.cpp (attached) restores energy conservation.
(If fix shake is used to constrain the donor-H bond, it should be
possible to use timesteps in the range of several fs.)

2) I also caught a very minor bug in the "coeff()" member function in
both pair_hbond_dreiding_morse.cpp and pair_hbond_dreiding_lj.cpp

All effected lines are flagged with //<-- BUGFIX 2012-11-14

3) I have some corrections to the documentation for these pair styles
which I'll send later.

Cheers!
Andrew

pair_hbond_dreiding_morse.cpp (13.4 KB)

pair_hbond_dreiding_lj.cpp (16 KB)

dreiding_morse_beforefix.gif

dreiding_morse_afterfix.gif

Sounds good - I'll let Tod take a look and comment.

Steve

Cool,.

Incidentally (you know this is coming), the bug in dihedral_class2.cpp
is equally serious. I actually know other random people who use that
dihedral style. We need to get that bug patched. Let me know if you
want me to send you the patch again.

Thanks!

Andrew

I never heard a definitive answer from my class2 "expert".
I'll nag him again ...

Steve