From b6821ed94277eeda8b13f66763b4ce63fa688eb5 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer <akohlmey@gmail.com> Date: Wed, 21 Feb 2018 11:15:09 +0100 Subject: [PATCH] since the code uses static ids, only one instance is allowed at a time --- src/USER-MISC/fix_bond_react.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/USER-MISC/fix_bond_react.cpp b/src/USER-MISC/fix_bond_react.cpp index b033f0f8af..b74168f2ac 100644 --- a/src/USER-MISC/fix_bond_react.cpp +++ b/src/USER-MISC/fix_bond_react.cpp @@ -85,6 +85,10 @@ Fix(lmp, narg, arg) // these group names are reserved for use exclusively by bond/react master_group = (char *) "bond_react_MASTER_group"; + // by using fixed group names, only one instance of fix bond/react is allowed. + if (modify->find_fix_by_style("bond/react") != -1) + error->all(FLERR,"Only one instance of fix bond/react allowed at a time"); + // let's find number of reactions specified nreacts = 0; for (int i = 3; i < narg; i++) { -- GitLab