ocean_bc_state_set_edges Subroutine

public pure subroutine ocean_bc_state_set_edges(this, has_west, has_east, has_south, has_north)

Set the physical-domain-edge flags from a decomposition descriptor. Called once by the driver after configure_ocean_bc so kernels can gate wall / BC / periodic closures on physical edges (a subdomain seam is never a wall), and re-derives the rank-local north_fold (the fold is applied only by the rank that owns the north edge). Default .true. keeps single-rank bit-identity.

Arguments

Type IntentOptional Attributes Name
type(ocean_bc_state_t), intent(inout) :: this
logical, intent(in) :: has_west

True when the west edge is a physical domain edge, false at an MPI seam.

logical, intent(in) :: has_east

True when the east edge is a physical domain edge, false at an MPI seam.

logical, intent(in) :: has_south

True when the south edge is a physical domain edge, false at an MPI seam.

logical, intent(in) :: has_north

True when the north edge is a physical domain edge, false at an MPI seam.


Called by

proc~~ocean_bc_state_set_edges~~CalledByGraph proc~ocean_bc_state_set_edges ocean_bc_state_set_edges proc~engine_setup engine_setup proc~engine_setup->proc~ocean_bc_state_set_edges proc~complete_ocean_create complete_ocean_create proc~complete_ocean_create->proc~engine_setup proc~driver_run_ocean driver_run_ocean proc~driver_run_ocean->proc~engine_setup proc~driver_validate driver_validate proc~driver_validate->proc~engine_setup proc~driver_run driver_run proc~driver_run->proc~driver_run_ocean proc~rdb_ocean_create_finalize rdb_ocean_create_finalize proc~rdb_ocean_create_finalize->proc~complete_ocean_create proc~rdb_ocean_create_from_string rdb_ocean_create_from_string proc~rdb_ocean_create_from_string->proc~complete_ocean_create

Source Code

   pure subroutine ocean_bc_state_set_edges(this, has_west, has_east, has_south, has_north)
      !! Set the physical-domain-edge flags from a decomposition descriptor.
      !! Called once by the driver after configure_ocean_bc so kernels can
      !! gate wall / BC / periodic closures on physical edges (a subdomain
      !! seam is never a wall), and re-derives the rank-local `north_fold`
      !! (the fold is applied only by the rank that owns the north edge).
      !! Default .true. keeps single-rank bit-identity.
      type(ocean_bc_state_t), intent(inout) :: this
      logical, intent(in) :: has_west
         !! True when the west edge is a physical domain edge, false at an MPI seam.
      logical, intent(in) :: has_east
         !! True when the east edge is a physical domain edge, false at an MPI seam.
      logical, intent(in) :: has_south
         !! True when the south edge is a physical domain edge, false at an MPI seam.
      logical, intent(in) :: has_north
         !! True when the north edge is a physical domain edge, false at an MPI seam.
      this%has_west = has_west
      this%has_east = has_east
      this%has_south = has_south
      this%has_north = has_north
      ! The tripolar fold is a north-EDGE operation: a rank whose north edge
      ! is an MPI seam must not fold (see `north_fold`).
      this%north_fold = (this%north%bc_type == OBC_TRIPOLAR_FOLD) .and. has_north
   end subroutine ocean_bc_state_set_edges