Ignore:
Timestamp:
Jul 1, 2010, 11:02:53 AM (14 years ago)
Author:
Laurent Fairhead
Message:

Merged LMDZ4V5.0-dev branch changes r1292:r1399 to trunk.

Validation:
Validation consisted in compiling the HEAD revision of the trunk,
LMDZ4V5.0-dev branch and the merged sources and running different
configurations on local and SX8 machines comparing results.

Local machine: bench configuration, 32x24x11, gfortran

  • IPSLCM5A configuration (comparison between trunk and merged sources):
    • numerical convergence on dynamical fields over 3 days
    • start files are equivalent (except for RN and PB fields)
    • daily history files equivalent
  • MH07 configuration, new physics package (comparison between LMDZ4V5.0-dev branch and merged sources):
    • numerical convergence on dynamical fields over 3 days
    • start files are equivalent (except for RN and PB fields)
    • daily history files equivalent

SX8 machine (brodie), 96x95x39 on 4 processors:

  • IPSLCM5A configuration:
    • start files are equivalent (except for RN and PB fields)
    • monthly history files equivalent
  • MH07 configuration:
    • start files are equivalent (except for RN and PB fields)
    • monthly history files equivalent

Changes to the makegcm and create_make_gcm scripts to take into account
main programs in F90 files


Fusion de la branche LMDZ4V5.0-dev (r1292:r1399) au tronc principal

Validation:
La validation a consisté à compiler la HEAD de le trunk et de la banche
LMDZ4V5.0-dev et les sources fusionnées et de faire tourner le modéle selon
différentes configurations en local et sur SX8 et de comparer les résultats

En local: 32x24x11, config bench/gfortran

  • pour une config IPSLCM5A (comparaison tronc/fusion):
    • convergence numérique sur les champs dynamiques après 3 jours
    • restart et restartphy égaux (à part sur RN et Pb)
    • fichiers histoire égaux
  • pour une config nlle physique (MH07) (comparaison LMDZ4v5.0-dev/fusion):
    • convergence numérique sur les champs dynamiques après 3 jours
    • restart et restartphy égaux
    • fichiers histoire équivalents

Sur brodie, 96x95x39 sur 4 proc:

  • pour une config IPSLCM5A:
    • restart et restartphy égaux (à part sur RN et PB)
    • pas de différence dans les fichiers histmth.nc
  • pour une config MH07
    • restart et restartphy égaux (à part sur RN et PB)
    • pas de différence dans les fichiers histmth.nc

Changement sur makegcm et create_make-gcm pour pouvoir prendre en compte des
programmes principaux en *F90

