Skip to content

Add check to avoid overwriting boundary IDs - #26

Open
jvwilliams23 wants to merge 1 commit into
aurora-multiphysics:mainfrom
jvwilliams23:fix-overwriteID
Open

Add check to avoid overwriting boundary IDs#26
jvwilliams23 wants to merge 1 commit into
aurora-multiphysics:mainfrom
jvwilliams23:fix-overwriteID

Conversation

@jvwilliams23

Copy link
Copy Markdown
Contributor

Hi @TheBEllis

This small PR fixes a niche issue that occurs when the input mesh has boundary IDs such as the following: [0,1,3].
The old code would assign part_boundary as n_boundary_ids + 1, which would be boundary 3 (thus overwriting the pre-existing tag).

We add a loop over all boundary ids just to check this one is not already taken. If it is, then we assign the new part_boundary as ID+1 (giving a new boundary as 4 for the example above).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant