mdlib -> imd
mdlib -> ewald
mdlib -> pulling
-topology -> gmxlib
topology -> listed-forces
pbcutil -> fileio
pbcutil -> mdtypes
#include "gromacs/fileio/xvgr.h"
#include "gromacs/gmxana/gmx_ana.h"
#include "gromacs/gmxana/gstat.h"
-#include "gromacs/gmxlib/disre.h"
#include "gromacs/gmxlib/main.h"
#include "gromacs/gmxlib/nrnb.h"
+#include "gromacs/listed-forces/disre.h"
#include "gromacs/math/do_fit.h"
#include "gromacs/math/vec.h"
#include "gromacs/mdlib/force.h"
#include "gromacs/fileio/enxio.h"
#include "gromacs/fileio/trxio.h"
#include "gromacs/gmxana/gmx_ana.h"
-#include "gromacs/gmxlib/disre.h"
+#include "gromacs/listed-forces/disre.h"
#include "gromacs/math/vec.h"
#include "gromacs/mdtypes/md_enums.h"
#include "gromacs/utility/arraysize.h"
* To help us fund GROMACS development, we humbly ask that you cite
* the research papers on the package. Check out http://www.gromacs.org.
*/
-#ifndef GMX_GMXLIB_DISRE_H
-#define GMX_GMXLIB_DISRE_H
+/*! \libinternal \file
+ * \brief
+ * Declares functions for handling distance restraints.
+ *
+ * \inlibraryapi
+ * \ingroup module_listed-forces
+ */
+#ifndef GMX_LISTED_FORCES_DISRE_H
+#define GMX_LISTED_FORCES_DISRE_H
-#include <stdio.h>
+#include <cstdio>
#include "gromacs/topology/ifunc.h"
#include "gromacs/utility/basedefinitions.h"
struct history_t;
struct t_commrec;
struct t_inputrec;
-struct t_state;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-struct t_commrec;
struct t_pbc;
+struct t_state;
-void init_disres(FILE *fplog, const struct gmx_mtop_t *mtop,
- t_inputrec *ir, const struct t_commrec *cr,
- t_fcdata *fcd, t_state *state, gmx_bool bIsREMD);
-/* Initiate *fcd data, must be called once, nbonds is the number
+/*! \brief
+ * Initiates *fcd data.
+ *
+ * Must be called once, nbonds is the number
* of iatoms in the ilist of the idef struct.
* When time averaging is used, the history is initialized in state,
* unless it was read before from a checkpoint file.
* The implementation of distance restraints with -multi
* must differ according to whether REMD is active.
*/
+void init_disres(FILE *fplog, const gmx_mtop_t *mtop,
+ t_inputrec *ir, const t_commrec *cr,
+ t_fcdata *fcd, t_state *state, gmx_bool bIsREMD);
-void calc_disres_R_6(int nfa, const t_iatom *fa, const t_iparams ip[],
- const rvec *x, const struct t_pbc *pbc,
- t_fcdata *fcd, history_t *hist);
-/* Calculates r and r^-3 (inst. and time averaged) for all pairs
+/*! \brief
+ * Calculates r and r^-3 (inst. and time averaged) for all pairs
* and the ensemble averaged r^-6 (inst. and time averaged) for all restraints
*/
+void calc_disres_R_6(int nfa, const t_iatom *fa, const t_iparams ip[],
+ const rvec *x, const t_pbc *pbc,
+ t_fcdata *fcd, history_t *hist);
+//! Calculates the distance restraint forces, return the potential.
t_ifunc ta_disres;
-/* Calculate the distance restraint forces, return the potential */
+//! Copies the new time averages that have been calculated in calc_disres_R_6.
void update_disres_history(t_fcdata *fcd, history_t *hist);
-/* Copy the new time averages that have been calculated in calc_disres_R_6 */
-#ifdef __cplusplus
-}
#endif
-
-#endif /* _disre_h */
#include <algorithm>
-#include "gromacs/gmxlib/disre.h"
#include "gromacs/gmxlib/network.h"
#include "gromacs/gmxlib/nrnb.h"
-#include "gromacs/gmxlib/orires.h"
#include "gromacs/listed-forces/bonded.h"
+#include "gromacs/listed-forces/disre.h"
+#include "gromacs/listed-forces/orires.h"
#include "gromacs/listed-forces/position-restraints.h"
#include "gromacs/math/vec.h"
#include "gromacs/mdlib/force.h"
* To help us fund GROMACS development, we humbly ask that you cite
* the research papers on the package. Check out http://www.gromacs.org.
*/
-#ifndef GMX_GMXLIB_ORIRES_H
-#define GMX_GMXLIB_ORIRES_H
+/*! \libinternal \file
+ * \brief
+ * Declares functions for handling orientation restraints.
+ *
+ * \inlibraryapi
+ * \ingroup module_listed-forces
+ */
+#ifndef GMX_LISTED_FORCES_ORIRES_H
+#define GMX_LISTED_FORCES_ORIRES_H
-#include <stdio.h>
+#include <cstdio>
#include "gromacs/topology/ifunc.h"
-#ifdef __cplusplus
-extern "C" {
-#endif
-
struct gmx_mtop_t;
struct gmx_multisim_t;
struct history_t;
struct t_oriresdata;
struct t_state;
+/*! \brief
+ * Decides whether orientation restraints can work, and initializes
+ * all the orientation restraint stuff in *od (and assumes *od is
+ * already allocated.
+ */
void init_orires(FILE *fplog, const gmx_mtop_t *mtop,
rvec x[],
const t_inputrec *ir,
- const struct t_commrec *cr, t_oriresdata *od,
+ const t_commrec *cr, t_oriresdata *od,
t_state *state);
-/* Decides whether orientation restraints can work, and initializes
- all the orientation restraint stuff in *od (and assumes *od is
- already allocated. */
-real calc_orires_dev(const struct gmx_multisim_t *ms,
- int nfa, const t_iatom fa[], const t_iparams ip[],
- const t_mdatoms *md, const rvec x[],
- const struct t_pbc *pbc, t_fcdata *fcd, history_t *hist);
-/*
+/*! \brief
* Calculates the time averaged D matrices, the S matrix for each experiment.
+ *
* Returns the weighted RMS deviation of the orientation restraints.
*/
+real calc_orires_dev(const gmx_multisim_t *ms,
+ int nfa, const t_iatom fa[], const t_iparams ip[],
+ const t_mdatoms *md, const rvec x[],
+ const t_pbc *pbc, t_fcdata *fcd, history_t *hist);
-void diagonalize_orires_tensors(t_oriresdata *od);
-/*
+/*! \brief
* Diagonalizes the order tensor(s) of the orienation restraints.
+ *
* For each experiment eig containts first 3 eigenvalues and then
* the 3 eigenvectors. The eigenvalues are ordered on magnitude.
*/
+void diagonalize_orires_tensors(t_oriresdata *od);
+//! Prints order parameter, eigenvalues and eigenvectors to the log file.
void print_orires_log(FILE *log, t_oriresdata *od);
-/* Print order parameter, eigenvalues and eigenvectors to the log file */
+//! Calculates the orientation restraint forces.
t_ifunc orires;
-/* Does only the orientation restraint force calculation */
+//! Copies the new time averages that have been calculated in calc_orires_dev.
void update_orires_history(t_fcdata *fcd, history_t *hist);
-/* Copy the new time averages that have been calculated in calc_orires_dev */
-#ifdef __cplusplus
-}
#endif
-
-#endif /* _orires_h */
#include "gromacs/fileio/gmxfio.h"
#include "gromacs/fileio/xtcio.h"
#include "gromacs/gmxlib/chargegroup.h"
-#include "gromacs/gmxlib/disre.h"
#include "gromacs/gmxlib/network.h"
#include "gromacs/gmxlib/nrnb.h"
-#include "gromacs/gmxlib/orires.h"
+#include "gromacs/listed-forces/disre.h"
+#include "gromacs/listed-forces/orires.h"
#include "gromacs/math/units.h"
#include "gromacs/math/vec.h"
#include "gromacs/mdlib/calcmu.h"
#include "gromacs/fileio/enxio.h"
#include "gromacs/fileio/gmxfio.h"
#include "gromacs/fileio/xvgr.h"
-#include "gromacs/gmxlib/disre.h"
#include "gromacs/gmxlib/network.h"
-#include "gromacs/gmxlib/orires.h"
+#include "gromacs/listed-forces/disre.h"
+#include "gromacs/listed-forces/orires.h"
#include "gromacs/math/units.h"
#include "gromacs/math/vec.h"
#include "gromacs/mdlib/constr.h"
#include "gromacs/essentialdynamics/edsam.h"
#include "gromacs/ewald/pme.h"
#include "gromacs/gmxlib/chargegroup.h"
-#include "gromacs/gmxlib/disre.h"
#include "gromacs/gmxlib/gmx_omp_nthreads.h"
#include "gromacs/gmxlib/network.h"
#include "gromacs/gmxlib/nrnb.h"
-#include "gromacs/gmxlib/orires.h"
#include "gromacs/gmxlib/nonbonded/nb_free_energy.h"
#include "gromacs/gmxlib/nonbonded/nb_kernel.h"
#include "gromacs/gmxlib/nonbonded/nonbonded.h"
#include "gromacs/imd/imd.h"
#include "gromacs/listed-forces/bonded.h"
+#include "gromacs/listed-forces/disre.h"
+#include "gromacs/listed-forces/orires.h"
#include "gromacs/math/units.h"
#include "gromacs/math/vec.h"
#include "gromacs/math/vecdump.h"
#include "gromacs/domdec/domdec_struct.h"
#include "gromacs/fileio/confio.h"
-#include "gromacs/gmxlib/disre.h"
#include "gromacs/gmxlib/gmx_omp_nthreads.h"
#include "gromacs/gmxlib/network.h"
#include "gromacs/gmxlib/nrnb.h"
-#include "gromacs/gmxlib/orires.h"
+#include "gromacs/listed-forces/disre.h"
+#include "gromacs/listed-forces/orires.h"
#include "gromacs/math/units.h"
#include "gromacs/math/vec.h"
#include "gromacs/math/vecdump.h"
#include "ifunc.h"
-#include "gromacs/gmxlib/disre.h"
-#include "gromacs/gmxlib/orires.h"
#include "gromacs/listed-forces/bonded.h"
+#include "gromacs/listed-forces/disre.h"
+#include "gromacs/listed-forces/orires.h"
#define def_bonded(str, lstr, nra, nrpa, nrpb, ind, func) \
{str, lstr, (nra), (nrpa), (nrpb), IF_BOND, (ind), (func)}
#include "gromacs/fileio/oenv.h"
#include "gromacs/fileio/tpxio.h"
#include "gromacs/fileio/trx.h"
-#include "gromacs/gmxlib/disre.h"
#include "gromacs/gmxlib/gmx_detect_hardware.h"
#include "gromacs/gmxlib/gmx_omp_nthreads.h"
#include "gromacs/gmxlib/main.h"
#include "gromacs/gmxlib/md_logging.h"
#include "gromacs/gmxlib/network.h"
-#include "gromacs/gmxlib/orires.h"
#include "gromacs/gmxlib/sighandler.h"
#include "gromacs/gmxlib/thread_affinity.h"
#include "gromacs/gmxlib/gpu_utils/gpu_utils.h"
+#include "gromacs/listed-forces/disre.h"
+#include "gromacs/listed-forces/orires.h"
#include "gromacs/math/calculate-ewald-splitting-coefficient.h"
#include "gromacs/math/vec.h"
#include "gromacs/mdlib/calc_verletbuf.h"