Changeset 1647 for trunk/LMDZ.TITAN/libf/phytitan/radii_mod.F90
- Timestamp:
- Jan 11, 2017, 3:33:51 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.TITAN/libf/phytitan/radii_mod.F90
r1529 r1647 3 3 !================================================================== 4 4 ! module to centralize the radii calculations for aerosols 5 ! OK for water but should be extended to other aerosols (CO2,...)6 5 !================================================================== 7 6 8 ! water cloud optical properties 9 10 use callkeys_mod, only: radfixed,Nmix_co2, & 11 pres_bottom_tropo,pres_top_tropo,size_tropo, & 12 pres_bottom_strato,size_strato 13 14 real, save :: rad_h2o 15 real, save :: rad_h2o_ice 16 real, save :: Nmix_h2o 17 real, save :: Nmix_h2o_ice 18 !$OMP THREADPRIVATE(rad_h2o,rad_h2o_ice,Nmix_h2o,Nmix_h2o_ice) 19 real, parameter :: coef_chaud=0.13 20 real, parameter :: coef_froid=0.09 21 7 use callkeys_mod, only: pres_bottom_tropo,pres_top_tropo, & 8 size_tropo,pres_bottom_strato,size_strato 22 9 23 10 contains … … 38 25 use ioipsl_getin_p_mod, only: getin_p 39 26 use radinc_h, only: naerkind 40 use aerosol_mod, only: iaero_back2lay, iaero_co2, iaero_dust, & 41 iaero_h2o, iaero_h2so4 27 use aerosol_mod, only: iaero_back2lay 42 28 Implicit none 43 29 … … 59 45 ! .def file. To be improved! 60 46 61 if(iaer.eq.iaero_co2)then ! CO2 ice 47 48 ! WARNING : Titan adapt. (J. Vatant d'Ollone, 2017) 49 ! - ONLY THE NO AEROSOL CASE FOR NOW SINCE WE COMPUTE THEM ANOTHER WAY ! 50 ! - This routine is just here to keep the code running without unplugging all (yet) 51 ! - There's only the dummy aerosol case on iaer = 1 52 if(iaer.eq.1)then 62 53 reffrad(1:ngrid,1:nlayer,iaer) = 1.e-4 63 nueffrad(1:ngrid,1:nlayer,iaer) = 0.164 endif65 66 if(iaer.eq.iaero_h2o)then ! H2O ice67 reffrad(1:ngrid,1:nlayer,iaer) = 1.e-568 nueffrad(1:ngrid,1:nlayer,iaer) = 0.169 endif70 71 if(iaer.eq.iaero_dust)then ! dust72 reffrad(1:ngrid,1:nlayer,iaer) = 1.e-573 nueffrad(1:ngrid,1:nlayer,iaer) = 0.174 endif75 76 if(iaer.eq.iaero_h2so4)then ! H2O ice77 reffrad(1:ngrid,1:nlayer,iaer) = 1.e-678 54 nueffrad(1:ngrid,1:nlayer,iaer) = 0.1 79 55 endif … … 83 59 nueffrad(1:ngrid,1:nlayer,iaer) = 0.1 84 60 endif 85 86 87 61 88 62 if(iaer.gt.5)then … … 95 69 enddo 96 70 97 98 if (radfixed) then99 100 write(*,*)"radius of H2O water particles:"101 rad_h2o=13. ! default value102 call getin_p("rad_h2o",rad_h2o)103 write(*,*)" rad_h2o = ",rad_h2o104 105 write(*,*)"radius of H2O ice particles:"106 rad_h2o_ice=35. ! default value107 call getin_p("rad_h2o_ice",rad_h2o_ice)108 write(*,*)" rad_h2o_ice = ",rad_h2o_ice109 110 else111 112 write(*,*)"Number mixing ratio of H2O water particles:"113 Nmix_h2o=1.e6 ! default value114 call getin_p("Nmix_h2o",Nmix_h2o)115 write(*,*)" Nmix_h2o = ",Nmix_h2o116 117 write(*,*)"Number mixing ratio of H2O ice particles:"118 Nmix_h2o_ice=Nmix_h2o ! default value119 call getin_p("Nmix_h2o_ice",Nmix_h2o_ice)120 write(*,*)" Nmix_h2o_ice = ",Nmix_h2o_ice121 endif122 123 71 print*,'exit su_aer_radii' 124 72 … … 126 74 !================================================================== 127 75 128 129 !==================================================================130 subroutine h2o_reffrad(ngrid,nlayer,pq,pt,reffrad,nueffrad)131 !==================================================================132 ! Purpose133 ! -------134 ! Compute the effective radii of liquid and icy water particles135 !136 ! Authors137 ! -------138 ! Jeremy Leconte (2012)139 !140 !==================================================================141 use watercommon_h, Only: T_h2O_ice_liq,T_h2O_ice_clouds,rhowater,rhowaterice142 use comcstfi_mod, only: pi143 Implicit none144 145 integer,intent(in) :: ngrid146 integer,intent(in) :: nlayer147 148 real, intent(in) :: pq(ngrid,nlayer) !water ice mixing ratios (kg/kg)149 real, intent(in) :: pt(ngrid,nlayer) !temperature (K)150 real, intent(out) :: reffrad(ngrid,nlayer) !aerosol radii151 real, intent(out) :: nueffrad(ngrid,nlayer) ! dispersion152 153 integer :: ig,l154 real zfice ,zrad,zrad_liq,zrad_ice155 real,external :: CBRT156 157 158 if (radfixed) then159 do l=1,nlayer160 do ig=1,ngrid161 zfice = 1.0 - (pt(ig,l)-T_h2O_ice_clouds) / (T_h2O_ice_liq-T_h2O_ice_clouds)162 zfice = MIN(MAX(zfice,0.0),1.0)163 reffrad(ig,l)= rad_h2o * (1.-zfice) + rad_h2o_ice * zfice164 nueffrad(ig,l) = coef_chaud * (1.-zfice) + coef_froid * zfice165 enddo166 enddo167 else168 do l=1,nlayer169 do ig=1,ngrid170 zfice = 1.0 - (pt(ig,l)-T_h2O_ice_clouds) / (T_h2O_ice_liq-T_h2O_ice_clouds)171 zfice = MIN(MAX(zfice,0.0),1.0)172 zrad_liq = CBRT( 3*pq(ig,l)/(4*Nmix_h2o*pi*rhowater) )173 zrad_ice = CBRT( 3*pq(ig,l)/(4*Nmix_h2o_ice*pi*rhowaterice) )174 nueffrad(ig,l) = coef_chaud * (1.-zfice) + coef_froid * zfice175 zrad = zrad_liq * (1.-zfice) + zrad_ice * zfice176 177 reffrad(ig,l) = min(max(zrad,1.e-6),1000.e-6)178 enddo179 enddo180 end if181 182 end subroutine h2o_reffrad183 !==================================================================184 185 186 !==================================================================187 subroutine h2o_cloudrad(ngrid,nlayer,pql,reffliq,reffice)188 !==================================================================189 ! Purpose190 ! -------191 ! Compute the effective radii of liquid and icy water particles192 !193 ! Authors194 ! -------195 ! Jeremy Leconte (2012)196 !197 !==================================================================198 use watercommon_h, Only: rhowater,rhowaterice199 use comcstfi_mod, only: pi200 Implicit none201 202 integer,intent(in) :: ngrid203 integer,intent(in) :: nlayer204 205 real, intent(in) :: pql(ngrid,nlayer) !condensed water mixing ratios (kg/kg)206 real, intent(out) :: reffliq(ngrid,nlayer),reffice(ngrid,nlayer) !liquid and ice water particle radii (m)207 208 real,external :: CBRT209 integer :: i,k210 211 if (radfixed) then212 reffliq(1:ngrid,1:nlayer)= rad_h2o213 reffice(1:ngrid,1:nlayer)= rad_h2o_ice214 else215 do k=1,nlayer216 do i=1,ngrid217 reffliq(i,k) = CBRT(3*pql(i,k)/(4*Nmix_h2o*pi*rhowater))218 reffliq(i,k) = min(max(reffliq(i,k),1.e-6),1000.e-6)219 220 reffice(i,k) = CBRT(3*pql(i,k)/(4*Nmix_h2o_ice*pi*rhowaterice))221 reffice(i,k) = min(max(reffice(i,k),1.e-6),1000.e-6)222 enddo223 enddo224 endif225 226 end subroutine h2o_cloudrad227 !==================================================================228 229 230 231 !==================================================================232 subroutine co2_reffrad(ngrid,nlayer,nq,pq,reffrad)233 !==================================================================234 ! Purpose235 ! -------236 ! Compute the effective radii of co2 ice particles237 !238 ! Authors239 ! -------240 ! Jeremy Leconte (2012)241 !242 !==================================================================243 USE tracer_h, only:igcm_co2_ice,rho_co2244 use comcstfi_mod, only: pi245 Implicit none246 247 integer,intent(in) :: ngrid,nlayer,nq248 249 real, intent(in) :: pq(ngrid,nlayer,nq) !tracer mixing ratios (kg/kg)250 real, intent(out) :: reffrad(ngrid,nlayer) !co2 ice particles radii (m)251 252 integer :: ig,l253 real :: zrad254 real,external :: CBRT255 256 257 258 if (radfixed) then259 reffrad(1:ngrid,1:nlayer) = 5.e-5 ! CO2 ice260 else261 do l=1,nlayer262 do ig=1,ngrid263 zrad = CBRT( 3*pq(ig,l,igcm_co2_ice)/(4*Nmix_co2*pi*rho_co2) )264 reffrad(ig,l) = min(max(zrad,1.e-6),100.e-6)265 enddo266 enddo267 end if268 269 end subroutine co2_reffrad270 !==================================================================271 272 273 274 !==================================================================275 subroutine dust_reffrad(ngrid,nlayer,reffrad)276 !==================================================================277 ! Purpose278 ! -------279 ! Compute the effective radii of dust particles280 !281 ! Authors282 ! -------283 ! Jeremy Leconte (2012)284 !285 !==================================================================286 Implicit none287 288 integer,intent(in) :: ngrid289 integer,intent(in) :: nlayer290 291 real, intent(out) :: reffrad(ngrid,nlayer) !dust particles radii (m)292 293 reffrad(1:ngrid,1:nlayer) = 2.e-6 ! dust294 295 end subroutine dust_reffrad296 !==================================================================297 298 299 !==================================================================300 subroutine h2so4_reffrad(ngrid,nlayer,reffrad)301 !==================================================================302 ! Purpose303 ! -------304 ! Compute the effective radii of h2so4 particles305 !306 ! Authors307 ! -------308 ! Jeremy Leconte (2012)309 !310 !==================================================================311 Implicit none312 313 integer,intent(in) :: ngrid314 integer,intent(in) :: nlayer315 316 real, intent(out) :: reffrad(ngrid,nlayer) !h2so4 particle radii (m)317 318 reffrad(1:ngrid,1:nlayer) = 1.e-6 ! h2so4319 320 end subroutine h2so4_reffrad321 !==================================================================322 76 323 77 !==================================================================
Note: See TracChangeset
for help on using the changeset viewer.