Use constexpr for physical constants and move them into gmx namespace
[alexxy/gromacs.git] / src / gromacs / gmxpreprocess / genion.cpp
index 4d98124057e3f0d18aabafdc6efab39c3f47ad2d..049921fb4612a4488db0de1fac947c0c51083d68 100644 (file)
@@ -4,7 +4,7 @@
  * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
  * Copyright (c) 2001-2004, The GROMACS development team.
  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
- * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
+ * Copyright (c) 2018,2019,2020,2021, by the GROMACS development team, led by
  * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
  * and including many others, as listed in the AUTHORS file in the
  * top-level source directory and at http://www.gromacs.org.
@@ -540,7 +540,7 @@ int gmx_genion(int argc, char* argv[])
     {
         /* Compute number of ions to be added */
         vol   = det(box);
-        nsalt = gmx::roundToInt(conc * vol * AVOGADRO / 1e24);
+        nsalt = gmx::roundToInt(conc * vol * gmx::c_avogadro / 1e24);
         p_num = abs(nsalt * n_q);
         n_num = abs(nsalt * p_q);
     }