Checkout common/Domain.h from MassD3Q19 into master
This commit is contained in:
parent
35a4ed8326
commit
7d870a2f4a
@ -105,12 +105,8 @@ struct Domain{
|
||||
}
|
||||
|
||||
private:
|
||||
int d[26][3] = {{1,0,0},{-1,0,0},{0,1,0},{0,-1,0},{0,0,1},{0,0,-1},
|
||||
{1,1,0},{1,-1,0},{-1,1,0},{-1,-1,0},{1,0,1},{-1,0,1},
|
||||
{1,0,-1},{-1,0,-1},{0,1,1},{0,-1,1},{0,1,-1},{0,-1,-1},
|
||||
{1,1,1},{1,1,-1},{1,-1,1},{1,-1,-1},{-1,1,1},{-1,1,-1},
|
||||
|
||||
int getRankForBlock( int i, int j, int k )
|
||||
int getRankForBlock( int i, int j, int k )
|
||||
{
|
||||
int i2 = (i+nprocx)%nprocx;
|
||||
int j2 = (j+nprocy)%nprocy;
|
||||
@ -137,6 +133,12 @@ private:
|
||||
}
|
||||
|
||||
int VoxelConnection(int n){
|
||||
int d[26][3] = {{1,0,0},{-1,0,0},{0,1,0},{0,-1,0},{0,0,1},{0,0,-1},
|
||||
{1,1,0},{1,-1,0},{-1,1,0},{-1,-1,0},{1,0,1},{-1,0,1},
|
||||
{1,0,-1},{-1,0,-1},{0,1,1},{0,-1,1},{0,1,-1},{0,-1,-1},
|
||||
{1,1,1},{1,1,-1},{1,-1,1},{1,-1,-1},{-1,1,1},{-1,1,-1},
|
||||
{-1,-1,1},{-1,-1,-1}}; // directions to neighbors
|
||||
|
||||
int returnVal = -1;
|
||||
int x,y,z;
|
||||
// Get the 3-D indices
|
||||
|
Loading…
Reference in New Issue
Block a user