Skip to content
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

Fix multi-comp axisym HLL #800

Merged
merged 1 commit into from
Feb 8, 2025

Conversation

ChrisZYJ
Copy link
Contributor

@ChrisZYJ ChrisZYJ commented Feb 7, 2025

Description

Fixes multi-component axisymmetric HLL solver.

PR #794 applied the same radial treatment as HLLC, which only fixed the single-component case but was completely unstable for multiple components. This is now fixed by adding the αv/r term for HLL to match the governing equations in cylindrical coordinates.

Also regenerates the test case.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Scope

  • This PR comprises a set of related changes with a common goal

How Has This Been Tested?

Below are 2-components axisymmetric simulations, with a cylindrical fluid 2 at the center.

2mat_bot_HLLC_top_HLL_old.mp4
2mat_bot_HLLC_top_HLL_1st_change.mp4
  • THIS PR HLL top (corrected); HLLC bottom (reference):
2mat_bot_HLLC_top_HLL_fixed.mp4

Checklist

  • I have added comments for the new code
  • I added Doxygen docstrings to the new code
  • I have made corresponding changes to the documentation (docs/)
  • I have added regression tests to the test suite so that people can verify in the future that the feature is behaving as expected
  • I have added example cases in examples/ that demonstrate my new feature performing as expected.
    They run to completion and demonstrate "interesting physics"
  • I ran ./mfc.sh format before committing my code
  • New and existing tests pass locally with my changes, including with GPU capability enabled (both NVIDIA hardware with NVHPC compilers and AMD hardware with CRAY compilers) and disabled
  • This PR does not introduce any repeated code (it follows the DRY principle)
  • I cannot think of a way to condense this code and reduce any introduced additional line count

If your code changes any code source files (anything in src/simulation)

To make sure the code is performing as expected on GPU devices, I have:

  • Checked that the code compiles using NVHPC compilers
  • Checked that the code compiles using CRAY compilers
  • Ran the code on either V100, A100, or H100 GPUs and ensured the new feature performed as expected (the GPU results match the CPU results)
  • Ran the code on MI200+ GPUs and ensure the new features performed as expected (the GPU results match the CPU results)
  • Enclosed the new feature via nvtx ranges so that they can be identified in profiles
  • Ran a Nsight Systems profile using ./mfc.sh run XXXX --gpu -t simulation --nsys, and have attached the output file (.nsys-rep) and plain text results to this PR
  • Ran an Omniperf profile using ./mfc.sh run XXXX --gpu -t simulation --omniperf, and have attached the output file and plain text results to this PR.
  • Ran my code using various numbers of different GPUs (1, 2, and 8, for example) in parallel and made sure that the results scale similarly to what happens if you run without the new code/feature

@ChrisZYJ ChrisZYJ requested review from a team as code owners February 7, 2025 00:47
Copy link

codecov bot commented Feb 7, 2025

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 43.74%. Comparing base (131b41e) to head (8434e72).
Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
src/simulation/m_riemann_solvers.fpp 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master     #800   +/-   ##
=======================================
  Coverage   43.74%   43.74%           
=======================================
  Files          65       65           
  Lines       19039    19039           
  Branches     2332     2332           
=======================================
  Hits         8328     8328           
  Misses       9303     9303           
  Partials     1408     1408           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sbryngelson sbryngelson merged commit 08f02bd into MFlowCode:master Feb 8, 2025
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants