Skip to content

Commit 7edb244

Browse files
committed
minor changes to core code used to generate results for JFM revision one
1 parent ce1bc33 commit 7edb244

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

RKLM_Python/inputs/boundary.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -463,11 +463,13 @@ def rayleigh_damping(Sol, mpv, ud, elem, node, forcing=None):
463463
C = ud.Cs * ud.u_ref
464464
Gam = N * G / C
465465
Om = ud.coriolis_strength[2] / 2.0 / ud.t_ref
466+
# Om = 7.292 * 1e-5 / ud.t_ref
466467
growth_rate = np.sqrt(Om * C * Gam)
467468
mfac = np.exp(growth_rate * t * ud.t_ref)
468469

469470
# if np.all(ud.coriolis_strength) == 0.0:
470-
# mfac = 1.0
471+
# if ud.trad_forcing:
472+
# mfac = 1.0
471473
else:
472474
mfac = 1.0
473475

RKLM_Python/inputs/lamb_wave_perturb.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ def __init__(self):
4040
self.gamm = self.gamma
4141
self.Rg_over_Rv = self.R_gas / self.R_vap
4242
self.Q = self.Q_vap / (self.R_gas * self.T_ref)
43+
self.R_gas = self.R_gas
4344
self.Rg = self.R_gas / (self.h_ref**2 / self.t_ref**2 / self.T_ref)
4445
self.cp_gas = self.cp_gas
4546

@@ -263,7 +264,7 @@ def sol_init(Sol, mpv, elem, node, th, ud, seeds=None):
263264

264265
ud.forcing_tcy, ud.forcing_tny = get_bottom_tau_y(ud, elem, node, 0.2, cutoff=0.3)
265266

266-
A0 = 1.0e-3
267+
A0 = 1.0e-1 / ud.u_ref
267268
Msq = ud.Msq
268269
g = ud.gravity_strength[1] * ud.Rg
269270

@@ -350,4 +351,9 @@ def sol_init(Sol, mpv, elem, node, th, ud, seeds=None):
350351
if ud.mixed_run:
351352
ud.coriolis_strength[2] = 2.0 * 7.292 * 1e-5 * ud.t_ref
352353

354+
if hasattr(ud, 'trad_forcing'):
355+
if ud.trad_forcing:
356+
ud.rf_bot.F = 0.0
357+
ud.rf_bot.get_T_matrix()
358+
353359
return Sol

RKLM_Python/management/data.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ def time_update(Sol,flux,mpv,t,tout,ud,elem,node,steps,th,bld=None,writer=None,d
207207

208208
pi = mpv_half_new.p2_nodes
209209

210-
boundary.rayleigh_damping(Sol, mpv, ud, [up, vp, Yp, pi, t+0.5*dt])
210+
boundary.rayleigh_damping(Sol, mpv, ud, elem, node, [up, vp, Yp, pi, t+0.5*dt])
211211

212212
elif ud.rayleigh_forcing_type == 'func':
213213
# boundary.set_explicit_boundary_data(Sol, elem, ud, th, mpv)
@@ -349,7 +349,7 @@ def time_update(Sol,flux,mpv,t,tout,ud,elem,node,steps,th,bld=None,writer=None,d
349349
# Yp = 0.0
350350
pi = mpv_half_new.p2_nodes
351351

352-
boundary.rayleigh_damping(Sol, mpv, ud, [up, vp, Yp, pi, t+dt])
352+
boundary.rayleigh_damping(Sol, mpv, ud, elem, node, [up, vp, Yp, pi, t+dt])
353353

354354
elif ud.rayleigh_forcing_type == 'func':
355355

0 commit comments

Comments
 (0)