subroutine largescale(ngrid,nlayer,nq,ptimestep, pplev, pplay, & pt, pq, pdt, pdq, pdtlsc, pdqvaplsc, pdqliqlsc, rneb) use ioipsl_getin_p_mod, only: getin_p use watercommon_h, only : RLVTT, RCPD, RVTMP2, & T_h2O_ice_clouds,T_h2O_ice_liq,Psat_waterDP,Lcpdqsat_waterDP USE tracer_h IMPLICIT none !================================================================== ! ! Purpose ! ------- ! Calculates large-scale (stratiform) H2O condensation. ! ! Authors ! ------- ! Adapted from the LMDTERRE code by R. Wordsworth (2009) ! Original author Z. X. Li (1993) ! !================================================================== INTEGER ngrid,nlayer,nq ! Arguments REAL ptimestep ! intervalle du temps (s) REAL pplev(ngrid,nlayer+1) ! pression a inter-couche REAL pplay(ngrid,nlayer) ! pression au milieu de couche REAL pt(ngrid,nlayer) ! temperature (K) REAL pq(ngrid,nlayer,nq) ! tracer mixing ratio (kg/kg) REAL pdt(ngrid,nlayer) ! physical temperature tenedency (K/s) REAL pdq(ngrid,nlayer,nq)! physical tracer tenedency (K/s) REAL pdtlsc(ngrid,nlayer) ! incrementation de la temperature (K) REAL pdqvaplsc(ngrid,nlayer) ! incrementation de la vapeur d'eau REAL pdqliqlsc(ngrid,nlayer) ! incrementation de l'eau liquide REAL rneb(ngrid,nlayer) ! fraction nuageuse ! Options du programme REAL, SAVE :: ratqs ! determine largeur de la distribution de vapeur !$OMP THREADPRIVATE(ratqs) ! Variables locales REAL CBRT EXTERNAL CBRT INTEGER i, k , nn INTEGER,PARAMETER :: nitermax=5000 DOUBLE PRECISION,PARAMETER :: alpha=.1,qthreshold=1.d-8 ! JL13: if "careful, T