Merge remote-tracking branch 'origin/release-v4.5.2'
[WRF.git] / var / da / da_verif_obs / da_verif_obs_control.f90
blobd7dc5dceb9a61d3c037249d059c780c603edfde1
1 MODULE da_verif_obs_control
2 !----------------------------------------------------------------------------
3 ! History:
5 ! Abstract:
6 ! Main module for
7 ! defining and initializing various data type,
8 ! defining unit numbers and cosnstants
10 ! Author: Syed RH Rizvi NCAR/MMM 05/25/2006
11 ! Updates:
12 ! Syed RH Rizvi NCAR/MMM 05/08/2007
13 ! Significance test & error bars are added
14 !----------------------------------------------------------------------------
15 implicit none
17 integer, parameter :: maxnum = 10, nstd = 16, nstdh = 150
18 integer, parameter :: num_verif_var =5
19 real, dimension(nstd) :: stdp
20 real, dimension(nstdh):: stdh
21 real :: rmiss = -99.99
22 integer :: num_miss = -99
23 real, parameter :: missing_r = -888888.
25 data stdp/1000.0, 925.0, 850.0, 700.0, 500.0, 400.0, 300.0, &
26 250.0, 200.0, 150.0, 100.0, 70.0, 50.0 ,30.0, 20.0 ,10.0/
27 data stdh/0.2, 0.4, 0.6, 0.8, 1.0, 1.2, 1.4, 1.6, 1.8, 2.0, &
28 2.2, 2.4, 2.6, 2.8, 3.0, 3.2, 3.4, 3.6, 3.8, 4.0, &
29 4.2, 4.4, 4.6, 4.8, 5.0, 5.2, 5.4, 5.6, 5.8, 6.0, &
30 6.2, 6.4, 6.6, 6.8, 7.0, 7.2, 7.4, 7.6, 7.8, 8.0, &
31 8.2, 8.4, 8.6, 8.8, 9.0, 9.2, 9.4, 9.6, 9.8,10.0, &
32 10.2,10.4,10.6,10.8,11.0,11.2,11.4,11.6,11.8,12.0, &
33 12.2,12.4,12.6,12.8,13.0,13.2,13.4,13.6,13.8,14.0, &
34 14.2,14.4,14.6,14.8,15.0,15.2,15.4,15.6,15.8,16.0, &
35 16.2,16.4,16.6,16.8,17.0,17.2,17.4,17.6,17.8,18.0, &
36 18.2,18.4,18.6,18.8,19.0,19.2,19.4,19.6,19.8,20.0, &
37 20.2,20.4,20.6,20.8,21.0,21.2,21.4,21.6,21.8,22.0, &
38 22.2,22.4,22.6,22.8,23.0,23.2,23.4,23.6,23.8,24.0, &
39 24.2,24.4,24.6,24.8,25.0,25.2,25.4,25.6,25.8,26.0, &
40 26.2,26.4,26.6,26.8,27.0,27.2,27.4,27.6,27.8,28.0, &
41 28.2,28.4,28.6,28.8,29.0,29.2,29.4,29.6,29.8,30.0 /
44 character (len=1) :: verif_var(num_verif_var)
45 character (len= 2) :: verif_type(2)
46 data verif_var/'U','V','T','Q','P'/
47 data verif_type/'OI','AO'/
49 type stats_value
50 integer :: num
51 real :: abias
52 real :: bias
53 real :: rmse
54 end type stats_value
56 type surface_type
57 type (stats_value) :: uomb, uoma
58 type (stats_value) :: vomb, voma
59 type (stats_value) :: tomb, toma
60 type (stats_value) :: pomb, poma
61 type (stats_value) :: qomb, qoma
62 end type surface_type
64 type upr_type
65 type (stats_value) :: uomb(nstd), uoma(nstd)
66 type (stats_value) :: vomb(nstd), voma(nstd)
67 type (stats_value) :: tomb(nstd), toma(nstd)
68 type (stats_value) :: qomb(nstd), qoma(nstd)
69 end type upr_type
71 type gpspw_type
72 type (stats_value) :: tpwomb, tpwoma
73 end type gpspw_type
75 type gpsref_type
76 type (stats_value) :: refomb(nstdh), refoma(nstdh)
77 end type gpsref_type
79 ! namelist.varstats variables
81 ! record1
82 INTEGER :: exp_num ! number of experiments
83 CHARACTER(LEN=512),DIMENSION(maxnum) :: exp_dirs, out_dirs
84 ! record2
85 CHARACTER(LEN=10) :: start_date
86 CHARACTER(LEN=10) :: end_date
87 INTEGER :: interval ! interval(h) between initial times
88 ! ! Typically 6 or 12 hours
90 ! record3
92 LOGICAL :: if_plot_rmse
93 LOGICAL :: if_plot_bias
94 LOGICAL :: if_plot_abias
96 ! record4
97 LOGICAL :: if_plot_surface
99 LOGICAL :: if_plot_synop
100 LOGICAL :: if_plot_metar
101 LOGICAL :: if_plot_ships
102 LOGICAL :: if_plot_buoy
103 LOGICAL :: if_plot_sonde_sfc
104 LOGICAL :: if_plot_qscat
106 LOGICAL :: if_plot_upr
108 LOGICAL :: if_plot_sound
109 LOGICAL :: if_plot_airep
110 LOGICAL :: if_plot_pilot
111 LOGICAL :: if_plot_profiler
112 LOGICAL :: if_plot_polaramv
113 LOGICAL :: if_plot_geoamv
114 LOGICAL :: if_plot_tamdar
116 LOGICAL :: if_plot_gpspw
117 LOGICAL :: if_plot_gpsref
118 LOGICAL :: if_plot_airsret
119 ! record5
120 character (len=50) :: file_path_string
121 character (len=512) :: wrf_file
122 integer :: istart, iend, jstart, jend
124 NAMELIST /Record1/ exp_num, exp_dirs, out_dirs
125 NAMELIST /Record2/ start_date, end_date, interval
126 NAMELIST /Record3/ if_plot_rmse, if_plot_bias, if_plot_abias
127 NAMELIST /Record4/ if_plot_synop, if_plot_sonde_sfc,if_plot_metar, &
128 if_plot_ships, if_plot_buoy , if_plot_qscat, &
129 if_plot_sound, if_plot_airep, if_plot_pilot, if_plot_profiler, &
130 if_plot_geoamv, if_plot_polaramv, if_plot_gpspw, if_plot_gpsref, &
131 if_plot_airsret, if_plot_tamdar
132 NAMELIST /Record5/ file_path_string
133 NAMELIST /Record6/ wrf_file, istart, iend, jstart, jend
135 ! Namelist declaration over
136 integer :: nml_unit, diag_unit_in, diag_unit_out, info_unit, plot_stats_unit
137 real, dimension(34,2) :: alpha
138 end MODULE da_verif_obs_control