roquet_recon_dpa_face Subroutine

public pure subroutine roquet_recon_dpa_face(rho0, rho_ref, e_top_l, e_top_r, dz_l, dz_r, t_t_l, t_b_l, t_m_l, t_t_r, t_b_r, t_m_r, s_t_l, s_b_l, s_m_l, s_t_r, s_b_r, s_m_r, dpa_l, dpa_r, parabolic, dpa_face)

boole_dpa_face (the reconstruct-for-pressure cross-face 5-point Boole rule) with the Roquet vertical rule roquet_recon_dpa_intz at the three interior sub-columns – identical sub-columns, weights and summation order; the end points are the columns’ own dpa. 15 inlined Roquet evaluations per face per layer.

Arguments

Type IntentOptional Attributes Name
real(kind=wp), intent(in) :: rho0

Pressure-estimate density / anomaly reference (kg/m^3).

real(kind=wp), intent(in) :: rho_ref

Pressure-estimate density / anomaly reference (kg/m^3).

real(kind=wp), intent(in) :: e_top_l

Left / right shallower-interface heights and thicknesses (m).

real(kind=wp), intent(in) :: e_top_r

Left / right shallower-interface heights and thicknesses (m).

real(kind=wp), intent(in) :: dz_l

Left / right shallower-interface heights and thicknesses (m).

real(kind=wp), intent(in) :: dz_r

Left / right shallower-interface heights and thicknesses (m).

real(kind=wp), intent(in) :: t_t_l

Left / right temperature triples (top, bottom, mean).

real(kind=wp), intent(in) :: t_b_l

Left / right temperature triples (top, bottom, mean).

real(kind=wp), intent(in) :: t_m_l

Left / right temperature triples (top, bottom, mean).

real(kind=wp), intent(in) :: t_t_r

Left / right temperature triples (top, bottom, mean).

real(kind=wp), intent(in) :: t_b_r

Left / right temperature triples (top, bottom, mean).

real(kind=wp), intent(in) :: t_m_r

Left / right temperature triples (top, bottom, mean).

real(kind=wp), intent(in) :: s_t_l

Left / right salinity triples.

real(kind=wp), intent(in) :: s_b_l

Left / right salinity triples.

real(kind=wp), intent(in) :: s_m_l

Left / right salinity triples.

real(kind=wp), intent(in) :: s_t_r

Left / right salinity triples.

real(kind=wp), intent(in) :: s_b_r

Left / right salinity triples.

real(kind=wp), intent(in) :: s_m_r

Left / right salinity triples.

real(kind=wp), intent(in) :: dpa_l

The left / right columns’ own layer dpa (Pa), the end points.

real(kind=wp), intent(in) :: dpa_r

The left / right columns’ own layer dpa (Pa), the end points.

logical, intent(in) :: parabolic

.true. -> PPM curvature.

real(kind=wp), intent(out) :: dpa_face

Along-face mean of g * int rho' dz over the layer (Pa).


Calls

proc~~roquet_recon_dpa_face~~CallsGraph proc~roquet_recon_dpa_face roquet_recon_dpa_face proc~roquet_recon_dpa_intz roquet_recon_dpa_intz proc~roquet_recon_dpa_face->proc~roquet_recon_dpa_intz rdb_roq_spv_p rdb_roq_spv_p proc~roquet_recon_dpa_intz->rdb_roq_spv_p rdb_roq_ts_coeffs rdb_roq_ts_coeffs proc~roquet_recon_dpa_intz->rdb_roq_ts_coeffs

Called by

proc~~roquet_recon_dpa_face~~CalledByGraph proc~roquet_recon_dpa_face roquet_recon_dpa_face proc~compute_fv_mom6_reconstruct_impl compute_fv_mom6_reconstruct_impl proc~compute_fv_mom6_reconstruct_impl->proc~roquet_recon_dpa_face proc~ocean_pressure_force_compute ocean_pressure_force_compute proc~ocean_pressure_force_compute->proc~compute_fv_mom6_reconstruct_impl proc~run_stage run_stage proc~run_stage->proc~ocean_pressure_force_compute proc~run_stage_split run_stage_split proc~run_stage_split->proc~ocean_pressure_force_compute proc~ocean_dyn_step ocean_dyn_step proc~ocean_dyn_step->proc~run_stage 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 proc~engine_step->proc~ocean_dyn_step_split

