Add support for planar periodic meshes #23
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.
This PR adds support for planar periodic meshes, by streamlining and abstracting the spherical wrapping functionality so that it works to both planar and spherical meshes. For this to work, I've added getter/setter methods for the period attributes that handle the planar periodic / spherical meshes details appropriately. This has also dramatically simplified the spherical wrapping procedure, which was unduly complicated (and insufficient) previously. Testing of new the spherical wrapping for vertex patches has revealed a bug in #12, which produces invalid geometries for vertices along culled boundaries. When these invalid geometries intersect the map projection boundary,
cartopy
struggles with them resulting in the patches spanning the entire plot area. This bug is fixed as part of this PR. Finally, for testing purposes this PR also adds a small planar periodic mesh to the datasets database.Fixes #15.