Unit test for find_exit_face function #128
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
We discovered that the
find_exit_face
function inpumipic_adjacency.tpp
should not work when theuseBcc
flag istrue
. A test case is added here to demonstrate the failed scenario.Briefly, the function here decides which edge the ray crosses by the index of the minimum of the barycentric coordinates of the ray's destination; this is incorrect. The following picture demonstrates this. Although it has the same destination and the origin is in the same triangle, they will intersect different edges.
I have added the failing test case to fix it in the future.
Note: It uses a mesh called
square2d4elem.msh
and it's added to the pumipic_data repository. It's in this pull request