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_water,Lcpdqsat_water 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 REAL, SAVE :: qvap_deep ! deep mixing ratio of water vapor when simulating bottom less planets !$OMP THREADPRIVATE(ratqs, qvap_deep) ! 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= 0.) then !brings lower vapor ratio to a fixed value. ! tau=3600. seems too fast pdqvaplsc(1:ngrid,1) = (qvap_deep - pq(1:ngrid,1,igcm_h2o_vap))/14400. - pdq(1:ngrid,1,igcm_h2o_vap) endif end