Skip to content

Commit

Permalink
working on 4.49
Browse files Browse the repository at this point in the history
  • Loading branch information
edwardhartnett committed Jul 2, 2024
1 parent 55dffdc commit eb61eca
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 6 deletions.
18 changes: 13 additions & 5 deletions src/grib2_all_tables_module.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2532,7 +2532,10 @@ end subroutine g2sec4_temp48
!> @param[in] lvl_type2 - Type of second fixed surfaced (see Code table 4.5)
!> @param[in] scale_fac2 - Scale factor of second fixed surface
!> @param[in] scaled_val2 - Scaled value of second fixed surfaces
!> @param[out] ipdstmpl49 - GRIB2 PDS Template 4.48 listing
!> @param[in] type_ens_fcst_key Type of ensemble forecast (see Code table 4.6)
!> @param[in] perturb_num Perturbation ensemble number
!> @param[in] num_fcst_ens number of forecasts in ensemble
!> @param[out] ipdstmpl49 - GRIB2 PDS Template 4.49 listing
!>
!> @author Edward Hartnett @date 2024-07-02
subroutine g2sec4_temp49(icatg, iparm, aer_type, typ_intvl_size, &
Expand All @@ -2544,19 +2547,22 @@ subroutine g2sec4_temp49(icatg, iparm, aer_type, typ_intvl_size,
hrs_obs_cutoff, min_obs_cutoff, &
unit_of_time_key, fcst_time, lvl_type1, scale_fac1, &
scaled_val1, lvl_type2, scale_fac2, scaled_val2, &
type_ens_fcst_key, perturb_num, num_fcst_ens, &
ipdstmpl49)

integer(4), intent(in) :: icatg, iparm, hrs_obs_cutoff, min_obs_cutoff, &
scale_fac1_size, scale_fac2_size, scale_fac1_wavelength, &
scale_fac2_wavelength, &
fcst_time, scale_fac1, scaled_val1, &
scale_fac2, scaled_val2
integer(4),intent(in) :: perturb_num, num_fcst_ens
real, intent(in) :: scale_val1_size, scale_val2_size, scale_val1_wavelength, &
scale_val2_wavelength

character(len=*), intent(in) :: aer_type, typ_intvl_size, &
typ_intvl_wavelength, typ_gen_proc_key, &
gen_proc_or_mod_key, unit_of_time_key, lvl_type1, lvl_type2
gen_proc_or_mod_key, unit_of_time_key, lvl_type1, lvl_type2, &
type_ens_fcst_key

integer(4), intent(inout) :: ipdstmpl49(29)

Expand Down Expand Up @@ -2611,9 +2617,11 @@ subroutine g2sec4_temp49(icatg, iparm, aer_type, typ_intvl_size,

ipdstmpl49(25) = scale_fac2
ipdstmpl49(26) = scaled_val2
ipdstmpl49(27) = 0
ipdstmpl49(28) = 0
ipdstmpl49(29) = 0

call get_g2_typeofensfcst(type_ens_fcst_key, value, ierr)
ipdstmpl49(27) = value
ipdstmpl49(28) = perturb_num
ipdstmpl49(29) = num_fcst_ens

end subroutine g2sec4_temp49

Expand Down
3 changes: 2 additions & 1 deletion tests/test_all_table_other.F90
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,8 @@ program test_all_table_other
print *, 'testing g2sec4_temp49'
call g2sec4_temp49(0, 1, 'methane', 'greater_than_first_limit', 4, 5.0, 6, 7.0, &
'greater_or_equal_first_limit', 9, 10., 11, 12., 'prob_wt_fcst', 'prob_st_surg', 15, 16, &
'second', 18, 'isothermal', 20, 21, 'isobaric_sfc', 22, 23, ipdstmpl49)
'second', 18, 'isothermal', 20, 21, 'isobaric_sfc', 22, 23, &
'unpert_hi_res_ctrl_fcst', 0, 0, ipdstmpl49)
do i = 1, 29
print *, ipdstmpl49(i)
if (ipdstmpl49(i) .ne. ipdstmpl49_expected(i)) stop 65
Expand Down

0 comments on commit eb61eca

Please sign in to comment.