ocean_surfflux_init Subroutine

private subroutine ocean_surfflux_init(this, grid)

Type Bound

ocean_surface_flux_t

Arguments

Type IntentOptional Attributes Name
class(ocean_surface_flux_t), intent(inout) :: this
type(hgrid_t), intent(in) :: grid

Variables

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

Source Code

   subroutine ocean_surfflux_init(this, grid)
      class(ocean_surface_flux_t), intent(inout) :: this
      type(hgrid_t), intent(in) :: grid
      integer :: nx, ny
      nx = grid%nx_total
      ny = grid%ny_total
      allocate (this%Q_heat(nx, ny), source=0.0_wp)
      allocate (this%Q_salt(nx, ny), source=0.0_wp)
      this%q_assembled = 0.0_wp
      this%is_init = .true.
   end subroutine ocean_surfflux_init