Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patch of class2 dihedral #1767

Merged
merged 6 commits into from Nov 11, 2019
Merged

Patch of class2 dihedral #1767

merged 6 commits into from Nov 11, 2019

Conversation

@LucienPan0903
Copy link
Contributor

LucienPan0903 commented Nov 8, 2019

Fix the NAN problem when any two bonds are nearly parallel

Summary

When any two bonds of the dihedral are nearly parallel, the costh12 costh13 costh23 will exceed the limit of [-1,1] slightly because of cut-off error, leading acos(costh12), acos(costh13) or acos(costh23) to be NAN.

Related Issues

If this addresses an open GitHub issue for this project, please mention the issue number here, and describe the relation. Use the phrases fixes #221 or closes #135, when you want an issue to be automatically closed when the pull request is merged

Author(s)

Lucien Pan

Licensing

By submitting this pull request, I agree, that my contribution will be included in LAMMPS and redistributed under either the GNU General Public License version 2 (GPL v2) or the GNU Lesser General Public License version 2.1 (LGPL v2.1).

Backward Compatibility

This fix is backward compatibility

Implementation Notes

Provide any relevant details about how the changes are implemented, how correctness was verified, how other features - if any - in LAMMPS are affected

Post Submission Checklist

Please check the fields below as they are completed after the pull request has been submitted. Delete lines that don't apply

  • The feature or features in this pull request is complete
  • Licensing information is complete
  • Corresponding author information is complete
  • The source code follows the LAMMPS formatting guidelines
  • Suitable new documentation files and/or updates to the existing docs are included
  • The added/updated documentation is integrated and tested with the documentation build system
  • The feature has been verified to work with the conventional build system
  • The feature has been verified to work with the CMake based build system
  • A package specific README file has been included or updated
  • One or more example input decks are included

Further Information, Files, and Links

Put any additional information here, attach relevant text or image files, and URLs to external sites (e.g. DOIs or webpages)

Fix the nan problem when any two bonds are nearly parallel
Fix the NAN problem when any two bonds are nearly parallel
@akohlmey

This comment has been minimized.

Copy link
Member

akohlmey commented Nov 8, 2019

@LucienPan0903 this pull request cannot be merged in the current form since it reverts changes to the master branch that were merged recently. Please correct it so that it only contains the changes that you intend to be added.

@akohlmey akohlmey added the needs_work label Nov 8, 2019
@LucienPan0903

This comment has been minimized.

Copy link
Contributor Author

LucienPan0903 commented Nov 8, 2019

Hi Akohlmey, I have correct the file.

@akohlmey

This comment has been minimized.

Copy link
Member

akohlmey commented Nov 8, 2019

Hi Akohlmey, I have correct the file.

Sorry, but not yet completely. There are still differences in whitespace: you are now deleting empty lines an have no EOL character at the end of the file.

@LucienPan0903

This comment has been minimized.

Copy link
Contributor Author

LucienPan0903 commented Nov 8, 2019

Fixed now. Thank you!

@akohlmey akohlmey requested review from athomps, sjplimp and stanmoore1 Nov 8, 2019
@akohlmey akohlmey self-assigned this Nov 8, 2019
@akohlmey

This comment has been minimized.

Copy link
Member

akohlmey commented Nov 8, 2019

Fixed now. Thank you!

Great. Much appreciated.

@akohlmey akohlmey merged commit 9e2129b into lammps:master Nov 11, 2019
8 checks passed
8 checks passed
lammps/pull-requests/build-docs-pr head run ended
Details
lammps/pull-requests/cmake/cmake-kokkos-cuda-pr head run ended
Details
lammps/pull-requests/cmake/cmake-kokkos-omp-pr head run ended
Details
lammps/pull-requests/cmake/cmake-serial-pr head run ended
Details
lammps/pull-requests/kokkos-omp-pr head run ended
Details
lammps/pull-requests/openmpi-pr head run ended
Details
lammps/pull-requests/serial-pr head run ended
Details
lammps/pull-requests/shlib-pr head run ended
Details
@LucienPan0903 LucienPan0903 deleted the LucienPan0903:p_class2 branch Nov 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.