Interface condition diagnostic#1169
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1169 +/- ##
==========================================
- Coverage 94.76% 93.62% -1.15%
==========================================
Files 46 46
Lines 3534 3590 +56
==========================================
+ Hits 3349 3361 +12
- Misses 185 229 +44 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
@RemDelaporteMathurin So far, this only interpolates the values of the residual onto a function which lives on the interface, but maybe we could also add something additional to the logger, like obtaining the max absolute value from the function? Let me know what you think |
| left = interface_condition_term( | ||
| self._u_0.x.array, K_S_0, self._law_0, self._law_1 | ||
| ) | ||
| right = interface_condition_term( | ||
| self._u_1.x.array, K_S_1, self._law_1, self._law_0 | ||
| ) | ||
| self.function.x.array[:] = right - left |
There was a problem hiding this comment.
i think using .x.array for this might be risky since it assumes they ordered wrt dofs in the exact same way, which might not be True.
the proper way to do it is to make a fem.Expression object with u_0/K_s - u_1/K_s and then interpolate it in self.function
RemDelaporteMathurin
left a comment
There was a problem hiding this comment.
- Logging: yes!
- We also need to be able to export not only the residual c/s - c/s but c/s itself
Description
Fix for issue #1180
Summary
This PR adds an additional export which evaluates the residual of the interface condition, which should confirm whether the penalty term used is high enough to enforce the condition properly.
Here is a small MWE which plots the max value of the residual against the penalty term used in both Sievert-Sieverts and Sieverts-Henry cases:
Related Issues
Motivation and Context
Type of Change
Testing
pytest)Code Quality Checklist
ruff format .)ruff check .)Documentation
Breaking Changes
Screenshots/Examples
Additional Notes