1 subroutine da_check_xtoy_adjoint_rad(iv, y, adjtest_lhs, pertile_lhs)
3 !------------------------------------------------------------------------------
4 ! Purpose: Calculate innovation vector for radiance data.
5 !------------------------------------------------------------------------------
9 type(iv_type), intent(in) :: iv ! obs. inc. vector (o-b).
10 type(y_type), intent(inout) :: y ! y = h (xa)
11 real, intent(inout) :: adjtest_lhs, pertile_lhs
13 integer :: inst, n, k ! Loop counter.
15 if (trace_use_dull) call da_trace_entry("da_check_xtoy_adjoint_rad")
17 do inst = 1, iv%num_inst ! loop for sensor
18 if (iv%instid(inst)%num_rad < 1) cycle
20 do n= 1, iv%instid(inst)%num_rad ! loop for pixel
21 ! if (iv%instid(inst)%rad(n)%loc%proc_domain_with_halo) then
22 if (iv%instid(inst)%info%proc_domain(1,n)) then
23 do k = 1, iv%instid(inst)%nchan
24 ! if ( iv%instid(inst)%tb_qc(k,n) >= obs_qc_pointer ) &
25 adjtest_lhs = adjtest_lhs + &
26 ( y%instid(inst)%tb(k,n)/iv%instid(inst)%tb_error(k,n) )**2
30 do k=1, iv%instid(inst)%nchan
31 ! if ( iv%instid(inst)%tb_qc(k,n) >= obs_qc_pointer ) &
32 pertile_lhs = pertile_lhs + &
33 ( y%instid(inst)%tb(k,n)/iv%instid(inst)%tb_error(k,n) )**2
35 y%instid(inst)%tb(k,n) = &
36 y%instid(inst)%tb(k,n) / (iv%instid(inst)%tb_error(k,n))**2
42 if (trace_use_dull) call da_trace_exit("da_check_xtoy_adjoint_rad")
44 end subroutine da_check_xtoy_adjoint_rad