Variables

Type Visibility Attributes Name Initial
real(kind=wp), private, parameter :: BOOLE_W(N_BOOLE) = [7.0_wp, 32.0_wp, 12.0_wp, 32.0_wp, 7.0_wp]
real(kind=wp), private :: acc
real(kind=wp), private :: dpa_m
real(kind=wp), private :: intz_m
integer, private :: m
real(kind=wp), private :: wl
real(kind=wp), private :: wr

Source Code

   pure subroutine roquet_recon_dpa_face(rho0, rho_ref, &
                                         e_top_l, e_top_r, dz_l, dz_r, &
                                         t_t_l, t_b_l, t_m_l, t_t_r, t_b_r, t_m_r, &
                                         s_t_l, s_b_l, s_m_l, s_t_r, s_b_r, s_m_r, &
                                         dpa_l, dpa_r, parabolic, dpa_face)
      !$acc routine seq
      !! `boole_dpa_face` (the reconstruct-for-pressure cross-face 5-point
      !! Boole rule) with the Roquet vertical rule `roquet_recon_dpa_intz` at
      !! the three interior sub-columns -- identical sub-columns, weights and
      !! summation order; the end points are the columns' own `dpa`.  15
      !! inlined Roquet evaluations per face per layer.
      real(wp), intent(in)  :: rho0, rho_ref
         !! Pressure-estimate density / anomaly reference (kg/m^3).
      real(wp), intent(in)  :: e_top_l, e_top_r, dz_l, dz_r
         !! Left / right shallower-interface heights and thicknesses (m).
      real(wp), intent(in)  :: t_t_l, t_b_l, t_m_l, t_t_r, t_b_r, t_m_r
         !! Left / right temperature triples (top, bottom, mean).
      real(wp), intent(in)  :: s_t_l, s_b_l, s_m_l, s_t_r, s_b_r, s_m_r
         !! Left / right salinity triples.
      real(wp), intent(in)  :: dpa_l, dpa_r
         !! The left / right columns' own layer `dpa` (Pa), the end points.
      logical, intent(in)   :: parabolic
         !! .true. -> PPM curvature.
      real(wp), intent(out) :: dpa_face
         !! Along-face mean of `g * int rho' dz` over the layer (Pa).

      real(wp) :: wr, wl, dpa_m, intz_m, acc
      integer  :: m
      real(wp), parameter :: BOOLE_W(N_BOOLE) = &
                             [7.0_wp, 32.0_wp, 12.0_wp, 32.0_wp, 7.0_wp]

      acc = BOOLE_W(1)*dpa_l + BOOLE_W(N_BOOLE)*dpa_r
      !GCC$ unroll 3
      do m = 2, N_BOOLE - 1
         wr = 0.25_wp*real(m - 1, wp)   ! 0 at the left column .. 1 at the right
         wl = 1.0_wp - wr
         call roquet_recon_dpa_intz(rho0, rho_ref, &
                                    wl*e_top_l + wr*e_top_r, &
                                    wl*dz_l + wr*dz_r, &
                                    wl*t_t_l + wr*t_t_r, &
                                    wl*t_b_l + wr*t_b_r, &
                                    wl*t_m_l + wr*t_m_r, &
                                    wl*s_t_l + wr*s_t_r, &
                                    wl*s_b_l + wr*s_b_r, &
                                    wl*s_m_l + wr*s_m_r, &
                                    parabolic, dpa_m, intz_m)
         acc = acc + BOOLE_W(m)*dpa_m
      end do
      dpa_face = acc/90.0_wp
   end subroutine roquet_recon_dpa_face