shape_matches_interior Function

private pure function shape_matches_interior(h, nx_p, ny_p, nz_p) result(ok)

True iff (nx_p, ny_p, nz_p) matches the live handle’s physical interior shape (grid%nx_phys, grid%ny_phys, multilayer%nz_ml) — the shape every P2 3D setter’s caller- supplied array must have.

Arguments

Type IntentOptional Attributes Name
type(ocean_handle_t), intent(in), pointer :: h
integer(kind=c_int), intent(in) :: nx_p
integer(kind=c_int), intent(in) :: ny_p
integer(kind=c_int), intent(in) :: nz_p

Return Value logical


Called by

proc~~shape_matches_interior~~CalledByGraph proc~shape_matches_interior shape_matches_interior proc~rdb_ocean_set_h rdb_ocean_set_h proc~rdb_ocean_set_h->proc~shape_matches_interior proc~rdb_ocean_set_tracer rdb_ocean_set_tracer proc~rdb_ocean_set_tracer->proc~shape_matches_interior proc~rdb_ocean_set_u rdb_ocean_set_u proc~rdb_ocean_set_u->proc~shape_matches_interior proc~rdb_ocean_set_v rdb_ocean_set_v proc~rdb_ocean_set_v->proc~shape_matches_interior

Source Code

   pure function shape_matches_interior(h, nx_p, ny_p, nz_p) result(ok)
      !! True iff `(nx_p, ny_p, nz_p)` matches the live handle's physical
      !! interior shape (`grid%nx_phys`, `grid%ny_phys`,
      !! `multilayer%nz_ml`) — the shape every P2 3D setter's caller-
      !! supplied array must have.
      type(ocean_handle_t), pointer, intent(in) :: h
      integer(c_int), intent(in) :: nx_p, ny_p, nz_p
      logical :: ok

      ok = (nx_p == h%grid%nx_phys) .and. (ny_p == h%grid%ny_phys) .and. &
           (nz_p == h%state%multilayer%nz_ml)
   end function shape_matches_interior