Skip to content

Commit

Permalink
TestArrayGroup: Correct multi-process tests
Browse files Browse the repository at this point in the history
  • Loading branch information
eschnett committed Aug 3, 2023
1 parent f4ab84a commit 4fc5ce4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion TestArrayGroup/src/TestArray.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,14 @@ extern "C" void TestArrayGroup_Initialize(CCTK_ARGUMENTS) {
ierr = CCTK_GrouplshGI(cctkGH, group.dim, lsh.data(), gi);
assert(!ierr);

const int i0 = cctk_lbnd[0];
const int j0 = cctk_lbnd[1];
const int k0 = cctk_lbnd[2];
for (int k = 0; k < lsh[2]; k++) {
for (int j = 0; j < lsh[1]; j++) {
for (int i = 0; i < lsh[0]; i++) {
const int index = CCTK_GFINDEX3D(cctkGH, i, j, k);
test_gf[index] = i * j * k;
test_gf[index] = (i0 + i) * (j0 + j) * (k0 + k);
}
}
}
Expand Down

0 comments on commit 4fc5ce4

Please sign in to comment.