NAMD
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
PmePencilX Class Reference

#include <PmeSolver.h>

Inheritance diagram for PmePencilX:

Public Member Functions

PmePencilX_SDAG_CODE PmePencilX ()
 
 PmePencilX (CkMigrateMessage *m)
 
virtual ~PmePencilX ()
 

Protected Member Functions

void initBlockSizes ()
 

Protected Attributes

PmeGrid pmeGrid
 
bool doEnergy
 
bool doVirial
 
int simulationStep
 
std::array< FFTCompute *, NUM_GRID_MAXfftComputes
 
std::array< PmeTranspose *, NUM_GRID_MAXpmeTransposes
 
std::vector< int > blockSizes
 
Lattice lattice
 
int numStrayAtoms
 
int imsg
 

Detailed Description

Definition at line 200 of file PmeSolver.h.

Constructor & Destructor Documentation

◆ PmePencilX() [1/2]

PmePencilX::PmePencilX ( )

Definition at line 422 of file PmeSolver.C.

References fftComputes, NUM_GRID_MAX, numStrayAtoms, and pmeTransposes.

422  {
423  __sdag_init();
424  setMigratable(false);
425  for (unsigned int iGrid = 0; iGrid < NUM_GRID_MAX; ++iGrid) {
426  pmeTransposes[iGrid] = NULL;
427  fftComputes[iGrid] = NULL;
428  }
429  numStrayAtoms = 0;
430 }
const unsigned int NUM_GRID_MAX
Definition: PmeSolverUtil.h:9
std::array< PmeTranspose *, NUM_GRID_MAX > pmeTransposes
Definition: PmeSolver.h:211
std::array< FFTCompute *, NUM_GRID_MAX > fftComputes
Definition: PmeSolver.h:210
int numStrayAtoms
Definition: PmeSolver.h:214

◆ PmePencilX() [2/2]

PmePencilX::PmePencilX ( CkMigrateMessage *  m)

Definition at line 432 of file PmeSolver.C.

References NAMD_bug().

432  {
433  NAMD_bug("PmePencilX cannot be migrated");
434 //__sdag_init();
435  // setMigratable(false);
436  // fftCompute = NULL;
437  // pmeTranspose = NULL;
438 }
void NAMD_bug(const char *err_msg)
Definition: common.C:195

◆ ~PmePencilX()

PmePencilX::~PmePencilX ( )
virtual

Definition at line 440 of file PmeSolver.C.

References fftComputes, NUM_GRID_MAX, and pmeTransposes.

440  {
441  for (unsigned int iGrid = 0; iGrid < NUM_GRID_MAX; ++iGrid) {
442  if (pmeTransposes[iGrid] != NULL) delete pmeTransposes[iGrid];
443  if (fftComputes[iGrid] != NULL) delete fftComputes[iGrid];
444  }
445 }
const unsigned int NUM_GRID_MAX
Definition: PmeSolverUtil.h:9
std::array< PmeTranspose *, NUM_GRID_MAX > pmeTransposes
Definition: PmeSolver.h:211
std::array< FFTCompute *, NUM_GRID_MAX > fftComputes
Definition: PmeSolver.h:210

Member Function Documentation

◆ initBlockSizes()

void PmePencilX::initBlockSizes ( )
protected

Definition at line 475 of file PmeSolver.C.

References blockSizes, getBlockDim(), Perm_cX_Y_Z, pmeGrid, and PmeGrid::xBlocks.

475  {
476  blockSizes.resize(pmeGrid.xBlocks);
477  for (int x=0;x < pmeGrid.xBlocks;x++) {
478  int i0, i1, j0, j1, k0, k1;
479  getBlockDim(pmeGrid, Perm_cX_Y_Z, x, thisIndex.y, thisIndex.z,
480  i0, i1, j0, j1, k0, k1);
481  int size = (i1-i0+1)*(j1-j0+1)*(k1-k0+1);
482  blockSizes[x] = size;
483  }
484 }
std::vector< int > blockSizes
Definition: PmeSolver.h:212
static void getBlockDim(const PmeGrid &pmeGrid, const int permutation, const int iblock, const int jblock, const int kblock, int &i0, int &i1, int &j0, int &j1, int &k0, int &k1)
Definition: PmeSolverUtil.h:89
int xBlocks
Definition: PmeBase.h:25
PmeGrid pmeGrid
Definition: PmeSolver.h:207

Member Data Documentation

◆ blockSizes

std::vector<int> PmePencilX::blockSizes
protected

Definition at line 212 of file PmeSolver.h.

Referenced by initBlockSizes().

◆ doEnergy

bool PmePencilX::doEnergy
protected

Definition at line 208 of file PmeSolver.h.

◆ doVirial

bool PmePencilX::doVirial
protected

Definition at line 208 of file PmeSolver.h.

◆ fftComputes

std::array<FFTCompute*, NUM_GRID_MAX> PmePencilX::fftComputes
protected

Definition at line 210 of file PmeSolver.h.

Referenced by PmePencilX(), and ~PmePencilX().

◆ imsg

int PmePencilX::imsg
protected

Definition at line 216 of file PmeSolver.h.

◆ lattice

Lattice PmePencilX::lattice
protected

Definition at line 213 of file PmeSolver.h.

◆ numStrayAtoms

int PmePencilX::numStrayAtoms
protected

Definition at line 214 of file PmeSolver.h.

Referenced by PmePencilX().

◆ pmeGrid

PmeGrid PmePencilX::pmeGrid
protected

Definition at line 207 of file PmeSolver.h.

Referenced by initBlockSizes().

◆ pmeTransposes

std::array<PmeTranspose*, NUM_GRID_MAX> PmePencilX::pmeTransposes
protected

Definition at line 211 of file PmeSolver.h.

Referenced by PmePencilX(), and ~PmePencilX().

◆ simulationStep

int PmePencilX::simulationStep
protected

Definition at line 209 of file PmeSolver.h.


The documentation for this class was generated from the following files: