CactusTest/TestArray outputs unitialized data for gf4d

Create issue
Issue #1526 closed
Roland Haas created an issue

the current test arrays in CactusTest/TestArrays does not initialize the 4d array that it outputs. The data in the test output files apparently ended up being zero in the past but gives me poison on my machine right now.

The attached patch adds the required code to fill in the 4d array the same way that the 0d-3d arrays are filled in.

Passes the tests if I copy the 3d output files onto the 4d ones.

Keyword: CactusTest

Comments (6)

  1. Frank Löffler
    • changed status to open
    • removed comment

    The patch calls

    CCTK_GrouplbndGI(ierr,cctkGH,4,lbnd_4d,groupindex3)
    

    in a few places. Shouldn't it be groupindex4? Similarly 'varindex3'.

    Also, just minor, could line 316:

    & (lbnd_4d(3)+k)*(lbnd_4d(4)+m)
    

    be lined up such that these terms align with the ones on the previous line?

  2. Roland Haas reporter
    • changed status to open
    • removed comment

    Quite simple code. Will apply on Feb 1st unless objections are raised.

  3. Roland Haas reporter
    • changed status to resolved
    • removed comment

    Replying to [comment:3 knarf]:

    The patch calls CCTK_GrouplbndGI(ierr,cctkGH,4,lbnd_4d,groupindex3) in a few places. Shouldn't it be groupindex4? Similarly 'varindex3'. Fixed. Thank you for spotting this.

    Also, just minor, could line 316: & (lbnd_4d(3)+k)*(lbnd_4d(4)+m) be lined up such that these terms align with the ones on the previous line? Yes, in principle it should be. I have modifid the patch to mirror the alignement of the 3d grid function loop which aligns the "(" with the "i" of the line above. This was what I had initially intended but was off by one space.

    Applied as rev 68 of TestArray.

  4. Log in to comment