NAMD
PmeKSpace.h
Go to the documentation of this file.
1 
7 #ifndef PME_K_SPACE_H__
8 #define PME_K_SPACE_H__
9 
10 #include "PmeBase.h"
11 #include "Lattice.h"
12 
13 #include "ComputeMoa.h"
14 #include "ComputeMoaMgr.decl.h"
15 
16 class PmeKSpace {
17 #ifdef OPENATOM_VERSION
18  friend class ComputeMoaMgr;
19 #endif //OPENATOM_VERSION
20 
21 public:
22  PmeKSpace(PmeGrid grid, int K2_start, int K2_end, int K3_start, int K3_end);
23 #ifdef OPENATOM_VERSION
24  PmeKSpace(PmeGrid grid, int K2_start, int K2_end, int K3_start, int K3_end, CProxy_ComputeMoaMgr moaProxy);
25 #endif //OPENATOM_VERSION
26  ~PmeKSpace();
27 
28  double compute_energy(float q_arr[], const Lattice &lattice, double ewald, double virial[], int useCkLoop);
29  double compute_energy_orthogonal_helper(float q_arr[], const Lattice &lattice, double ewald, double virial[]);
30  void compute_energy_orthogonal_subset(float q_arr[], double *recips, double partialVirial[], double *partialEnergy, int k1from, int k1to);
31 
32 
33 private:
34  // b-spline moduli
35  double *bm1, *bm2, *bm3;
36  double *exp1, *exp2, *exp3;
37  double i_pi_volume, piob;
38 
39  const PmeGrid myGrid;
40  const int k2_start, k2_end, k3_start, k3_end;
41 
42  void init_exp(double *xp, int K, int k_start, int k_end, double recip);
43 };
44 
45 #endif
void compute_energy_orthogonal_subset(float q_arr[], double *recips, double partialVirial[], double *partialEnergy, int k1from, int k1to)
Definition: PmeKSpace.C:135
static void init_exp(float *xp, int K, float recip, float kappa)
Definition: ComputeEwald.C:290
double compute_energy(float q_arr[], const Lattice &lattice, double ewald, double virial[], int useCkLoop)
Definition: PmeKSpace.C:321
~PmeKSpace()
Definition: PmeKSpace.C:125
double compute_energy_orthogonal_helper(float q_arr[], const Lattice &lattice, double ewald, double virial[])
Definition: PmeKSpace.C:240
PmeKSpace(PmeGrid grid, int K2_start, int K2_end, int K3_start, int K3_end)
Definition: PmeKSpace.C:63