- Timestamp:
- Mar 19, 2026, 2:35:46 PM (11 days ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.GENERIC/libf/phygeneric/mass_redistribution_mod.F90
r3893 r4146 13 13 USE planete_mod, only: bp 14 14 use comcstfi_mod, only: g 15 USE callkeys_mod, ONLY: water 15 USE callkeys_mod, ONLY: water, generic_condensation 16 use generic_tracer_index_mod, only: generic_tracer_index 17 use generic_cloud_common_h 16 18 17 19 IMPLICIT NONE … … 96 98 REAL zqm(nlayer+1,nq),zqm1(nlayer+1) 97 99 REAL sigma(nlayer+1) 98 99 ! local saved variables 100 LOGICAL, SAVE :: firstcall=.true. 101 !$OMP THREADPRIVATE(firstcall) 102 103 !---------------------------------------------------------------------- 104 105 ! Initialisation 106 ! -------------- 107 ! 108 IF (firstcall) THEN 109 firstcall=.false. 110 ENDIF 111 ! 100 101 ! Generic condensation 102 integer igcm_generic_vap, igcm_generic_ice 103 logical call_ice_vap_generic 104 112 105 !====================================================================== 113 106 ! Calcul of h2o condensation … … 159 152 enddo 160 153 endif 154 155 if (generic_condensation) then 156 157 do iq=1,nq 158 159 call generic_tracer_index(nq,iq,igcm_generic_vap,igcm_generic_ice,call_ice_vap_generic) 160 161 end do ! do iq=1,nq loop on tracers 162 163 do ig=1,ngrid 164 call Tsat_generic(pplev(ig,1)+zdmass_sum(ig,1)*g*ptimestep,Tsat(ig)) 165 enddo 166 #ifndef MESOSCALE 167 call writediagfi(ngrid,'Tsat','saturation temperature at surface','',2,Tsat) 168 #endif 169 170 do ig=1,ngrid 171 if (ztsrf(ig).gt.Tsat(ig)) then 172 zmassboil(ig)=(ptsrf(ig)-Tsat(ig))*pcapcal(ig)/RLVTT_generic/ptimestep 173 if ((zmassboil(ig)*ptimestep.gt.pqs(ig,igcm_generic_vap)).and.(nint(rnat(ig)).eq.1)) then 174 zmassboil(ig)=pqs(ig,igcm_generic_vap)/ptimestep 175 endif 176 zmassboil(ig)=zmassboil(ig)*0.0 !momentary, should be 1. JL12 177 pdqsmr(ig,igcm_generic_vap)=-zmassboil(ig) 178 pdtsrfmr(ig)=-zmassboil(ig)*RLVTT_generic/pcapcal(ig) 179 ztsrf(ig)=ptsrf(ig)+pdtsrfmr(ig)*ptimestep 180 else 181 zmassboil(ig)=0. 182 pdtsrfmr(ig)=0. 183 endif 184 enddo 185 endif 161 186 162 187 ! ************************* … … 225 250 zqm(1,1:nq)=0. ! most tracer do not condense ! 226 251 if (water) zqm(1,igcm_h2o_vap)=1. ! flux is 100% h2o at surface 252 if (generic_condensation) zqm(1,igcm_generic_vap)=1. ! flux is 100% condensable at surface 227 253 228 254 ! Van Leer scheme:
Note: See TracChangeset
for help on using the changeset viewer.
