da_transform_xtoy_polaramv.inc
References to this file elsewhere.
1 subroutine da_transform_xtoy_polaramv (grid, iv, y)
2
3 !----------------------------------------------------------------------
4 ! Purpose: X to Y Transform operator for Polar AMV's
5 !----------------------------------------------------------------------
6
7 implicit none
8
9 type (domain), intent(in) :: grid
10 type (iv_type), intent(in) :: iv ! Innovation vector (O-B).
11 type (y_type), intent(inout) :: y ! y = h (grid%xa)
12
13 integer :: n ! Loop counter.
14 real, allocatable :: u(:,:)
15 real, allocatable :: v(:,:)
16
17 if (trace_use_dull) call da_trace_entry("da_transform_xtoy_polaramv")
18
19 allocate (u(iv%info(polaramv)%max_lev,iv%info(polaramv)%n1:iv%info(polaramv)%n2))
20 allocate (v(iv%info(polaramv)%max_lev,iv%info(polaramv)%n1:iv%info(polaramv)%n2))
21
22 call da_interp_lin_3d (grid%xa%u, iv%info(polaramv), u)
23 call da_interp_lin_3d (grid%xa%v, iv%info(polaramv), v)
24
25 do n=iv%info(polaramv)%n1,iv%info(polaramv)%n2
26 y%polaramv(n)%u(:) = u(1:size(y%polaramv(n)%u),n)
27 y%polaramv(n)%v(:) = v(1:size(y%polaramv(n)%v),n)
28 end do
29
30 deallocate (u)
31 deallocate (v)
32
33 if (trace_use_dull) call da_trace_exit("da_transform_xtoy_polaramv")
34
35 end subroutine da_transform_xtoy_polaramv
36
37