Skip to content

Commit

Permalink
Fix Axisymmetric HLL (#794)
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisZYJ authored Jan 28, 2025
1 parent 43812d8 commit 03fbbe1
Show file tree
Hide file tree
Showing 4 changed files with 216 additions and 0 deletions.
25 changes: 25 additions & 0 deletions src/simulation/m_riemann_solvers.fpp
Original file line number Diff line number Diff line change
Expand Up @@ -858,6 +858,31 @@ contains
flux_src_rs${XYZ}$_vf(j, k, l, i) = 0._wp
end do
end if
#:if (NORM_DIR == 2)
if (cyl_coord) then
!Substituting the advective flux into the inviscid geometrical source flux
!$acc loop seq
do i = 1, E_idx
flux_gsrc_rs${XYZ}$_vf(j, k, l, i) = flux_rs${XYZ}$_vf(j, k, l, i)
end do
! Recalculating the radial momentum geometric source flux
flux_gsrc_rs${XYZ}$_vf(j, k, l, contxe + dir_idx(1)) = &
(s_M*(rho_R*vel_R(dir_idx(1)) &
*vel_R(dir_idx(1))) &
- s_P*(rho_L*vel_L(dir_idx(1)) &
*vel_L(dir_idx(1))) &
+ s_M*s_P*(rho_L*vel_L(dir_idx(1)) &
- rho_R*vel_R(dir_idx(1)))) &
/(s_M - s_P)
! Geometrical source of the void fraction(s) is zero
!$acc loop seq
do i = advxb, advxe
flux_gsrc_rs${XYZ}$_vf(j, k, l, i) = 0._wp
end do
end if
#:endif
end do
end do
end do
Expand Down
176 changes: 176 additions & 0 deletions tests/6FE484B5/golden-metadata.txt

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions tests/6FE484B5/golden.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions toolchain/mfc/test/cases.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ def alter_2d():

cases.append(define_case_d(stack, "model_eqns=2", {'model_eqns': 2}))
cases.append(define_case_d(stack, "model_eqns=3", {'model_eqns': 3}))
cases.append(define_case_d(stack, "HLL", {'riemann_solver': 1}))

stack.push("Viscous", {
'fluid_pp(1)%Re(1)' : 0.0001, 'fluid_pp(1)%Re(2)' : 0.0001,
Expand Down

0 comments on commit 03fbbe1

Please sign in to comment.