fill_ghost_south_sign Subroutine

private pure subroutine fill_ghost_south_sign(hTr, h_layer, v_layer, nx_total, ny_total, nz, j_s, i0, i1, nghost, clamped_tr_s)

Sign-switch ghost fill for the south edge.

Arguments

Type IntentOptional Attributes Name
real(kind=wp), intent(inout) :: hTr(nx_total,ny_total,nz)
real(kind=wp), intent(in) :: h_layer(nx_total,ny_total,nz)
real(kind=wp), intent(in) :: v_layer(nx_total,ny_total+1,nz)
integer, intent(in) :: nx_total
integer, intent(in) :: ny_total
integer, intent(in) :: nz
integer, intent(in) :: j_s
integer, intent(in) :: i0
integer, intent(in) :: i1
integer, intent(in) :: nghost
real(kind=wp), intent(in) :: clamped_tr_s

Calls

proc~~fill_ghost_south_sign~~CallsGraph proc~fill_ghost_south_sign fill_ghost_south_sign local local proc~fill_ghost_south_sign->local

Called by

proc~~fill_ghost_south_sign~~CalledByGraph proc~fill_ghost_south_sign fill_ghost_south_sign proc~ocean_obc_fill_ghosts ocean_obc_fill_ghosts proc~ocean_obc_fill_ghosts->proc~fill_ghost_south_sign proc~run_continuity_chain run_continuity_chain proc~run_continuity_chain->proc~ocean_obc_fill_ghosts proc~run_stage_split run_stage_split proc~run_stage_split->proc~run_continuity_chain proc~ocean_dyn_step_split ocean_dyn_step_split proc~ocean_dyn_step_split->proc~run_stage_split proc~engine_step engine_step proc~engine_step->proc~ocean_dyn_step_split

Variables

Type Visibility Attributes Name Initial
integer, private :: g
real(kind=wp), private :: hTr_bc
real(kind=wp), private :: hTr_int
integer, private :: i
integer, private :: k

Source Code

   pure subroutine fill_ghost_south_sign(hTr, h_layer, v_layer, &
                                         nx_total, ny_total, nz, &
                                         j_s, i0, i1, nghost, clamped_tr_s)
      !! Sign-switch ghost fill for the south edge.
      integer, intent(in) :: nx_total, ny_total, nz, nghost
      real(wp), intent(inout) :: hTr(nx_total, ny_total, nz)
      real(wp), intent(in)    :: h_layer(nx_total, ny_total, nz)
      real(wp), intent(in)    :: v_layer(nx_total, ny_total + 1, nz)
      integer, intent(in) :: j_s, i0, i1
      real(wp), intent(in) :: clamped_tr_s
      integer :: i, k, g
      real(wp) :: hTr_bc, hTr_int
      do concurrent(k=1:nz, i=i0:i1, g=1:nghost) local(hTr_bc, hTr_int)
         if (v_layer(i, j_s, k) > 0.0_wp) then
            hTr_bc = clamped_tr_s*h_layer(i, g, k)
            hTr(i, g, k) = hTr_bc
         else
            hTr_int = hTr(i, j_s, k)
            hTr(i, g, k) = hTr_int
         end if
      end do
   end subroutine fill_ghost_south_sign