[38] | 1 | SUBROUTINE GWSTRESS |
---|
| 2 | * ( klon , klev |
---|
| 3 | * , KKCRIT, KSECT, KKHLIM, KTEST, KKCRITH, KCRIT, kkenvh |
---|
| 4 | * , kknu |
---|
| 5 | * , PRHO , PSTAB, PVPH , PVAR ,PVARor, psig |
---|
| 6 | * , PTFR , PTAU |
---|
| 7 | * ,pgeom1 , pgamma, pd1 , pd2 ,pdmod ,pnu ) |
---|
| 8 | C |
---|
| 9 | C**** *GWSTRESS* |
---|
| 10 | C |
---|
| 11 | C PURPOSE. |
---|
| 12 | C -------- |
---|
| 13 | C |
---|
| 14 | C** INTERFACE. |
---|
| 15 | C ---------- |
---|
| 16 | C CALL *GWSTRESS* FROM *GWDRAG* |
---|
| 17 | C |
---|
| 18 | C EXPLICIT ARGUMENTS : |
---|
| 19 | C -------------------- |
---|
| 20 | C ==== INPUTS === |
---|
| 21 | C ==== OUTPUTS === |
---|
| 22 | C |
---|
| 23 | C IMPLICIT ARGUMENTS : NONE |
---|
| 24 | C -------------------- |
---|
| 25 | C |
---|
| 26 | C METHOD. |
---|
| 27 | C ------- |
---|
| 28 | C |
---|
| 29 | C |
---|
| 30 | C EXTERNALS. |
---|
| 31 | C ---------- |
---|
| 32 | C |
---|
| 33 | C |
---|
| 34 | C REFERENCE. |
---|
| 35 | C ---------- |
---|
| 36 | C |
---|
| 37 | C SEE ECMWF RESEARCH DEPARTMENT DOCUMENTATION OF THE "I.F.S." |
---|
| 38 | C |
---|
| 39 | C AUTHOR. |
---|
| 40 | C ------- |
---|
| 41 | C |
---|
| 42 | C MODIFICATIONS. |
---|
| 43 | C -------------- |
---|
| 44 | C F. LOTT PUT THE NEW GWD ON IFS 22/11/93 |
---|
| 45 | C |
---|
| 46 | C----------------------------------------------------------------------- |
---|
[1047] | 47 | use dimradmars_mod, only: ndlo2 |
---|
[38] | 48 | implicit none |
---|
| 49 | #include "dimensions.h" |
---|
| 50 | #include "dimphys.h" |
---|
[1047] | 51 | !#include "dimradmars.h" |
---|
[38] | 52 | integer klon,klev,kidia,kfdia |
---|
| 53 | |
---|
| 54 | #include "yoegwd.h" |
---|
| 55 | |
---|
| 56 | C----------------------------------------------------------------------- |
---|
| 57 | C |
---|
| 58 | C* 0.1 ARGUMENTS |
---|
| 59 | C --------- |
---|
| 60 | C |
---|
| 61 | INTEGER KKCRIT(NDLO2),KKCRITH(NDLO2),KCRIT(NDLO2),KSECT(NDLO2), |
---|
| 62 | * KKHLIM(NDLO2),KTEST(NDLO2),KKENVH(NDLO2),KKNU(NDLO2) |
---|
| 63 | C |
---|
| 64 | REAL PRHO(NDLO2,klev+1),PSTAB(NDLO2,klev+1),PTAU(NDLO2,klev+1), |
---|
| 65 | * PVPH(NDLO2,klev+1),PVAR(NDLO2,4),PTFR(NDLO2), |
---|
| 66 | * pgeom1(NDLO2,klev),PVARor(NDLO2) |
---|
| 67 | C |
---|
| 68 | real pd1(NDLO2),pd2(NDLO2),pnu(NDLO2),psig(NDLO2),pgamma(NDLO2) |
---|
| 69 | real pdmod(NDLO2) |
---|
| 70 | C |
---|
| 71 | C----------------------------------------------------------------------- |
---|
| 72 | C |
---|
| 73 | C* 0.2 LOCAL ARRAYS |
---|
| 74 | C ------------ |
---|
| 75 | integer jl |
---|
| 76 | real zblock,zvar,zeff |
---|
| 77 | logical lo |
---|
| 78 | |
---|
| 79 | C |
---|
| 80 | C----------------------------------------------------------------------- |
---|
| 81 | C |
---|
| 82 | C* 0.3 FUNCTIONS |
---|
| 83 | C --------- |
---|
| 84 | C ------------------------------------------------------------------ |
---|
| 85 | C |
---|
| 86 | C* 1. INITIALIZATION |
---|
| 87 | C -------------- |
---|
| 88 | |
---|
| 89 | |
---|
| 90 | kidia=1 |
---|
| 91 | kfdia=klon |
---|
| 92 | |
---|
| 93 | |
---|
| 94 | C |
---|
| 95 | 100 CONTINUE |
---|
| 96 | C |
---|
| 97 | C* 3.1 GRAVITY WAVE STRESS. |
---|
| 98 | C |
---|
| 99 | 300 CONTINUE |
---|
| 100 | C |
---|
| 101 | C |
---|
| 102 | DO 301 JL=kidia,kfdia |
---|
| 103 | IF(KTEST(JL).EQ.1) THEN |
---|
| 104 | |
---|
| 105 | C EFFECTIVE MOUNTAIN HEIGHT ABOVE THE BLOCKED FLOW |
---|
| 106 | |
---|
| 107 | c IF(KKENVH(JL).EQ.KLEV)THEN |
---|
| 108 | ZBLOCK=0.0 |
---|
| 109 | c ELSE |
---|
| 110 | c ZBLOCK=(PGEOM1(JL,KKENVH(JL))+PGEOM1(JL,KKENVH(JL)+1))/2./RG |
---|
| 111 | c ENDIF |
---|
| 112 | |
---|
| 113 | ZVAR=PVAROR(JL) |
---|
| 114 | ZEFF=AMAX1(0.,2.*ZVAR-ZBLOCK) |
---|
| 115 | |
---|
| 116 | PTAU(JL,KLEV+1)=PRHO(JL,KLEV+1)*GKDRAG*psig(jl)*ZEFF**2 |
---|
| 117 | * /4./ZVAR*PVPH(JL,KLEV+1)*pdmod(jl)*sqrt(pstab(jl,klev+1)) |
---|
| 118 | |
---|
| 119 | C TOO SMALL VALUE OF STRESS OR LOW LEVEL FLOW INCLUDE CRITICAL LEVEL |
---|
| 120 | C OR LOW LEVEL FLOW: GRAVITY WAVE STRESS NUL. |
---|
| 121 | |
---|
| 122 | LO=(PTAU(JL,KLEV+1).LT.GTSEC).OR.(KCRIT(JL).GE.KKNU(JL)) |
---|
| 123 | * .OR.(PVPH(JL,KLEV+1).LT.GVCRIT) |
---|
| 124 | c IF(LO) PTAU(JL,KLEV+1)=0.0 |
---|
| 125 | |
---|
| 126 | ELSE |
---|
| 127 | |
---|
| 128 | PTAU(JL,KLEV+1)=0.0 |
---|
| 129 | |
---|
| 130 | ENDIF |
---|
| 131 | |
---|
| 132 | 301 CONTINUE |
---|
| 133 | C |
---|
| 134 | RETURN |
---|
| 135 | END |
---|