LMDZ
su_aerw.F90
Go to the documentation of this file.
1 SUBROUTINE su_aerw
2 
3 !**** *SU_AERW* - DEFINES INDICES AND PARAMETERS FOR VARIOUS AEROSOL VARIABLES
4 
5 ! PURPOSE.
6 ! --------
7 ! INITIALIZE YOEAERATM, YOEAERSRC, YOEAERSNK, THE MODULES THAT CONTAINS INDICES
8 ! ALLOWING TO GET THE AEROSOL PARAMETERS RELEVANT FOR THE PROGNOSTIC AEROSOL
9 ! CONFIGURATION.
10 
11 !** INTERFACE.
12 ! ----------
13 ! *CALL* *SU_AERW
14 
15 ! EXPLICIT ARGUMENTS :
16 ! --------------------
17 ! NONE
18 
19 ! IMPLICIT ARGUMENTS :
20 ! --------------------
21 ! YOEAERW
22 
23 ! METHOD.
24 ! -------
25 ! SEE DOCUMENTATION
26 
27 ! EXTERNALS.
28 ! ----------
29 
30 ! REFERENCE.
31 ! ----------
32 ! ECMWF RESEARCH DEPARTMENT DOCUMENTATION OF THE IFS
33 
34 ! AUTHOR.
35 ! -------
36 ! JEAN-JACQUES MORCRETTE *ECMWF*
37 
38 ! MODIFICATIONS.
39 ! --------------
40 ! ORIGINAL : 2005-07-08
41 
42 ! ------------------------------------------------------------------
43 
44 USE parkind1 ,ONLY : jpim ,jprb
45 USE yomhook ,ONLY : lhook, dr_hook
46 
49  & repscaer , indbg
50 
51 USE yoeaersrc, ONLY : jkbin, jktyp, lepaero , &
55 
56 USE yoephy , ONLY : le4alb
57 
58 USE yoedbug , ONLY : kstpdbg
59 
60 USE yomcst , ONLY : rpi
61 USE yomgc , ONLY : gelam
62 USE yomgem , ONLY : ngptot
63 USE yomleg , ONLY : rmu
64 ! Ce qui concerne NULNAM commente par MPL le 15.04.09
65 !USE YOMLUN , ONLY : NULNAM, NULOUT
66 USE yomlun , ONLY : nulout
67 
68 USE yom_ygfl, ONLY : naero
69 
70 IMPLICIT NONE
71 
72 INTEGER(KIND=JPIM) :: IAER, ICAER, ITAER
73 INTEGER(KIND=JPIM) :: J, JAER, JL
74 
75 REAL(KIND=JPRB) :: ZHOOK_HANDLE
76 ! ----------------------------------------------------------------
77 
78 #include "posnam.intfb.h"
79 
80 #include "su_aerp.intfb.h"
81 #include "su_aerop.intfb.h"
82 ! ----------------------------------------------------------------
83 
84 #include "naeaer.h"
85 
86 ! ----------------------------------------------------------------
87 IF (lhook) CALL dr_hook('SU_AERW',0,zhook_handle)
88 
89 !* 1. DEFAULT VALUES OF PARAMETERS
90 ! ----------------------------
91 
92 print *,'DANS SU_AERW'
93 nbinaer(:) = (/ 3, 3, 2, 2, 1, 1, 1, 1, 1 /)
94 
95 nmaxtaer=9
96 ntypaer(:) = 0
97 jkbin(:) = 0
98 jktyp(:) = 0
99 
100 lepaero=.false.
105 laerextr=.false.
106 laergbud=.false.
107 laerngat=.false.
108 laerprnt=.false.
109 laerscav=.false.
111 laersurf=.false.
113 indbg=1
114 ntaer =0
115 nddust =2
116 
117 ! the 9 types and assumed number of bins are:
118 ! NTYPAER bins type
119 ! 1 1- 3 sea-salt 0.03 - 0.5 - 5 - 20 microns
120 ! 2 4- 6 dust 0.03 - 0.5 - 0.9 - 20 microns
121 ! 3 7- 8 POM hydrophilic, hydrophobic
122 ! 4 9-10 BC hydrophilic, hydrophobic
123 ! 5 11 sulfate
124 ! 6 12 fly ash
125 ! 7 13 pseudo-prognostic stratospheric aerosols
126 ! 8 14 pseudo-prognostic volcanic aerosols
127 ! 9 15 prognostic stratospheric aerosols
128 
129 DO jaer=1,nmaxtaer
130  ntypaer(jaer)=0
131 ENDDO
132 
133 rlatvol=-999._jprb
134 rlonvol=-999._jprb
135 rgelav =-999._jprb
136 rgemuv =-999._jprb
137 rdglav = 999._jprb
138 rdgmuv = 999._jprb
139 rclonv =-999._jprb
140 rslonv =-999._jprb
141 rdclonv= 999._jprb
142 rdslonv= 999._jprb
143 DO j=1,3
144  kstpdbg(j)=-999
145 ENDDO
146 
147 repscaer=1.e-15_jprb
148 
149 ! ------------------------------------------------------------------
150 
151 !* 2. READ VALUES OF PROGNOSTIC AEROSOL CONFIGURATION
152 ! -----------------------------------------------
153 ! Ce qui concerne NAEAER commente par MPL le 15.04.09
154 !IF(NAERO > 0) THEN
155 ! CALL POSNAM(NULNAM,'NAEAER')
156 ! READ (NULNAM,NAEAER)
157 !ENDIF
158 
159 IF (.NOT.le4alb) THEN
160  nddust=2
161 ENDIF
162 ! ------------------------------------------------------------------
163 
164 !* 3. INITIALIZE PROGNOSTIC AEROSOL PHYSICAL AND OPTICAL PARAMETERS
165 ! -------------------------------------------------------------
166 
167  CALL su_aerp
168 print *,'SU_AERW: apres SU_AERP'
169  CALL su_aerop
170 print *,'SU_AERW: apres SU_AEROP'
171 
172 IF (lepaero) THEN
173 
174 ! define a composite index for each bin of each different aerosol type to be used
175 ! in source, sedimentation and deposition routines
176 
177  icaer=0
178  DO jaer=1,nmaxtaer
179  IF (ntypaer(jaer) /= 0) THEN
180  ntaer=ntaer+1
181  itaer=ntypaer(jaer)
182  DO iaer=1,itaer
183  icaer=icaer+1
184  nindaer(icaer)=jaer*10+iaer
185  jktyp(icaer)=jaer
186  jkbin(icaer)=iaer
187  ENDDO
188  ENDIF
189  ENDDO
190 
191 !-- if volcanic aerosols, define the model coordinates
192 
193  IF (ntypaer(9) /= 0) THEN
194  rgemuv=(rlatvol+90._jprb)*rpi/180._jprb
195  rgelav=rlonvol*rpi/180._jprb
196  rclonv=cos(rgelav)
197  rslonv=sin(rgelav)
198  DO j=1,ngptot-1
199  IF (rgelav > gelam(j) .AND. rgelav <= gelam(j+1) .AND. &
200  & rgemuv < rmu(jl) .AND. rgemuv >= rmu(jl+1) ) THEN
201  rdgmuv=abs( rmu(j+1) - rmu(j))
202  rdglav=abs( gelam(j+1)-gelam(j) )
203  rdslonv=abs( sin(gelam(jl+1))-sin(gelam(jl)) )
204  rdclonv=abs( cos(gelam(jl+1))-cos(gelam(jl)) )
205  ENDIF
206  ENDDO
207  ENDIF
208 
209 ! ----------------------------------------------------------------
210 
211 !* 4. PRINT FINAL VALUES.
212 ! -------------------
213 
214  WRITE(unit=nulout,fmt='('' LEPAERO = '',L5 &
215  & ,'' NTAER = '',I2 ,'' NDDUST = '',I1,/&
216  & ,'' NTYPAER = '',9I3,/ &
217  & ,'' NBINAER = '',9I3,/ &
218  & ,'' JKTYP = '',15I3,/&
219  & ,'' JKBIN = '',15I3 &
220  & )')&
221  & lepaero,ntaer,(ntypaer(jaer),jaer=1,9),(nbinaer(jaer),jaer=1,9), &
222  & (jktyp(jaer),jaer=1,15),(jkbin(jaer),jaer=1,15)
223  WRITE(unit=nulout,fmt='('' LAERGBUD = '',L3 &
224  & ,'' LAERNGAT = '',L3 &
225  & ,'' LAERDRYDP= '',L3 &
226  & ,'' LAERSEDIM= '',L3 &
227  & ,'' LAERSCAV = '',L3 &
228  & ,'' LAER6SDIA= '',L3 &
229  & ,'' LAERCLIMZ= '',L3 &
230  & ,'' LAERCLIMG= '',L3 &
231  & ,'' LAERCLIST= '',L3 &
232  & )')&
234  WRITE(unit=nulout,fmt='('' RSSFLX= '',10E10.3)') rssflx
235  IF (ntypaer(9) /= 0) THEN
236  WRITE(unit=nulout,fmt='('' RLATVOL= '',F5.2 &
237  & ,'' RLONVOL= '',F6.2,'' RGEMUV= '',F6.4,'' RGELAV= '',F6.4 &
238  & ,'' RCLONV = '',F6.4,'' RSLONV= '',F6.4,'' RDGMUV= '',F6.4 &
239  & ,'' RDGLAV = '',F6.4,'' RDCLONV= '',F6.4,'' RDSLONV= '',F6.4 &
240  & )')&
242  ENDIF
243 ENDIF
244 
245 ! ----------------------------------------------------------------
246 IF (lhook) CALL dr_hook('SU_AERW',1,zhook_handle)
247 END SUBROUTINE su_aerw
248 
249 
250 
251 
252 
253 
254 
255 
256 
257 
258 
259 
260 
261 
262 
263 
264 
265 
266 
267 
268 
269 
270 
271 
272 
273 
274 
275 
276 
277 
278 
279 
280 
281 
282 
283 
Definition: yoephy.F90:1
Definition: yomleg.F90:1
real(kind=jprb) rpi
Definition: yomcst.F90:15
logical le4alb
Definition: yoephy.F90:40
logical laersedim
Definition: yoeaeratm.F90:22
integer(kind=jpim), dimension(9) ntypaer
Definition: yoeaersrc.F90:16
logical laer6sdia
Definition: yoeaeratm.F90:22
logical laerclimz
Definition: yoeaeratm.F90:21
integer(kind=jpim) naero
Definition: yom_ygfl.F90:38
real(kind=jprb) rdclonv
Definition: yoeaersrc.F90:22
real(kind=jprb) rgelav
Definition: yoeaersrc.F90:21
real(kind=jprb) repscaer
Definition: yoeaeratm.F90:19
real(kind=jprb) rclonv
Definition: yoeaersrc.F90:22
logical lepaero
Definition: yoeaersrc.F90:19
real(kind=jprb) rdslonv
Definition: yoeaersrc.F90:22
real(kind=jprb), dimension(3) rssflx
Definition: yoeaersrc.F90:25
real(kind=jprb) rslonv
Definition: yoeaersrc.F90:22
integer(kind=jpim) nmaxtaer
Definition: yoeaersrc.F90:12
real(kind=jprb), dimension(:), allocatable gelam
Definition: yomgc.F90:42
Definition: yomgc.F90:1
Definition: yomgem.F90:1
integer(kind=jpim) ngptot
Definition: yomgem.F90:19
!$Id itapm1 ENDIF!IM on interpole les champs sur les niveaux STD de pression!IM a chaque pas de temps de la physique c!positionnement de l argument logique a false c!pour ne pas recalculer deux fois la meme chose!c!a cet effet un appel a plevel_new a ete deplace c!a la fin de la serie d appels c!la boucle DO nlevSTD a ete internalisee c!dans d ou la creation de cette routine c c!CALL false
Definition: calcul_STDlev.h:26
integer(kind=jpim), dimension(9) nbinaer
Definition: yoeaersrc.F90:14
integer(kind=jpim), dimension(15) nindaer
Definition: yoeaersrc.F90:15
real(kind=jprb) rgemuv
Definition: yoeaersrc.F90:21
integer, parameter jprb
Definition: parkind1.F90:31
logical laerclimg
Definition: yoeaeratm.F90:21
subroutine su_aerp
Definition: su_aerp.F90:2
real(kind=jprb) rlonvol
Definition: yoeaersrc.F90:23
logical laergbud
Definition: yoeaeratm.F90:21
logical laerclist
Definition: yoeaeratm.F90:21
integer(kind=jpim) indbg
Definition: yoeaeratm.F90:13
Definition: yomlun.F90:1
integer(kind=jpim) ntaer
Definition: yoeaersrc.F90:13
logical lhook
Definition: yomhook.F90:12
subroutine su_aerw
Definition: su_aerw.F90:2
logical laerngat
Definition: yoeaeratm.F90:22
real(kind=jprb), dimension(:), allocatable rmu
Definition: yomleg.F90:27
real(kind=jprb) rdglav
Definition: yoeaersrc.F90:21
real(kind=jprb) rdgmuv
Definition: yoeaersrc.F90:21
logical laerprnt
Definition: yoeaeratm.F90:22
subroutine dr_hook(CDNAME, KSWITCH, PKEY)
Definition: yomhook.F90:17
integer(kind=jpim), dimension(3) kstpdbg
Definition: yoedbug.F90:12
integer(kind=jpim), dimension(15) jkbin
Definition: yoeaersrc.F90:15
integer(kind=jpim) nddust
Definition: yoeaersrc.F90:17
integer, parameter jpim
Definition: parkind1.F90:13
integer(kind=jpim), dimension(15) jktyp
Definition: yoeaersrc.F90:15
logical laerextr
Definition: yoeaersrc.F90:19
subroutine su_aerop
Definition: su_aerop.F90:2
logical laerdrydp
Definition: yoeaeratm.F90:21
Definition: yomcst.F90:1
logical laersurf
Definition: yoeaeratm.F90:22
!$Header!integer nvarmx s s unit
Definition: gradsdef.h:20
real(kind=jprb) rlatvol
Definition: yoeaersrc.F90:23
logical laerscav
Definition: yoeaeratm.F90:22