Repository navigation
Enclosure cylindrical - #1277
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1277 +/- ##
==========================================
+ Coverage 96.05% 96.07% +0.01%
==========================================
Files 57 57
Lines 5070 5069 -1
==========================================
Hits 4870 4870
+ Misses 200 199 -1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
RemDelaporteMathurin
left a comment
There was a problem hiding this comment.
Thanks for this @hhy2022, do you plan to do more with this?
|
Thanks! I was planning to also fix the issue with the weakly enforced |
|
I'm ok with these changes. @jhdark could you give it a look too? The nightly and 0.10 CI don't pass but I think this is a separate issue right? |
|
Merging this now that the backwards compatibility has been fixed. |
Description
Summary
Gas enclosures can now be used on cylindrical and spherical meshes. The surface term of the pressure balance is multiplied by
CoordinateSystem.integration_weight(added in #1264), and theNotImplementedErrorraised for non-cartesian meshes is removed.The value given for each surface in
Enclosure.surfacesis the extent that the mesh and coordinate system cannot provide:Cartesian behaviour is unchanged.
Related Issues
Fixes #1271
Motivation and Context
Type of Change
Testing
pytest)Code Quality Checklist
ruff format .)ruff check .)Documentation
Breaking Changes
Screenshots/Examples
Additional Notes
Known limitation, not addressed here. With a weakly enforced
HenrysBC/SievertsBCcoupled to an enclosure, conservation is exact in cartesian but only approximate on non-cartesian meshes (1D, 60 cells):The drift comes from the symmetry term of the Nitsche formulation in
dirichlet_bc.py, which usesgrad(v). Replacing it withr * grad(v / r)in a local experiment restored exact conservation in cylindrical. This affects every weakly enforced Dirichlet BC on non-cartesian meshes, not only enclosures.