/[lmdze]/trunk/Sources/phylmd/CV30_routines/cv30_mixing.f
ViewVC logotype

Diff of /trunk/Sources/phylmd/CV30_routines/cv30_mixing.f

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 47 by guez, Fri Jul 1 15:00:48 2011 UTC revision 69 by guez, Mon Feb 18 16:33:12 2013 UTC
# Line 3  Line 3 
3                            ,ph,t,rr,rs,u,v,tra,h,lv,qnk &                            ,ph,t,rr,rs,u,v,tra,h,lv,qnk &
4                            ,hp,tv,tvp,ep,clw,m,sig &                            ,hp,tv,tvp,ep,clw,m,sig &
5           ,ment,qent,uent,vent, nent, sij,elij,ments,qents,traent)           ,ment,qent,uent,vent, nent, sij,elij,ments,qents,traent)
6              use cvparam3              use cv3_param_m
7              use cvthermo              use cvthermo
8        implicit none        implicit none
9    
# Line 15  Line 15 
15    
16    
17  ! inputs:  ! inputs:
18        integer ncum, nd, na, ntra, nloc        integer, intent(in):: ncum, nd, na, ntra, nloc
19        integer icb(nloc), inb(nloc), nk(nloc)        integer icb(nloc), inb(nloc), nk(nloc)
20        real sig(nloc,nd)        real sig(nloc,nd)
21        real qnk(nloc)        real qnk(nloc)
# Line 51  Line 51 
51  ! --- INITIALIZE VARIOUS ARRAYS USED IN THE COMPUTATIONS  ! --- INITIALIZE VARIOUS ARRAYS USED IN THE COMPUTATIONS
52  !=====================================================================  !=====================================================================
53    
 ! ori        do 360 i=1,ncum*nlp  
54          do 361 j=1,nl          do 361 j=1,nl
55          do 360 i=1,ncum          do 360 i=1,ncum
56            nent(i,j)=0            nent(i,j)=0
# Line 79  Line 78 
78        ment(1:ncum,1:nd,1:nd)=0.0        ment(1:ncum,1:nd,1:nd)=0.0
79        sij(1:ncum,1:nd,1:nd)=0.0        sij(1:ncum,1:nd,1:nd)=0.0
80    
 !      do k=1,ntra  
 !       do j=1,nd  ! instead nlp  
 !        do i=1,nd ! instead nlp  
 !         do il=1,ncum  
 !            traent(il,i,j,k)=tra(il,j,k)  
 !         enddo  
 !        enddo  
 !       enddo  
 !      enddo  
81        zm(:,:)=0.        zm(:,:)=0.
82    
83  !=====================================================================  !=====================================================================
# Line 143  Line 133 
133   700   continue   700   continue
134   710  continue   710  continue
135    
 !       do k=1,ntra  
 !        do j=minorig,nl  
 !         do il=1,ncum  
 !          if( (i.ge.icb(il)).and.(i.le.inb(il)).and.  
 !     :       (j.ge.(icb(il)-1)).and.(j.le.inb(il)))then  
 !            traent(il,i,j,k)=sij(il,i,j)*tra(il,i,k)  
 !     :            +(1.-sij(il,i,j))*tra(il,nk(il),k)  
 !          endif  
 !         enddo  
 !        enddo  
 !       enddo  
   
136  !  !
137  !   ***   if no air can entrain at level i assume that updraft detrains  ***  !   ***   if no air can entrain at level i assume that updraft detrains  ***
138  !   ***   at that level and calculate detrained air flux and properties  ***  !   ***   at that level and calculate detrained air flux and properties  ***
# Line 176  Line 154 
154   740  continue   740  continue
155   750  continue   750  continue
156    
 !      do j=1,ntra  
 !       do i=minorig+1,nl  
 !        do il=1,ncum  
 !         if (i.ge.icb(il) .and. i.le.inb(il) .and. nent(il,i).eq.0) then  
 !          traent(il,i,i,j)=tra(il,nk(il),j)  
 !         endif  
 !        enddo  
 !       enddo  
 !      enddo  
   
157        do 100 j=minorig,nl        do 100 j=minorig,nl
158        do 101 i=minorig,nl        do 101 i=minorig,nl
159        do 102 il=1,ncum        do 102 il=1,ncum
# Line 205  Line 173 
173  !   ---  TO REPRESENT EQUAL PROBABILITIES OF MIXING  !   ---  TO REPRESENT EQUAL PROBABILITIES OF MIXING
174  !=====================================================================  !=====================================================================
175    
 !ym      call zilch(asum,ncum*nd)  
 !ym      call zilch(bsum,ncum*nd)  
 !ym      call zilch(csum,ncum*nd)  
176        call zilch(asum,nloc*nd)        call zilch(asum,nloc*nd)
177        call zilch(csum,nloc*nd)        call zilch(csum,nloc*nd)
178        call zilch(csum,nloc*nd)        call zilch(csum,nloc*nd)
# Line 353  Line 318 
318         endif         endif
319        enddo ! il        enddo ! il
320    
 !      do j=1,ntra  
 !       do il=1,ncum  
 !        if ( i.ge.icb(il) .and. i.le.inb(il) .and. lwork(il)  
 !     :     .and. csum(il,i).lt.m(il,i) ) then  
 !         traent(il,i,i,j)=tra(il,nk(il),j)  
 !        endif  
 !       enddo  
 !      enddo  
321  789   continue  789   continue
322  !  !
323  ! MAF: renormalisation de MENT  ! MAF: renormalisation de MENT

Legend:
Removed from v.47  
changed lines
  Added in v.69

  ViewVC Help
Powered by ViewVC 1.1.21