15 subroutine invert_pv (x,pv,x_north,x_south,rs,nx,ny,deltax,deltay,F1,F2,bet)
22 integer,
intent(in) :: nx
23 integer,
intent(in) :: ny
24 real(kind=kind_real),
intent(out) :: x(nx,ny,2)
25 real(kind=kind_real),
intent(in) :: pv(nx,ny,2)
26 real(kind=kind_real),
intent(in) :: x_north(2)
27 real(kind=kind_real),
intent(in) :: x_south(2)
28 real(kind=kind_real),
intent(in) :: rs(nx,ny)
29 real(kind=kind_real),
intent(in) :: deltax
30 real(kind=kind_real),
intent(in) :: deltay
31 real(kind=kind_real),
intent(in) :: F1
32 real(kind=kind_real),
intent(in) :: F2
33 real(kind=kind_real),
intent(in) :: bet
35 real(kind=kind_real) :: y
36 real(kind=kind_real) :: pv_nobc(nx,ny,2)
42 y =
real(jj-(ny+1)/2,kind_real)*deltay;
43 pv_nobc(:,jj,1) = pv(:,jj,1) - bet*y
44 pv_nobc(:,jj,2) = pv(:,jj,2) - bet*y -rs(:,jj)
49 pv_nobc(:,1 ,1) = pv_nobc(:,1 ,1) - (1.0_kind_real/(deltay*deltay))*x_south(1)
50 pv_nobc(:,1 ,2) = pv_nobc(:,1 ,2) - (1.0_kind_real/(deltay*deltay))*x_south(2)
51 pv_nobc(:,ny,1) = pv_nobc(:,ny,1) - (1.0_kind_real/(deltay*deltay))*x_north(1)
52 pv_nobc(:,ny,2) = pv_nobc(:,ny,2) - (1.0_kind_real/(deltay*deltay))*x_north(2)
subroutine invert_pv(x, pv, x_north, x_south, rs, nx, ny, deltax, deltay, F1, F2, bet)
Invert potential vorticity, returning streamfunction.
subroutine solve_elliptic_system(x, pv, nx, ny, deltax, deltay, F1, F2)
Solves the elliptic system that arises when inverting potential vorticity.