Gridding Algorithm error with refine boxes
- Dominant language
- C++
- Stars
- 250
- Forks
- 89
- Avg merge
- 34m
- Merged PRs (30d)
- 1
Description
User submitted:
I am trying to use class algs::TimeRefinementIntegrator but I am facing an error which may be a bug or a misconfiguration.
I tried to use 4 levels with "REFINE_BOXES" tagging method and SAMRAI returns an error in the gridding algorithm class:
P=0000000:Failed assertion: !d_hierarchy->levelExists(new_ln + 1) || tag_to_finer
But, If I set 3 levels, the simulation runs smoothly. What is more, if I use 4 levels with "REFINE_BOXES" and "GRADIENT_DETECTOR" (without tagging any cell) it also works.
From what I debugged, the problem comes from a checking of the tagging method if using exclusively fixed refinement. In a specific level, the tag_to_finer variable is not filled and the level to refine already exists, so the exception is raised.
I imagine this is a bug in SAMRAI, since there is no sense that the time refinement integrator works for less than 4 levels but not otherwise when using exclusively FMR.
The error is easily reproducible using applications/LinAdv example. The sphere_4levels.2d.input parameter file may be changed to use the following tagging:
StandardTagAndInitialize {
tagging_method = "REFINE_BOXES"
level_0 {
boxes = [ (5, 0) , (24, 19) ]
}
level_1 {
boxes = [ (15, 5) , (44, 34) ]
}
level_2 {
boxes = [ (35, 15) , (84, 64) ]
}
level_3 {
boxes = [ (75, 35) , (164, 104) ]
}
}
If I am wrong and this is a misconfiguration from my side, please indicate me the problem. Otherwise I hope this bug can be fixed in a proper release.
If you need more information, do not hesitate to ask me.
Contributor guide
Research direction
Reproduce the failure with applications/LinAdv using the sphere_4levels.2d.input configuration and the listed REFINE_BOXES levels. Start by tracing algs::TimeRefinementIntegrator and the assertion involving tag_to_finer and levelExists. Done means determining whether the configuration is valid and making the four-level REFINE_BOXES run complete without the assertion.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- hpc
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100