[2] | 1 | SUBROUTINE drag_noro (nlon,nlev,dtime,paprs,pplay, |
---|
| 2 | e pmea,pstd, psig, pgam, pthe,ppic,pval, |
---|
[155] | 3 | e kgwd,kdx,ktest, |
---|
[2] | 4 | e t, u, v, |
---|
| 5 | s pulow, pvlow, pustr, pvstr, |
---|
| 6 | s d_t, d_u, d_v) |
---|
| 7 | c |
---|
| 8 | IMPLICIT none |
---|
| 9 | c====================================================================== |
---|
| 10 | c Auteur(s): F.Lott (LMD/CNRS) date: 19950201 |
---|
| 11 | c Objet: Frottement de la montagne Interface |
---|
| 12 | c====================================================================== |
---|
| 13 | c Arguments: |
---|
| 14 | c dtime---input-R- pas d'integration (s) |
---|
| 15 | c paprs---input-R-pression pour chaque inter-couche (en Pa) |
---|
| 16 | c pplay---input-R-pression pour le mileu de chaque couche (en Pa) |
---|
| 17 | c t-------input-R-temperature (K) |
---|
| 18 | c u-------input-R-vitesse horizontale (m/s) |
---|
| 19 | c v-------input-R-vitesse horizontale (m/s) |
---|
| 20 | c |
---|
| 21 | c d_t-----output-R-increment de la temperature |
---|
| 22 | c d_u-----output-R-increment de la vitesse u |
---|
| 23 | c d_v-----output-R-increment de la vitesse v |
---|
| 24 | c====================================================================== |
---|
| 25 | #include "dimensions.h" |
---|
| 26 | #include "dimphy.h" |
---|
| 27 | #include "YOMCST.h" |
---|
| 28 | c |
---|
| 29 | c ARGUMENTS |
---|
| 30 | c |
---|
| 31 | INTEGER nlon,nlev |
---|
| 32 | REAL dtime |
---|
| 33 | REAL paprs(klon,klev+1) |
---|
| 34 | REAL pplay(klon,klev) |
---|
| 35 | REAL pmea(nlon),pstd(nlon),psig(nlon),pgam(nlon),pthe(nlon) |
---|
| 36 | REAL ppic(nlon),pval(nlon) |
---|
| 37 | REAL pulow(nlon),pvlow(nlon),pustr(nlon),pvstr(nlon) |
---|
| 38 | REAL t(nlon,nlev), u(nlon,nlev), v(nlon,nlev) |
---|
| 39 | REAL d_t(nlon,nlev), d_u(nlon,nlev), d_v(nlon,nlev) |
---|
| 40 | c |
---|
[155] | 41 | INTEGER i, k, kgwd, kdx(nlon), ktest(nlon) |
---|
[2] | 42 | c |
---|
| 43 | c Variables locales: |
---|
| 44 | c |
---|
| 45 | REAL zgeom(klon,klev) |
---|
| 46 | REAL pdtdt(klon,klev), pdudt(klon,klev), pdvdt(klon,klev) |
---|
| 47 | REAL pt(klon,klev), pu(klon,klev), pv(klon,klev) |
---|
| 48 | REAL papmf(klon,klev),papmh(klon,klev+1) |
---|
| 49 | c |
---|
| 50 | c initialiser les variables de sortie (pour securite) |
---|
| 51 | c |
---|
| 52 | DO i = 1,klon |
---|
| 53 | pulow(i) = 0.0 |
---|
| 54 | pvlow(i) = 0.0 |
---|
| 55 | pustr(i) = 0.0 |
---|
| 56 | pvstr(i) = 0.0 |
---|
| 57 | ENDDO |
---|
| 58 | DO k = 1, klev |
---|
| 59 | DO i = 1, klon |
---|
| 60 | d_t(i,k) = 0.0 |
---|
| 61 | d_u(i,k) = 0.0 |
---|
| 62 | d_v(i,k) = 0.0 |
---|
| 63 | pdudt(i,k)=0.0 |
---|
| 64 | pdvdt(i,k)=0.0 |
---|
| 65 | pdtdt(i,k)=0.0 |
---|
| 66 | ENDDO |
---|
| 67 | ENDDO |
---|
| 68 | c |
---|
| 69 | c preparer les variables d'entree (attention: l'ordre des niveaux |
---|
| 70 | c verticaux augmente du haut vers le bas) |
---|
| 71 | c |
---|
| 72 | DO k = 1, klev |
---|
| 73 | DO i = 1, klon |
---|
| 74 | pt(i,k) = t(i,klev-k+1) |
---|
| 75 | pu(i,k) = u(i,klev-k+1) |
---|
| 76 | pv(i,k) = v(i,klev-k+1) |
---|
| 77 | papmf(i,k) = pplay(i,klev-k+1) |
---|
| 78 | ENDDO |
---|
| 79 | ENDDO |
---|
| 80 | DO k = 1, klev+1 |
---|
| 81 | DO i = 1, klon |
---|
| 82 | papmh(i,k) = paprs(i,klev-k+2) |
---|
| 83 | ENDDO |
---|
| 84 | ENDDO |
---|
| 85 | DO i = 1, klon |
---|
| 86 | zgeom(i,klev) = RD * pt(i,klev) |
---|
| 87 | . * LOG(papmh(i,klev+1)/papmf(i,klev)) |
---|
| 88 | ENDDO |
---|
| 89 | DO k = klev-1, 1, -1 |
---|
| 90 | DO i = 1, klon |
---|
| 91 | zgeom(i,k) = zgeom(i,k+1) + RD * (pt(i,k)+pt(i,k+1))/2.0 |
---|
| 92 | . * LOG(papmf(i,k+1)/papmf(i,k)) |
---|
| 93 | ENDDO |
---|
| 94 | ENDDO |
---|
| 95 | c |
---|
| 96 | c appeler la routine principale |
---|
| 97 | c |
---|
[155] | 98 | CALL orodrag(klon,klev,kgwd,kdx,ktest, |
---|
[2] | 99 | . dtime, |
---|
| 100 | . papmh, papmf, zgeom, |
---|
| 101 | . pt, pu, pv, |
---|
| 102 | . pmea, pstd, psig, pgam, pthe, ppic,pval, |
---|
| 103 | . pulow,pvlow, |
---|
| 104 | . pdudt,pdvdt,pdtdt) |
---|
| 105 | C |
---|
| 106 | DO k = 1, klev |
---|
| 107 | DO i = 1, klon |
---|
| 108 | d_u(i,klev+1-k) = dtime*pdudt(i,k) |
---|
| 109 | d_v(i,klev+1-k) = dtime*pdvdt(i,k) |
---|
| 110 | d_t(i,klev+1-k) = dtime*pdtdt(i,k) |
---|
| 111 | pustr(i) = pustr(i) |
---|
| 112 | . +rg*pdudt(i,k)*(papmh(i,k+1)-papmh(i,k)) |
---|
| 113 | pvstr(i) = pvstr(i) |
---|
| 114 | . +rg*pdvdt(i,k)*(papmh(i,k+1)-papmh(i,k)) |
---|
| 115 | ENDDO |
---|
| 116 | ENDDO |
---|
| 117 | c |
---|
| 118 | RETURN |
---|
| 119 | END |
---|
| 120 | SUBROUTINE orodrag( nlon,nlev |
---|
[155] | 121 | i , kgwd, kdx, ktest |
---|
[2] | 122 | r , ptsphy |
---|
| 123 | r , paphm1,papm1,pgeom1,ptm1,pum1,pvm1 |
---|
| 124 | r , pmea, pstd, psig, pgamma, ptheta, ppic, pval |
---|
| 125 | c outputs |
---|
| 126 | r , pulow,pvlow |
---|
| 127 | r , pvom,pvol,pte ) |
---|
[155] | 128 | |
---|
| 129 | implicit none |
---|
| 130 | |
---|
[2] | 131 | c |
---|
| 132 | c |
---|
| 133 | c**** *gwdrag* - does the gravity wave parametrization. |
---|
| 134 | c |
---|
| 135 | c purpose. |
---|
| 136 | c -------- |
---|
| 137 | c |
---|
| 138 | c this routine computes the physical tendencies of the |
---|
| 139 | c prognostic variables u,v and t due to vertical transports by |
---|
| 140 | c subgridscale orographically excited gravity waves |
---|
| 141 | c |
---|
| 142 | c** interface. |
---|
| 143 | c ---------- |
---|
| 144 | c called from *callpar*. |
---|
| 145 | c |
---|
| 146 | c the routine takes its input from the long-term storage: |
---|
| 147 | c u,v,t and p at t-1. |
---|
| 148 | c |
---|
| 149 | c explicit arguments : |
---|
| 150 | c -------------------- |
---|
| 151 | c ==== inputs === |
---|
| 152 | c ==== outputs === |
---|
| 153 | c |
---|
| 154 | c implicit arguments : none |
---|
| 155 | c -------------------- |
---|
| 156 | c |
---|
[155] | 157 | c implicit logical (l) |
---|
[2] | 158 | c |
---|
| 159 | c method. |
---|
| 160 | c ------- |
---|
| 161 | c |
---|
| 162 | c externals. |
---|
| 163 | c ---------- |
---|
| 164 | integer ismin, ismax |
---|
| 165 | external ismin, ismax |
---|
| 166 | c |
---|
| 167 | c reference. |
---|
| 168 | c ---------- |
---|
| 169 | c |
---|
| 170 | c author. |
---|
| 171 | c ------- |
---|
| 172 | c m.miller + b.ritter e.c.m.w.f. 15/06/86. |
---|
| 173 | c |
---|
| 174 | c f.lott + m. miller e.c.m.w.f. 22/11/94 |
---|
| 175 | c----------------------------------------------------------------------- |
---|
| 176 | c |
---|
| 177 | c |
---|
| 178 | #include "dimensions.h" |
---|
| 179 | #include "dimphy.h" |
---|
| 180 | #include "YOMCST.h" |
---|
| 181 | #include "YOEGWD.h" |
---|
| 182 | c----------------------------------------------------------------------- |
---|
| 183 | c |
---|
| 184 | c* 0.1 arguments |
---|
| 185 | c --------- |
---|
| 186 | c |
---|
| 187 | c |
---|
[155] | 188 | integer nlon, nlev, klevm1 |
---|
| 189 | integer kgwd, jl, ilevp1, jk, ji |
---|
| 190 | real zdelp, ztemp, zforc, ztend |
---|
| 191 | real rover, zb, zc, zconb, zabsv |
---|
| 192 | real zzd1, ratio, zbet, zust,zvst, zdis |
---|
[2] | 193 | real pte(nlon,nlev), |
---|
| 194 | * pvol(nlon,nlev), |
---|
| 195 | * pvom(nlon,nlev), |
---|
| 196 | * pulow(klon), |
---|
| 197 | * pvlow(klon) |
---|
| 198 | real pum1(nlon,nlev), |
---|
| 199 | * pvm1(nlon,nlev), |
---|
| 200 | * ptm1(nlon,nlev), |
---|
| 201 | * pmea(nlon),pstd(nlon),psig(nlon), |
---|
| 202 | * pgamma(nlon),ptheta(nlon),ppic(nlon),pval(nlon), |
---|
| 203 | * pgeom1(nlon,nlev), |
---|
| 204 | * papm1(nlon,nlev), |
---|
| 205 | * paphm1(nlon,nlev+1) |
---|
| 206 | c |
---|
| 207 | integer kdx(nlon),ktest(nlon) |
---|
| 208 | c----------------------------------------------------------------------- |
---|
| 209 | c |
---|
| 210 | c* 0.2 local arrays |
---|
| 211 | c ------------ |
---|
| 212 | integer isect(klon), |
---|
| 213 | * icrit(klon), |
---|
| 214 | * ikcrith(klon), |
---|
| 215 | * ikenvh(klon), |
---|
| 216 | * iknu(klon), |
---|
| 217 | * iknu2(klon), |
---|
| 218 | * ikcrit(klon), |
---|
| 219 | * ikhlim(klon) |
---|
| 220 | c |
---|
| 221 | real ztau(klon,klev+1), |
---|
| 222 | * zstab(klon,klev+1), |
---|
| 223 | * zvph(klon,klev+1), |
---|
| 224 | * zrho(klon,klev+1), |
---|
| 225 | * zri(klon,klev+1), |
---|
| 226 | * zpsi(klon,klev+1), |
---|
| 227 | * zzdep(klon,klev) |
---|
| 228 | real zdudt(klon), |
---|
| 229 | * zdvdt(klon), |
---|
| 230 | * zdtdt(klon), |
---|
| 231 | * zdedt(klon), |
---|
| 232 | * zvidis(klon), |
---|
| 233 | * znu(klon), |
---|
| 234 | * zd1(klon), |
---|
| 235 | * zd2(klon), |
---|
| 236 | * zdmod(klon) |
---|
[155] | 237 | real ztmst, ptsphy, zrtmst |
---|
[2] | 238 | c |
---|
| 239 | c------------------------------------------------------------------ |
---|
| 240 | c |
---|
| 241 | c* 1. initialization |
---|
| 242 | c -------------- |
---|
| 243 | c |
---|
| 244 | 100 continue |
---|
| 245 | c |
---|
| 246 | c ------------------------------------------------------------------ |
---|
| 247 | c |
---|
| 248 | c* 1.1 computational constants |
---|
| 249 | c ----------------------- |
---|
| 250 | c |
---|
| 251 | 110 continue |
---|
| 252 | c |
---|
| 253 | c ztmst=twodt |
---|
| 254 | c if(nstep.eq.nstart) ztmst=0.5*twodt |
---|
| 255 | klevm1=klev-1 |
---|
| 256 | ztmst=ptsphy |
---|
| 257 | zrtmst=1./ztmst |
---|
| 258 | c ------------------------------------------------------------------ |
---|
| 259 | c |
---|
| 260 | 120 continue |
---|
| 261 | c |
---|
| 262 | c ------------------------------------------------------------------ |
---|
| 263 | c |
---|
| 264 | c* 1.3 check whether row contains point for printing |
---|
| 265 | c --------------------------------------------- |
---|
| 266 | c |
---|
| 267 | 130 continue |
---|
| 268 | c |
---|
| 269 | c ------------------------------------------------------------------ |
---|
| 270 | c |
---|
| 271 | c* 2. precompute basic state variables. |
---|
| 272 | c* ---------- ----- ----- ---------- |
---|
| 273 | c* define low level wind, project winds in plane of |
---|
| 274 | c* low level wind, determine sector in which to take |
---|
| 275 | c* the variance and set indicator for critical levels. |
---|
| 276 | c |
---|
| 277 | 200 continue |
---|
| 278 | c |
---|
| 279 | c |
---|
| 280 | c |
---|
| 281 | call orosetup |
---|
[155] | 282 | * ( nlon, ktest |
---|
| 283 | * , ikcrit, ikcrith, icrit, ikenvh,iknu,iknu2 |
---|
[2] | 284 | * , paphm1, papm1 , pum1 , pvm1 , ptm1 , pgeom1, pstd |
---|
| 285 | * , zrho , zri , zstab , ztau , zvph , zpsi, zzdep |
---|
| 286 | * , pulow, pvlow |
---|
| 287 | * , ptheta,pgamma,pmea,ppic,pval,znu ,zd1, zd2, zdmod ) |
---|
| 288 | c |
---|
| 289 | c |
---|
| 290 | c |
---|
| 291 | c*********************************************************** |
---|
| 292 | c |
---|
| 293 | c |
---|
| 294 | c* 3. compute low level stresses using subcritical and |
---|
| 295 | c* supercritical forms.computes anisotropy coefficient |
---|
| 296 | c* as measure of orographic twodimensionality. |
---|
| 297 | c |
---|
| 298 | 300 continue |
---|
| 299 | c |
---|
| 300 | call gwstress |
---|
| 301 | * ( nlon , nlev |
---|
[155] | 302 | * , ktest , icrit, ikenvh, iknu |
---|
| 303 | * , zrho , zstab, zvph , pstd, psig, pmea, ppic |
---|
| 304 | * , ztau |
---|
| 305 | * , pgeom1,zdmod) |
---|
[2] | 306 | c |
---|
| 307 | c |
---|
| 308 | c* 4. compute stress profile. |
---|
| 309 | c* ------- ------ -------- |
---|
| 310 | c |
---|
| 311 | 400 continue |
---|
| 312 | c |
---|
| 313 | c |
---|
| 314 | call gwprofil |
---|
| 315 | * ( nlon , nlev |
---|
[155] | 316 | * , kgwd , kdx |
---|
| 317 | * , ikcrith, icrit |
---|
| 318 | * , paphm1, zrho , zstab , zvph |
---|
| 319 | * , zri , ztau |
---|
| 320 | * , zdmod , psig , pstd) |
---|
[2] | 321 | c |
---|
| 322 | c |
---|
| 323 | c* 5. compute tendencies. |
---|
| 324 | c* ------------------- |
---|
| 325 | c |
---|
| 326 | 500 continue |
---|
| 327 | c |
---|
| 328 | c explicit solution at all levels for the gravity wave |
---|
| 329 | c implicit solution for the blocked levels |
---|
| 330 | |
---|
| 331 | do 510 jl=kidia,kfdia |
---|
| 332 | zvidis(jl)=0.0 |
---|
| 333 | zdudt(jl)=0.0 |
---|
| 334 | zdvdt(jl)=0.0 |
---|
| 335 | zdtdt(jl)=0.0 |
---|
| 336 | 510 continue |
---|
| 337 | c |
---|
| 338 | ilevp1=klev+1 |
---|
| 339 | c |
---|
| 340 | c |
---|
| 341 | do 524 jk=1,klev |
---|
| 342 | c |
---|
| 343 | c |
---|
| 344 | do 523 jl=1,kgwd |
---|
| 345 | ji=kdx(jl) |
---|
| 346 | zdelp=paphm1(ji,jk+1)-paphm1(ji,jk) |
---|
| 347 | ztemp=-rg*(ztau(ji,jk+1)-ztau(ji,jk))/(zvph(ji,ilevp1)*zdelp) |
---|
| 348 | zdudt(ji)=(pulow(ji)*zd1(ji)-pvlow(ji)*zd2(ji))*ztemp/zdmod(ji) |
---|
| 349 | zdvdt(ji)=(pvlow(ji)*zd1(ji)+pulow(ji)*zd2(ji))*ztemp/zdmod(ji) |
---|
| 350 | c |
---|
| 351 | c controle des overshoots: |
---|
| 352 | c |
---|
| 353 | zforc=sqrt(zdudt(ji)**2+zdvdt(ji)**2)+1.E-12 |
---|
| 354 | ztend=sqrt(pum1(ji,jk)**2+pvm1(ji,jk)**2)/ztmst+1.E-12 |
---|
| 355 | rover=0.25 |
---|
| 356 | if(zforc.ge.rover*ztend)then |
---|
| 357 | zdudt(ji)=rover*ztend/zforc*zdudt(ji) |
---|
| 358 | zdvdt(ji)=rover*ztend/zforc*zdvdt(ji) |
---|
| 359 | endif |
---|
| 360 | c |
---|
| 361 | c fin du controle des overshoots |
---|
| 362 | c |
---|
| 363 | if(jk.ge.ikenvh(ji)) then |
---|
| 364 | zb=1.0-0.18*pgamma(ji)-0.04*pgamma(ji)**2 |
---|
| 365 | zc=0.48*pgamma(ji)+0.3*pgamma(ji)**2 |
---|
| 366 | zconb=2.*ztmst*gkwake*psig(ji)/(4.*pstd(ji)) |
---|
| 367 | zabsv=sqrt(pum1(ji,jk)**2+pvm1(ji,jk)**2)/2. |
---|
| 368 | zzd1=zb*cos(zpsi(ji,jk))**2+zc*sin(zpsi(ji,jk))**2 |
---|
| 369 | ratio=(cos(zpsi(ji,jk))**2+pgamma(ji)*sin(zpsi(ji,jk))**2)/ |
---|
| 370 | * (pgamma(ji)*cos(zpsi(ji,jk))**2+sin(zpsi(ji,jk))**2) |
---|
| 371 | zbet=max(0.,2.-1./ratio)*zconb*zzdep(ji,jk)*zzd1*zabsv |
---|
| 372 | c |
---|
| 373 | c simplement oppose au vent |
---|
| 374 | c |
---|
| 375 | zdudt(ji)=-pum1(ji,jk)/ztmst |
---|
| 376 | zdvdt(ji)=-pvm1(ji,jk)/ztmst |
---|
| 377 | c |
---|
| 378 | c projection dans la direction de l'axe principal de l'orographie |
---|
| 379 | cmod zdudt(ji)=-(pum1(ji,jk)*cos(ptheta(ji)*rpi/180.) |
---|
| 380 | cmod * +pvm1(ji,jk)*sin(ptheta(ji)*rpi/180.)) |
---|
| 381 | cmod * *cos(ptheta(ji)*rpi/180.)/ztmst |
---|
| 382 | cmod zdvdt(ji)=-(pum1(ji,jk)*cos(ptheta(ji)*rpi/180.) |
---|
| 383 | cmod * +pvm1(ji,jk)*sin(ptheta(ji)*rpi/180.)) |
---|
| 384 | cmod * *sin(ptheta(ji)*rpi/180.)/ztmst |
---|
| 385 | zdudt(ji)=zdudt(ji)*(zbet/(1.+zbet)) |
---|
| 386 | zdvdt(ji)=zdvdt(ji)*(zbet/(1.+zbet)) |
---|
| 387 | end if |
---|
| 388 | pvom(ji,jk)=zdudt(ji) |
---|
| 389 | pvol(ji,jk)=zdvdt(ji) |
---|
| 390 | zust=pum1(ji,jk)+ztmst*zdudt(ji) |
---|
| 391 | zvst=pvm1(ji,jk)+ztmst*zdvdt(ji) |
---|
| 392 | zdis=0.5*(pum1(ji,jk)**2+pvm1(ji,jk)**2-zust**2-zvst**2) |
---|
| 393 | zdedt(ji)=zdis/ztmst |
---|
| 394 | zvidis(ji)=zvidis(ji)+zdis*zdelp |
---|
| 395 | zdtdt(ji)=zdedt(ji)/rcpd |
---|
| 396 | c pte(ji,jk)=zdtdt(ji) |
---|
| 397 | c |
---|
| 398 | c ENCORE UN TRUC POUR EVITER LES EXPLOSIONS |
---|
| 399 | c |
---|
| 400 | pte(ji,jk)=0.0 |
---|
| 401 | |
---|
| 402 | 523 continue |
---|
| 403 | |
---|
| 404 | 524 continue |
---|
| 405 | c |
---|
| 406 | c |
---|
| 407 | return |
---|
| 408 | end |
---|
| 409 | SUBROUTINE orosetup |
---|
[155] | 410 | * ( nlon , ktest |
---|
| 411 | * , kkcrit, kkcrith, kcrit |
---|
[2] | 412 | * , kkenvh, kknu , kknu2 |
---|
| 413 | * , paphm1, papm1 , pum1 , pvm1 , ptm1 , pgeom1, pstd |
---|
| 414 | * , prho , pri , pstab , ptau , pvph ,ppsi, pzdep |
---|
| 415 | * , pulow , pvlow |
---|
| 416 | * , ptheta, pgamma, pmea, ppic, pval |
---|
| 417 | * , pnu , pd1 , pd2 ,pdmod ) |
---|
| 418 | c |
---|
| 419 | c**** *gwsetup* |
---|
| 420 | c |
---|
| 421 | c purpose. |
---|
| 422 | c -------- |
---|
| 423 | c |
---|
| 424 | c** interface. |
---|
| 425 | c ---------- |
---|
| 426 | c from *orodrag* |
---|
| 427 | c |
---|
| 428 | c explicit arguments : |
---|
| 429 | c -------------------- |
---|
| 430 | c ==== inputs === |
---|
| 431 | c ==== outputs === |
---|
| 432 | c |
---|
| 433 | c implicit arguments : none |
---|
| 434 | c -------------------- |
---|
| 435 | c |
---|
| 436 | c method. |
---|
| 437 | c ------- |
---|
| 438 | c |
---|
| 439 | c |
---|
| 440 | c externals. |
---|
| 441 | c ---------- |
---|
| 442 | c |
---|
| 443 | c |
---|
| 444 | c reference. |
---|
| 445 | c ---------- |
---|
| 446 | c |
---|
| 447 | c see ecmwf research department documentation of the "i.f.s." |
---|
| 448 | c |
---|
| 449 | c author. |
---|
| 450 | c ------- |
---|
| 451 | c |
---|
| 452 | c modifications. |
---|
| 453 | c -------------- |
---|
| 454 | c f.lott for the new-gwdrag scheme november 1993 |
---|
| 455 | c |
---|
| 456 | c----------------------------------------------------------------------- |
---|
[155] | 457 | implicit none |
---|
[2] | 458 | c |
---|
| 459 | |
---|
| 460 | #include "dimensions.h" |
---|
| 461 | #include "dimphy.h" |
---|
| 462 | #include "YOMCST.h" |
---|
| 463 | #include "YOEGWD.h" |
---|
| 464 | |
---|
| 465 | c----------------------------------------------------------------------- |
---|
| 466 | c |
---|
| 467 | c* 0.1 arguments |
---|
| 468 | c --------- |
---|
| 469 | c |
---|
[155] | 470 | integer nlon |
---|
| 471 | integer jl, jk |
---|
| 472 | real zdelp |
---|
[2] | 473 | |
---|
[155] | 474 | integer kkcrit(nlon),kkcrith(nlon),kcrit(nlon), |
---|
| 475 | * ktest(nlon),kkenvh(nlon) |
---|
| 476 | |
---|
[2] | 477 | c |
---|
| 478 | real paphm1(nlon,klev+1),papm1(nlon,klev),pum1(nlon,klev), |
---|
| 479 | * pvm1(nlon,klev),ptm1(nlon,klev),pgeom1(nlon,klev), |
---|
| 480 | * prho(nlon,klev+1),pri(nlon,klev+1),pstab(nlon,klev+1), |
---|
| 481 | * ptau(nlon,klev+1),pvph(nlon,klev+1),ppsi(nlon,klev+1), |
---|
| 482 | * pzdep(nlon,klev) |
---|
| 483 | real pulow(nlon),pvlow(nlon),ptheta(nlon),pgamma(nlon),pnu(nlon), |
---|
| 484 | * pd1(nlon),pd2(nlon),pdmod(nlon) |
---|
| 485 | real pstd(nlon),pmea(nlon),ppic(nlon),pval(nlon) |
---|
| 486 | c |
---|
| 487 | c----------------------------------------------------------------------- |
---|
| 488 | c |
---|
| 489 | c* 0.2 local arrays |
---|
| 490 | c ------------ |
---|
| 491 | c |
---|
| 492 | c |
---|
[155] | 493 | integer ilevm1, ilevm2, ilevh |
---|
| 494 | real zcons1, zcons2,zcons3, zhgeo |
---|
| 495 | real zu, zphi, zvt1,zvt2, zst, zvar, zdwind, zwind |
---|
| 496 | real zstabm, zstabp, zrhom, zrhop, alpha |
---|
| 497 | real zggeenv, zggeom1,zgvar |
---|
| 498 | logical lo |
---|
[2] | 499 | logical ll1(klon,klev+1) |
---|
| 500 | integer kknu(klon),kknu2(klon),kknub(klon),kknul(klon), |
---|
| 501 | * kentp(klon),ncount(klon) |
---|
| 502 | c |
---|
| 503 | real zhcrit(klon,klev),zvpf(klon,klev), |
---|
| 504 | * zdp(klon,klev) |
---|
[155] | 505 | real znorm(klon),zb(klon),zc(klon), |
---|
[2] | 506 | * zulow(klon),zvlow(klon),znup(klon),znum(klon) |
---|
| 507 | c |
---|
| 508 | c ------------------------------------------------------------------ |
---|
| 509 | c |
---|
| 510 | c* 1. initialization |
---|
| 511 | c -------------- |
---|
| 512 | c |
---|
| 513 | c print *,' entree gwsetup' |
---|
| 514 | 100 continue |
---|
| 515 | c |
---|
| 516 | c ------------------------------------------------------------------ |
---|
| 517 | c |
---|
| 518 | c* 1.1 computational constants |
---|
| 519 | c ----------------------- |
---|
| 520 | c |
---|
| 521 | 110 continue |
---|
| 522 | c |
---|
| 523 | ilevm1=klev-1 |
---|
| 524 | ilevm2=klev-2 |
---|
| 525 | ilevh =klev/3 |
---|
| 526 | c |
---|
| 527 | zcons1=1./rd |
---|
| 528 | cold zcons2=g**2/cpd |
---|
| 529 | zcons2=rg**2/rcpd |
---|
| 530 | cold zcons3=1.5*api |
---|
| 531 | zcons3=1.5*rpi |
---|
| 532 | c |
---|
| 533 | c |
---|
| 534 | c ------------------------------------------------------------------ |
---|
| 535 | c |
---|
| 536 | c* 2. |
---|
| 537 | c -------------- |
---|
| 538 | c |
---|
| 539 | 200 continue |
---|
| 540 | c |
---|
| 541 | c ------------------------------------------------------------------ |
---|
| 542 | c |
---|
| 543 | c* 2.1 define low level wind, project winds in plane of |
---|
| 544 | c* low level wind, determine sector in which to take |
---|
| 545 | c* the variance and set indicator for critical levels. |
---|
| 546 | c |
---|
| 547 | c |
---|
| 548 | c |
---|
| 549 | do 2001 jl=kidia,kfdia |
---|
| 550 | kknu(jl) =klev |
---|
| 551 | kknu2(jl) =klev |
---|
| 552 | kknub(jl) =klev |
---|
| 553 | kknul(jl) =klev |
---|
| 554 | pgamma(jl) =max(pgamma(jl),gtsec) |
---|
| 555 | ll1(jl,klev+1)=.false. |
---|
| 556 | 2001 continue |
---|
| 557 | c |
---|
| 558 | c Ajouter une initialisation (L. Li, le 23fev99): |
---|
| 559 | c |
---|
| 560 | do jk=klev,ilevh,-1 |
---|
| 561 | do jl=kidia,kfdia |
---|
| 562 | ll1(jl,jk)= .FALSE. |
---|
| 563 | ENDDO |
---|
| 564 | ENDDO |
---|
| 565 | c |
---|
| 566 | c* define top of low level flow |
---|
| 567 | c ---------------------------- |
---|
| 568 | do 2002 jk=klev,ilevh,-1 |
---|
| 569 | do 2003 jl=kidia,kfdia |
---|
| 570 | lo=(paphm1(jl,jk)/paphm1(jl,klev+1)).ge.gsigcr |
---|
| 571 | if(lo) then |
---|
| 572 | kkcrit(jl)=jk |
---|
| 573 | endif |
---|
| 574 | zhcrit(jl,jk)=ppic(jl) |
---|
| 575 | zhgeo=pgeom1(jl,jk)/rg |
---|
| 576 | ll1(jl,jk)=(zhgeo.gt.zhcrit(jl,jk)) |
---|
| 577 | if(ll1(jl,jk).xor.ll1(jl,jk+1)) then |
---|
| 578 | kknu(jl)=jk |
---|
| 579 | endif |
---|
| 580 | if(.not.ll1(jl,ilevh))kknu(jl)=ilevh |
---|
| 581 | 2003 continue |
---|
| 582 | 2002 continue |
---|
| 583 | do 2004 jk=klev,ilevh,-1 |
---|
| 584 | do 2005 jl=kidia,kfdia |
---|
| 585 | zhcrit(jl,jk)=ppic(jl)-pval(jl) |
---|
| 586 | zhgeo=pgeom1(jl,jk)/rg |
---|
| 587 | ll1(jl,jk)=(zhgeo.gt.zhcrit(jl,jk)) |
---|
| 588 | if(ll1(jl,jk).xor.ll1(jl,jk+1)) then |
---|
| 589 | kknu2(jl)=jk |
---|
| 590 | endif |
---|
| 591 | if(.not.ll1(jl,ilevh))kknu2(jl)=ilevh |
---|
| 592 | 2005 continue |
---|
| 593 | 2004 continue |
---|
| 594 | do 2006 jk=klev,ilevh,-1 |
---|
| 595 | do 2007 jl=kidia,kfdia |
---|
| 596 | zhcrit(jl,jk)=amax1(ppic(jl)-pmea(jl),pmea(jl)-pval(jl)) |
---|
| 597 | zhgeo=pgeom1(jl,jk)/rg |
---|
| 598 | ll1(jl,jk)=(zhgeo.gt.zhcrit(jl,jk)) |
---|
| 599 | if(ll1(jl,jk).xor.ll1(jl,jk+1)) then |
---|
| 600 | kknub(jl)=jk |
---|
| 601 | endif |
---|
| 602 | if(.not.ll1(jl,ilevh))kknub(jl)=ilevh |
---|
| 603 | 2007 continue |
---|
| 604 | 2006 continue |
---|
| 605 | c |
---|
| 606 | do 2010 jl=kidia,kfdia |
---|
| 607 | kknu(jl)=min(kknu(jl),nktopg) |
---|
| 608 | kknu2(jl)=min(kknu2(jl),nktopg) |
---|
| 609 | kknub(jl)=min(kknub(jl),nktopg) |
---|
| 610 | kknul(jl)=klev |
---|
| 611 | 2010 continue |
---|
| 612 | c |
---|
| 613 | |
---|
| 614 | 210 continue |
---|
| 615 | c |
---|
| 616 | c |
---|
| 617 | cc* initialize various arrays |
---|
| 618 | c |
---|
| 619 | do 2107 jl=kidia,kfdia |
---|
| 620 | prho(jl,klev+1) =0.0 |
---|
| 621 | pstab(jl,klev+1) =0.0 |
---|
| 622 | pstab(jl,1) =0.0 |
---|
| 623 | pri(jl,klev+1) =9999.0 |
---|
| 624 | ppsi(jl,klev+1) =0.0 |
---|
| 625 | pri(jl,1) =0.0 |
---|
| 626 | pvph(jl,1) =0.0 |
---|
| 627 | pulow(jl) =0.0 |
---|
| 628 | pvlow(jl) =0.0 |
---|
| 629 | zulow(jl) =0.0 |
---|
| 630 | zvlow(jl) =0.0 |
---|
| 631 | kkcrith(jl) =klev |
---|
| 632 | kkenvh(jl) =klev |
---|
| 633 | kentp(jl) =klev |
---|
| 634 | kcrit(jl) =1 |
---|
| 635 | ncount(jl) =0 |
---|
| 636 | ll1(jl,klev+1) =.false. |
---|
| 637 | 2107 continue |
---|
| 638 | c |
---|
| 639 | c* define low-level flow |
---|
| 640 | c --------------------- |
---|
| 641 | c |
---|
| 642 | do 223 jk=klev,2,-1 |
---|
| 643 | do 222 jl=kidia,kfdia |
---|
| 644 | if(ktest(jl).eq.1) then |
---|
| 645 | zdp(jl,jk)=papm1(jl,jk)-papm1(jl,jk-1) |
---|
| 646 | prho(jl,jk)=2.*paphm1(jl,jk)*zcons1/(ptm1(jl,jk)+ptm1(jl,jk-1)) |
---|
| 647 | pstab(jl,jk)=2.*zcons2/(ptm1(jl,jk)+ptm1(jl,jk-1))* |
---|
| 648 | * (1.-rcpd*prho(jl,jk)*(ptm1(jl,jk)-ptm1(jl,jk-1))/zdp(jl,jk)) |
---|
| 649 | pstab(jl,jk)=max(pstab(jl,jk),gssec) |
---|
| 650 | endif |
---|
| 651 | 222 continue |
---|
| 652 | 223 continue |
---|
| 653 | c |
---|
| 654 | c******************************************************************** |
---|
| 655 | c |
---|
| 656 | c* define blocked flow |
---|
| 657 | c ------------------- |
---|
| 658 | do 2115 jk=klev,ilevh,-1 |
---|
| 659 | do 2116 jl=kidia,kfdia |
---|
| 660 | if(jk.ge.kknub(jl).and.jk.le.kknul(jl)) then |
---|
| 661 | pulow(jl)=pulow(jl)+pum1(jl,jk)*(paphm1(jl,jk+1)-paphm1(jl,jk)) |
---|
| 662 | pvlow(jl)=pvlow(jl)+pvm1(jl,jk)*(paphm1(jl,jk+1)-paphm1(jl,jk)) |
---|
| 663 | end if |
---|
| 664 | 2116 continue |
---|
| 665 | 2115 continue |
---|
| 666 | do 2110 jl=kidia,kfdia |
---|
| 667 | pulow(jl)=pulow(jl)/(paphm1(jl,kknul(jl)+1)-paphm1(jl,kknub(jl))) |
---|
| 668 | pvlow(jl)=pvlow(jl)/(paphm1(jl,kknul(jl)+1)-paphm1(jl,kknub(jl))) |
---|
| 669 | znorm(jl)=max(sqrt(pulow(jl)**2+pvlow(jl)**2),gvsec) |
---|
| 670 | pvph(jl,klev+1)=znorm(jl) |
---|
| 671 | 2110 continue |
---|
| 672 | c |
---|
| 673 | c******* setup orography axes and define plane of profiles ******* |
---|
| 674 | c |
---|
| 675 | do 2112 jl=kidia,kfdia |
---|
| 676 | lo=(pulow(jl).lt.gvsec).and.(pulow(jl).ge.-gvsec) |
---|
| 677 | if(lo) then |
---|
| 678 | zu=pulow(jl)+2.*gvsec |
---|
| 679 | else |
---|
| 680 | zu=pulow(jl) |
---|
| 681 | endif |
---|
| 682 | zphi=atan(pvlow(jl)/zu) |
---|
| 683 | ppsi(jl,klev+1)=ptheta(jl)*rpi/180.-zphi |
---|
| 684 | zb(jl)=1.-0.18*pgamma(jl)-0.04*pgamma(jl)**2 |
---|
| 685 | zc(jl)=0.48*pgamma(jl)+0.3*pgamma(jl)**2 |
---|
| 686 | pd1(jl)=zb(jl)-(zb(jl)-zc(jl))*(sin(ppsi(jl,klev+1))**2) |
---|
| 687 | pd2(jl)=(zb(jl)-zc(jl))*sin(ppsi(jl,klev+1))*cos(ppsi(jl,klev+1)) |
---|
| 688 | pdmod(jl)=sqrt(pd1(jl)**2+pd2(jl)**2) |
---|
| 689 | 2112 continue |
---|
| 690 | c |
---|
| 691 | c ************ define flow in plane of lowlevel stress ************* |
---|
| 692 | c |
---|
| 693 | do 213 jk=1,klev |
---|
| 694 | do 212 jl=kidia,kfdia |
---|
| 695 | if(ktest(jl).eq.1) then |
---|
| 696 | zvt1 =pulow(jl)*pum1(jl,jk)+pvlow(jl)*pvm1(jl,jk) |
---|
| 697 | zvt2 =-pvlow(jl)*pum1(jl,jk)+pulow(jl)*pvm1(jl,jk) |
---|
| 698 | zvpf(jl,jk)=(zvt1*pd1(jl)+zvt2*pd2(jl))/(znorm(jl)*pdmod(jl)) |
---|
| 699 | endif |
---|
| 700 | ptau(jl,jk) =0.0 |
---|
| 701 | pzdep(jl,jk) =0.0 |
---|
| 702 | ppsi(jl,jk) =0.0 |
---|
| 703 | ll1(jl,jk) =.false. |
---|
| 704 | 212 continue |
---|
| 705 | 213 continue |
---|
| 706 | do 215 jk=2,klev |
---|
| 707 | do 214 jl=kidia,kfdia |
---|
| 708 | if(ktest(jl).eq.1) then |
---|
| 709 | zdp(jl,jk)=papm1(jl,jk)-papm1(jl,jk-1) |
---|
| 710 | pvph(jl,jk)=((paphm1(jl,jk)-papm1(jl,jk-1))*zvpf(jl,jk)+ |
---|
| 711 | * (papm1(jl,jk)-paphm1(jl,jk))*zvpf(jl,jk-1)) |
---|
| 712 | * /zdp(jl,jk) |
---|
| 713 | if(pvph(jl,jk).lt.gvsec) then |
---|
| 714 | pvph(jl,jk)=gvsec |
---|
| 715 | kcrit(jl)=jk |
---|
| 716 | endif |
---|
| 717 | endif |
---|
| 718 | 214 continue |
---|
| 719 | 215 continue |
---|
| 720 | c |
---|
| 721 | c |
---|
| 722 | c* 2.2 brunt-vaisala frequency and density at half levels. |
---|
| 723 | c |
---|
| 724 | 220 continue |
---|
| 725 | c |
---|
| 726 | do 2211 jk=ilevh,klev |
---|
| 727 | do 221 jl=kidia,kfdia |
---|
| 728 | if(ktest(jl).eq.1) then |
---|
| 729 | if(jk.ge.(kknub(jl)+1).and.jk.le.kknul(jl)) then |
---|
| 730 | zst=zcons2/ptm1(jl,jk)*(1.-rcpd*prho(jl,jk)* |
---|
| 731 | * (ptm1(jl,jk)-ptm1(jl,jk-1))/zdp(jl,jk)) |
---|
| 732 | pstab(jl,klev+1)=pstab(jl,klev+1)+zst*zdp(jl,jk) |
---|
| 733 | pstab(jl,klev+1)=max(pstab(jl,klev+1),gssec) |
---|
| 734 | prho(jl,klev+1)=prho(jl,klev+1)+paphm1(jl,jk)*2.*zdp(jl,jk) |
---|
| 735 | * *zcons1/(ptm1(jl,jk)+ptm1(jl,jk-1)) |
---|
| 736 | endif |
---|
| 737 | endif |
---|
| 738 | 221 continue |
---|
| 739 | 2211 continue |
---|
| 740 | c |
---|
| 741 | do 2212 jl=kidia,kfdia |
---|
| 742 | pstab(jl,klev+1)=pstab(jl,klev+1)/(papm1(jl,kknul(jl)) |
---|
| 743 | * -papm1(jl,kknub(jl))) |
---|
| 744 | prho(jl,klev+1)=prho(jl,klev+1)/(papm1(jl,kknul(jl)) |
---|
| 745 | * -papm1(jl,kknub(jl))) |
---|
| 746 | zvar=pstd(jl) |
---|
| 747 | 2212 continue |
---|
| 748 | c |
---|
| 749 | c* 2.3 mean flow richardson number. |
---|
| 750 | c* and critical height for froude layer |
---|
| 751 | c |
---|
| 752 | 230 continue |
---|
| 753 | c |
---|
| 754 | do 232 jk=2,klev |
---|
| 755 | do 231 jl=kidia,kfdia |
---|
| 756 | if(ktest(jl).eq.1) then |
---|
| 757 | zdwind=max(abs(zvpf(jl,jk)-zvpf(jl,jk-1)),gvsec) |
---|
| 758 | pri(jl,jk)=pstab(jl,jk)*(zdp(jl,jk) |
---|
| 759 | * /(rg*prho(jl,jk)*zdwind))**2 |
---|
| 760 | pri(jl,jk)=max(pri(jl,jk),grcrit) |
---|
| 761 | endif |
---|
| 762 | 231 continue |
---|
| 763 | 232 continue |
---|
| 764 | |
---|
| 765 | c |
---|
| 766 | c |
---|
| 767 | c* define top of 'envelope' layer |
---|
| 768 | c ---------------------------- |
---|
| 769 | |
---|
| 770 | do 233 jl=kidia,kfdia |
---|
| 771 | pnu (jl)=0.0 |
---|
| 772 | znum(jl)=0.0 |
---|
| 773 | 233 continue |
---|
| 774 | |
---|
| 775 | do 234 jk=2,klev-1 |
---|
| 776 | do 234 jl=kidia,kfdia |
---|
| 777 | |
---|
| 778 | if(ktest(jl).eq.1) then |
---|
| 779 | |
---|
| 780 | if (jk.ge.kknub(jl)) then |
---|
| 781 | |
---|
| 782 | znum(jl)=pnu(jl) |
---|
| 783 | zwind=(pulow(jl)*pum1(jl,jk)+pvlow(jl)*pvm1(jl,jk))/ |
---|
| 784 | * max(sqrt(pulow(jl)**2+pvlow(jl)**2),gvsec) |
---|
| 785 | zwind=max(sqrt(zwind**2),gvsec) |
---|
| 786 | zdelp=paphm1(jl,jk+1)-paphm1(jl,jk) |
---|
| 787 | zstabm=sqrt(max(pstab(jl,jk ),gssec)) |
---|
| 788 | zstabp=sqrt(max(pstab(jl,jk+1),gssec)) |
---|
| 789 | zrhom=prho(jl,jk ) |
---|
| 790 | zrhop=prho(jl,jk+1) |
---|
| 791 | pnu(jl) = pnu(jl) + (zdelp/rg)* |
---|
| 792 | * ((zstabp/zrhop+zstabm/zrhom)/2.)/zwind |
---|
| 793 | if((znum(jl).le.gfrcrit).and.(pnu(jl).gt.gfrcrit) |
---|
| 794 | * .and.(kkenvh(jl).eq.klev)) |
---|
| 795 | * kkenvh(jl)=jk |
---|
| 796 | |
---|
| 797 | endif |
---|
| 798 | |
---|
| 799 | endif |
---|
| 800 | |
---|
| 801 | 234 continue |
---|
| 802 | |
---|
| 803 | c calculation of a dynamical mixing height for the breaking |
---|
| 804 | c of gravity waves: |
---|
| 805 | |
---|
| 806 | |
---|
| 807 | do 235 jl=kidia,kfdia |
---|
| 808 | znup(jl)=0.0 |
---|
| 809 | znum(jl)=0.0 |
---|
| 810 | 235 continue |
---|
| 811 | |
---|
| 812 | do 236 jk=klev-1,2,-1 |
---|
| 813 | do 236 jl=kidia,kfdia |
---|
| 814 | |
---|
| 815 | if(ktest(jl).eq.1) then |
---|
| 816 | |
---|
| 817 | znum(jl)=znup(jl) |
---|
| 818 | zwind=(pulow(jl)*pum1(jl,jk)+pvlow(jl)*pvm1(jl,jk))/ |
---|
| 819 | * max(sqrt(pulow(jl)**2+pvlow(jl)**2),gvsec) |
---|
| 820 | zwind=max(sqrt(zwind**2),gvsec) |
---|
| 821 | zdelp=paphm1(jl,jk+1)-paphm1(jl,jk) |
---|
| 822 | zstabm=sqrt(max(pstab(jl,jk ),gssec)) |
---|
| 823 | zstabp=sqrt(max(pstab(jl,jk+1),gssec)) |
---|
| 824 | zrhom=prho(jl,jk ) |
---|
| 825 | zrhop=prho(jl,jk+1) |
---|
| 826 | znup(jl) = znup(jl) + (zdelp/rg)* |
---|
| 827 | * ((zstabp/zrhop+zstabm/zrhom)/2.)/zwind |
---|
| 828 | if((znum(jl).le.rpi/2.).and.(znup(jl).gt.rpi/2.) |
---|
| 829 | * .and.(kkcrith(jl).eq.klev)) |
---|
| 830 | * kkcrith(jl)=jk |
---|
| 831 | |
---|
| 832 | endif |
---|
| 833 | |
---|
| 834 | 236 continue |
---|
| 835 | |
---|
| 836 | do 237 jl=kidia,kfdia |
---|
| 837 | kkcrith(jl)=min0(kkcrith(jl),kknu2(jl)) |
---|
| 838 | kkcrith(jl)=max0(kkcrith(jl),ilevh*2) |
---|
| 839 | 237 continue |
---|
| 840 | c |
---|
| 841 | c directional info for flow blocking ************************* |
---|
| 842 | c |
---|
| 843 | do 251 jk=ilevh,klev |
---|
| 844 | do 252 jl=kidia,kfdia |
---|
| 845 | if(jk.ge.kkenvh(jl)) then |
---|
| 846 | lo=(pum1(jl,jk).lt.gvsec).and.(pum1(jl,jk).ge.-gvsec) |
---|
| 847 | if(lo) then |
---|
| 848 | zu=pum1(jl,jk)+2.*gvsec |
---|
| 849 | else |
---|
| 850 | zu=pum1(jl,jk) |
---|
| 851 | endif |
---|
| 852 | zphi=atan(pvm1(jl,jk)/zu) |
---|
| 853 | ppsi(jl,jk)=ptheta(jl)*rpi/180.-zphi |
---|
| 854 | end if |
---|
| 855 | 252 continue |
---|
| 856 | 251 continue |
---|
| 857 | c forms the vertical 'leakiness' ************************** |
---|
| 858 | |
---|
| 859 | alpha=3. |
---|
| 860 | |
---|
| 861 | do 254 jk=ilevh,klev |
---|
| 862 | do 253 jl=kidia,kfdia |
---|
| 863 | if(jk.ge.kkenvh(jl)) then |
---|
| 864 | zggeenv=amax1(1., |
---|
| 865 | * (pgeom1(jl,kkenvh(jl))+pgeom1(jl,kkenvh(jl)-1))/2.) |
---|
| 866 | zggeom1=amax1(pgeom1(jl,jk),1.) |
---|
| 867 | zgvar=amax1(pstd(jl)*rg,1.) |
---|
| 868 | cmod pzdep(jl,jk)=sqrt((zggeenv-zggeom1)/(zggeom1+zgvar)) |
---|
| 869 | pzdep(jl,jk)=(pgeom1(jl,kkenvh(jl)-1)-pgeom1(jl, jk))/ |
---|
| 870 | * (pgeom1(jl,kkenvh(jl)-1)-pgeom1(jl,klev)) |
---|
| 871 | end if |
---|
| 872 | 253 continue |
---|
| 873 | 254 continue |
---|
| 874 | |
---|
| 875 | 260 continue |
---|
| 876 | |
---|
| 877 | return |
---|
| 878 | end |
---|
| 879 | SUBROUTINE gwstress |
---|
| 880 | * ( nlon , nlev |
---|
[155] | 881 | * , ktest, kcrit, kkenvh |
---|
[2] | 882 | * , kknu |
---|
| 883 | * , prho , pstab , pvph , pstd, psig |
---|
[155] | 884 | * , pmea , ppic , ptau |
---|
| 885 | * , pgeom1 , pdmod ) |
---|
[2] | 886 | c |
---|
| 887 | c**** *gwstress* |
---|
| 888 | c |
---|
| 889 | c purpose. |
---|
| 890 | c -------- |
---|
| 891 | c |
---|
| 892 | c** interface. |
---|
| 893 | c ---------- |
---|
| 894 | c call *gwstress* from *gwdrag* |
---|
| 895 | c |
---|
| 896 | c explicit arguments : |
---|
| 897 | c -------------------- |
---|
| 898 | c ==== inputs === |
---|
| 899 | c ==== outputs === |
---|
| 900 | c |
---|
| 901 | c implicit arguments : none |
---|
| 902 | c -------------------- |
---|
| 903 | c |
---|
| 904 | c method. |
---|
| 905 | c ------- |
---|
| 906 | c |
---|
| 907 | c |
---|
| 908 | c externals. |
---|
| 909 | c ---------- |
---|
| 910 | c |
---|
| 911 | c |
---|
| 912 | c reference. |
---|
| 913 | c ---------- |
---|
| 914 | c |
---|
| 915 | c see ecmwf research department documentation of the "i.f.s." |
---|
| 916 | c |
---|
| 917 | c author. |
---|
| 918 | c ------- |
---|
| 919 | c |
---|
| 920 | c modifications. |
---|
| 921 | c -------------- |
---|
| 922 | c f. lott put the new gwd on ifs 22/11/93 |
---|
| 923 | c |
---|
| 924 | c----------------------------------------------------------------------- |
---|
[155] | 925 | implicit none |
---|
[2] | 926 | #include "dimensions.h" |
---|
| 927 | #include "dimphy.h" |
---|
| 928 | #include "YOMCST.h" |
---|
| 929 | #include "YOEGWD.h" |
---|
| 930 | |
---|
| 931 | c----------------------------------------------------------------------- |
---|
| 932 | c |
---|
| 933 | c* 0.1 arguments |
---|
| 934 | c --------- |
---|
| 935 | c |
---|
[155] | 936 | integer nlon, nlev |
---|
| 937 | integer kcrit(nlon), |
---|
| 938 | * ktest(nlon),kkenvh(nlon),kknu(nlon) |
---|
[2] | 939 | c |
---|
| 940 | real prho(nlon,nlev+1),pstab(nlon,nlev+1),ptau(nlon,nlev+1), |
---|
[155] | 941 | * pvph(nlon,nlev+1), |
---|
[2] | 942 | * pgeom1(nlon,nlev),pstd(nlon) |
---|
| 943 | c |
---|
[155] | 944 | real psig(nlon) |
---|
| 945 | real pmea(nlon),ppic(nlon) |
---|
[2] | 946 | real pdmod(nlon) |
---|
| 947 | c |
---|
| 948 | c----------------------------------------------------------------------- |
---|
| 949 | c |
---|
| 950 | c* 0.2 local arrays |
---|
| 951 | c ------------ |
---|
[155] | 952 | integer jl |
---|
| 953 | real zblock, zvar, zeff |
---|
| 954 | logical lo |
---|
[2] | 955 | c |
---|
| 956 | c----------------------------------------------------------------------- |
---|
| 957 | c |
---|
| 958 | c* 0.3 functions |
---|
| 959 | c --------- |
---|
| 960 | c ------------------------------------------------------------------ |
---|
| 961 | c |
---|
| 962 | c* 1. initialization |
---|
| 963 | c -------------- |
---|
| 964 | c |
---|
| 965 | 100 continue |
---|
| 966 | c |
---|
| 967 | c* 3.1 gravity wave stress. |
---|
| 968 | c |
---|
| 969 | 300 continue |
---|
| 970 | c |
---|
| 971 | c |
---|
| 972 | do 301 jl=kidia,kfdia |
---|
| 973 | if(ktest(jl).eq.1) then |
---|
| 974 | |
---|
| 975 | c effective mountain height above the blocked flow |
---|
| 976 | |
---|
| 977 | if(kkenvh(jl).eq.klev)then |
---|
| 978 | zblock=0.0 |
---|
| 979 | else |
---|
| 980 | zblock=(pgeom1(jl,kkenvh(jl))+pgeom1(jl,kkenvh(jl)+1))/2./rg |
---|
| 981 | endif |
---|
| 982 | |
---|
| 983 | zvar=ppic(jl)-pmea(jl) |
---|
| 984 | zeff=amax1(0.,zvar-zblock) |
---|
| 985 | |
---|
| 986 | ptau(jl,klev+1)=prho(jl,klev+1)*gkdrag*psig(jl)*zeff**2 |
---|
| 987 | * /4./pstd(jl)*pvph(jl,klev+1)*pdmod(jl)*sqrt(pstab(jl,klev+1)) |
---|
| 988 | |
---|
| 989 | c too small value of stress or low level flow include critical level |
---|
| 990 | c or low level flow: gravity wave stress nul. |
---|
| 991 | |
---|
| 992 | lo=(ptau(jl,klev+1).lt.gtsec).or.(kcrit(jl).ge.kknu(jl)) |
---|
| 993 | * .or.(pvph(jl,klev+1).lt.gvcrit) |
---|
| 994 | c if(lo) ptau(jl,klev+1)=0.0 |
---|
| 995 | |
---|
| 996 | else |
---|
| 997 | |
---|
| 998 | ptau(jl,klev+1)=0.0 |
---|
| 999 | |
---|
| 1000 | endif |
---|
| 1001 | |
---|
| 1002 | 301 continue |
---|
| 1003 | c |
---|
| 1004 | return |
---|
| 1005 | end |
---|
| 1006 | SUBROUTINE GWPROFIL |
---|
| 1007 | * ( NLON, NLEV |
---|
[155] | 1008 | * , kgwd, kdx |
---|
| 1009 | * , KKCRITH, KCRIT |
---|
| 1010 | * , PAPHM1, PRHO , PSTAB , PVPH , PRI , PTAU |
---|
| 1011 | * , pdmod , psig , pvar) |
---|
[2] | 1012 | |
---|
| 1013 | C**** *GWPROFIL* |
---|
| 1014 | C |
---|
| 1015 | C PURPOSE. |
---|
| 1016 | C -------- |
---|
| 1017 | C |
---|
| 1018 | C** INTERFACE. |
---|
| 1019 | C ---------- |
---|
| 1020 | C FROM *GWDRAG* |
---|
| 1021 | C |
---|
| 1022 | C EXPLICIT ARGUMENTS : |
---|
| 1023 | C -------------------- |
---|
| 1024 | C ==== INPUTS === |
---|
| 1025 | C ==== OUTPUTS === |
---|
| 1026 | C |
---|
| 1027 | C IMPLICIT ARGUMENTS : NONE |
---|
| 1028 | C -------------------- |
---|
| 1029 | C |
---|
| 1030 | C METHOD: |
---|
| 1031 | C ------- |
---|
| 1032 | C THE STRESS PROFILE FOR GRAVITY WAVES IS COMPUTED AS FOLLOWS: |
---|
| 1033 | C IT IS CONSTANT (NO GWD) AT THE LEVELS BETWEEN THE GROUND |
---|
| 1034 | C AND THE TOP OF THE BLOCKED LAYER (KKENVH). |
---|
| 1035 | C IT DECREASES LINEARLY WITH HEIGHTS FROM THE TOP OF THE |
---|
| 1036 | C BLOCKED LAYER TO 3*VAROR (kKNU), TO SIMULATES LEE WAVES OR |
---|
| 1037 | C NONLINEAR GRAVITY WAVE BREAKING. |
---|
| 1038 | C ABOVE IT IS CONSTANT, EXCEPT WHEN THE WAVE ENCOUNTERS A CRITICAL |
---|
| 1039 | C LEVEL (KCRIT) OR WHEN IT BREAKS. |
---|
| 1040 | C |
---|
| 1041 | C |
---|
| 1042 | C |
---|
| 1043 | C EXTERNALS. |
---|
| 1044 | C ---------- |
---|
| 1045 | C |
---|
| 1046 | C |
---|
| 1047 | C REFERENCE. |
---|
| 1048 | C ---------- |
---|
| 1049 | C |
---|
| 1050 | C SEE ECMWF RESEARCH DEPARTMENT DOCUMENTATION OF THE "I.F.S." |
---|
| 1051 | C |
---|
| 1052 | C AUTHOR. |
---|
| 1053 | C ------- |
---|
| 1054 | C |
---|
| 1055 | C MODIFICATIONS. |
---|
| 1056 | C -------------- |
---|
| 1057 | C PASSAGE OF THE NEW GWDRAG TO I.F.S. (F. LOTT, 22/11/93) |
---|
| 1058 | C----------------------------------------------------------------------- |
---|
[155] | 1059 | implicit none |
---|
[2] | 1060 | C |
---|
| 1061 | |
---|
| 1062 | C |
---|
| 1063 | |
---|
| 1064 | #include "dimensions.h" |
---|
| 1065 | #include "dimphy.h" |
---|
| 1066 | #include "YOMCST.h" |
---|
| 1067 | #include "YOEGWD.h" |
---|
| 1068 | |
---|
| 1069 | C----------------------------------------------------------------------- |
---|
| 1070 | C |
---|
| 1071 | C* 0.1 ARGUMENTS |
---|
| 1072 | C --------- |
---|
| 1073 | C |
---|
[155] | 1074 | integer nlon,nlev |
---|
| 1075 | INTEGER KKCRITH(NLON),KCRIT(NLON) |
---|
| 1076 | * ,kdx(nlon) |
---|
[2] | 1077 | C |
---|
| 1078 | REAL PAPHM1(NLON,NLEV+1), PSTAB(NLON,NLEV+1), |
---|
| 1079 | * PRHO (NLON,NLEV+1), PVPH (NLON,NLEV+1), |
---|
[155] | 1080 | * PRI (NLON,NLEV+1), PTAU(NLON,NLEV+1) |
---|
[2] | 1081 | |
---|
[155] | 1082 | REAL pdmod (NLON) , psig(NLON), |
---|
| 1083 | * pvar(NLON) |
---|
[2] | 1084 | |
---|
| 1085 | C----------------------------------------------------------------------- |
---|
| 1086 | C |
---|
| 1087 | C* 0.2 LOCAL ARRAYS |
---|
| 1088 | C ------------ |
---|
| 1089 | C |
---|
[155] | 1090 | integer ilevh, ji, kgwd, jl, jk |
---|
| 1091 | real zsqr, zalfa, zriw, zdel, zb, zalpha,zdz2n |
---|
| 1092 | real zdelp, zdelpt |
---|
[2] | 1093 | REAL ZDZ2 (KLON,KLEV) , ZNORM(KLON) , zoro(KLON) |
---|
| 1094 | REAL ZTAU (KLON,KLEV+1) |
---|
| 1095 | C |
---|
| 1096 | C----------------------------------------------------------------------- |
---|
| 1097 | C |
---|
| 1098 | C* 1. INITIALIZATION |
---|
| 1099 | C -------------- |
---|
| 1100 | C |
---|
| 1101 | c print *,' entree gwprofil' |
---|
| 1102 | 100 CONTINUE |
---|
| 1103 | C |
---|
| 1104 | C |
---|
| 1105 | C* COMPUTATIONAL CONSTANTS. |
---|
| 1106 | C ------------- ---------- |
---|
| 1107 | C |
---|
| 1108 | ilevh=KLEV/3 |
---|
| 1109 | C |
---|
| 1110 | DO 400 ji=1,kgwd |
---|
| 1111 | jl=kdx(ji) |
---|
| 1112 | Zoro(JL)=Psig(JL)*Pdmod(JL)/4./max(pvar(jl),1.0) |
---|
| 1113 | ZTAU(JL,KLEV+1)=PTAU(JL,KLEV+1) |
---|
| 1114 | 400 CONTINUE |
---|
| 1115 | |
---|
| 1116 | C |
---|
| 1117 | DO 430 JK=KLEV,2,-1 |
---|
| 1118 | C |
---|
| 1119 | C |
---|
| 1120 | C* 4.1 CONSTANT WAVE STRESS UNTIL TOP OF THE |
---|
| 1121 | C BLOCKING LAYER. |
---|
| 1122 | 410 CONTINUE |
---|
| 1123 | C |
---|
| 1124 | DO 411 ji=1,kgwd |
---|
| 1125 | jl=kdx(ji) |
---|
| 1126 | IF(JK.GT.KKCRITH(JL)) THEN |
---|
| 1127 | PTAU(JL,JK)=ZTAU(JL,KLEV+1) |
---|
| 1128 | C ENDIF |
---|
| 1129 | C IF(JK.EQ.KKCRITH(JL)) THEN |
---|
| 1130 | ELSE |
---|
| 1131 | PTAU(JL,JK)=GRAHILO*ZTAU(JL,KLEV+1) |
---|
| 1132 | ENDIF |
---|
| 1133 | 411 CONTINUE |
---|
| 1134 | C |
---|
| 1135 | C* 4.15 CONSTANT SHEAR STRESS UNTIL THE TOP OF THE |
---|
| 1136 | C LOW LEVEL FLOW LAYER. |
---|
| 1137 | 415 CONTINUE |
---|
| 1138 | C |
---|
| 1139 | C |
---|
| 1140 | C* 4.2 WAVE DISPLACEMENT AT NEXT LEVEL. |
---|
| 1141 | C |
---|
| 1142 | 420 CONTINUE |
---|
| 1143 | C |
---|
| 1144 | DO 421 ji=1,kgwd |
---|
| 1145 | jl=kdx(ji) |
---|
| 1146 | IF(JK.LT.KKCRITH(JL)) THEN |
---|
| 1147 | ZNORM(JL)=gkdrag*PRHO(JL,JK)*SQRT(PSTAB(JL,JK))*PVPH(JL,JK) |
---|
| 1148 | * *zoro(jl) |
---|
| 1149 | ZDZ2(JL,JK)=PTAU(JL,JK+1)/max(ZNORM(JL),gssec) |
---|
| 1150 | ENDIF |
---|
| 1151 | 421 CONTINUE |
---|
| 1152 | C |
---|
| 1153 | C* 4.3 WAVE RICHARDSON NUMBER, NEW WAVE DISPLACEMENT |
---|
| 1154 | C* AND STRESS: BREAKING EVALUATION AND CRITICAL |
---|
| 1155 | C LEVEL |
---|
| 1156 | C |
---|
| 1157 | |
---|
| 1158 | DO 431 ji=1,kgwd |
---|
| 1159 | jl=kdx(ji) |
---|
| 1160 | IF(JK.LT.KKCRITH(JL)) THEN |
---|
| 1161 | IF((PTAU(JL,JK+1).LT.GTSEC).OR.(JK.LE.KCRIT(JL))) THEN |
---|
| 1162 | PTAU(JL,JK)=0.0 |
---|
| 1163 | ELSE |
---|
| 1164 | ZSQR=SQRT(PRI(JL,JK)) |
---|
| 1165 | ZALFA=SQRT(PSTAB(JL,JK)*ZDZ2(JL,JK))/PVPH(JL,JK) |
---|
| 1166 | ZRIW=PRI(JL,JK)*(1.-ZALFA)/(1+ZALFA*ZSQR)**2 |
---|
| 1167 | IF(ZRIW.LT.GRCRIT) THEN |
---|
| 1168 | ZDEL=4./ZSQR/GRCRIT+1./GRCRIT**2+4./GRCRIT |
---|
| 1169 | ZB=1./GRCRIT+2./ZSQR |
---|
| 1170 | ZALPHA=0.5*(-ZB+SQRT(ZDEL)) |
---|
| 1171 | ZDZ2N=(PVPH(JL,JK)*ZALPHA)**2/PSTAB(JL,JK) |
---|
| 1172 | PTAU(JL,JK)=ZNORM(JL)*ZDZ2N |
---|
| 1173 | ELSE |
---|
| 1174 | PTAU(JL,JK)=ZNORM(JL)*ZDZ2(JL,JK) |
---|
| 1175 | ENDIF |
---|
| 1176 | PTAU(JL,JK)=MIN(PTAU(JL,JK),PTAU(JL,JK+1)) |
---|
| 1177 | ENDIF |
---|
| 1178 | ENDIF |
---|
| 1179 | 431 CONTINUE |
---|
| 1180 | |
---|
| 1181 | 430 CONTINUE |
---|
| 1182 | 440 CONTINUE |
---|
| 1183 | |
---|
| 1184 | C REORGANISATION OF THE STRESS PROFILE AT LOW LEVEL |
---|
| 1185 | |
---|
| 1186 | DO 530 ji=1,kgwd |
---|
| 1187 | jl=kdx(ji) |
---|
| 1188 | ZTAU(JL,KKCRITH(JL))=PTAU(JL,KKCRITH(JL)) |
---|
| 1189 | ZTAU(JL,NSTRA)=PTAU(JL,NSTRA) |
---|
| 1190 | 530 CONTINUE |
---|
| 1191 | |
---|
| 1192 | DO 531 JK=1,KLEV |
---|
| 1193 | |
---|
| 1194 | DO 532 ji=1,kgwd |
---|
| 1195 | jl=kdx(ji) |
---|
| 1196 | |
---|
| 1197 | IF(JK.GT.KKCRITH(JL))THEN |
---|
| 1198 | |
---|
| 1199 | ZDELP=PAPHM1(JL,JK)-PAPHM1(JL,KLEV+1 ) |
---|
| 1200 | ZDELPT=PAPHM1(JL,KKCRITH(JL))-PAPHM1(JL,KLEV+1 ) |
---|
| 1201 | PTAU(JL,JK)=ZTAU(JL,KLEV+1 ) + |
---|
| 1202 | . (ZTAU(JL,KKCRITH(JL))-ZTAU(JL,KLEV+1 ) )* |
---|
| 1203 | . ZDELP/ZDELPT |
---|
| 1204 | |
---|
| 1205 | ENDIF |
---|
| 1206 | |
---|
| 1207 | 532 CONTINUE |
---|
| 1208 | |
---|
| 1209 | C REORGANISATION IN THE STRATOSPHERE |
---|
| 1210 | |
---|
| 1211 | DO 533 ji=1,kgwd |
---|
| 1212 | jl=kdx(ji) |
---|
| 1213 | |
---|
| 1214 | IF(JK.LT.NSTRA)THEN |
---|
| 1215 | |
---|
| 1216 | ZDELP =PAPHM1(JL,NSTRA) |
---|
| 1217 | ZDELPT=PAPHM1(JL,JK) |
---|
| 1218 | PTAU(JL,JK)=ZTAU(JL,NSTRA)*ZDELPT/ZDELP |
---|
| 1219 | |
---|
| 1220 | ENDIF |
---|
| 1221 | |
---|
| 1222 | 533 CONTINUE |
---|
| 1223 | |
---|
| 1224 | C REORGANISATION IN THE TROPOSPHERE |
---|
| 1225 | |
---|
| 1226 | DO 534 ji=1,kgwd |
---|
| 1227 | jl=kdx(ji) |
---|
| 1228 | |
---|
| 1229 | IF(JK.LT.KKCRITH(JL).AND.JK.GT.NSTRA)THEN |
---|
| 1230 | |
---|
| 1231 | ZDELP=PAPHM1(JL,JK)-PAPHM1(JL,KKCRITH(JL)) |
---|
| 1232 | ZDELPT=PAPHM1(JL,NSTRA)-PAPHM1(JL,KKCRITH(JL)) |
---|
| 1233 | PTAU(JL,JK)=ZTAU(JL,KKCRITH(JL)) + |
---|
| 1234 | * (ZTAU(JL,NSTRA)-ZTAU(JL,KKCRITH(JL)))*ZDELP/ZDELPT |
---|
| 1235 | |
---|
| 1236 | ENDIF |
---|
| 1237 | 534 CONTINUE |
---|
| 1238 | |
---|
| 1239 | |
---|
| 1240 | 531 CONTINUE |
---|
| 1241 | |
---|
| 1242 | |
---|
| 1243 | RETURN |
---|
| 1244 | END |
---|
| 1245 | SUBROUTINE lift_noro (nlon,nlev,dtime,paprs,pplay, |
---|
[155] | 1246 | e plat,pmea,pstd, ppic, |
---|
| 1247 | e ktest, |
---|
[2] | 1248 | e t, u, v, |
---|
| 1249 | s pulow, pvlow, pustr, pvstr, |
---|
| 1250 | s d_t, d_u, d_v) |
---|
| 1251 | c |
---|
| 1252 | IMPLICIT none |
---|
| 1253 | c====================================================================== |
---|
| 1254 | c Auteur(s): F.Lott (LMD/CNRS) date: 19950201 |
---|
| 1255 | c Objet: Frottement de la montagne Interface |
---|
| 1256 | c====================================================================== |
---|
| 1257 | c Arguments: |
---|
| 1258 | c dtime---input-R- pas d'integration (s) |
---|
| 1259 | c paprs---input-R-pression pour chaque inter-couche (en Pa) |
---|
| 1260 | c pplay---input-R-pression pour le mileu de chaque couche (en Pa) |
---|
| 1261 | c t-------input-R-temperature (K) |
---|
| 1262 | c u-------input-R-vitesse horizontale (m/s) |
---|
| 1263 | c v-------input-R-vitesse horizontale (m/s) |
---|
| 1264 | c |
---|
| 1265 | c d_t-----output-R-increment de la temperature |
---|
| 1266 | c d_u-----output-R-increment de la vitesse u |
---|
| 1267 | c d_v-----output-R-increment de la vitesse v |
---|
| 1268 | c====================================================================== |
---|
| 1269 | #include "dimensions.h" |
---|
| 1270 | #include "dimphy.h" |
---|
| 1271 | #include "YOMCST.h" |
---|
| 1272 | c |
---|
| 1273 | c ARGUMENTS |
---|
| 1274 | c |
---|
| 1275 | INTEGER nlon,nlev |
---|
| 1276 | REAL dtime |
---|
| 1277 | REAL paprs(klon,klev+1) |
---|
| 1278 | REAL pplay(klon,klev) |
---|
| 1279 | REAL plat(nlon),pmea(nlon) |
---|
[155] | 1280 | REAL pstd(nlon) |
---|
| 1281 | REAL ppic(nlon) |
---|
[2] | 1282 | REAL pulow(nlon),pvlow(nlon),pustr(nlon),pvstr(nlon) |
---|
| 1283 | REAL t(nlon,nlev), u(nlon,nlev), v(nlon,nlev) |
---|
| 1284 | REAL d_t(nlon,nlev), d_u(nlon,nlev), d_v(nlon,nlev) |
---|
| 1285 | c |
---|
[155] | 1286 | INTEGER i, k, ktest(nlon) |
---|
[2] | 1287 | c |
---|
| 1288 | c Variables locales: |
---|
| 1289 | c |
---|
| 1290 | REAL zgeom(klon,klev) |
---|
| 1291 | REAL pdtdt(klon,klev), pdudt(klon,klev), pdvdt(klon,klev) |
---|
| 1292 | REAL pt(klon,klev), pu(klon,klev), pv(klon,klev) |
---|
| 1293 | REAL papmf(klon,klev),papmh(klon,klev+1) |
---|
| 1294 | c |
---|
| 1295 | c initialiser les variables de sortie (pour securite) |
---|
| 1296 | c |
---|
| 1297 | DO i = 1,klon |
---|
| 1298 | pulow(i) = 0.0 |
---|
| 1299 | pvlow(i) = 0.0 |
---|
| 1300 | pustr(i) = 0.0 |
---|
| 1301 | pvstr(i) = 0.0 |
---|
| 1302 | ENDDO |
---|
| 1303 | DO k = 1, klev |
---|
| 1304 | DO i = 1, klon |
---|
| 1305 | d_t(i,k) = 0.0 |
---|
| 1306 | d_u(i,k) = 0.0 |
---|
| 1307 | d_v(i,k) = 0.0 |
---|
| 1308 | pdudt(i,k)=0.0 |
---|
| 1309 | pdvdt(i,k)=0.0 |
---|
| 1310 | pdtdt(i,k)=0.0 |
---|
| 1311 | ENDDO |
---|
| 1312 | ENDDO |
---|
| 1313 | c |
---|
| 1314 | c preparer les variables d'entree (attention: l'ordre des niveaux |
---|
| 1315 | c verticaux augmente du haut vers le bas) |
---|
| 1316 | c |
---|
| 1317 | DO k = 1, klev |
---|
| 1318 | DO i = 1, klon |
---|
| 1319 | pt(i,k) = t(i,klev-k+1) |
---|
| 1320 | pu(i,k) = u(i,klev-k+1) |
---|
| 1321 | pv(i,k) = v(i,klev-k+1) |
---|
| 1322 | papmf(i,k) = pplay(i,klev-k+1) |
---|
| 1323 | ENDDO |
---|
| 1324 | ENDDO |
---|
| 1325 | DO k = 1, klev+1 |
---|
| 1326 | DO i = 1, klon |
---|
| 1327 | papmh(i,k) = paprs(i,klev-k+2) |
---|
| 1328 | ENDDO |
---|
| 1329 | ENDDO |
---|
| 1330 | DO i = 1, klon |
---|
| 1331 | zgeom(i,klev) = RD * pt(i,klev) |
---|
| 1332 | . * LOG(papmh(i,klev+1)/papmf(i,klev)) |
---|
| 1333 | ENDDO |
---|
| 1334 | DO k = klev-1, 1, -1 |
---|
| 1335 | DO i = 1, klon |
---|
| 1336 | zgeom(i,k) = zgeom(i,k+1) + RD * (pt(i,k)+pt(i,k+1))/2.0 |
---|
| 1337 | . * LOG(papmf(i,k+1)/papmf(i,k)) |
---|
| 1338 | ENDDO |
---|
| 1339 | ENDDO |
---|
| 1340 | c |
---|
| 1341 | c appeler la routine principale |
---|
| 1342 | c |
---|
[155] | 1343 | CALL OROLIFT(klon,klev,ktest, |
---|
[2] | 1344 | . dtime, |
---|
[155] | 1345 | . papmh, zgeom, |
---|
[2] | 1346 | . pt, pu, pv, |
---|
[155] | 1347 | . plat,pmea, pstd, ppic, |
---|
[2] | 1348 | . pulow,pvlow, |
---|
| 1349 | . pdudt,pdvdt,pdtdt) |
---|
| 1350 | C |
---|
| 1351 | DO k = 1, klev |
---|
| 1352 | DO i = 1, klon |
---|
| 1353 | d_u(i,klev+1-k) = dtime*pdudt(i,k) |
---|
| 1354 | d_v(i,klev+1-k) = dtime*pdvdt(i,k) |
---|
| 1355 | d_t(i,klev+1-k) = dtime*pdtdt(i,k) |
---|
| 1356 | pustr(i) = pustr(i) |
---|
| 1357 | . +RG*pdudt(i,k)*(papmh(i,k+1)-papmh(i,k)) |
---|
| 1358 | pvstr(i) = pvstr(i) |
---|
| 1359 | . +RG*pdvdt(i,k)*(papmh(i,k+1)-papmh(i,k)) |
---|
| 1360 | ENDDO |
---|
| 1361 | ENDDO |
---|
| 1362 | c |
---|
| 1363 | RETURN |
---|
| 1364 | END |
---|
| 1365 | SUBROUTINE OROLIFT( NLON,NLEV |
---|
[155] | 1366 | I , KTEST |
---|
[2] | 1367 | R , PTSPHY |
---|
[155] | 1368 | R , PAPHM1,PGEOM1,PTM1,PUM1,PVM1 |
---|
[2] | 1369 | R , PLAT |
---|
[155] | 1370 | R , PMEA, PVAROR, ppic |
---|
[2] | 1371 | C OUTPUTS |
---|
| 1372 | R , PULOW,PVLOW |
---|
| 1373 | R , PVOM,PVOL,PTE ) |
---|
| 1374 | |
---|
| 1375 | C |
---|
| 1376 | C**** *OROLIFT: SIMULATE THE GEOSTROPHIC LIFT. |
---|
| 1377 | C |
---|
| 1378 | C PURPOSE. |
---|
| 1379 | C -------- |
---|
| 1380 | C |
---|
| 1381 | C** INTERFACE. |
---|
| 1382 | C ---------- |
---|
| 1383 | C CALLED FROM *lift_noro |
---|
| 1384 | C ---------- |
---|
| 1385 | C |
---|
| 1386 | C AUTHOR. |
---|
| 1387 | C ------- |
---|
| 1388 | C F.LOTT LMD 22/11/95 |
---|
| 1389 | C |
---|
[155] | 1390 | implicit none |
---|
[2] | 1391 | C |
---|
| 1392 | C |
---|
| 1393 | #include "dimensions.h" |
---|
| 1394 | #include "dimphy.h" |
---|
| 1395 | #include "YOMCST.h" |
---|
| 1396 | #include "YOEGWD.h" |
---|
| 1397 | C----------------------------------------------------------------------- |
---|
| 1398 | C |
---|
| 1399 | C* 0.1 ARGUMENTS |
---|
| 1400 | C --------- |
---|
| 1401 | C |
---|
| 1402 | C |
---|
[155] | 1403 | integer nlon, nlev |
---|
[2] | 1404 | REAL PTE(NLON,NLEV), |
---|
| 1405 | * PVOL(NLON,NLEV), |
---|
| 1406 | * PVOM(NLON,NLEV), |
---|
| 1407 | * PULOW(NLON), |
---|
| 1408 | * PVLOW(NLON) |
---|
| 1409 | REAL PUM1(NLON,NLEV), |
---|
| 1410 | * PVM1(NLON,NLEV), |
---|
| 1411 | * PTM1(NLON,NLEV), |
---|
| 1412 | * PLAT(NLON),PMEA(NLON), |
---|
[155] | 1413 | * PVAROR(NLON), |
---|
| 1414 | * ppic(NLON), |
---|
[2] | 1415 | * PGEOM1(NLON,NLEV), |
---|
| 1416 | * PAPHM1(NLON,NLEV+1) |
---|
| 1417 | C |
---|
[155] | 1418 | INTEGER KTEST(NLON) |
---|
| 1419 | real ptsphy |
---|
[2] | 1420 | C----------------------------------------------------------------------- |
---|
| 1421 | C |
---|
| 1422 | C* 0.2 LOCAL ARRAYS |
---|
| 1423 | C ------------ |
---|
[155] | 1424 | logical lifthigh, ll1 |
---|
| 1425 | integer klevm1, jl, ilevh, jk |
---|
| 1426 | real zcons1, ztmst, zrtmst,zpi, zhgeo |
---|
| 1427 | real zdelp, zslow, zsqua, zscav, zbet |
---|
| 1428 | INTEGER |
---|
[2] | 1429 | * IKNUB(klon), |
---|
[155] | 1430 | * IKNUL(klon) |
---|
[2] | 1431 | LOGICAL LL1(KLON,KLEV+1) |
---|
| 1432 | C |
---|
| 1433 | REAL ZTAU(KLON,KLEV+1), |
---|
| 1434 | * ZTAV(KLON,KLEV+1), |
---|
[155] | 1435 | * ZRHO(KLON,KLEV+1) |
---|
[2] | 1436 | REAL ZDUDT(KLON), |
---|
[155] | 1437 | * ZDVDT(KLON) |
---|
[2] | 1438 | REAL ZHCRIT(KLON,KLEV) |
---|
| 1439 | C----------------------------------------------------------------------- |
---|
| 1440 | C |
---|
| 1441 | C* 1.1 INITIALIZATIONS |
---|
| 1442 | C --------------- |
---|
| 1443 | |
---|
| 1444 | LIFTHIGH=.FALSE. |
---|
| 1445 | |
---|
| 1446 | IF(NLON.NE.KLON.OR.NLEV.NE.KLEV)STOP |
---|
| 1447 | ZCONS1=1./RD |
---|
| 1448 | KLEVM1=KLEV-1 |
---|
| 1449 | ZTMST=PTSPHY |
---|
| 1450 | ZRTMST=1./ZTMST |
---|
| 1451 | ZPI=ACOS(-1.) |
---|
| 1452 | C |
---|
| 1453 | DO 1001 JL=kidia,kfdia |
---|
| 1454 | ZRHO(JL,KLEV+1) =0.0 |
---|
| 1455 | PULOW(JL) =0.0 |
---|
| 1456 | PVLOW(JL) =0.0 |
---|
| 1457 | iknub(JL) =klev |
---|
| 1458 | iknul(JL) =klev |
---|
| 1459 | ilevh=klev/3 |
---|
| 1460 | ll1(jl,klev+1)=.false. |
---|
| 1461 | DO 1000 JK=1,KLEV |
---|
| 1462 | PVOM(JL,JK)=0.0 |
---|
| 1463 | PVOL(JL,JK)=0.0 |
---|
| 1464 | PTE (JL,JK)=0.0 |
---|
| 1465 | 1000 CONTINUE |
---|
| 1466 | 1001 CONTINUE |
---|
| 1467 | |
---|
| 1468 | C |
---|
| 1469 | C* 2.1 DEFINE LOW LEVEL WIND, PROJECT WINDS IN PLANE OF |
---|
| 1470 | C* LOW LEVEL WIND, DETERMINE SECTOR IN WHICH TO TAKE |
---|
| 1471 | C* THE VARIANCE AND SET INDICATOR FOR CRITICAL LEVELS. |
---|
| 1472 | C |
---|
| 1473 | C |
---|
| 1474 | C |
---|
| 1475 | DO 2006 JK=KLEV,1,-1 |
---|
| 1476 | DO 2007 JL=kidia,kfdia |
---|
| 1477 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1478 | ZHCRIT(JL,JK)=amax1(Ppic(JL)-pmea(JL),100.) |
---|
| 1479 | ZHGEO=PGEOM1(JL,JK)/RG |
---|
| 1480 | ll1(JL,JK)=(ZHGEO.GT.ZHCRIT(JL,JK)) |
---|
| 1481 | IF(ll1(JL,JK).XOR.ll1(JL,JK+1)) THEN |
---|
| 1482 | iknub(JL)=JK |
---|
| 1483 | ENDIF |
---|
| 1484 | ENDIF |
---|
| 1485 | 2007 CONTINUE |
---|
| 1486 | 2006 CONTINUE |
---|
| 1487 | C |
---|
| 1488 | do 2010 jl=kidia,kfdia |
---|
| 1489 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1490 | iknub(jl)=max(iknub(jl),klev/2) |
---|
| 1491 | iknul(jl)=max(iknul(jl),2*klev/3) |
---|
| 1492 | if(iknub(jl).gt.nktopg) iknub(jl)=nktopg |
---|
| 1493 | if(iknub(jl).eq.nktopg) iknul(jl)=klev |
---|
| 1494 | if(iknub(jl).eq.iknul(jl)) iknub(jl)=iknul(jl)-1 |
---|
| 1495 | ENDIF |
---|
| 1496 | 2010 continue |
---|
| 1497 | |
---|
| 1498 | C do 2011 jl=kidia,kfdia |
---|
| 1499 | C IF(KTEST(JL).EQ.1) THEN |
---|
| 1500 | C print *,' iknul= ',iknul(jl),' iknub=',iknub(jl) |
---|
| 1501 | C ENDIF |
---|
| 1502 | C2011 continue |
---|
| 1503 | |
---|
| 1504 | C PRINT *,' DANS OROLIFT: 2010' |
---|
| 1505 | |
---|
| 1506 | DO 223 JK=KLEV,2,-1 |
---|
| 1507 | DO 222 JL=kidia,kfdia |
---|
| 1508 | ZRHO(JL,JK)=2.*PAPHM1(JL,JK)*ZCONS1/(PTM1(JL,JK)+PTM1(JL,JK-1)) |
---|
| 1509 | 222 CONTINUE |
---|
| 1510 | 223 CONTINUE |
---|
| 1511 | C PRINT *,' DANS OROLIFT: 223' |
---|
| 1512 | |
---|
| 1513 | C******************************************************************** |
---|
| 1514 | C |
---|
| 1515 | C* DEFINE LOW LEVEL FLOW |
---|
| 1516 | C ------------------- |
---|
| 1517 | DO 2115 JK=klev,1,-1 |
---|
| 1518 | DO 2116 JL=kidia,kfdia |
---|
| 1519 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1520 | if(jk.ge.iknub(jl).and.jk.le.iknul(jl)) then |
---|
| 1521 | pulow(JL)=pulow(JL)+PUM1(JL,JK)*(PAPHM1(JL,JK+1)-PAPHM1(JL,JK)) |
---|
| 1522 | pvlow(JL)=pvlow(JL)+PVM1(JL,JK)*(PAPHM1(JL,JK+1)-PAPHM1(JL,JK)) |
---|
| 1523 | zrho(JL,klev+1)=zrho(JL,klev+1) |
---|
| 1524 | * +zrho(JL,JK)*(PAPHM1(JL,JK+1)-PAPHM1(JL,JK)) |
---|
| 1525 | end if |
---|
| 1526 | ENDIF |
---|
| 1527 | 2116 CONTINUE |
---|
| 1528 | 2115 CONTINUE |
---|
| 1529 | DO 2110 JL=kidia,kfdia |
---|
| 1530 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1531 | pulow(JL)=pulow(JL)/(PAPHM1(JL,iknul(jl)+1)-PAPHM1(JL,iknub(jl))) |
---|
| 1532 | pvlow(JL)=pvlow(JL)/(PAPHM1(JL,iknul(jl)+1)-PAPHM1(JL,iknub(jl))) |
---|
| 1533 | zrho(JL,klev+1)=zrho(JL,klev+1) |
---|
| 1534 | * /(PAPHM1(JL,iknul(jl)+1)-PAPHM1(JL,iknub(jl))) |
---|
| 1535 | ENDIF |
---|
| 1536 | 2110 CONTINUE |
---|
| 1537 | |
---|
| 1538 | |
---|
| 1539 | 200 CONTINUE |
---|
| 1540 | |
---|
| 1541 | C*********************************************************** |
---|
| 1542 | C |
---|
| 1543 | C* 3. COMPUTE MOUNTAIN LIFT |
---|
| 1544 | C |
---|
| 1545 | 300 CONTINUE |
---|
| 1546 | C |
---|
| 1547 | DO 301 JL=kidia,kfdia |
---|
| 1548 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1549 | ZTAU(JL,KLEV+1)= - GKLIFT*ZRHO(JL,KLEV+1)*2.*ROMEGA* |
---|
| 1550 | C * (2*PVAROR(JL)+PMEA(JL))* |
---|
| 1551 | * 2*PVAROR(JL)* |
---|
| 1552 | * SIN(ZPI/180.*PLAT(JL))*PVLOW(JL) |
---|
| 1553 | ZTAV(JL,KLEV+1)= GKLIFT*ZRHO(JL,KLEV+1)*2.*ROMEGA* |
---|
| 1554 | C * (2*PVAROR(JL)+PMEA(JL))* |
---|
| 1555 | * 2*PVAROR(JL)* |
---|
| 1556 | * SIN(ZPI/180.*PLAT(JL))*PULOW(JL) |
---|
| 1557 | ELSE |
---|
| 1558 | ZTAU(JL,KLEV+1)=0.0 |
---|
| 1559 | ZTAV(JL,KLEV+1)=0.0 |
---|
| 1560 | ENDIF |
---|
| 1561 | 301 CONTINUE |
---|
| 1562 | |
---|
| 1563 | C |
---|
| 1564 | C* 4. COMPUTE LIFT PROFILE |
---|
| 1565 | C* -------------------- |
---|
| 1566 | C |
---|
| 1567 | |
---|
| 1568 | 400 CONTINUE |
---|
| 1569 | |
---|
| 1570 | DO 401 JK=1,KLEV |
---|
| 1571 | DO 401 JL=kidia,kfdia |
---|
| 1572 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1573 | ZTAU(JL,JK)=ZTAU(JL,KLEV+1)*PAPHM1(JL,JK)/PAPHM1(JL,KLEV+1) |
---|
| 1574 | ZTAV(JL,JK)=ZTAV(JL,KLEV+1)*PAPHM1(JL,JK)/PAPHM1(JL,KLEV+1) |
---|
| 1575 | ELSE |
---|
| 1576 | ZTAU(JL,JK)=0.0 |
---|
| 1577 | ZTAV(JL,JK)=0.0 |
---|
| 1578 | ENDIF |
---|
| 1579 | 401 CONTINUE |
---|
| 1580 | C |
---|
| 1581 | C |
---|
| 1582 | C* 5. COMPUTE TENDENCIES. |
---|
| 1583 | C* ------------------- |
---|
| 1584 | IF(LIFTHIGH)THEN |
---|
| 1585 | C |
---|
| 1586 | 500 CONTINUE |
---|
| 1587 | C PRINT *,' DANS OROLIFT: 500' |
---|
| 1588 | C |
---|
| 1589 | C EXPLICIT SOLUTION AT ALL LEVELS |
---|
| 1590 | C |
---|
| 1591 | DO 524 JK=1,klev |
---|
| 1592 | DO 523 JL=KIDIA,KFDIA |
---|
| 1593 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1594 | ZDELP=PAPHM1(JL,JK+1)-PAPHM1(JL,JK) |
---|
| 1595 | ZDUDT(JL)=-RG*(ZTAU(JL,JK+1)-ZTAU(JL,JK))/ZDELP |
---|
| 1596 | ZDVDT(JL)=-RG*(ZTAV(JL,JK+1)-ZTAV(JL,JK))/ZDELP |
---|
| 1597 | ENDIF |
---|
| 1598 | 523 CONTINUE |
---|
| 1599 | 524 CONTINUE |
---|
| 1600 | C |
---|
| 1601 | C PROJECT PERPENDICULARLY TO U NOT TO DESTROY ENERGY |
---|
| 1602 | C |
---|
| 1603 | DO 530 JK=1,klev |
---|
| 1604 | DO 530 JL=KIDIA,KFDIA |
---|
| 1605 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1606 | |
---|
| 1607 | ZSLOW=SQRT(PULOW(JL)**2+PVLOW(JL)**2) |
---|
| 1608 | ZSQUA=AMAX1(SQRT(PUM1(JL,JK)**2+PVM1(JL,JK)**2),GVSEC) |
---|
| 1609 | ZSCAV=-ZDUDT(JL)*PVM1(JL,JK)+ZDVDT(JL)*PUM1(JL,JK) |
---|
| 1610 | IF(ZSQUA.GT.GVSEC)THEN |
---|
| 1611 | PVOM(JL,JK)=-ZSCAV*PVM1(JL,JK)/ZSQUA**2 |
---|
| 1612 | PVOL(JL,JK)= ZSCAV*PUM1(JL,JK)/ZSQUA**2 |
---|
| 1613 | ELSE |
---|
| 1614 | PVOM(JL,JK)=0.0 |
---|
| 1615 | PVOL(JL,JK)=0.0 |
---|
| 1616 | ENDIF |
---|
| 1617 | ZSQUA=SQRT(PUM1(JL,JK)**2+PUM1(JL,JK)**2) |
---|
| 1618 | IF(ZSQUA.LT.ZSLOW)THEN |
---|
| 1619 | PVOM(JL,JK)=ZSQUA/ZSLOW*PVOM(JL,JK) |
---|
| 1620 | PVOL(JL,JK)=ZSQUA/ZSLOW*PVOL(JL,JK) |
---|
| 1621 | ENDIF |
---|
| 1622 | |
---|
| 1623 | ENDIF |
---|
| 1624 | 530 CONTINUE |
---|
| 1625 | C |
---|
| 1626 | C 6. LOW LEVEL LIFT, SEMI IMPLICIT: |
---|
| 1627 | C ---------------------------------- |
---|
| 1628 | |
---|
| 1629 | ELSE |
---|
| 1630 | |
---|
| 1631 | DO 601 JL=KIDIA,KFDIA |
---|
| 1632 | IF(KTEST(JL).EQ.1) THEN |
---|
| 1633 | DO JK=KLEV,IKNUB(JL),-1 |
---|
| 1634 | ZBET=GKLIFT*2.*ROMEGA*SIN(ZPI/180.*PLAT(JL))*ztmst* |
---|
| 1635 | * (PGEOM1(JL,IKNUB(JL)-1)-PGEOM1(JL, JK))/ |
---|
| 1636 | * (PGEOM1(JL,IKNUB(JL)-1)-PGEOM1(JL,KLEV)) |
---|
| 1637 | ZDUDT(JL)=-PUM1(JL,JK)/ztmst/(1+ZBET**2) |
---|
| 1638 | ZDVDT(JL)=-PVM1(JL,JK)/ztmst/(1+ZBET**2) |
---|
| 1639 | PVOM(JL,JK)= ZBET**2*ZDUDT(JL) - ZBET *ZDVDT(JL) |
---|
| 1640 | PVOL(JL,JK)= ZBET *ZDUDT(JL) + ZBET**2*ZDVDT(JL) |
---|
| 1641 | ENDDO |
---|
| 1642 | ENDIF |
---|
| 1643 | 601 CONTINUE |
---|
| 1644 | |
---|
| 1645 | ENDIF |
---|
| 1646 | |
---|
| 1647 | RETURN |
---|
| 1648 | END |
---|
| 1649 | SUBROUTINE SUGWD(NLON,NLEV,paprs,pplay) |
---|
| 1650 | C |
---|
| 1651 | C**** *SUGWD* INITIALIZE COMMON YOEGWD CONTROLLING GRAVITY WAVE DRAG |
---|
| 1652 | C |
---|
| 1653 | C PURPOSE. |
---|
| 1654 | C -------- |
---|
| 1655 | C INITIALIZE YOEGWD, THE COMMON THAT CONTROLS THE |
---|
| 1656 | C GRAVITY WAVE DRAG PARAMETRIZATION. |
---|
| 1657 | C |
---|
| 1658 | C** INTERFACE. |
---|
| 1659 | C ---------- |
---|
| 1660 | C CALL *SUGWD* FROM *SUPHEC* |
---|
| 1661 | C ----- ------ |
---|
| 1662 | C |
---|
| 1663 | C EXPLICIT ARGUMENTS : |
---|
| 1664 | C -------------------- |
---|
| 1665 | C PSIG : VERTICAL COORDINATE TABLE |
---|
| 1666 | C NLEV : NUMBER OF MODEL LEVELS |
---|
| 1667 | C |
---|
| 1668 | C IMPLICIT ARGUMENTS : |
---|
| 1669 | C -------------------- |
---|
| 1670 | C COMMON YOEGWD |
---|
| 1671 | C |
---|
| 1672 | C METHOD. |
---|
| 1673 | C ------- |
---|
| 1674 | C SEE DOCUMENTATION |
---|
| 1675 | C |
---|
| 1676 | C EXTERNALS. |
---|
| 1677 | C ---------- |
---|
| 1678 | C NONE |
---|
| 1679 | C |
---|
| 1680 | C REFERENCE. |
---|
| 1681 | C ---------- |
---|
| 1682 | C ECMWF Research Department documentation of the IFS |
---|
| 1683 | C |
---|
| 1684 | C AUTHOR. |
---|
| 1685 | C ------- |
---|
| 1686 | C MARTIN MILLER *ECMWF* |
---|
| 1687 | C |
---|
| 1688 | C MODIFICATIONS. |
---|
| 1689 | C -------------- |
---|
| 1690 | C ORIGINAL : 90-01-01 |
---|
| 1691 | C ------------------------------------------------------------------ |
---|
[155] | 1692 | implicit none |
---|
[2] | 1693 | C |
---|
| 1694 | C ----------------------------------------------------------------- |
---|
| 1695 | #include "YOEGWD.h" |
---|
| 1696 | C ---------------------------------------------------------------- |
---|
| 1697 | C |
---|
[155] | 1698 | integer nlon,nlev, jk |
---|
[2] | 1699 | REAL paprs(nlon,nlev+1) |
---|
| 1700 | REAL pplay(nlon,nlev) |
---|
[155] | 1701 | real zpr,zstra,zsigt,zpm1r |
---|
[2] | 1702 | C |
---|
| 1703 | C* 1. SET THE VALUES OF THE PARAMETERS |
---|
| 1704 | C -------------------------------- |
---|
| 1705 | C |
---|
| 1706 | 100 CONTINUE |
---|
| 1707 | C |
---|
| 1708 | PRINT *,' DANS SUGWD NLEV=',NLEV |
---|
| 1709 | GHMAX=10000. |
---|
| 1710 | C |
---|
| 1711 | ZPR=100000. |
---|
| 1712 | ZSTRA=0.1 |
---|
| 1713 | ZSIGT=0.94 |
---|
| 1714 | cold ZPR=80000. |
---|
| 1715 | cold ZSIGT=0.85 |
---|
| 1716 | C |
---|
| 1717 | DO 110 JK=1,NLEV |
---|
| 1718 | ZPM1R=pplay(nlon/2,jk)/paprs(nlon/2,1) |
---|
| 1719 | IF(ZPM1R.GE.ZSIGT)THEN |
---|
| 1720 | nktopg=JK |
---|
| 1721 | ENDIF |
---|
| 1722 | ZPM1R=pplay(nlon/2,jk)/paprs(nlon/2,1) |
---|
| 1723 | IF(ZPM1R.GE.ZSTRA)THEN |
---|
| 1724 | NSTRA=JK |
---|
| 1725 | ENDIF |
---|
| 1726 | 110 CONTINUE |
---|
| 1727 | c |
---|
| 1728 | c inversion car dans orodrag on compte les niveaux a l'envers |
---|
| 1729 | nktopg=nlev-nktopg+1 |
---|
| 1730 | nstra=nlev-nstra |
---|
| 1731 | print *,' DANS SUGWD nktopg=', nktopg |
---|
| 1732 | print *,' DANS SUGWD nstra=', nstra |
---|
| 1733 | C |
---|
| 1734 | GSIGCR=0.80 |
---|
| 1735 | C |
---|
| 1736 | GKDRAG=0.2 |
---|
[155] | 1737 | GRAHILO=1. |
---|
[2] | 1738 | GRCRIT=0.01 |
---|
| 1739 | GFRCRIT=1.0 |
---|
| 1740 | GKWAKE=0.50 |
---|
| 1741 | C |
---|
| 1742 | GKLIFT=0.50 |
---|
| 1743 | GVCRIT =0.0 |
---|
| 1744 | C |
---|
| 1745 | C |
---|
| 1746 | C ---------------------------------------------------------------- |
---|
| 1747 | C |
---|
| 1748 | C* 2. SET VALUES OF SECURITY PARAMETERS |
---|
| 1749 | C --------------------------------- |
---|
| 1750 | C |
---|
| 1751 | 200 CONTINUE |
---|
| 1752 | C |
---|
| 1753 | GVSEC=0.10 |
---|
| 1754 | GSSEC=1.E-12 |
---|
| 1755 | C |
---|
| 1756 | GTSEC=1.E-07 |
---|
| 1757 | C |
---|
| 1758 | C ---------------------------------------------------------------- |
---|
| 1759 | C |
---|
| 1760 | RETURN |
---|
| 1761 | END |
---|