78 SUBROUTINE sptranfv(IROMB,MAXWV,IDRT,IMAX,JMAX,KMAX,
79 & IP,IS,JN,JS,KW,KG,JB,JE,JC,
80 & WAVED,WAVEZ,GRIDUN,GRIDUS,GRIDVN,GRIDVS,IDIR)
82 REAL WAVED(*),WAVEZ(*),GRIDUN(*),GRIDUS(*),GRIDVN(*),GRIDVS(*)
83 REAL EPS((MAXWV+1)*((IROMB+1)*MAXWV+2)/2),EPSTOP(MAXWV+1)
84 REAL ENN1((MAXWV+1)*((IROMB+1)*MAXWV+2)/2)
85 REAL ELONN1((MAXWV+1)*((IROMB+1)*MAXWV+2)/2)
86 REAL EON((MAXWV+1)*((IROMB+1)*MAXWV+2)/2),EONTOP(MAXWV+1)
87 REAL(8) AFFT(50000+4*IMAX), AFFT_TMP(50000+4*IMAX)
88 REAL CLAT(JB:JE),SLAT(JB:JE),WLAT(JB:JE)
89 REAL PLN((MAXWV+1)*((IROMB+1)*MAXWV+2)/2,JB:JE)
90 REAL PLNTOP(MAXWV+1,JB:JE)
92 REAL W((MAXWV+1)*((IROMB+1)*MAXWV+2)/2*2,2)
93 REAL WTOP(2*(MAXWV+1),2)
95 REAL WINC((MAXWV+1)*((IROMB+1)*MAXWV+2)/2*2,2)
98 mx=(maxwv+1)*((iromb+1)*maxwv+2)/2
100 CALL sptranf0(iromb,maxwv,idrt,imax,jmax,jb,je,
101 & eps,epstop,enn1,elonn1,eon,eontop,
102 & afft,clat,slat,wlat,pln,plntop)
110 CALL spdz2uv(iromb,maxwv,enn1,elonn1,eon,eontop,
111 & waved(kws+1),wavez(kws+1),
112 & w(1,1),w(1,2),wtop(1,1),wtop(1,2))
114 CALL sptranf1(iromb,maxwv,idrt,imax,jmax,j,j,
115 & eps,epstop,enn1,elonn1,eon,eontop,
116 & afft_tmp,clat(j),slat(j),wlat(j),
117 & pln(1,j),plntop(1,j),mp,
118 & w(1,1),wtop(1,1),g(1,1,1),idir)
119 CALL sptranf1(iromb,maxwv,idrt,imax,jmax,j,j,
120 & eps,epstop,enn1,elonn1,eon,eontop,
121 & afft_tmp,clat(j),slat(j),wlat(j),
122 & pln(1,j),plntop(1,j),mp,
123 & w(1,2),wtop(1,2),g(1,1,2),idir)
124 IF(ip.EQ.1.AND.is.EQ.1)
THEN
126 ijkn=i+(j-jb)*jn+(k-1)*kg
127 ijks=i+(j-jb)*js+(k-1)*kg
128 gridun(ijkn)=g(i,1,1)
129 gridus(ijks)=g(i,2,1)
130 gridvn(ijkn)=g(i,1,2)
131 gridvs(ijks)=g(i,2,2)
135 ijkn=mod(i+ip-2,imax)*is+(j-jb)*jn+(k-1)*kg+1
136 ijks=mod(i+ip-2,imax)*is+(j-jb)*js+(k-1)*kg+1
137 gridun(ijkn)=g(i,1,1)
138 gridus(ijks)=g(i,2,1)
139 gridvn(ijkn)=g(i,1,2)
140 gridvs(ijks)=g(i,2,2)
155 IF(wlat(j).GT.0.)
THEN
156 IF(ip.EQ.1.AND.is.EQ.1)
THEN
158 ijkn=i+(j-jb)*jn+(k-1)*kg
159 ijks=i+(j-jb)*js+(k-1)*kg
160 g(i,1,1)=gridun(ijkn)/clat(j)**2
161 g(i,2,1)=gridus(ijks)/clat(j)**2
162 g(i,1,2)=gridvn(ijkn)/clat(j)**2
163 g(i,2,2)=gridvs(ijks)/clat(j)**2
167 ijkn=mod(i+ip-2,imax)*is+(j-jb)*jn+(k-1)*kg+1
168 ijks=mod(i+ip-2,imax)*is+(j-jb)*js+(k-1)*kg+1
169 g(i,1,1)=gridun(ijkn)/clat(j)**2
170 g(i,2,1)=gridus(ijks)/clat(j)**2
171 g(i,1,2)=gridvn(ijkn)/clat(j)**2
172 g(i,2,2)=gridvs(ijks)/clat(j)**2
175 CALL sptranf1(iromb,maxwv,idrt,imax,jmax,j,j,
176 & eps,epstop,enn1,elonn1,eon,eontop,
177 & afft_tmp,clat(j),slat(j),wlat(j),
178 & pln(1,j),plntop(1,j),mp,
179 & w(1,1),wtop(1,1),g(1,1,1),idir)
180 CALL sptranf1(iromb,maxwv,idrt,imax,jmax,j,j,
181 & eps,epstop,enn1,elonn1,eon,eontop,
182 & afft_tmp,clat(j),slat(j),wlat(j),
183 & pln(1,j),plntop(1,j),mp,
184 & w(1,2),wtop(1,2),g(1,1,2),idir)
187 CALL spuv2dz(iromb,maxwv,enn1,elonn1,eon,eontop,
188 & w(1,1),w(1,2),wtop(1,1),wtop(1,2),
189 & winc(1,1),winc(1,2))
190 waved(kws+1:kws+2*mx)=waved(kws+1:kws+2*mx)+winc(1:2*mx,1)
191 wavez(kws+1:kws+2*mx)=wavez(kws+1:kws+2*mx)+winc(1:2*mx,2)