-
Notifications
You must be signed in to change notification settings - Fork 113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add functionality for TimeSeries
callback on UnstructuredMesh2D
#1855
Add functionality for TimeSeries
callback on UnstructuredMesh2D
#1855
Conversation
Review checklistThis checklist is meant to assist creators of PRs (to let them know what reviewers will typically look for) and reviewers (to guide them in a structured review process). Items do not need to be checked explicitly for a PR to be eligible for merging. Purpose and scope
Code quality
Documentation
Testing
Performance
Verification
Created with ❤️ by the Trixi.jl community. |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1855 +/- ##
==========================================
- Coverage 89.44% 87.23% -2.22%
==========================================
Files 438 439 +1
Lines 35593 35734 +141
==========================================
- Hits 31836 31170 -666
- Misses 3757 4564 +807
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Co-authored-by: Hendrik Ranocha <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey Andrew, I just took a look at this during yesterdays meeting and added some quality of life remarks :)
Co-authored-by: Daniel Doehring <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot! I didn't check the implementation in detail but I assume you have already done so.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just added couple comments.
Co-authored-by: Hendrik Ranocha <[email protected]> Co-authored-by: Daniel Doehring <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a great feature, thanks for tackling it!
I forgot to mention in my review: It would be great to update the docs as well, indicating which mesh types are supported (both in the docstring of the callback and the docs in |
There are still normal use cases that fail, I need to work more and make this more robust. |
I updated the docstring but could not find this callback mentioned anywhere else in the docs. |
You're right, sorry. I thought we had mentioned it there, but apparently we didn't. |
We have this: https://github.com/trixi-framework/Trixi.jl/blob/main/docs/src/callbacks.md#time-series. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding this functionality!
Everything looks good already. I just added a few comment suggestions and a question regarding the new strategy.
Since this general discussion links to the |
Co-authored-by: Hendrik Ranocha <[email protected]>
…callback is used without the SaveSolution callback
…e bi-linear interpolation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just have one question about where the additional tests should live.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot!
For now this callback is only reliable on straight-sided unstructured elements. If a curved element contains a time series point then a warning is thrown to inform the user. The callback itself still works and creates data, but it may have errors.I updated my element identification strategy such that this callback now works as expected on curvilinear elements as well. It uses the same Newton approach and reuses the existing mapping and metric functions used in the mesh creation. It took me a bit to realize that we already had all the tools necessary to invert the transfinite interpolation as well. My new strategy to identify if a point lies in a curved element is a bit brute force (it involves computing all the barycenters), so I am open to suggestions to optimize it if it allocates too much or so.