Skip to content

Commit 1cd33ac

Browse files
committed
Correct unit conversion for BS_coeff_h diagnostic
Added missing conversion arguments for the register_diag_field calls for the recently added diagnostics BS_coeff_h and BS_coeff_q. All answers are bitwise identical, but two diagnostics will have corrected dimensional rescaling when EY24_EBT_BS is true.
1 parent e6e0870 commit 1cd33ac

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

src/parameterizations/lateral/MOM_hor_visc.F90

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1816,14 +1816,12 @@ subroutine horizontal_viscosity(u, v, h, uh, vh, diffu, diffv, MEKE, VarMix, G,
18161816
else
18171817
if (use_kh_struct) then
18181818
Kh_BS(I,J) = 0.25*( ((MEKE%Ku(i,j)*VarMix%BS_struct(i,j,k)) + &
1819-
(MEKE%Ku(i+1,j+1)*VarMix%BS_struct(i+1,j+1,k))) + &
1820-
((MEKE%Ku(i+1,j)*VarMix%BS_struct(i+1,j,k)) + &
1821-
(MEKE%Ku(i,j+1)*VarMix%BS_struct(i,j+1,k))) )
1819+
(MEKE%Ku(i+1,j+1)*VarMix%BS_struct(i+1,j+1,k))) + &
1820+
((MEKE%Ku(i+1,j)*VarMix%BS_struct(i+1,j,k)) + &
1821+
(MEKE%Ku(i,j+1)*VarMix%BS_struct(i,j+1,k))) )
18221822
else
1823-
Kh_BS(I,J) = 0.25*( (MEKE%Ku(i,j) + &
1824-
MEKE%Ku(i+1,j+1)) + &
1825-
(MEKE%Ku(i+1,j) + &
1826-
MEKE%Ku(i,j+1)) )
1823+
Kh_BS(I,J) = 0.25*( (MEKE%Ku(i,j) + MEKE%Ku(i+1,j+1)) + &
1824+
(MEKE%Ku(i+1,j) + MEKE%Ku(i,j+1)) )
18271825
endif
18281826
endif
18291827
enddo ; enddo
@@ -3217,9 +3215,9 @@ subroutine hor_visc_init(Time, G, GV, US, param_file, diag, CS, ADp)
32173215

32183216
if (CS%EY24_EBT_BS) then
32193217
CS%id_BS_coeff_h = register_diag_field('ocean_model', 'BS_coeff_h', diag%axesTL, Time, &
3220-
'Backscatter coefficient at h points', 'm2 s-1')
3218+
'Backscatter coefficient at h points', units='m2 s-1', conversion=US%L_to_m**2*US%s_to_T)
32213219
CS%id_BS_coeff_q = register_diag_field('ocean_model', 'BS_coeff_q', diag%axesBL, Time, &
3222-
'Backscatter coefficient at q points', 'm2 s-1')
3220+
'Backscatter coefficient at q points', units='m2 s-1', conversion=US%L_to_m**2*US%s_to_T)
32233221
endif
32243222

32253223
CS%id_FrictWork = register_diag_field('ocean_model','FrictWork',diag%axesTL,Time,&

0 commit comments

Comments
 (0)