Changeset 3959 for trunk/LMDZ.PLUTO/libf
- Timestamp:
- Nov 12, 2025, 6:12:16 PM (4 weeks ago)
- Location:
- trunk/LMDZ.PLUTO/libf/phypluto
- Files:
-
- 8 edited
-
aeropacity.F90 (modified) (5 diffs)
-
callcorrk.F90 (modified) (4 diffs)
-
callkeys_mod.F90 (modified) (1 diff)
-
datafile_mod.F90 (modified) (1 diff)
-
inifis_mod.F90 (modified) (4 diffs)
-
optci.F90 (modified) (9 diffs)
-
optcv.F90 (modified) (6 diffs)
-
suaer_corrk.F90 (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.PLUTO/libf/phypluto/aeropacity.F90
r3802 r3959 13 13 use comcstfi_mod, only: g, pi, mugaz, avocado 14 14 use geometry_mod, only: latitude 15 use callkeys_mod, only: kastprof, callmufi 15 use callkeys_mod, only: kastprof, callmufi, callmuclouds 16 16 use mp2m_diagnostics 17 17 implicit none … … 32 32 ! Input 33 33 ! ----- 34 ! ngrid Number of horizontal gridpoints35 ! nlayer Number of layers36 ! nq Number of tracers37 ! pplev Pressure (Pa) at each layer boundary38 ! pq Aerosol mixing ratio39 ! reffrad(ngrid,nlayer,naerkind) Aerosol effective radius40 ! QREFvis3d(ngrid,nlayer,naerkind) \ 3 dextinction coefficients34 ! ngrid Number of horizontal gridpoints 35 ! nlayer Number of layers 36 ! nq Number of tracers 37 ! pplev Pressure (Pa) at each layer boundary 38 ! pq Aerosol mixing ratio 39 ! reffrad(ngrid,nlayer,naerkind) Aerosol effective radius 40 ! QREFvis3d(ngrid,nlayer,naerkind) \ 3D extinction coefficients 41 41 ! QREFir3d(ngrid,nlayer,naerkind) / at reference wavelengths 42 42 ! … … 48 48 !======================================================================= 49 49 50 INTEGER,INTENT(IN) :: ngrid ! number of atmospheric columns51 INTEGER,INTENT(IN) :: nlayer ! number of atmospheric layers52 INTEGER,INTENT(IN) :: nq ! number of tracers53 REAL,INTENT(IN) :: pplay(ngrid,nlayer) ! mid-layer pressure (Pa)54 REAL,INTENT(IN) :: pplev(ngrid,nlayer+1) ! inter-layer pressure (Pa)55 REAL,INTENT(IN) :: zzlev(ngrid,nlayer)! Altitude at the layer boundaries.56 REAL,INTENT(IN) :: pq(ngrid,nlayer,nq) ! tracers (.../kg_of_air)57 REAL,INTENT(IN) :: pt(ngrid,nlayer) ! mid-layer temperature (K)58 REAL,INTENT(OUT) :: dtau_aer(ngrid,nlayer,naerkind) ! aerosol optical depth59 REAL,INTENT(IN) :: reffrad(ngrid,nlayer,naerkind) ! aerosol effective radius60 REAL,INTENT(IN) :: nueffrad(ngrid,nlayer,naerkind) ! aerosol effective variance61 REAL,INTENT(IN) :: QREFvis3d(ngrid,nlayer,naerkind) ! extinction coefficient in the visible62 REAL,INTENT(IN) :: QREFir3d(ngrid,nlayer,naerkind)63 REAL,INTENT(OUT) :: tau_col(ngrid) !column integrated visible optical depth50 INTEGER,INTENT(IN) :: ngrid ! Number of atmospheric columns 51 INTEGER,INTENT(IN) :: nlayer ! Number of atmospheric layers 52 INTEGER,INTENT(IN) :: nq ! Number of tracers 53 REAL,INTENT(IN) :: pplay(ngrid,nlayer) ! Mid-layer pressure (Pa) 54 REAL,INTENT(IN) :: pplev(ngrid,nlayer+1) ! Inter-layer pressure (Pa) 55 REAL,INTENT(IN) :: zzlev(ngrid,nlayer) ! Altitude at the layer boundaries. 56 REAL,INTENT(IN) :: pq(ngrid,nlayer,nq) ! Tracers (.../kg_of_air) 57 REAL,INTENT(IN) :: pt(ngrid,nlayer) ! Mid-layer temperature (K) 58 REAL,INTENT(OUT) :: dtau_aer(ngrid,nlayer,naerkind) ! Aerosol optical depth 59 REAL,INTENT(IN) :: reffrad(ngrid,nlayer,naerkind) ! Aerosol effective radius 60 REAL,INTENT(IN) :: nueffrad(ngrid,nlayer,naerkind) ! Aerosol effective variance 61 REAL,INTENT(IN) :: QREFvis3d(ngrid,nlayer,naerkind) ! Extinction coefficient in the visible 62 REAL,INTENT(IN) :: QREFir3d(ngrid,nlayer,naerkind) ! Extinction coefficient in the infrared 63 REAL,INTENT(OUT) :: tau_col(ngrid) ! Column integrated visible optical depth 64 64 65 65 real aerosol0, obs_tau_col_aurora, pm … … 74 74 real m0as(ngrid,nlayer) 75 75 real m0af(ngrid,nlayer) 76 real m0ccn(ngrid,nlayer) 76 77 77 78 INTEGER l,ig,iq,iaer,ia … … 135 136 endwhere 136 137 137 ! write(*,*) 'dtau_as :', MINVAL(dtau_aer(:,:,1)), '-', MAXVAL(dtau_aer(:,:,1)) 138 ! write(*,*) 'dtau_af :', MINVAL(dtau_aer(:,:,2)), '-', MAXVAL(dtau_aer(:,:,2)) 138 ! Cloud drops 139 if (callmuclouds) then 140 m0ccn(:,:) = pq(:,:,micro_indx(5)) * (pplev(:,1:nlayer) - pplev(:,2:nlayer+1)) / g 141 sig = 0.2 142 where ((m0ccn(:,:) >= 1e-8).and.(mp2m_rc_cld(:,:) >= 5e-9)) 143 dtau_aer(:,:,3) = m0ccn(:,:) * QREFvis3d(:,:,3) * pi * mp2m_rc_cld(:,:)**2 * exp(2*sig**2) 144 elsewhere 145 dtau_aer(:,:,3) = 0d0 146 endwhere 147 endif ! end callmuclouds 139 148 140 149 else -
trunk/LMDZ.PLUTO/libf/phypluto/callcorrk.F90
r3955 r3959 37 37 methane,carbox,cooling,nlte,strobel,& 38 38 ch4fix,vmrch4_proffix,vmrch4fix,& 39 callmufi, triton39 callmufi,callmuclouds,triton 40 40 use optcv_mod, only: optcv 41 41 use optci_mod, only: optci … … 492 492 endwhere 493 493 nueffrad(:,:,2) = exp(sig**2) - 1 494 ! Cloud drops 495 if (callmuclouds) then 496 sig = 0.2 497 where (mp2m_rc_cld(:,:) >= 5e-9) 498 reffrad(:,:,3) = mp2m_rc_cld(:,:) * exp(5.*sig**2 / 2.) 499 elsewhere 500 reffrad(:,:,3) = 0d0 501 endwhere 502 nueffrad(:,:,3) = exp(sig**2) - 1 503 endif ! end callmuclouds 494 504 495 505 else … … 593 603 !----------------------------------------------------------------------- 594 604 595 596 ! AF24: for now only consider one aerosol (=haze)597 605 if (optichaze) then 598 606 do iaer=1,naerkind … … 676 684 end do ! naerkind 677 685 678 ! Test / Correct for freaky s . s.albedo values.686 ! Test / Correct for freaky single scattering albedo values. 679 687 do iaer=1,naerkind 680 688 do k=1,L_LEVELS -
trunk/LMDZ.PLUTO/libf/phypluto/callkeys_mod.F90
r3949 r3959 217 217 !! Variables for aerosol absorption 218 218 real,save :: Fabs_aers_VI, Fabs_aerf_VI, Fabs_aers_IR, Fabs_aerf_IR 219 !$OMP THREADPRIVATE(Fabs_aers_VI, Fabs_aerf_VI, Fabs_aers_IR, Fabs_aerf_IR) 219 !$OMP THREADPRIVATE(Fabs_aers_VI,Fabs_aerf_VI,Fabs_aers_IR,Fabs_aerf_IR) 220 !! Variables for cloud drop absorption 221 real,save :: Fabs_cldd_VI, Fabs_cldd_IR 222 !$OMP THREADPRIVATE(Fabs_cldd_VI,Fabs_cldd_IR) 220 223 221 224 integer,save :: iddist -
trunk/LMDZ.PLUTO/libf/phypluto/datafile_mod.F90
r3949 r3959 22 22 character(len=300),save :: aersprop_file 23 23 character(len=300),save :: aerfprop_file 24 character(len=300),save :: clddprop_file 24 25 25 26 ! surfdir stores planetary topography, albedo, etc. (surface.nc files) -
trunk/LMDZ.PLUTO/libf/phypluto/inifis_mod.F90
r3951 r3959 14 14 use radii_mod, only: radfixed 15 15 use datafile_mod, only: datadir,hazeprop_file,hazerad_file,hazemmr_file,hazedens_file, & 16 config_mufi, mugasflux_file, aersprop_file, aerfprop_file 16 config_mufi, mugasflux_file, aersprop_file, aerfprop_file, clddprop_file 17 17 use comdiurn_h, only: sinlat, coslat, sinlon, coslon 18 18 use comgeomfi_h, only: totarea, totarea_planet … … 801 801 if (is_master) write(*,*) trim(rname)//" aerfprop_file = ",trim(aerfprop_file) 802 802 803 if (is_master) write(*,*) "Cloud drop optical properties datafile" 804 clddprop_file="optprop_rannou_r2-200nm_nu003.dat" ! default file 805 call getin_p("clddprop_file",clddprop_file) 806 if (is_master) write(*,*) trim(rname)//" clddprop_file = ",trim(clddprop_file) 807 803 808 if (is_master) write(*,*) "Use haze production from CH4 photolysis or production rate?" 804 809 call_haze_prod_pCH4=.false. ! default value … … 879 884 call getin_p("Fabs_aerf_IR",Fabs_aerf_IR) 880 885 if (is_master) write(*,*)" Fabs_aerf_IR = ",Fabs_aerf_IR 886 887 if (is_master) write(*,*) "Cloud drop absorption correction in VI?" 888 Fabs_cldd_VI=1. ! default value 889 call getin_p("Fabs_cldd_VI",Fabs_cldd_VI) 890 if (is_master) write(*,*)" Fabs_cldd_VI = ",Fabs_cldd_VI 891 892 if (is_master) write(*,*) "Cloud drop absorption correction in IR?" 893 Fabs_cldd_IR=1. ! default value 894 call getin_p("Fabs_cldd_IR",Fabs_cldd_IR) 895 if (is_master) write(*,*)" Fabs_cldd_IR = ",Fabs_cldd_IR 881 896 882 897 ! Pluto haze model … … 1454 1469 call abort_physic(rname, 'if microphysics is on, naerkind must be > 1!', 1) 1455 1470 endif 1456 ! if ((callmufi).and.(callmuclouds).and..not.(naerkind.gt.2)) then 1457 ! call abort_physic(rname, 'if microphysical clouds are on, naerkind must be > 2!', 1) 1458 ! endif 1471 if ((callmufi).and..not.(callmuclouds).and.(naerkind.gt.2)) then 1472 call abort_physic(rname, 'Warning: here microphysical clouds are on, naerkind must be = 2!', 1) 1473 endif 1474 if ((callmufi).and.(callmuclouds).and..not.(naerkind.gt.2)) then 1475 call abort_physic(rname, 'if microphysical clouds are on, naerkind must be > 2!', 1) 1476 endif 1459 1477 if (.not.(callmufi.or.haze).and.(optichaze)) then 1460 1478 call abort_physic(rname, 'if microphysics and haze are off, optichaze must be deactivated!', 1) -
trunk/LMDZ.PLUTO/libf/phypluto/optci.F90
r3889 r3959 15 15 igas_CH4, igas_N2 16 16 use comcstfi_mod, only: g, r, mugaz 17 use callkeys_mod, only: kastprof,continuum,graybody,callmufi,Fabs_aers_IR,Fabs_aerf_IR 17 use callkeys_mod, only: kastprof,continuum,graybody,callmufi,callmuclouds, & 18 Fabs_aers_IR,Fabs_aerf_IR,Fabs_cldd_IR 18 19 use recombin_corrk_mod, only: corrk_recombin, gasi_recomb 19 20 use tpindex_mod, only: tpindex … … 143 144 lkcoef(:,:) = 0.0 144 145 145 if (callmufi) then146 if (callmufi) then 146 147 Fabs_aer(1) = Fabs_aers_IR 147 148 Fabs_aer(2) = Fabs_aerf_IR 149 if (callmuclouds) then 150 Fabs_aer(3) = Fabs_cldd_IR 151 endif 148 152 else 149 153 Fabs_aer(:) = 1.0 150 endif 154 endif ! end callmufi 151 155 152 156 do K=2,L_LEVELS … … 186 190 do K=2,L_LEVELS 187 191 TAEROS(K,NW,IAER) = TAUAERO(K,IAER) * QXIAER(K,NW,IAER) 188 ! Aerosol absorption correction --> impact on opacity.192 ! Aerosol/Cloud absorption correction --> impact on opacity. 189 193 if (callmufi .and. (TAEROS(K,NW,IAER).gt.0.d0)) then 190 194 TAEROS(K,NW,IAER) = TAEROS(K,NW,IAER) * & … … 343 347 ! Aerosol absorption correction --> impact on single scattering albedo. 344 348 if (callmufi) then 349 ! Spherical aerosols 345 350 if ((TAEROS(K,NW,1).gt.0.d0) .and. TAEROS(K+1,NW,1).gt.0.d0) then 346 351 btemp(L,NW) = TAUAEROLK(K,NW,1) / & … … 353 358 btemp(L,NW) = TAUAEROLK(K,NW,1) + TAUAEROLK(K+1,NW,1) 354 359 endif 360 ! Fractal aerosols 355 361 if ((TAEROS(K,NW,2).gt.0.d0) .and. TAEROS(K+1,NW,2).gt.0.d0) then 356 362 btemp(L,NW) = btemp(L,NW) + & … … 364 370 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,2) + TAUAEROLK(K+1,NW,2) 365 371 endif 372 ! Cloud absorption correction --> impact on single scattering albedo. 373 if (callmuclouds) then 374 if ((TAEROS(K,NW,3).gt.0.d0) .and. TAEROS(K+1,NW,3).gt.0.d0) then 375 btemp(L,NW) = btemp(L,NW) + & 376 (TAUAEROLK(K,NW,3) / & 377 (QSIAER(K,NW,3)/QXIAER(K,NW,3) + & 378 Fabs_aer(3)*(1.-QSIAER(K,NW,3)/QXIAER(K,NW,3)))) + & 379 (TAUAEROLK(K+1,NW,3) / & 380 (QSIAER(K+1,NW,3)/QXIAER(K+1,NW,3) + & 381 Fabs_aer(3)*(1.-QSIAER(K+1,NW,3)/QXIAER(K+1,NW,3)))) 382 else 383 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,3) + TAUAEROLK(K+1,NW,3) 384 endif 385 endif ! end callmuclouds 366 386 else 367 387 btemp(L,NW) = SUM(TAUAEROLK(K,NW,1:naerkind)) + SUM(TAUAEROLK(K+1,NW,1:naerkind)) … … 375 395 ! Aerosol absorption correction --> impact on single scattering albedo. 376 396 if (callmufi) then 397 ! Spherical aerosols 377 398 if (TAEROS(K,NW,1).gt.0.d0) then 378 399 btemp(L,NW) = TAUAEROLK(K,NW,1) / & … … 382 403 btemp(L,NW) = TAUAEROLK(K,NW,1) 383 404 endif 405 ! Fractal aerosols 384 406 if (TAEROS(K,NW,2).gt.0.d0) then 385 407 btemp(L,NW) = btemp(L,NW) + & … … 390 412 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,2) 391 413 endif 414 ! Cloud absorption correction --> impact on single scattering albedo. 415 if (callmuclouds) then 416 if (TAEROS(K,NW,3).gt.0.d0) then 417 btemp(L,NW) = btemp(L,NW) + & 418 (TAUAEROLK(K,NW,3) / & 419 (QSIAER(K,NW,3)/QXIAER(K,NW,3) + & 420 Fabs_aer(3)*(1.-QSIAER(K,NW,3)/QXIAER(K,NW,3)))) 421 else 422 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,3) 423 endif 424 endif ! end callmuclouds 392 425 else 393 426 btemp(L,NW) = SUM(TAUAEROLK(K,NW,1:naerkind)) -
trunk/LMDZ.PLUTO/libf/phypluto/optcv.F90
r3947 r3959 15 15 igas_CH4, igas_N2 16 16 use comcstfi_mod, only: g, r, mugaz 17 use callkeys_mod, only: kastprof,continuum,graybody,callgasvis,callmufi,Fabs_aers_VI,Fabs_aerf_VI 17 use callkeys_mod, only: kastprof,continuum,graybody,callgasvis,callmufi,callmuclouds, & 18 Fabs_aers_VI,Fabs_aerf_VI,Fabs_cldd_VI 18 19 use recombin_corrk_mod, only: corrk_recombin, gasv_recomb 19 20 use tpindex_mod, only: tpindex … … 146 147 wbarv_aer(:,:,:) = 1.0 147 148 148 if (callmufi) then149 if (callmufi) then 149 150 Fabs_aer(1) = Fabs_aers_VI 150 151 Fabs_aer(2) = Fabs_aerf_VI 152 if (callmuclouds) then 153 Fabs_aer(3) = Fabs_cldd_VI 154 endif 151 155 else 152 156 Fabs_aer(:) = 1.0 … … 185 189 do K=5,L_LEVELS 186 190 TAEROS(K,NW,IAER) = TAUAERO(K,IAER) * QXVAER(K,NW,IAER) 187 ! Aerosol absorption correction --> impact on opacity.191 ! Aerosol/Cloud absorption correction --> impact on opacity. 188 192 if (callmufi .and. (TAEROS(K,NW,IAER).gt.0.d0)) then 189 193 TAEROS(K,NW,IAER) = TAEROS(K,NW,IAER) * & … … 376 380 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,2) + TAUAEROLK(K+1,NW,2) 377 381 endif 382 383 ! Cloud absorption correction --> impact on single scattering albedo. 384 if (callmuclouds) then 385 if ((TAEROS(K,NW,3).gt.0.d0) .and. TAEROS(K+1,NW,3).gt.0.d0) then 386 btemp(L,NW) = btemp(L,NW) + & 387 (TAUAEROLK(K,NW,3) / & 388 (QSVAER(K,NW,3)/QXVAER(K,NW,3) + & 389 Fabs_aer(3)*(1.-QSVAER(K,NW,3)/QXVAER(K,NW,3)))) + & 390 (TAUAEROLK(K+1,NW,3) / & 391 (QSVAER(K+1,NW,3)/QXVAER(K+1,NW,3) + & 392 Fabs_aer(3)*(1.-QSVAER(K+1,NW,3)/QXVAER(K+1,NW,3)))) 393 else 394 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,3) + TAUAEROLK(K+1,NW,3) 395 endif 396 endif ! end callmuclouds 378 397 else 379 398 btemp(L,NW) = SUM(TAUAEROLK(K,NW,1:naerkind)) + SUM(TAUAEROLK(K+1,NW,1:naerkind)) … … 409 428 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,2) 410 429 endif 430 ! Cloud absorption correction --> impact on single scattering albedo. 431 if (callmuclouds) then 432 if (TAEROS(K,NW,3).gt.0.d0) then 433 btemp(L,NW) = btemp(L,NW) + & 434 (TAUAEROLK(K,NW,3) / & 435 (QSVAER(K,NW,3)/QXVAER(K,NW,3) + & 436 Fabs_aer(3)*(1.-QSVAER(K,NW,3)/QXVAER(K,NW,3)))) 437 else 438 btemp(L,NW) = btemp(L,NW) + TAUAEROLK(K,NW,3) 439 endif 440 endif ! end callmuclouds 411 441 else 412 442 btemp(L,NW) = SUM(TAUAEROLK(K,NW,1:naerkind)) … … 421 451 DO NW=1,L_NSPECTV 422 452 DO L=1,L_NLAYRAD-1 423 424 453 K = 2*L+1 425 454 DTAUV(L,nw,ng) = DTAUKV(K,NW,NG) + DTAUKV(K+1,NW,NG) 426 455 WBARV(L,nw,ng) = ctemp(L,NW) / DTAUV(L,nw,ng) 427 428 456 END DO ! L vertical loop 429 457 430 ! Last level 431 432 L = L_NLAYRAD 433 K = 2*L+1 434 DTAUV(L,nw,ng) = DTAUKV(K,NW,NG) 435 436 WBARV(L,NW,NG) = ctemp(L,NW) / DTAUV(L,NW,NG) 437 438 END DO ! NW spectral loop 439 END DO ! NG Gauss loop 458 ! Last level 459 !----------- 460 L = L_NLAYRAD 461 K = 2*L+1 462 463 DTAUV(L,nw,ng) = DTAUKV(K,NW,NG) 464 WBARV(L,NW,NG) = ctemp(L,NW) / DTAUV(L,NW,NG) 465 END DO ! NW spectral loop 466 END DO ! NG Gauss loop 440 467 441 468 ! Aerosols extinction optical depths -
trunk/LMDZ.PLUTO/libf/phypluto/suaer_corrk.F90
r3613 r3959 11 11 use radcommon_h, only: blamv,blami,lamrefir,lamrefvis 12 12 use datafile_mod, only: datadir, aerdir, & 13 hazeprop_file, aersprop_file, aerfprop_file 13 hazeprop_file, aersprop_file, aerfprop_file, clddprop_file 14 14 15 15 ! outputs … … 18 18 use radcommon_h, only: qrefvis,qrefir,omegarefir !,omegarefvis 19 19 use aerosol_mod, only: iaero_haze 20 use callkeys_mod, only: tplanet, callmufi 20 use callkeys_mod, only: tplanet, callmufi, callmuclouds 21 21 use tracer_h, only: noms 22 22 … … 127 127 128 128 !-------------------------------------------------------------- 129 ! allocate file_id, as naerkind is a variable 129 ! allocate file_id, as naerkind is a variable (VIS & IR) 130 130 allocate(file_id(naerkind,2)) 131 132 131 133 132 if (callmufi) then … … 137 136 write(*,*)'Suaer fractal aerosols optical properties, using: ', & 138 137 TRIM(aerfprop_file) 138 if (callmuclouds) then 139 write(*,*)'Suaer cloud drop optical properties, using: ', & 140 TRIM(clddprop_file) 141 endif 139 142 endif 140 143 ! Visible 141 144 file_id(1,1)=TRIM(aersprop_file) 142 145 file_id(2,1)=TRIM(aerfprop_file) 146 if (callmuclouds) then 147 file_id(3,1)=TRIM(clddprop_file) 148 endif 143 149 ! Infrared 144 150 file_id(1,2)=file_id(1,1) 145 151 file_id(2,2)=file_id(2,1) 152 if (callmuclouds) then 153 file_id(3,2)=file_id(3,1) 154 endif 146 155 147 156 do iaer=1,naerkind
Note: See TracChangeset
for help on using the changeset viewer.
