Merge remote-tracking branch 'origin/release-v4.6.1'
[WRF.git] / var / da / da_radar / da_radar.f90
blob507a5df0b8f54bca00ba1f87351a6e058a198b72
1 module da_radar
3 use module_domain, only : domain
4 use module_dm, only : wrf_dm_sum_real
5 use da_control, only : obs_qc_pointer,max_ob_levels,missing_r, &
6 v_interp_p, v_interp_h, check_max_iv_print, trace_use, &
7 missing, max_error_uv, max_error_t, rootproc, &
8 max_error_p,max_error_q, check_max_iv_unit,check_max_iv, &
9 max_stheight_diff,missing_data,max_error_bq,max_error_slp, &
10 max_error_bt, max_error_buv, radar,fails_error_max, &
11 use_radar_rv, use_radar_rf,radar_rf_opt,radar_rf_rscl,radar_rv_rscl,rf_noice,rfmin, rf_qthres, &
12 use_radar_rhv, use_radar_rqv, radar_rhv_opt,&
13 below_model_surface,mkz,above_model_lid,&
14 fg_format,fg_format_wrf_arw_regional,fg_format_wrf_nmm_regional,fg_format_wrf_arw_global,&
15 fg_format_kma_global,max_error_rv,max_error_rf, &
16 far_below_model_surface,kms,kme,kts,kte, trace_use_dull,filename_len,&
17 myproc, analysis_date, num_procs , ierr, comm, es_beta, es_gamma, a_ew
18 use da_control, only : its, ite, jts, jte, ids, ide, jds, jde, ims, ime, jms, jme, ips, ipe, jps, jpe, kds, kde
19 use da_control, only : cloudbase_calc_opt, &
20 radar_non_precip_rf, radar_non_precip_opt, radar_rqv_thresh1, radar_rqv_thresh2, &
21 radar_rqv_rh1, radar_rqv_rh2, radar_non_precip_rh_w, radar_non_precip_rh_i, &
22 radar_rqv_h_lbound, radar_rqv_h_ubound, radar_saturated_rf, cloud_cv_options, &
23 radar_rhv_err_opt, radar_rhv_rrn_err, radar_rhv_rsn_err, radar_rhv_rgr_err
24 use da_define_structures, only : maxmin_type, iv_type, y_type, jo_type, &
25 bad_data_type, x_type, number_type, bad_data_type, &
26 infa_type, field_type
27 use da_interpolation, only : da_to_zk, da_interp_lin_3d,da_interp_lin_3d_adj
28 use da_par_util, only :da_proc_stats_combine, da_patch_to_global
29 use da_par_util1, only : da_proc_sum_int
30 use da_statistics, only : da_stats_calculate
31 use da_tools, only : da_residual, map_info, da_llxy_wrf, da_llxy_default, da_convert_zk
32 use da_tracing, only : da_trace_entry, da_trace_exit
33 use da_reporting, only : da_error, da_warning, da_message, message
34 use da_tools_serial, only : da_get_unit, da_free_unit
36 ! The "stats_radar_type" is ONLY used locally in da_radar:
38 type residual_radar1_type
39 real :: rv
40 real :: rf
41 real :: rrn
42 real :: rsn
43 real :: rgr
44 real :: rqv
45 end type residual_radar1_type
47 type maxmin_radar_stats_type
48 type (maxmin_type) :: rv ! Radial velocity
49 type (maxmin_type) :: rf ! Reflectivity
50 type (maxmin_type) :: rrn
51 type (maxmin_type) :: rsn
52 type (maxmin_type) :: rgr
53 type (maxmin_type) :: rqv
54 end type maxmin_radar_stats_type
56 type stats_radar_type
57 type (maxmin_radar_stats_type) :: maximum, minimum
58 type (residual_radar1_type) :: average, rms_err
59 end type stats_radar_type
61 real, parameter :: leh1=43.1
62 real, parameter :: leh2=17.5
64 real :: zlcl_mean !model grid mean LCL
66 contains
68 #include "da_ao_stats_radar.inc"
69 #include "da_jo_and_grady_radar.inc"
70 #include "da_residual_radar.inc"
71 #include "da_oi_stats_radar.inc"
72 #include "da_print_stats_radar.inc"
73 #include "da_transform_xtoy_radar.inc"
74 #include "da_transform_xtoy_radar_adj.inc"
75 #include "da_check_max_iv_radar.inc"
76 #include "da_get_innov_vector_radar.inc"
77 #include "da_radial_velocity.inc"
78 #include "da_radial_velocity_lin.inc"
79 #include "da_radial_velocity_adj.inc"
80 #include "da_calculate_grady_radar.inc"
81 #include "da_max_error_qc_radar.inc"
82 #include "da_write_oa_radar_ascii.inc"
83 #include "da_radar_rf.inc"
85 #include "da_radzicevar_calc_ice_abc.inc"
86 #include "da_radzicevar_pkx.inc"
87 #include "da_radzicevar_upper_f.inc"
88 #include "da_radzicevar_cal_tl_fw4wetice.inc"
89 #include "da_radzicevar_prepare_interceptpara.inc"
90 #include "da_radzicevar_virtual.inc"
91 #include "da_radzicevar_parameter_zrx.inc"
92 #include "da_radzicevar_prepare_mixingratios.inc"
93 #include "da_radzicevar_waterfraction.inc"
94 #include "da_radzicevar_parameter_zxx.inc"
95 #include "da_radzicevar_prepare_zmm_adj.inc"
96 #include "da_radzicevar_dryice_adj.inc"
97 #include "da_radzicevar_pxabk.inc"
98 #include "da_radzicevar_wetice_adj.inc"
99 #include "da_radzicevar_dryice_tl.inc"
100 #include "da_radzicevar_rain_adj.inc"
101 #include "da_radzicevar_wetice_tl.inc"
102 #include "da_radzicevar_rain_tl.inc"
103 #include "da_radzicevar_rhoair_tl.inc"
104 #include "da_radzicevar.inc"
105 #include "da_radzicevar_tl.inc"
106 #include "da_radzicevar_adj.inc"
107 #include "da_radzicevar_sigma_in_abc.inc"
109 end module da_radar