Tinker9 70bd052 (Thu Nov 9 12:11:35 2023 -0800)
Loading...
Searching...
No Matches
rattle.h
1#pragma once
2#include "ff/energybuffer.h"
3#include "ff/molecule.h"
4
5extern "C"
6{
7 class RATTLE
8 {
9 int foo;
10 };
11
12 class SHAKE
13 {
14 int foo;
15 };
16}
17
18namespace tinker {
21bool useRattle();
22
24
25void rattle(time_prec dt, const pos_prec* xold, const pos_prec* yold,
26 const pos_prec* zold);
27
28void rattle2(time_prec dt, bool do_v);
29
30void shake(time_prec dt, pos_prec* xnew, pos_prec* ynew, pos_prec* znew,
31 const pos_prec* xold, const pos_prec* yold, const pos_prec* zold);
32
33void hcKinetic();
34
35void hcVirial();
36
37void hcCenterOfMass(const pos_prec* atomx, const pos_prec* atomy,
38 const pos_prec* atomz, pos_prec* molx, pos_prec* moly, pos_prec* molz);
40
45
50void hcVelAn(vel_prec s[3][3]);
51
54
56void hcPosAn(pos_prec (*scal)[3]);
57}
58
59//====================================================================//
60// //
61// Global Variables //
62// //
63//====================================================================//
64
65namespace tinker {
69
70TINKER_EXTERN int nratwt; // rattle water
71TINKER_EXTERN int (*iratwt)[3]; // atoms a b c
72TINKER_EXTERN pos_prec (*kratwt)[3]; // lengths ab ac bc
73
74TINKER_EXTERN int nratch; // rattle methine group
75TINKER_EXTERN int (*iratch)[2]; // atoms a b (-C H)
76TINKER_EXTERN pos_prec* kratch; // length ab
77
78TINKER_EXTERN int nratch2; // rattle methylene group
79TINKER_EXTERN int (*iratch2)[3]; // atoms a b c (-C H H)
80TINKER_EXTERN pos_prec (*kratch2)[2]; // lengths ab ac
81
82TINKER_EXTERN int nratch3; // rattle methyl group
83TINKER_EXTERN int (*iratch3)[4]; // atoms a b c d (-C H H H)
84TINKER_EXTERN pos_prec (*kratch3)[3]; // lengths ab ac ad
85
87TINKER_EXTERN int (*irat)[2];
89
91TINKER_EXTERN int (*iratmol)[2];
92
96
97// The "rattle-molecules" on device.
99// center-of-mass positions, momenta, and gradients
107
113}
Definition: rattle.h:8
Definition: rattle.h:13
#define TINKER_EXTERN
Definition: macro.h:108
VirialBufferTraits::type(* VirialBuffer)[VirialBufferTraits::value]
Definition: energybuffer.h:94
int(* iratwt)[3]
int nratwt
energy_prec hc_ekin[3][3]
double * ratcom_massfrac
void hcVirial()
pos_prec * kratch
void hcVelAn(vel_prec s[3][3])
Update velocities by .
pos_prec * ratcom_x
int(* iratch2)[3]
int(* iratch)[2]
energy_prec hc_eksum
int(* irat)[2]
vel_prec * ratcom_vx
int nratmol
pos_prec rateps
virial_prec hc_vir[9]
pos_prec * krat
pos_prec * ratcom_z
void hcKinetic()
vel_prec * ratcom_vy
pos_prec * ratcom_y
int nratch2
vel_prec * ratcom_vz
int nratch3
void shake(time_prec dt, pos_prec *xnew, pos_prec *ynew, pos_prec *znew, const pos_prec *xold, const pos_prec *yold, const pos_prec *zold)
void hcPosIso(pos_prec s)
void hcPosAn(pos_prec(*scal)[3])
bool useRattle()
pos_prec(* kratch2)[2]
void rattle(time_prec dt, const pos_prec *xold, const pos_prec *yold, const pos_prec *zold)
pos_prec * rattle_zold
void hcVelIso(vel_prec s)
Update velocities by .
pos_prec(* kratch3)[3]
pos_prec * rattle_xold
VirialBuffer hc_vir_buf
int(* iratmol)[2]
void rattle2(time_prec dt, bool do_v)
void rattleData(RcOp)
pos_prec(* kratwt)[3]
int(* iratch3)[4]
void hcCenterOfMass(const pos_prec *atomx, const pos_prec *atomy, const pos_prec *atomz, pos_prec *molx, pos_prec *moly, pos_prec *molz)
int nrat
Molecule rattle_dmol
pos_prec * rattle_yold
int nratch
mixed virial_prec
Definition: precision.h:98
mixed pos_prec
Floating-point type for coordinates.
Definition: precision.h:93
mixed time_prec
Floating-point type for time.
Definition: precision.h:90
mixed energy_prec
Floating-point type for total energies.
Definition: precision.h:97
mixed vel_prec
Floating-point type for velocities.
Definition: precision.h:92
ResourceOperation
Definition: rcman.h:46
Definition: testrt.h:9