Use constexpr for physical constants and move them into gmx namespace
[alexxy/gromacs.git] / src / gromacs / mdlib / calcmu.cpp
index 83a61bed785e557cc689eb8f72a3a03910ad0389..982faf33e02020aa5a85eb91ec562d5de490faf2 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) 2012,2014,2015,2017,2018 by the GROMACS development team.
- * Copyright (c) 2019,2020, by the GROMACS development team, led by
+ * Copyright (c) 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.
@@ -79,7 +79,7 @@ void calc_mu(int                            start,
 
     for (m = 0; (m < DIM); m++)
     {
-        mu[m] *= ENM2DEBYE;
+        mu[m] *= gmx::c_enm2Debye;
     }
 
     if (nChargePerturbed)
@@ -94,9 +94,9 @@ void calc_mu(int                            start,
             mu_y += qB[i] * x[i][YY];
             mu_z += qB[i] * x[i][ZZ];
         }
-        mu_B[XX] = mu_x * ENM2DEBYE;
-        mu_B[YY] = mu_y * ENM2DEBYE;
-        mu_B[ZZ] = mu_z * ENM2DEBYE;
+        mu_B[XX] = mu_x * gmx::c_enm2Debye;
+        mu_B[YY] = mu_y * gmx::c_enm2Debye;
+        mu_B[ZZ] = mu_z * gmx::c_enm2Debye;
     }
     else
     {