
#include <MultiGrid.h>
Public Member Functions | |
| MultiGrid () | |
| void | anterpolateCharge (Real q, const Vector3D &coord, unsigned int index) |
| void | fineToCoarse (int level, unsigned int block, unsigned int nBlocks) |
| void | fineToCoarse (int level) |
| void | direct (unsigned int block, unsigned int nBlocks) |
| void | direct () |
| void | coarseToFine (int level, unsigned int block, unsigned int nBlocks) |
| void | coarseToFine (int level) |
| void | correction (int level, unsigned int block, unsigned int nBlocks) |
| void | correction (int level) |
| Real | energy (int level, unsigned int block, unsigned int nBlocks) |
| Real | energy (int level) |
| void | interpolateForce (Real q, unsigned int index, Vector3D &force) |
| void | initialize (unsigned int n, Real s, int levels, int nx, int ny, int nz, int interOrder, int ratio, Vector3D min, Vector3D max, Vector3D h, Vector3D origin) |
| void | updateSize (Vector3D min, Vector3D max) |
| void | getV (int level, Real *&begin, Real *&end) |
| void | getQ (int level, Real *&begin, Real *&end) |
| void | clear () |
| Real | sumV (int level) |
| Real | sumQ (int level) |
| void | print (int level) |
| void | printV (int level) |
| void | printQ (int level) |
| void | printConst () |
Private Member Functions | |
| void | precomputeG () |
| void | blocksCorrection (unsigned int nBlocks) |
Private Attributes | |
| std::vector< Array< Real, 3 > > | myQ |
| std::vector< Array< Real, 3 > > | myV |
| Array< Real, 3 > | myGDirect |
| Array< Real, 3 > | myGCorrection |
| int | myGCorrDimX |
| int | myGCorrDimY |
| int | myGCorrDimZ |
| Vector3D | myMin |
| Vector3D | myMax |
| Vector3D | myCMin |
| Vector3D | myCMax |
| Vector3D | myH |
| Vector3D | myOrigin |
| int | myNX |
| int | myNY |
| int | myNZ |
| int | myNXOffset |
| int | myNYOffset |
| int | myNZOffset |
| Real | myHX |
| Real | myHY |
| Real | myHZ |
| Real | myHXr |
| Real | myHYr |
| Real | myHZr |
| std::vector< Int3D > | myScaledParticleIntPositions |
| std::vector< Interpolation3D > | myInterpolations |
| std::vector< TInterpolation > | myGridInterpolation |
| Real | myS |
| Real | myRS |
| int | myInterOrder |
| int | myRatio |
| int | myLevels |
| int | mySigma |
| std::vector< Int3D > | myDim |
| std::vector< Real > | myScale |
| std::vector< std::vector< int > > | myBlocksCorrection |
|
|||||||||
|
|
|
||||||||||||||||||||
|
Interpolation weights for the position and anterpolate the charge q onto grid level 0, q -> Q(0).
|
|
||||||||||
|
|
|
|||||||||
|
|
|
||||||||||
|
|
|
||||||||||||||||||||
|
Interpolates Q from level to level-1, Q(level) -> Q(level-1).
|
|
||||||||||
|
|
|
||||||||||||||||||||
|
Adds the correction term Q(level) -> V(level).
|
|
|||||||||
|
|
|
||||||||||||||||
|
Computes the potential for the top level, Q(maxLevels-1) -> V(maxLevels-1).
|
|
||||||||||
|
|
|
||||||||||||||||||||
|
Computes the energy of a given level, V(level) -> energy.
|
|
||||||||||
|
|
|
||||||||||||||||||||
|
Anterpolates Q from level to level+1, Q(level) -> Q(level+1).
|
|
||||||||||||||||||||
|
|
|
||||||||||||||||||||
|
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
||||||||||||||||||||
|
Interpolates the force from grid, level 0, Q(0) -> force.
|
|
|||||||||
|
|
|
||||||||||
|
|
|
|||||||||
|
|
|
||||||||||
|
|
|
||||||||||
|
|
|
||||||||||
|
|
|
||||||||||
|
|
|
||||||||||||||||
|
Update the length, width and height of the grid according min and max such that anter-/interpolated works regardless order and boundary conditions. In case of non-PBC it adds a border such that all points inside [min,max] are correctly anter-/interpolated. |
|
|||||
|
List of blocks for the correction.
|
|
|||||
|
|
|
|||||
|
|
|
|||||
|
Dimension of the grids.
|
|
|||||
|
Dimensions of G_correction.
|
|
|||||
|
|
|
|||||
|
|
|
|||||
|
G_Correction for other levels, G->V.
|
|
|||||
|
G_direct for top level, G->V.
|
|
|||||
|
Interpolation between grids.
|
|
|||||
|
|
|
|||||
|
h_x at level 0
|
|
|||||
|
1/h_x at level 0
|
|
|||||
|
h_y at level 0
|
|
|||||
|
1/h_y at level 0
|
|
|||||
|
h_z at level 0
|
|
|||||
|
1/h_z at level 0
|
|
|||||
|
Interpolation order.
|
|
|||||
|
Interpolation weights for each particle.
|
|
|||||
|
Number of levels, 0,1,2,...,myLevels-1.
|
|
|||||
|
|
|
|||||
|
|
|
|||||
|
x dimension of the grid level 0
|
|
|||||
|
x index offset between to grid levels
|
|
|||||
|
y dimension of the grid level 0
|
|
|||||
|
y index offset between to grid levels
|
|
|||||
|
z dimension of the grid level 0
|
|
|||||
|
z index offset between to grid levels
|
|
|||||
|
|
|
|||||
|
Arrays of charges.
|
|
|||||
|
Ratio between to levels, usually 2.
|
|
|||||
|
1 / Softening distance
|
|
|||||
|
Softening distance.
|
|
|||||
|
Scaling factor for each level.
|
|
|||||
|
Starting index for anter/-interpolation.
|
|
|||||
|
1 if interpolation weights ...,0 for w=0, 0 else
|
|
|||||
|
Arrays of potentials.
|