Changeset 1897 for trunk/LMDZ.TITAN/libf/muphytitan/mm_microphysic.f90
- Timestamp:
- Jan 24, 2018, 10:24:24 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.TITAN/libf/muphytitan/mm_microphysic.f90
r1819 r1897 1 ! Copyright 2013-2015 Université de Reims Champagne-Ardenne1 ! Copyright 2013-2015,2017 Université de Reims Champagne-Ardenne 2 2 ! Contributor: J. Burgalat (GSMA, URCA) 3 3 ! email of the author : jeremie.burgalat@univ-reims.fr … … 35 35 !! brief: Microphysic processes interface module. 36 36 !! author: J. Burgalat 37 !! date: 2013-2015 37 !! date: 2013-2015,2017 38 38 39 39 MODULE MM_MICROPHYSIC … … 111 111 ! add temporary aerosols tendencies (-> m-3) 112 112 dm0a_f = dm0a_f + zdm0a_f ; dm3a_f = dm3a_f + zdm3a_f 113 ! sanity check for clouds tendencies114 WHERE (mm_m0ccn+dm0n*mm_dzlev < 0) ; dm0n = -mm_m0ccn/mm_dzlev ; END WHERE115 WHERE (mm_m3ccn+dm3n*mm_dzlev < 0) ; dm3n = -mm_m3ccn/mm_dzlev ; END WHERE116 117 113 ! reverse directly clouds tendencies (-> m-2) 118 114 dm0n = dm0n(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) 119 115 dm3n = dm3n(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) 116 ! sanity check for clouds tendencies 117 WHERE (mm_m0ccn+dm0n < 0) ; dm0n = -mm_m0ccn ; END WHERE 118 WHERE (mm_m3ccn+dm3n < 0) ; dm3n = -mm_m3ccn ; END WHERE 120 119 DO i=1,mm_nesp 121 120 dm3i(:,i) = dm3i(mm_nla:1:-1,i) * mm_dzlev(mm_nla:1:-1) 122 WHERE (mm_m3 ccn+dm3n*mm_dzlev < 0) ; dm3n = -mm_m3ccn/mm_dzlev; END WHERE121 WHERE (mm_m3ice+dm3i < 0) ; dm3i = -mm_m3ice ; END WHERE 123 122 dgazs(:,i) = dgazs(mm_nla:1:-1,i) 124 123 ! no sanity check for gazs, let's prey. … … 127 126 dm0n = 0._mm_wp ; dm3n = 0._mm_wp ; dm3i = 0._mm_wp ; dgazs = 0._mm_wp 128 127 ENDIF 129 ! sanity check130 WHERE (mm_m0aer_s+dm0a_s*mm_dzlev < 0) ; dm0a_s = -mm_m0aer_s/mm_dzlev ; END WHERE131 WHERE (mm_m3aer_s+dm3a_f*mm_dzlev < 0) ; dm3a_s = -mm_m3aer_s/mm_dzlev ; END WHERE132 WHERE (mm_m0aer_f+dm0a_f*mm_dzlev < 0) ; dm0a_f = -mm_m0aer_f/mm_dzlev ; END WHERE133 WHERE (mm_m3aer_f+dm3a_f*mm_dzlev < 0) ; dm3a_f = -mm_m3aer_f/mm_dzlev ; END WHERE134 135 128 ! multiply by altitude thickness and reverse vectors so they go from ground to top :) 136 129 dm0a_s = dm0a_s(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) … … 138 131 dm0a_f = dm0a_f(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) 139 132 dm3a_f = dm3a_f(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) 133 ! sanity check 134 WHERE (mm_m0aer_s+dm0a_s < 0) ; dm0a_s = -mm_m0aer_s ; END WHERE 135 WHERE (mm_m3aer_s+dm3a_f < 0) ; dm3a_s = -mm_m3aer_s ; END WHERE 136 WHERE (mm_m0aer_f+dm0a_f < 0) ; dm0a_f = -mm_m0aer_f ; END WHERE 137 WHERE (mm_m3aer_f+dm3a_f < 0) ; dm3a_f = -mm_m3aer_f ; END WHERE 140 138 141 139 RETURN … … 167 165 ! Calls haze microphysics 168 166 call mm_haze_microphysics(dm0a_s,dm3a_s,dm0a_f,dm3a_f) 169 ! sanity check170 WHERE (mm_m0aer_s+dm0a_s*mm_dzlev < 0) ; dm0a_s = -mm_m0aer_s/mm_dzlev ; END WHERE171 WHERE (mm_m3aer_s+dm3a_f*mm_dzlev < 0) ; dm3a_s = -mm_m3aer_s/mm_dzlev ; END WHERE172 WHERE (mm_m0aer_f+dm0a_f*mm_dzlev < 0) ; dm0a_f = -mm_m0aer_f/mm_dzlev ; END WHERE173 WHERE (mm_m3aer_f+dm3a_f*mm_dzlev < 0) ; dm3a_f = -mm_m3aer_f/mm_dzlev ; END WHERE174 167 ! reverse vectors so they go from ground to top :) 175 168 dm0a_s = dm0a_s(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) … … 177 170 dm0a_f = dm0a_f(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) 178 171 dm3a_f = dm3a_f(mm_nla:1:-1) * mm_dzlev(mm_nla:1:-1) 172 ! sanity check 173 WHERE (mm_m0aer_s+dm0a_s < 0) ; dm0a_s = -mm_m0aer_s ; END WHERE 174 WHERE (mm_m3aer_s+dm3a_f < 0) ; dm3a_s = -mm_m3aer_s ; END WHERE 175 WHERE (mm_m0aer_f+dm0a_f < 0) ; dm0a_f = -mm_m0aer_f ; END WHERE 176 WHERE (mm_m3aer_f+dm3a_f < 0) ; dm3a_f = -mm_m3aer_f ; END WHERE 179 177 RETURN 180 178 END FUNCTION muphys_nocld
Note: See TracChangeset
for help on using the changeset viewer.