ice_pass_y Subroutine

private pure subroutine ice_pass_y(grid, metrics, ice, dt_adv, wall_s, wall_n, ok)

Meridional twin of ice_pass_x. Reads the POST-x-pass masses (SIS2 SIS_continuity.F90:170-216).

Arguments

Type IntentOptional Attributes Name
type(hgrid_t), intent(in) :: grid
type(ocean_metrics_t), intent(in) :: metrics
type(ocean_sea_ice_t), intent(inout) :: ice
real(kind=wp), intent(in) :: dt_adv
logical, intent(in) :: wall_s

Zero the south / north tile-edge face (physical, non-periodic).

logical, intent(in) :: wall_n

Zero the south / north tile-edge face (physical, non-periodic).

logical, intent(out) :: ok

Calls

proc~~ice_pass_y~~CallsGraph proc~ice_pass_y ice_pass_y proc~ice_cat_flux_y_impl ice_cat_flux_y_impl proc~ice_pass_y->proc~ice_cat_flux_y_impl proc~ice_gather_flux_y_impl ice_gather_flux_y_impl proc~ice_pass_y->proc~ice_gather_flux_y_impl proc~ice_gather_flux_y_layer_impl ice_gather_flux_y_layer_impl proc~ice_pass_y->proc~ice_gather_flux_y_layer_impl proc~ice_mask_snow_by_ice_impl ice_mask_snow_by_ice_impl proc~ice_pass_y->proc~ice_mask_snow_by_ice_impl proc~ice_mass_update_y_impl ice_mass_update_y_impl proc~ice_pass_y->proc~ice_mass_update_y_impl proc~ice_ride_update_y_impl ice_ride_update_y_impl proc~ice_pass_y->proc~ice_ride_update_y_impl proc~ice_ride_update_y_layer_impl ice_ride_update_y_layer_impl proc~ice_pass_y->proc~ice_ride_update_y_layer_impl proc~ice_validity_reduce_impl ice_validity_reduce_impl proc~ice_pass_y->proc~ice_validity_reduce_impl local local proc~ice_cat_flux_y_impl->local proc~ppm_cell_limiter ppm_cell_limiter proc~ice_cat_flux_y_impl->proc~ppm_cell_limiter proc~ppm_limit_pos ppm_limit_pos proc~ice_cat_flux_y_impl->proc~ppm_limit_pos proc~ppm_limited_slope ppm_limited_slope proc~ice_cat_flux_y_impl->proc~ppm_limited_slope proc~ppm_mirror_h ppm_mirror_h proc~ice_cat_flux_y_impl->proc~ppm_mirror_h proc~volcfl_face volcfl_face proc~ice_cat_flux_y_impl->proc~volcfl_face proc~ice_ride_update_y_impl->local proc~ice_ride_update_y_layer_impl->local reduce reduce proc~ice_validity_reduce_impl->reduce

Called by

proc~~ice_pass_y~~CalledByGraph proc~ice_pass_y ice_pass_y proc~ice_transport_step ice_transport_step proc~ice_transport_step->proc~ice_pass_y proc~engine_step_ice engine_step_ice proc~engine_step_ice->proc~ice_transport_step proc~driver_run_ocean driver_run_ocean proc~driver_run_ocean->proc~engine_step_ice proc~rdb_ocean_step rdb_ocean_step proc~rdb_ocean_step->proc~engine_step_ice proc~driver_run driver_run proc~driver_run->proc~driver_run_ocean

Variables

Type Visibility Attributes Name Initial
integer, private :: l
integer, private :: nghost
integer, private :: nx
integer, private :: ny

