source: LMDZ6/branches/Amaury_dev/libf/phylmd/rrtm/aeropt_lw_rrtm.F90 @ 5218

Last change on this file since 5218 was 5159, checked in by abarral, 5 months ago

Put dimensions.h and paramet.h into modules

File size: 2.3 KB
Line 
1
2! aeropt_lw_rrtm.F90 2014-05-13 C. Kleinschmitt
3!                    2016-05-03 O. Boucher
4!                    2016-12-17 O. Boucher
5
6! This routine feeds aerosol LW properties to RRTM
7! we only consider absorption (not scattering)
8! we only consider dust for now
9
10SUBROUTINE AEROPT_LW_RRTM(ok_alw, pdel, zrho, flag_aerosol, m_allaer, m_allaer_pi)
11
12  USE dimphy
13  USE aero_mod
14  USE phys_state_var_mod, ONLY: tau_aero_lw_rrtm
15  USE YOERAD, ONLY: NLW
16  USE YOMCST, ONLY: RG
17  USE lmdz_abort_physic, ONLY: abort_physic
18  USE lmdz_clesphys
19
20  IMPLICIT NONE
21
22
23  ! Input arguments:
24
25  LOGICAL, INTENT(IN)                              :: ok_alw
26  INTEGER, INTENT(IN)                              :: flag_aerosol
27  REAL, DIMENSION(klon,klev), INTENT(IN)           :: pdel, zrho
28  REAL, DIMENSION(klon,klev,naero_tot), INTENT(IN) :: m_allaer, m_allaer_pi
29
30  INTEGER inu, i, k
31  REAL :: zdh(klon,klev)
32  REAL :: tmp_var, tmp_var_pi
33  CHARACTER*20 modname
34
35  !--absorption coefficient for CIDUST
36  REAL:: alpha_abs_CIDUST_16bands(nbands_lw_rrtm)   !--unit m2/g
37  DATA alpha_abs_CIDUST_16bands /                         &
38  0.001, 0.003, 0.005, 0.006, 0.012, 0.030, 0.148, 0.098, &
39  0.017, 0.053, 0.031, 0.008, 0.010, 0.011, 0.013, 0.015  /
40
41  modname='aeropt_lw_rrtm'
42
43  IF (NLW.NE.nbands_lw_rrtm) THEN
44    CALL abort_physic(modname,'Erreur NLW doit etre egal a 16 pour cette routine',1)
45  ENDIF
46  !
47  IF (ok_alw) THEN                                   !--aerosol LW effects
48
49   IF (flag_aerosol.EQ.5.OR.flag_aerosol.EQ.6.OR.flag_aerosol.EQ.7) THEN  !-Dust
50
51    zdh(:,:)=pdel(:,:)/(RG*zrho(:,:))      ! m
52
53    DO k=1, klev
54      DO i=1, klon
55
56         tmp_var   =m_allaer(i,k,id_CIDUSTM_phy)   /1.e6*zdh(i,k)  !--g/m2
57         tmp_var_pi=m_allaer_pi(i,k,id_CIDUSTM_phy)/1.e6*zdh(i,k)  !--g/m2
58
59         DO inu=1, NLW
60
61           !--total aerosol
62           tau_aero_lw_rrtm(i,k,2,inu) = MAX(1.e-15,tmp_var*alpha_abs_CIDUST_16bands(inu))
63           !--natural aerosol
64!           tau_aero_lw_rrtm(:,:,1,inu) = MAX(1.e-15,tmp_var_pi*alpha_abs_CIDUST_16bands(inu))
65           tau_aero_lw_rrtm(i,k,1,inu) = 1.e-15  !--test
66
67         ENDDO
68      ENDDO
69
70    ENDDO
71    !
72   ENDIF
73
74  ELSE !--no aerosol LW effects
75
76    tau_aero_lw_rrtm = 1.e-15
77  ENDIF
78
79END SUBROUTINE AEROPT_LW_RRTM
Note: See TracBrowser for help on using the repository browser.