1 subroutine da_check_max_iv_lightning(iv,ob, it)
3 !-----------------------------------------------------------------------
5 ! Authors: Z Chen (zchen@fjnu.edu.cn), Jenny Sun (NCAR), X Qie (IAP)
6 !-----------------------------------------------------------------------
10 type(iv_type), intent(inout) :: iv
11 integer, intent(in) :: it ! Outer iteration
12 type(y_type), intent(in) :: ob ! Observation structure.
17 if (trace_use) call da_trace_entry("da_check_max_iv_lightning")
19 !---------------------------------------------------------------------------
20 ! [1.0] Perform maximum innovation vector check:
21 !---------------------------------------------------------------------------
23 do n = iv%info(lightning)%n1,iv%info(lightning)%n2
24 do k = 1, iv%info(lightning)%levels(n)
26 if(iv%lightning(n)%w(k)%qc >= obs_qc_pointer) then
27 call da_max_error_qc(it, iv%info(lightning), n, iv%lightning(n)%w(k),max_error_lda_w, failed)
28 if(iv%info(lightning)%proc_domain(k,n)) then
30 write(qcstat_conv_unit,'(2x, a10, 2x, a10, 4f12.3, a12)')&
31 'Lightning','lightning',iv%info(lightning)%lat(k,n),iv%info(lightning)%lon(k,n), iv%lightning(n)%w(k)%inv, ob%lightning(n)%w(k)
37 if(iv%lightning(n)%div(k)%qc >= obs_qc_pointer) then
38 call da_max_error_qc(it, iv%info(lightning), n, iv%lightning(n)%div(k),max_error_lda_div, failed)
39 if(iv%info(lightning)%proc_domain(k,n)) then
41 write(qcstat_conv_unit,'(2x, a10, 2x, a10, 4f12.3, a12)')&
42 'Lightning','lightning',iv%info(lightning)%lat(k,n),iv%info(lightning)%lon(k,n), iv%lightning(n)%div(k)%inv, ob%lightning(n)%div(k)
48 if(iv%lightning(n)%qv(k)%qc >= obs_qc_pointer) then
49 call da_max_error_qc(it, iv%info(lightning), n, iv%lightning(n)%qv(k),max_error_lda_qv, failed)
50 if(iv%info(lightning)%proc_domain(k,n)) then
52 write(qcstat_conv_unit,'(2x,a10,2x,a10,4f12.2,a12)')&
53 'Lightning','lightning',iv%info(lightning)%lat(k,n),iv%info(lightning)%lon(k,n), iv%lightning(n)%qv(k)%inv, ob%lightning(n)%qv(k)
60 if (trace_use) call da_trace_exit("da_check_max_iv_lightning")
62 end subroutine da_check_max_iv_lightning