@@ -2317,9 +2317,6 @@ subroutine btstep_timeloop(eta, ubt, vbt, uhbt0, Datu, BTCL_u, vhbt0, Datv, BTCL
2317
2317
eta_pred ! A predictor value of eta [H ~> m or kg m-2] like eta
2318
2318
real , dimension (SZIW_(CS),SZJW_(CS)) :: &
2319
2319
p_surf_dyn ! < A dynamic surface pressure under rigid ice [L2 T-2 ~> m2 s-2]
2320
- real , dimension (:,:), pointer :: &
2321
- eta_PF_BT ! A pointer to the eta array (either eta or eta_pred) that
2322
- ! determines the barotropic pressure force [H ~> m or kg m-2]
2323
2320
real :: wt_end ! The weighting of the final value of eta_PF [nondim]
2324
2321
real :: Instep ! The inverse of the number of barotropic time steps to take [nondim]
2325
2322
real :: trans_wt1, trans_wt2 ! The weights used to compute ubt_trans and vbt_trans [nondim]
@@ -2431,8 +2428,6 @@ subroutine btstep_timeloop(eta, ubt, vbt, uhbt0, Datu, BTCL_u, vhbt0, Datv, BTCL
2431
2428
2432
2429
p_surf_dyn(:,:) = 0.0
2433
2430
2434
- if (CS% BT_project_velocity) then ; eta_PF_BT = > eta ; else ; eta_PF_BT = > eta_pred ; endif
2435
-
2436
2431
! Set up the group pass used for halo updates within the barotropic time stepping loops.
2437
2432
call create_group_pass(CS% pass_eta_ubt, eta, CS% BT_Domain)
2438
2433
call create_group_pass(CS% pass_eta_ubt, ubt, vbt, CS% BT_Domain)
@@ -2503,9 +2498,16 @@ subroutine btstep_timeloop(eta, ubt, vbt, uhbt0, Datu, BTCL_u, vhbt0, Datv, BTCL
2503
2498
endif
2504
2499
2505
2500
v_first = (MOD (n+ G% first_direction,2 )==1 )
2506
- call btloop_find_PF(PFu, PFv, isv, iev, jsv, jev, eta_PF_BT, eta_PF, &
2507
- gtot_N, gtot_S, gtot_E, gtot_W, p_surf_dyn, dgeo_de, &
2508
- find_etaav, wt_accel2(n), eta_sum, v_first, G, US, CS)
2501
+
2502
+ if (CS% BT_project_velocity) then
2503
+ call btloop_find_PF(PFu, PFv, isv, iev, jsv, jev, eta, eta_PF, &
2504
+ gtot_N, gtot_S, gtot_E, gtot_W, p_surf_dyn, dgeo_de, &
2505
+ find_etaav, wt_accel2(n), eta_sum, v_first, G, US, CS)
2506
+ else
2507
+ call btloop_find_PF(PFu, PFv, isv, iev, jsv, jev, eta_pred, eta_PF, &
2508
+ gtot_N, gtot_S, gtot_E, gtot_W, p_surf_dyn, dgeo_de, &
2509
+ find_etaav, wt_accel2(n), eta_sum, v_first, G, US, CS)
2510
+ endif
2509
2511
2510
2512
if (v_first) then
2511
2513
! On odd-steps, update v first.
@@ -2734,7 +2736,12 @@ subroutine btstep_timeloop(eta, ubt, vbt, uhbt0, Datu, BTCL_u, vhbt0, Datv, BTCL
2734
2736
if (CS% id_eta_hifreq > 0 ) call post_data(CS% id_eta_hifreq, eta(isd:ied,jsd:jed), CS% diag)
2735
2737
if (CS% id_uhbt_hifreq > 0 ) call post_data(CS% id_uhbt_hifreq, uhbt(IsdB:IedB,jsd:jed), CS% diag)
2736
2738
if (CS% id_vhbt_hifreq > 0 ) call post_data(CS% id_vhbt_hifreq, vhbt(isd:ied,JsdB:JedB), CS% diag)
2737
- if (CS% id_eta_pred_hifreq > 0 ) call post_data(CS% id_eta_pred_hifreq, eta_PF_BT(isd:ied,jsd:jed), CS% diag)
2739
+ if (CS% BT_project_velocity) then
2740
+ ! This diagnostic is redundant in this case and should probably be omitted.
2741
+ if (CS% id_eta_pred_hifreq > 0 ) call post_data(CS% id_eta_pred_hifreq, eta(isd:ied,jsd:jed), CS% diag)
2742
+ else
2743
+ if (CS% id_eta_pred_hifreq > 0 ) call post_data(CS% id_eta_pred_hifreq, eta_pred(isd:ied,jsd:jed), CS% diag)
2744
+ endif
2738
2745
endif
2739
2746
enddo ! end of do n=1,ntimestep
2740
2747
@@ -5740,6 +5747,7 @@ subroutine barotropic_init(u, v, h, Time, G, GV, US, param_file, diag, CS, &
5740
5747
' High Frequency Barotropic zonal velocity' , ' m s-1' , conversion= US% L_T_to_m_s)
5741
5748
CS% id_vbt_hifreq = register_diag_field(' ocean_model' , ' vbt_hifreq' , diag% axesCv1, Time, &
5742
5749
' High Frequency Barotropic meridional velocity' , ' m s-1' , conversion= US% L_T_to_m_s)
5750
+ ! if (.not.CS%BT_project_velocity) & ! The following diagnostic is redundant with BT_project_velocity.
5743
5751
CS% id_eta_pred_hifreq = register_diag_field(' ocean_model' , ' eta_pred_hifreq' , diag% axesT1, Time, &
5744
5752
' High Frequency Predictor Barotropic SSH' , thickness_units, conversion= GV% H_to_MKS)
5745
5753
CS% id_uhbt_hifreq = register_diag_field(' ocean_model' , ' uhbt_hifreq' , diag% axesCu1, Time, &
0 commit comments