da_check_max_iv_ssmi_tb.inc
References to this file elsewhere.
1 subroutine da_check_max_iv_ssmi_tb(iv, it, &
2 itb19v, itb19vf, itb19h, itb19hf, itb22v, itb22vf, &
3 itb37v, itb37vf, itb37h, itb37hf, itb85v, itb85vf, itb85h, itb85hf)
4
5 !-----------------------------------------------------------------------
6 ! Purpose: TBD
7 !-----------------------------------------------------------------------
8
9 implicit none
10
11 type(iv_type), intent(inout) :: iv
12 integer, intent(in) :: it
13 integer, intent(inout) :: itb19h, itb19v, itb22v
14 integer, intent(inout) :: itb37h, itb37v, itb85h, itb85v
15 integer, intent(inout) :: itb19hf, itb19vf, itb22vf
16 integer, intent(inout) :: itb37hf, itb37vf, itb85hf, itb85vf
17
18 logical :: failed
19 integer :: n
20
21 if (trace_use) call da_trace_entry("da_check_max_iv_ssmi_tb")
22
23 !-----------------------------------------------------------------------------!
24 ! [1.0] Open diagnostic file:
25 !-----------------------------------------------------------------------------!
26
27 if (rootproc .and. check_max_iv_print) then
28 write (check_max_iv_unit,'(A)') &
29 '----------------------------------------------------------------'
30 write (unit = check_max_iv_unit, fmt = '(A,/)') 'MAX ERROR TEST QC:'
31 write (unit = check_max_iv_unit, fmt = '(/,9(A,F3.0,/))') &
32 'Error max test ratio for SSMI_tb_TB19h = ',max_error_tb, &
33 'Error max test ratio for SSMI_tb_TB19v = ',max_error_tb, &
34 'Error max test ratio for SSMI_tb_TB22v = ',max_error_tb, &
35 'Error max test ratio for SSMI_tb_TB37h = ',max_error_tb, &
36 'Error max test ratio for SSMI_tb_TB37v = ',max_error_tb, &
37 'Error max test ratio for SSMI_tb_TB85h = ',max_error_tb, &
38 'Error max test ratio for SSMI_tb_TB85v = ',max_error_tb
39 end if
40
41 ! itb19h = 0; itb19v = 0; itb22v = 0;
42 ! itb37h = 0; itb37v = 0; itb85h = 0; itb85v = 0
43 ! itb19hf = 0; itb19vf = 0; itb22vf = 0;
44 ! itb37hf = 0; itb37vf = 0; itb85hf = 0; itb85vf = 0
45
46 !---------------------------------------------------------------------------
47 ! [2.0] Perform maximum innovation vector check:
48 !---------------------------------------------------------------------------
49
50 ! failed=.false. is defined inside the da_max_error_qc
51 ! failed = .false.
52
53 do n=iv%info(ssmi_tb)%n1, iv%info(ssmi_tb)%n2
54 ! Tb19h
55
56 call da_max_error_qc(it, iv%info(ssmi_tb), n, iv%ssmi_tb(n)%tb19h, max_error_tb, &
57 itb19h, itb19hf, check_max_iv_unit, 'TB19h', failed, check_max_iv_print)
58
59 ! Tb19v
60
61 call da_max_error_qc(it, iv%info(ssmi_tb), n, iv%ssmi_tb(n)%tb19v, &
62 max_error_tb, itb19v, itb19vf, check_max_iv_unit, 'TB19v', failed, check_max_iv_print)
63
64 ! Tb22v
65
66 call da_max_error_qc(it, iv%info(ssmi_tb), n, iv%ssmi_tb(n)%tb22v, max_error_tb, &
67 itb22v, itb22vf, check_max_iv_unit, 'TB22v', failed, check_max_iv_print)
68
69 ! Tb37h
70
71 call da_max_error_qc(it, iv%info(ssmi_tb), n, iv%ssmi_tb(n)%tb37h, max_error_tb, &
72 itb37h, itb37hf, check_max_iv_unit, 'TB37h', failed, check_max_iv_print)
73
74 ! Tb37v
75
76 call da_max_error_qc(it, iv%info(ssmi_tb), n, iv%ssmi_tb(n)%tb37v, max_error_tb, &
77 itb37v, itb37vf, check_max_iv_unit, 'TB37v', failed, check_max_iv_print)
78
79 ! Tb85h
80
81 call da_max_error_qc(it, iv%info(ssmi_tb), n, iv%ssmi_tb(n)%tb85h, max_error_tb, &
82 itb85h, itb85hf, check_max_iv_unit, 'TB85h', failed, check_max_iv_print)
83
84 ! Tb85v
85
86 call da_max_error_qc(it, iv%info(ssmi_tb), n, iv%ssmi_tb(n)%tb85v,max_error_tb, &
87 itb85v, itb85vf, check_max_iv_unit, 'TB85v', failed, check_max_iv_print)
88 end do
89
90 !---------------------------------------------------------------------------
91 ! [3.0] Output test failed results:
92 !---------------------------------------------------------------------------
93
94 ! if (rootproc .and. check_max_iv_print .and. failed) then
95 ! write (unit = check_max_iv_unit, fmt = '(/,10(2(A,I6),/))') &
96 ! 'Number of failed ssmi tb19h observations: ',itb19hf,' on ',itb19h, &
97 ! 'Number of failed ssmi tb19v observations: ',itb19vf,' on ',itb19v, &
98 ! 'Number of failed ssmi tb22v observations: ',itb22vf,' on ',itb22v, &
99 ! 'Number of failed ssmi tb37h observations: ',itb37hf,' on ',itb37h, &
100 ! 'Number of failed ssmi tb37v observations: ',itb37vf,' on ',itb37v, &
101 ! 'Number of failed ssmi tb85h observations: ',itb85hf,' on ',itb85h, &
102 ! 'Number of failed ssmi tb85v observations: ',itb85vf,' on ',itb85v
103 ! end if
104
105 if (trace_use) call da_trace_exit("da_check_max_iv_ssmi_tb")
106
107 end subroutine da_check_max_iv_ssmi_tb
108
109