Changeset 290 for trunk/LMDZ.MARS/libf/phymars/thermcell_main_mars.F90
- Timestamp:
- Sep 9, 2011, 4:24:40 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.MARS/libf/phymars/thermcell_main_mars.F90
r190 r290 114 114 LOGICAL active(ngridmx),activetmp(ngridmx) 115 115 REAL a1,b1,ae,be,ad,bd 116 INTEGER tic 116 117 117 118 ! ========================================== … … 334 335 alim_star(ig,1)=MAX((ztv(ig,1)-ztv(ig,2)),0.) & 335 336 & *sqrt(zlev(ig,2)) 337 ! & /sqrt(zlev(ig,2)) 336 338 ! & *zlev(ig,2) 337 339 lalim(ig)=2 … … 381 383 ! dans un panache conservatif 382 384 f_star(ig,1)=0. 385 383 386 f_star(ig,2)=alim_star(ig,1) 387 384 388 zw2(ig,2)=2.*g*(ztv(ig,1)-ztv(ig,2))/ztv(ig,2) & 385 389 & *(zlev(ig,2)-zlev(ig,1)) & 386 & 390 & *0.4*pphi(ig,1)/(pphi(ig,2)-pphi(ig,1)) 387 391 w_est(ig,2)=zw2(ig,2) 388 392 … … 420 424 421 425 ! if(l .lt. lalim(ig)) then 422 ! 426 ! ztva_est(ig,l)=(f_star(ig,l)*ztla(ig,l-1)+ & 423 427 ! & alim_star(ig,l)*ztv(ig,l)) & 424 428 ! & /(f_star(ig,l)+alim_star(ig,l)) … … 522 526 !--------------------------------------------------------------------------- 523 527 528 DO tic=0,3 529 524 530 activetmp(:)=active(:) .and. f_star(:,l+1)>1.e-10 525 531 do ig=1,ngridmx … … 547 553 enddo 548 554 555 ! ================ RECOMPUTE ENTR, DETR, and F FROM NEW W2 =================== 556 557 558 do ig=1,ngridmx 559 if (activetmp(ig)) then 560 561 zw2m=zw2(ig,l+1) 562 if(zw2m .gt. 0) then 563 if((a1*(zbuoy(ig,l)/zw2m)-b1) .gt. 0.) then 564 entr_star(ig,l)=f_star(ig,l)*zdz* & 565 & MAX(0.,ae*(a1*(zbuoy(ig,l)/zw2m)-b1)**be) 566 else 567 entr_star(ig,l)=0. 568 endif 569 570 if(zbuoy(ig,l) .gt. 0.) then 571 if(l .lt. lalim(ig)) then 572 detr_star(ig,l)=0. 573 else 574 detr_star(ig,l) = f_star(ig,l)*zdz* & 575 & ad 576 endif 577 else 578 detr_star(ig,l)=f_star(ig,l)*zdz* & 579 & bd*zbuoy(ig,l)/zw2m 580 endif 581 else 582 entr_star(ig,l)=0. 583 detr_star(ig,l)=0. 584 endif 585 586 ! En dessous de lalim, on prend le max de alim_star et entr_star pour 587 ! alim_star et 0 sinon 588 589 if (l.lt.lalim(ig)) then 590 alim_star(ig,l)=max(alim_star(ig,l),entr_star(ig,l)) 591 entr_star(ig,l)=0. 592 endif 593 594 ! Calcul du flux montant normalise 595 596 f_star(ig,l+1)=f_star(ig,l)+alim_star(ig,l)+entr_star(ig,l) & 597 & -detr_star(ig,l) 598 599 endif 600 enddo 601 602 ENDDO 549 603 !--------------------------------------------------------------------------- 550 604 !initialisations pour le calcul de la hauteur du thermique, de l'inversion et de la vitesse verticale max … … 1121 1175 do ig=1,ngridmx 1122 1176 if(lmax(ig) .gt. 1) then 1123 do k=1,lmax(ig) 1177 ! No downdraft in the very-near surface layer, we begin at k=3 1178 do k=3,lmax(ig) 1124 1179 zdthladj_down(ig,k)=(1./masse(ig,k))*(fm_down(ig,k+1)*ztv(ig,k+1)- & 1125 1180 & fm_down(ig,k)*ztv(ig,k)+fm_down(ig,k)*ztvd(ig,k)-fm_down(ig,k+1)*ztvd(ig,k+1))
Note: See TracChangeset
for help on using the changeset viewer.