- Timestamp:
- Mar 19, 2025, 4:44:03 PM (3 months ago)
- Location:
- LMDZ6/branches/contrails/libf/phylmd
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/branches/contrails/libf/phylmd/lmdz_lscp.f90
r5579 r5580 487 487 DO k = klev, 1, -1 488 488 489 !--Initialisation of advected properties 489 490 cldfra_in(:) = cf_seri(:,k) 490 qvc_in(:) = rvc_seri(:,k) * q _seri(:,k)491 qvc_in(:) = rvc_seri(:,k) * qt(:,k) 491 492 qliq_in(:) = ql_seri(:,k) 492 493 qice_in(:) = qi_seri(:,k) -
LMDZ6/branches/contrails/libf/phylmd/lmdz_lscp_condensation.f90
r5579 r5580 306 306 cldfra(i) = MAX(0., MIN(1., cldfra_in(i))) 307 307 qcld(i) = MAX(0., MIN(qtot(i), qliq_in(i) + qice_in(i) + qvc_in(i))) 308 qvc(i) = MAX(0., MIN(qcld(i), qvc_in ))308 qvc(i) = MAX(0., MIN(qcld(i), qvc_in(i))) 309 309 ok_warm_cloud = .TRUE. 310 310 ELSE -
LMDZ6/branches/contrails/libf/phylmd/lmdz_lscp_ini.f90
r5579 r5580 344 344 !$OMP THREADPRIVATE(snow_fallspeed_cld) 345 345 346 INTEGER, SAVE, PROTECTED :: ok_precip_resuspension=.FALSE.! Flag to activate the resuspension of ice crystals346 LOGICAL, SAVE, PROTECTED :: ok_precip_resuspension=.FALSE.! Flag to activate the resuspension of ice crystals 347 347 !$OMP THREADPRIVATE(ok_precip_resuspension) 348 348 -
LMDZ6/branches/contrails/libf/phylmd/lmdz_lscp_precip.f90
r5579 r5580 800 800 dqrevap = 0. 801 801 dqssubl = 0. 802 IF ( ok_ ice_supersat .AND. ok_precip_resuspension ) THEN802 IF ( ok_precip_resuspension ) THEN 803 803 dqsres(:) = 0. 804 804 dcfres(:) = 0. … … 1086 1086 !--Only the snow flux can go back to cloud, and only if there is no rain flux 1087 1087 !--(mixed-phase clouds) 1088 !--The ok_ice_supersaturation is used to ensure that cloud fraction is advected 1089 !--but maybe it is not needed 1090 IF ( ok_ice_supersat .AND. ok_precip_resuspension ) THEN 1091 1092 IF ( (precipfracclr_tmp(i) .GT. 0.) .AND. (rainclr_tmp(i) .LT. eps) ) THEN 1093 dsnowres = snowclr_tmp(i) * EXP( - snowclr_tmp(i) / precipfracclr_tmp(i) / snow_thresh_resuspension ) 1094 dqsres(i) = dqsres(i) - dsnowres / dhum_to_dflux(i) 1095 !--The following line determines the in-cloud ice water content of the newly formed cloud 1096 !--It is a linear combination between the in-precip ice water content (left term) and the 1097 !--in-existing-cloud ice water content (right term). This is done so that the existing cloud 1098 !--is not too modified, i.e. unphysical ice fluxes going from the existing cloud to the new 1099 !--cloud. If the existing cloud is already large, the newly formed cloud fraction is reduced 1100 !--to match the in-cloud ice water content of the existing cloud. 1101 !--NB. this is done on qi, not on qvc. Not sure what impact that implies 1102 qiceinprecip = - dqsres(i) / precipfracclr_tmp(i) * ( 1. - cldfra(i) ) + qice(i) 1103 dcfres(i) = - dqsres(i) / qiceinprecip 1104 dqvcres(i) = qvapclr * dcfres(i) 1105 !--Add tendencies 1106 snowcld_tmp(i) = snowcld_tmp(i) + dsnowres 1107 ENDIF 1108 1109 IF ( (precipfraccld_tmp(i) .GT. 0.) .AND. (raincld_tmp(i) .LT. eps) ) THEN 1110 dsnowres = snowcld_tmp(i) * EXP( - snowcld_tmp(i) / precipfraccld_tmp(i) / snow_thresh_resuspension ) 1111 dqsres(i) = dqsres(i) - dsnowres / dhum_to_dflux(i) 1112 !--Add tendencies 1113 snowcld_tmp(i) = snowcld_tmp(i) + dsnowres 1088 IF ( ok_precip_resuspension ) THEN 1089 1090 IF ( (snowclr_tmp(i) .GT. 0.) .AND. (precipfracclr_tmp(i) .GT. eps) & 1091 .AND. (rainclr_tmp(i) .LT. eps) ) THEN 1092 IF ( dsnowres .GT. 0. ) THEN 1093 dsnowres = snowclr_tmp(i) * EXP( - snowclr_tmp(i) / precipfracclr_tmp(i) & 1094 / snow_thresh_resuspension ) 1095 dqsres(i) = dqsres(i) - dsnowres / dhum_to_dflux(i) 1096 !--The following line determines the in-cloud ice water content of the newly formed cloud 1097 !--It is a linear combination between the in-precip ice water content (left term) and the 1098 !--in-existing-cloud ice water content (right term). This is done so that the existing 1099 !--cloud is not too modified, i.e. unphysical ice fluxes going from the existing cloud 1100 !--to the new cloud. If the existing cloud is already large, the newly formed cloud 1101 !--fraction is reduced to match the in-cloud ice water content of the existing cloud. 1102 !--NB. this is done on qi, not on qvc. Not sure what impact that implies 1103 qiceinprecip = - dqsres(i) / precipfracclr_tmp(i) * ( 1. - cldfra(i) ) + qice(i) 1104 dcfres(i) = - dqsres(i) / qiceinprecip 1105 dqvcres(i) = qvapclr * dcfres(i) 1106 !--Add tendencies 1107 snowcld_tmp(i) = snowcld_tmp(i) + dsnowres 1108 ENDIF 1109 ENDIF 1110 1111 IF ( (snowcld_tmp(i) .GT. 0.) .AND. (precipfraccld_tmp(i) .GT. 0.) & 1112 .AND. (raincld_tmp(i) .LT. eps) ) THEN 1113 IF ( dsnowres .GT. 0. ) THEN 1114 dsnowres = snowcld_tmp(i) * EXP( - snowcld_tmp(i) / precipfraccld_tmp(i) & 1115 / snow_thresh_resuspension ) 1116 dqsres(i) = dqsres(i) - dsnowres / dhum_to_dflux(i) 1117 !--Add tendencies 1118 snowcld_tmp(i) = snowcld_tmp(i) + dsnowres 1119 ENDIF 1114 1120 ENDIF 1115 1121 … … 1118 1124 qvc(i) = qvc(i) + dqvcres(i) 1119 1125 qice(i) = qice(i) - dqsres(i) 1126 !--Recall that qvap is here the total water in the gridbox 1127 qvap(i) = qvap(i) - dqsres(i) 1120 1128 ENDIF 1121 1129
Note: See TracChangeset
for help on using the changeset viewer.