Location:
LMDZ4/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • LMDZ4/trunk

  • LMDZ4/trunk/libf/phylmd/thermcell_env.F90

    r970 r1403  
    11      SUBROUTINE thermcell_env(ngrid,nlay,po,pt,pu,pv,pplay,  &
    2      &           pplev,zo,zh,zl,ztv,zthl,zu,zv,zpspsk,zqsat,lev_out)
     2     &           pplev,zo,zh,zl,ztv,zthl,zu,zv,zpspsk,pqsat,lev_out)
    33
    44!--------------------------------------------------------------
     
    3131      REAL zu(ngrid,nlay)
    3232      REAL zv(ngrid,nlay)
    33       REAL zqsat(ngrid,nlay)
     33      REAL pqsat(ngrid,nlay)
    3434
    35       INTEGER ig,l,ll
     35      INTEGER ig,ll
    3636
    37       real zcor,zdelta,zcvm5,qlbef
    38       real Tbef,qsatbef
    39       real dqsat_dT,DT,num,denom
    40       REAL RLvCp,DDT0
    41       PARAMETER (DDT0=.01)
    42       LOGICAL Zsat
     37      real dqsat_dT
     38      real RLvCp
    4339
    44       Zsat=.false.
    45       RLvCp = RLVTT/RCPD
     40logical mask(ngrid,nlay)
    4641
    47 !
    48 ! Pr Tprec=Tl calcul de qsat
    49 ! Si qsat>qT T=Tl, q=qT
    50 ! Sinon DDT=(-Tprec+Tl+RLVCP (qT-qsat(T')) / (1+RLVCP dqsat/dt)
    51 ! On cherche DDT < DDT0
     42
     43!^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     44! Initialisations :
     45!------------------
     46
     47mask(:,:)=.true.
     48RLvCp = RLVTT/RCPD
     49
    5250!
    5351! calcul des caracteristiques de l environnement
     
    5755            zl(ig,ll)=0.
    5856            zh(ig,ll)=pt(ig,ll)
    59             zqsat(ig,ll)=0.
    6057         EndDO
    6158       EndDO
    6259!
    6360!
    64 !recherche de saturation dans l environnement
    65        DO ll=1,nlay
    66 ! les points insatures sont definitifs
    67          DO ig=1,ngrid
    68             Tbef=pt(ig,ll)
    69             zdelta=MAX(0.,SIGN(1.,RTT-Tbef))
    70             qsatbef= R2ES * FOEEW(Tbef,zdelta)/pplev(ig,ll)
    71             qsatbef=MIN(0.5,qsatbef)
    72             zcor=1./(1.-retv*qsatbef)
    73             qsatbef=qsatbef*zcor
    74             Zsat = (max(0.,po(ig,ll)-qsatbef) .gt. 1.e-10)
    75             if (Zsat) then
    76             qlbef=max(0.,po(ig,ll)-qsatbef)
    77 ! si sature: ql est surestime, d'ou la sous-relax
    78             DT = 0.5*RLvCp*qlbef
    79 ! on pourra enchainer 2 ou 3 calculs sans Do while
    80             do while (abs(DT).gt.DDT0)
    81 ! il faut verifier si c,a conserve quand on repasse en insature ...
    82               Tbef=Tbef+DT
    83               zdelta=MAX(0.,SIGN(1.,RTT-Tbef))
    84               qsatbef= R2ES * FOEEW(Tbef,zdelta)/pplev(ig,ll)
    85               qsatbef=MIN(0.5,qsatbef)
    86               zcor=1./(1.-retv*qsatbef)
    87               qsatbef=qsatbef*zcor
    88 ! on veut le signe de qlbef
    89               qlbef=po(ig,ll)-qsatbef
    90 !          dqsat_dT
    91               zdelta=MAX(0.,SIGN(1.,RTT-Tbef))
    92               zcvm5=R5LES*(1.-zdelta) + R5IES*zdelta
    93               zcor=1./(1.-retv*qsatbef)
    94               dqsat_dT=FOEDE(Tbef,zdelta,zcvm5,qsatbef,zcor)
    95               num=-Tbef+pt(ig,ll)+RLvCp*qlbef
    96               denom=1.+RLvCp*dqsat_dT
    97               if (denom.lt.1.e-10) then
    98                   print*,'pb denom'
    99               endif
    100               DT=num/denom
    101             enddo
    102 ! on ecrit de maniere conservative (sat ou non)
    103             zl(ig,ll) = max(0.,qlbef)
    104 !          T = Tl +Lv/Cp ql
    105             zh(ig,ll) = pt(ig,ll)+RLvCp*zl(ig,ll)
    106             zo(ig,ll) = po(ig,ll)-zl(ig,ll)
    107            endif
    108 !on ecrit zqsat
    109             zqsat(ig,ll)=qsatbef     
    110          EndDO
    111        EndDO
     61! Condensation :
     62!---------------
     63! Calcul de l'humidite a saturation et de la condensation
     64
     65call thermcell_qsat(ngrid*nlay,mask,pplev,pt,po,pqsat)
     66DO ll=1,nlay
     67   DO ig=1,ngrid
     68      zl(ig,ll) = max(0.,po(ig,ll)-pqsat(ig,ll))
     69      zh(ig,ll) = pt(ig,ll)+RLvCp*zl(ig,ll)         !   T = Tl + Lv/Cp ql
     70      zo(ig,ll) = po(ig,ll)-zl(ig,ll)
     71   ENDDO
     72ENDDO
    11273!
    11374!
    11475!-----------------------------------------------------------------------
    115 !   incrementation eventuelle de tendances precedentes:
    116 !   ---------------------------------------------------
    11776
    11877      if (prt_level.ge.1) print*,'0 OK convect8'
    11978
    120       DO 1010 l=1,nlay
    121          DO 1015 ig=1,ngrid
    122              zpspsk(ig,l)=(pplay(ig,l)/100000.)**RKAPPA
    123              zu(ig,l)=pu(ig,l)
    124              zv(ig,l)=pv(ig,l)
     79      DO ll=1,nlay
     80         DO ig=1,ngrid
     81             zpspsk(ig,ll)=(pplay(ig,ll)/100000.)**RKAPPA
     82             zu(ig,ll)=pu(ig,ll)
     83             zv(ig,ll)=pv(ig,ll)
    12584!attention zh est maintenant le profil de T et plus le profil de theta !
     85! Quelle horreur ! A eviter.
    12686!
    12787!   T-> Theta
    128             ztv(ig,l)=zh(ig,l)/zpspsk(ig,l)
     88            ztv(ig,ll)=zh(ig,ll)/zpspsk(ig,ll)
    12989!Theta_v
    130             ztv(ig,l)=ztv(ig,l)*(1.+RETV*(zo(ig,l))  &
    131      &           -zl(ig,l))
     90            ztv(ig,ll)=ztv(ig,ll)*(1.+RETV*(zo(ig,ll))-zl(ig,ll))
    13291!Thetal
    133             zthl(ig,l)=pt(ig,l)/zpspsk(ig,l)
     92            zthl(ig,ll)=pt(ig,ll)/zpspsk(ig,ll)
    13493!           
    135 1015     CONTINUE
    136 1010  CONTINUE
     94         ENDDO
     95      ENDDO
    13796 
    13897      RETURN
Note: See TracChangeset for help on using the changeset viewer.