Changeset 1232 for LMDZ4/trunk/libf
- Timestamp:
- Aug 27, 2009, 3:23:40 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ4/trunk/libf/phylmd/plevel_new.F
r1194 r1232 46 46 47 47 cym save lt,lb,ptop,pbot,aist,aisb 48 INTEGER,ALLOCATABLE,SAVE,DIMENSION(: ) :: lt,lb48 INTEGER,ALLOCATABLE,SAVE,DIMENSION(:,:) :: lt,lb 49 49 REAL,ALLOCATABLE,SAVE,DIMENSION(:,:) :: aist,aisb 50 50 c$OMP THREADPRIVATE(lt,lb,aist,aisb) … … 57 57 c 58 58 if (first) then 59 allocate(lt(klon ),lb(klon))59 allocate(lt(klon,klevSTD),lb(klon,klevSTD)) 60 60 allocate(aist(klon,klevSTD),aisb(klon, klevSTD)) 61 61 first=.false. … … 78 78 IF ( ABS(pres(nlev)-pgcm(i,ilev) ) .LT. 79 79 & ABS(pres(nlev)-pgcm(i,1)) ) THEN 80 lt(i ) = ilev ! 281 lb(i ) = ilev-1 ! 180 lt(i,nlev) = ilev ! 2 81 lb(i,nlev) = ilev-1 ! 1 82 82 ELSE 83 lt(i ) = 284 lb(i ) = 183 lt(i,nlev) = 2 84 lb(i,nlev) = 1 85 85 ENDIF 86 86 ENDDO … … 90 90 ptop = pgcm(i,k+1) 91 91 IF (ptop.LE.pres(nlev) .AND. pbot.GE.pres(nlev)) THEN 92 lt(i ) = k+193 lb(i ) = k92 lt(i,nlev) = k+1 93 lb(i,nlev) = k 94 94 ENDIF 95 95 ENDDO … … 103 103 c Modif Frederic Hourdin (3/01/02) 104 104 105 aist(i,nlev) = LOG( pgcm(i,lb(i ))/ pres(nlev) )106 & / LOG( pgcm(i,lb(i ))/ pgcm(i,lt(i)) )107 aisb(i,nlev) = LOG( pres(nlev) / pgcm(i,lt(i )) )108 & / LOG( pgcm(i,lb(i ))/ pgcm(i,lt(i)))105 aist(i,nlev) = LOG( pgcm(i,lb(i,nlev))/ pres(nlev) ) 106 & / LOG( pgcm(i,lb(i,nlev))/ pgcm(i,lt(i,nlev)) ) 107 aisb(i,nlev) = LOG( pres(nlev) / pgcm(i,lt(i,nlev)) ) 108 & / LOG( pgcm(i,lb(i,nlev))/ pgcm(i,lt(i,nlev))) 109 109 ENDDO 110 110 ENDDO … … 124 124 ELSE 125 125 Qpres(i,nlev) = 126 & Qgcm(i,lb(i ))*aisb(i,nlev) +127 & Qgcm(i,lt(i ))*aist(i,nlev)126 & Qgcm(i,lb(i,nlev))*aisb(i,nlev) + 127 & Qgcm(i,lt(i,nlev))*aist(i,nlev) 128 128 ENDIF 129 129 ENDDO
Note: See TracChangeset
for help on using the changeset viewer.