throw error when trying to use neigh_modify exclude with dynamic groups

This commit is contained in:
Axel Kohlmeyer
2024-08-21 10:34:20 -04:00
parent cdbec96e07
commit 47b5b2dfa3
2 changed files with 5 additions and 1 deletions

View File

@ -271,6 +271,8 @@ The value of the *page* setting must be at least 10x larger than the
*one* setting. This ensures neighbor pages are not mostly empty
space.
The *exclude group* setting is currently not compatible with dynamic groups.
Related commands
""""""""""""""""

View File

@ -2722,6 +2722,8 @@ void Neighbor::modify_params(int narg, char **arg)
error->all(FLERR, "Invalid exclude group keyword: group {} not found", arg[iarg+2]);
if (ex2_group[nex_group] == -1)
error->all(FLERR, "Invalid exclude group keyword: group {} not found", arg[iarg+3]);
if (group->dynamic[ex1_group[nex_group]] || group->dynamic[ex2_group[nex_group]])
error->all(FLERR, "Neigh_modify exclude group is not compatible with dynamic groups");
nex_group++;
iarg += 4;
} else if (strcmp(arg[iarg+1],"molecule/inter") == 0 ||