Add angles to ListedForces selections
authorBerk Hess <hess@kth.se>
Thu, 10 Sep 2020 11:37:55 +0000 (13:37 +0200)
committerBerk Hess <hess@kth.se>
Thu, 10 Sep 2020 11:37:55 +0000 (13:37 +0200)
src/gromacs/listed_forces/listed_forces.cpp
src/gromacs/listed_forces/listed_forces.h

index e6b34c04b41490744af64a8da0ca7b1088c441c9..d68b21b93f76c719d9401045c389742b93fe03da 100644 (file)
@@ -105,6 +105,8 @@ static void selectInteractions(InteractionDefinitions*                  idef,
             interactionSelection.test(static_cast<int>(ListedForces::InteractionGroup::Pairs));
     const bool selectDihedrals =
             interactionSelection.test(static_cast<int>(ListedForces::InteractionGroup::Dihedrals));
+    const bool selectAngles =
+            interactionSelection.test(static_cast<int>(ListedForces::InteractionGroup::Angles));
     const bool selectRest =
             interactionSelection.test(static_cast<int>(ListedForces::InteractionGroup::Rest));
 
@@ -122,6 +124,10 @@ static void selectInteractions(InteractionDefinitions*                  idef,
             {
                 assign = selectDihedrals;
             }
+            else if (ifunc.flags & IF_ATYPE)
+            {
+                assign = selectAngles;
+            }
             else
             {
                 assign = selectRest;
index c1901aa42a2303e455429e6e0efe327d83442778..c044baf11730375ab30db3a15b08b902bdfadfb8 100644 (file)
@@ -136,6 +136,7 @@ public:
     {
         Pairs,     //!< Pair interactions
         Dihedrals, //!< Dihedrals, including cmap
+        Angles,    //!< Angles
         Rest,      //!< All listed interactions that are not any of the above
         Count      //!< The number of items above
     };