da_transform_xtozrhoq.inc
References to this file elsewhere.
1 subroutine da_transform_xtozrhoq(xb, i, j, zh, zf, zrhom)
2
3 !-----------------------------------------------------------------------
4 ! Purpose: TBD
5 !-----------------------------------------------------------------------
6
7 implicit none
8
9 integer, intent(in) :: i, j
10 type (xb_type), intent(in) :: xb ! first guess state.
11 real, intent(out) :: zrhom ! gridded height weighted moisture
12 real, intent(in), &
13 dimension(mkz) :: zh
14 real, intent(in), &
15 dimension(mkz+1) :: zf
16 integer :: k
17
18 if (trace_use) call da_trace_entry("da_transform_xtozrhoq")
19
20 zrhom = 0.
21
22 do k = 1,mkz
23 zrhom = (zf(k)-zf(k+1))*zh(k)*(xb%q(i,j,k)*xb%rho(i,j,k))+zrhom
24 end do
25
26 if (trace_use) call da_trace_exit("da_transform_xtozrhoq")
27
28 end subroutine da_transform_xtozrhoq
29
30