Skip to content

Commit d19e280

Browse files
committed
teno7 works
1 parent 33d829e commit d19e280

File tree

9 files changed

+63
-128
lines changed

9 files changed

+63
-128
lines changed

case/weno7_test/case.py

Lines changed: 0 additions & 77 deletions
This file was deleted.

src/simulation/m_checker.fpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,14 @@ contains
6666
@:PROHIBIT(weno_order /= 1 .and. f_is_default(weno_eps), &
6767
"weno_order != 1, but weno_eps is not set. A typical value of weno_eps is 1e-6")
6868
@:PROHIBIT(weno_eps <= 0d0, "weno_eps must be positive. A typical value of weno_eps is 1e-6")
69+
@:PROHIBIT(wenoz .and. weno_order == 7 .and. f_is_default(wenoz_q), &
70+
"wenoz is used at 7th order, but wenoz_q is not set. It should be either 2 or 4")
6971
@:PROHIBIT(teno .and. f_is_default(teno_CT), "teno is used, but teno_CT is not set. A typical value of teno_CT is 1e-6")
7072
@:PROHIBIT(teno .and. teno_CT <= 0d0, "teno_CT must be positive. A typical value of teno_CT is 1e-6")
7173
@:PROHIBIT(count([mapped_weno, wenoz, teno]) >= 2, "Only one of mapped_weno, wenoz, or teno can be set to true")
7274
@:PROHIBIT(weno_order == 1 .and. mapped_weno)
7375
@:PROHIBIT(weno_order == 1 .and. wenoz)
74-
@:PROHIBIT(weno_order /= 5 .and. teno)
76+
@:PROHIBIT((weno_order == 1 .or. weno_order == 3) .and. teno)
7577
@:PROHIBIT(weno_order /= 5 .and. mp_weno)
7678
@:PROHIBIT(model_eqns == 1 .and. weno_avg)
7779
end subroutine s_check_inputs_weno

src/simulation/m_global_parameters.fpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ module m_global_parameters
149149

150150
real(kind(0d0)) :: weno_eps !< Binding for the WENO nonlinear weights
151151
real(kind(0d0)) :: teno_CT !< Smoothness threshold for TENO
152+
real(kind(0d0)) :: wenoz_q !< Power constant for WENO-Z
152153
logical :: mp_weno !< Monotonicity preserving (MP) WENO
153154
logical :: weno_avg ! Average left/right cell-boundary states
154155
logical :: weno_Re_flux !< WENO reconstruct velocity gradients for viscous stress tensor
@@ -180,7 +181,7 @@ module m_global_parameters
180181
!$acc declare create(num_dims, weno_polyn, weno_order, num_fluids, wenojs, mapped_weno, wenoz, teno)
181182
#:endif
182183

183-
!$acc declare create(mpp_lim, model_eqns, mixture_err, alt_soundspeed, avg_state, mp_weno, weno_eps, teno_CT, hypoelasticity, low_Mach)
184+
!$acc declare create(mpp_lim, model_eqns, mixture_err, alt_soundspeed, avg_state, mp_weno, weno_eps, teno_CT, wenoz_q, hypoelasticity, low_Mach)
184185

185186
logical :: relax !< activate phase change
186187
integer :: relax_model !< Relaxation model
@@ -528,6 +529,7 @@ contains
528529
time_stepper = dflt_int
529530
weno_eps = dflt_real
530531
teno_CT = dflt_real
532+
wenoz_q = dflt_real
531533
mp_weno = .false.
532534
weno_avg = .false.
533535
weno_Re_flux = .false.
@@ -1109,7 +1111,7 @@ contains
11091111
!$acc update device(cfl_target, m, n, p)
11101112

11111113
!$acc update device(alt_soundspeed, acoustic_source, num_source)
1112-
!$acc update device(dt, sys_size, buff_size, pref, rhoref, gamma_idx, pi_inf_idx, E_idx, alf_idx, stress_idx, mpp_lim, bubbles, hypoelasticity, alt_soundspeed, avg_state, num_fluids, model_eqns, num_dims, mixture_err, grid_geometry, cyl_coord, mp_weno, weno_eps, teno_CT, low_Mach)
1114+
!$acc update device(dt, sys_size, buff_size, pref, rhoref, gamma_idx, pi_inf_idx, E_idx, alf_idx, stress_idx, mpp_lim, bubbles, hypoelasticity, alt_soundspeed, avg_state, num_fluids, model_eqns, num_dims, mixture_err, grid_geometry, cyl_coord, mp_weno, weno_eps, teno_CT, wenoz_q, low_Mach)
11131115

