Fixed bugs in swap algorithm for D3Q19, checked D3Q7 also which I think was right

This commit is contained in:
James McClure
2016-07-25 11:09:05 -04:00
parent f6a0d331be
commit 1cc1c82427
3 changed files with 3 additions and 3 deletions

View File

@@ -106,7 +106,7 @@ extern "C" void SwapD3Q19(char *ID, double *disteven, double *distodd, int Nx, i
//.......Back out the 3-D indices for node n..............
k = n/(Nx*Ny);
j = (n-Nx*Ny*k)/Nx;
i = n-Nx*Ny*k-Nz*j;
i = n-Nx*Ny*k-Nx*j;
if (ID[n] > 0){
//........................................................................