Add KOKKOS version of dihedral style nharmonic#4933
Merged
Conversation
Create dihedral_nharmonic_kokkos.h and .cpp in src/KOKKOS/ following the pattern from dihedral_multi_harmonic_kokkos and dihedral_fourier_kokkos. Uses 2D Kokkos views for variable-length coefficient arrays and 1D int views for per-type term counts. Update documentation to list the new nharmonic/kk accelerated variant. Agent-Logs-Url: https://github.com/akohlmey/lammps/sessions/5d795956-0b37-4808-837f-9a840867ed96 Co-authored-by: akohlmey <289251+akohlmey@users.noreply.github.com>
ndtrung81
approved these changes
Mar 30, 2026
stanmoore1
approved these changes
Mar 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This ports the dihedral style nharmonic to the KOKKOS package.
Related Issue(s)
Implements and thus closes #4931
Author(s)
Axel Kohlmeyer, Temple U
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).
Artificial Intelligence (AI) Tools Usage
The porting was done almost completely by GitHub Copilot using Claude Opus 4.6.
Axel Kohlmeyer only fixed a couple of bugs including the restart bug that was
just today discovered and corrected in dihedral style fourier in PR #4929.
Backward Compatibility
Binary restarts for dihedral nharmonic are not compatible with older versions.
Post Submission Checklist