Implement subcell limiting for non-conservative systems#1670
Implement subcell limiting for non-conservative systems#1670amrueda merged 49 commits intotrixi-framework:mainfrom
Conversation
…ative systems -> A working version of this implementation is added for the GLM-MHD system -> The flux-differencing formula requires non-conservative terms of the form (local * symmetric)... I modified equations/ideal_glm_mhd_2d.jl and solvers/dgsem_tree/dg_2d.jl to make it work -> In this first implementation, we only use the Powell term and deactivate the GLM term
…2d.jl back to its original state
…he modified Powell source term. This was needed due to incompatibility on non-conforming meshes.
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 ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1670 +/- ##
==========================================
- Coverage 90.84% 82.73% -8.11%
==========================================
Files 430 431 +1
Lines 34437 34672 +235
==========================================
- Hits 31282 28683 -2599
- Misses 3155 5989 +2834
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
|
I ran a convergence test (5 different meshes and |
|
When running the convergence test documented above, the following performance summary was obtained with the novel subcell limiting for non-conservative systems and one thread: The summary obtained with It is clear that the volume integral with subcell limiting is significantly more expensive than |
Co-authored-by: Hendrik Ranocha <ranocha@users.noreply.github.com>
|
Thanks for your comments, @ranocha! I already applied your suggestions and replied to your questions. Do you have any clue of what might be making my code slow? (see performance post) It seems that my problem is in the function calcflux_fhat!, which is taking a total of As I wrote above,
Do you see any performance issues in calcflux_fhat!? or do you have any idea about how I can speed up that function? |
Did you try starting Julia with the flag |
Yes, the results I reported were obtained with |
Co-authored-by: Michael Schlottke-Lakemper <michael@sloede.com>
Co-authored-by: Michael Schlottke-Lakemper <michael@sloede.com>
…vative equations Co-authored-by: Benjamin Bolm <74359358+bennibolm@users.noreply.github.com>
Co-authored-by: Hendrik Ranocha <ranocha@users.noreply.github.com>
…ut a method Co-authored-by: Michael Schlottke-Lakemper <michael@sloede.com>
Co-authored-by: Michael Schlottke-Lakemper <michael@sloede.com>
This PR extends the subcell limiting strategies implemented in #1476 to non-conservative systems.
To do the subcell limiting, the DGSEM is formulated as a flux-differencing formula. For non-conservative systems, this formulation requires expressing non-conservative terms as the product of both local and symmetric components. I have included an example using the GLM-MHD equations, where the Powell and GLM non-conservative terms have been recast in the format of "local * symmetric."