11141116
#:if not MFC_CASE_OPTIMIZATION
11151117
!$acc update device(wenojs, mapped_weno, wenoz, teno)

src/simulation/m_mpi_proxy.fpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ contains
213213
#:endfor
214214
end if
215215
216-
#:for VAR in [ 'dt','weno_eps','teno_CT','pref','rhoref','R0ref','Web','Ca', 'sigma', &
216+
#:for VAR in [ 'dt','weno_eps','wenoz_q','teno_CT','pref','rhoref','R0ref','Web','Ca', 'sigma', &
217217
& 'Re_inv', 'poly_sigma', 'palpha_eps', 'ptgalpha_eps', 'pi_fac', &
218218
& 'bc_x%vb1','bc_x%vb2','bc_x%vb3','bc_x%ve1','bc_x%ve2','bc_x%ve2', &
219219
& 'bc_y%vb1','bc_y%vb2','bc_y%vb3','bc_y%ve1','bc_y%ve2','bc_y%ve3', &

src/simulation/m_rhs.fpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -942,7 +942,7 @@ contains
942942
flux_src_n(id)%vf, &
943943
flux_gsrc_n(id)%vf, &
944944
id, ix, iy, iz)
945-
print *, 'DEBUG riemann_solver completed'
945+
! print *, 'DEBUG riemann_solver completed'
946946
call nvtxEndRange
947947

948948
! Additional physics and source terms ==============================
@@ -2159,7 +2159,7 @@ contains
21592159
integer :: ii
21602160
! Reconstruction in s1-direction ===================================
21612161

2162-
print *, 'DEBUG m_rhs s_reconstruct_cell_boundary_values started'
2162+
! print *, 'DEBUG m_rhs s_reconstruct_cell_boundary_values started'
21632163

21642164
if (norm_dir == 1) then
21652165
is1 = ix; is2 = iy; is3 = iz
@@ -2199,7 +2199,7 @@ contains
21992199
is1, is2, is3)
22002200
end if
22012201

2202-
print *, 'DEBUG m_rhs s_reconstruct_cell_boundary_values ended'
2202+
! print *, 'DEBUG m_rhs s_reconstruct_cell_boundary_values ended'
22032203

22042204
! ==================================================================
22052205
end subroutine s_reconstruct_cell_boundary_values

src/simulation/m_start_up.fpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ contains
136136
t_step_start, t_step_stop, t_step_save, t_step_print, &
137137
model_eqns, mpp_lim, time_stepper, weno_eps, weno_flat, &
138138
riemann_flat, rdma_mpi, cu_tensor, &
139-
teno_CT, mp_weno, weno_avg, &
139+
teno_CT, wenoz_q, mp_weno, weno_avg, &
140140
riemann_solver, low_Mach, wave_speeds, avg_state, &
141141
bc_x, bc_y, bc_z, &
142142
x_domain, y_domain, z_domain, &

src/simulation/m_time_steppers.fpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -630,13 +630,13 @@ contains
630630
end if
631631

632632
call s_compute_rhs(q_cons_ts(1)%vf, q_prim_vf, rhs_vf, pb_ts(1)%sf, rhs_pb, mv_ts(1)%sf, rhs_mv, t_step, time_avg)
633-
print *, 'DEBUG RK3 step 1 compute_rhs completed'
633+
! print *, 'DEBUG RK3 step 1 compute_rhs completed'
634634

635635
! if (run_time_info) then
636636
if (.true.) then ! DEBUG ALWAYS WRITE RUN_TIME INFO
637637
call s_write_run_time_information(q_prim_vf, t_step)
638638
end if
639-
print *, 'DEBUG RK3 step 1 write run_time_information completed'
639+
! print *, 'DEBUG RK3 step 1 write run_time_information completed'
640640
! call exit(66)
641641

642642
if (probe_wrt) then

src/simulation/m_viscous.fpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -997,7 +997,7 @@ contains
997997

998998
! Reconstruction in s1-direction ===================================
999999

1000-
print *, 'DEBUG m_rhs s_reconstruct_cell_boundary_values_visc started'
1000+
! print *, 'DEBUG m_rhs s_reconstruct_cell_boundary_values_visc started'
10011001

10021002
if (norm_dir == 1) then
10031003
is1_viscous = ix; is2_viscous = iy; is3_viscous = iz

0 commit comments

Comments
 (0)