Changeset 1403 for LMDZ4/trunk/libf/phylmd/thermcell_dry.F90
- Timestamp:
- Jul 1, 2010, 11:02:53 AM (14 years ago)
- Location:
- LMDZ4/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ4/trunk
- Property svn:mergeinfo changed
-
LMDZ4/trunk/libf/phylmd/thermcell_dry.F90
r938 r1403 1 ! 2 ! $Id$ 3 ! 1 4 SUBROUTINE thermcell_dry(ngrid,nlay,zlev,pphi,ztv,alim_star, & 2 5 & lalim,lmin,zmax,wmax,lev_out) … … 4 7 !-------------------------------------------------------------------------- 5 8 !thermcell_dry: calcul de zmax et wmax du thermique sec 9 ! Calcul de la vitesse maximum et de la hauteur maximum pour un panache 10 ! ascendant avec une fonction d'alimentation alim_star et sans changement 11 ! de phase. 12 ! Le calcul pourrait etre sans doute simplifier. 13 ! La temperature potentielle virtuelle dans la panache ascendant est 14 ! la temperature potentielle virtuelle pondérée par alim_star. 6 15 !-------------------------------------------------------------------------- 16 7 17 IMPLICIT NONE 8 18 #include "YOMCST.h" … … 29 39 REAL linter(ngrid),zlevinter(ngrid) 30 40 INTEGER lmix(ngrid),lmax(ngrid),lmin(ngrid) 41 CHARACTER (LEN=20) :: modname='thermcell_dry' 42 CHARACTER (LEN=80) :: abort_message 31 43 32 44 !initialisations … … 47 59 enddo 48 60 !calcul de la vitesse a partir de la CAPE en melangeant thetav 49 50 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!51 ! A eliminer52 ! Ce if complique etait fait pour reperer la premiere couche instable53 ! Ici, c'est lmin.54 !55 ! do l=1,nlay-256 ! do ig=1,ngrid57 ! if (ztv(ig,l).gt.ztv(ig,l+1) &58 ! & .and.alim_star(ig,l).gt.1.e-10 &59 ! & .and.zw2(ig,l).lt.1e-10) then60 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!61 61 62 62 … … 84 84 ! Premiere couche du panache thermique 85 85 !------------------------------------------------------------------------ 86 86 87 zw2(ig,l+1)=2.*RG*(ztv(ig,l)-ztv(ig,l+1))/ztv(ig,l+1) & 87 88 & *(zlev(ig,l+1)-zlev(ig,l)) & … … 96 97 ! 3. la vitesse au carré en haut zw2(ig,l+1) 97 98 !------------------------------------------------------------------------ 98 99 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!100 ! A eliminer : dans cette version, si zw2 est > 0 on a un therique.101 ! et donc, au dessus, f_star(ig,l+1) est forcement suffisamment102 ! grand puisque on n'a pas de detrainement.103 ! f_star est une fonction croissante.104 ! c'est donc vraiment sur zw2 uniquement qu'il faut faire le test.105 ! else if ((zw2(ig,l).ge.1e-10).and. &106 ! & (f_star(ig,l)+alim_star(ig,l).gt.1.e-10)) then107 ! f_star(ig,l+1)=f_star(ig,l)+alim_star(ig,l)108 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!109 99 110 100 else if (zw2(ig,l).ge.1e-10) then … … 145 135 if (prt_level.ge.1) print*,'fin calcul zw2' 146 136 ! 147 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!148 ! A eliminer :149 ! Ce calcul de lmax est fait en meme temps que celui de linter, plus haut150 ! Calcul de la couche correspondant a la hauteur du thermique151 ! do ig=1,ngrid152 ! lmax(ig)=lalim(ig)153 ! enddo154 ! do ig=1,ngrid155 ! do l=nlay,lalim(ig)+1,-1156 ! if (zw2(ig,l).le.1.e-10) then157 ! lmax(ig)=l-1158 ! endif159 ! enddo160 ! enddo161 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!162 163 !164 137 ! Determination de zw2 max 165 138 do ig=1,ngrid … … 185 158 do ig=1,ngrid 186 159 ! calcul de zlevinter 187 188 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!189 ! FH A eliminer190 ! Simplification191 ! zlevinter(ig)=(zlev(ig,lmax(ig)+1)-zlev(ig,lmax(ig)))* &192 ! & linter(ig)+zlev(ig,lmax(ig))-lmax(ig)*(zlev(ig,lmax(ig)+1) &193 ! & -zlev(ig,lmax(ig)))194 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!195 196 160 zlevinter(ig)=zlev(ig,lmax(ig)) + & 197 161 & (linter(ig)-lmax(ig))*(zlev(ig,lmax(ig)+1)-zlev(ig,lmax(ig))) … … 199 163 enddo 200 164 201 ! Verification que lalim<=lmax202 do ig=1,ngrid203 if(lalim(ig)>lmax(ig)) then204 if ( prt_level > 1 ) THEN205 print*,'WARNING thermcell_dry ig=',ig,' lalim=',lalim(ig),' lmax(ig)=',lmax(ig)206 endif207 lmax(ig)=lalim(ig)208 endif209 enddo210 211 165 RETURN 212 166 END
Note: See TracChangeset
for help on using the changeset viewer.