Source Code

   pure subroutine ice_pass_y(grid, metrics, ice, dt_adv, wall_s, wall_n, ok)
      !! Meridional twin of `ice_pass_x`.  Reads the POST-x-pass masses
      !! (SIS2 `SIS_continuity.F90:170-216`).
      type(hgrid_t), intent(in) :: grid
      type(ocean_metrics_t), intent(in) :: metrics
      type(ocean_sea_ice_t), intent(inout) :: ice
      real(wp), intent(in) :: dt_adv
      logical, intent(in) :: wall_s, wall_n
         !! Zero the south / north tile-edge face (physical, non-periodic).
      logical, intent(out) :: ok
      integer :: nx, ny, nghost, l

      nx = grid%nx_total
      ny = grid%ny_total
      nghost = grid%nghost

      call ice_cat_flux_y_impl(metrics%wet_T, metrics%dx_cv, metrics%idyT, ice%v_ice, &
                               ice%mca_ice, ice%htot_work, ice%hl_y_work, ice%hr_y_work, &
                               ice%vhtot_work, ice%vh_ice, dt_adv, nghost, grid%ny_phys, &
                               ice%ncat, nx, ny, wall_s, wall_n)
      call ice_cat_flux_y_impl(metrics%wet_T, metrics%dx_cv, metrics%idyT, ice%v_ice, &
                               ice%mca_snow, ice%htot_work, ice%hl_y_work, ice%hr_y_work, &
                               ice%vhtot_work, ice%vh_snow, dt_adv, nghost, grid%ny_phys, &
                               ice%ncat, nx, ny, wall_s, wall_n)
      call ice_mask_snow_by_ice_impl(ice%vh_ice, ice%vh_snow, nx, ny + 1, ice%ncat)

      call ice_gather_flux_y_impl(ice%vh_ice, ice%m_ice, ice%tr_flux_y_work, ice%ncat, nx, ny)
      call ice_ride_update_y_impl(metrics%iareaT, ice%vh_ice, ice%tr_flux_y_work, ice%mca_ice, &
                                  ice%m_ice, dt_adv, ice%ncat, nx, ny)
      do l = 1, ice%nk_ice
         call ice_gather_flux_y_layer_impl(ice%vh_ice, ice%enth_ice, l, ice%tr_flux_y_work, &
                                           ice%ncat, ice%nk_ice, nx, ny)
         call ice_ride_update_y_layer_impl(metrics%iareaT, ice%vh_ice, ice%tr_flux_y_work, &
                                           ice%mca_ice, ice%enth_ice, l, dt_adv, ice%ncat, &
                                           ice%nk_ice, nx, ny)
         call ice_gather_flux_y_layer_impl(ice%vh_ice, ice%sal_ice, l, ice%tr_flux_y_work, &
                                           ice%ncat, ice%nk_ice, nx, ny)
         call ice_ride_update_y_layer_impl(metrics%iareaT, ice%vh_ice, ice%tr_flux_y_work, &
                                           ice%mca_ice, ice%sal_ice, l, dt_adv, ice%ncat, &
                                           ice%nk_ice, nx, ny)
      end do
      call ice_gather_flux_y_layer_impl(ice%vh_snow, ice%enth_snow, 1, ice%tr_flux_y_work, &
                                        ice%ncat, 1, nx, ny)
      call ice_ride_update_y_layer_impl(metrics%iareaT, ice%vh_snow, ice%tr_flux_y_work, &
                                        ice%mca_snow, ice%enth_snow, 1, dt_adv, ice%ncat, &
                                        1, nx, ny)

      call ice_mass_update_y_impl(metrics%iareaT, ice%vh_ice, ice%mca_ice, dt_adv, &
                                  nghost, grid%ny_phys, ice%ncat, nx, ny)
      call ice_mass_update_y_impl(metrics%iareaT, ice%vh_snow, ice%mca_snow, dt_adv, &
                                  nghost, grid%ny_phys, ice%ncat, nx, ny)

      call ice_validity_reduce_impl(ice%mca_ice, ice%mca_snow, nghost, grid%nx_phys, &
                                    grid%ny_phys, ice%ncat, nx, ny, ok)
   end subroutine ice_pass_y