m7.F90 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314
  1. #include "tm5.inc"
  2. #ifdef with_budgets
  3. SUBROUTINE m7(kproma, kbdim, klev, & ! TM5 indices
  4. papp1, prelhum, ptp1, & ! " thermodynamics
  5. pso4g, paerml, paernl, & ! M7 tracers
  6. prhop, pww, pm6rp, pm6dry, & ! " aerosol properties
  7. ptime, & ! TM5 time step
  8. pprocess ) ! TM5 budget processes
  9. #else
  10. SUBROUTINE m7(kproma, kbdim, klev, & ! TM5 indices
  11. papp1, prelhum, ptp1, & ! " thermodynamics
  12. pso4g, paerml, paernl, & ! M7 tracers
  13. prhop, pww, pm6rp, pm6dry, & ! " aerosol properties
  14. ptime ) ! TM5 time step
  15. #endif
  16. !
  17. ! ****m7* Aerosol model for the system so4,bc,oc,ss,dust in 7 modes.
  18. !
  19. ! Authors:
  20. ! ---------
  21. ! E. Vignati, JRC/EI (original source) 2000
  22. ! P. Stier, MPI (f90-version, changes, comments) 2001
  23. ! E. Vignati, JRC/IES (so2 is not required in this version) 2005
  24. !
  25. ! Purpose
  26. ! ---------
  27. ! Aerosol model for the system so4,bc,oc,ss,dust in 7 modes.
  28. !
  29. ! Externals
  30. ! ---------
  31. !
  32. ! *m7_averageproperties*
  33. ! calculates the average mass for all modes and the particle
  34. ! dry radius and density for the insoluble modes.
  35. !
  36. ! *m7_equiz*
  37. ! calculates the ambient radius of sulphate particles
  38. !
  39. ! *m7_equimix*
  40. ! calculates the ambient radius of so4,bc,oc (dust) particles
  41. !
  42. ! *m7_equil*
  43. ! calculates the ambient radius of so4,ss particles
  44. !
  45. ! *m7_dgas*
  46. ! calculates the sulfate condensation on existing particles
  47. !
  48. ! *m7_dnum*
  49. ! calculates new gas phase sulfate and aerosol numbers and masses
  50. ! after condensation, nucleation and coagulation over one timestep
  51. !
  52. ! *m7_dconc*
  53. ! repartitions aerosol number and mass between the
  54. ! the modes to account for condensational growth and the formation
  55. ! of an accumulation mode from the upper tail of the aitken mode and
  56. ! of a coarse mode from the upper tail of the accumulation mode
  57. !
  58. USE mo_aero_m7, ONLY: lsnucl, lscoag, lscond, &
  59. nmod, nss, nsol, naermod
  60. use tracer_data, only : tracer_print
  61. use GO, only : gol, goErr, goPr, goBug
  62. #ifdef with_budgets
  63. Use M7_Data, Only: nm7procs
  64. #endif
  65. IMPLICIT NONE
  66. !--- Parameter list:
  67. !
  68. ! papp1 = atmospheric pressure at time t+1 [Pa]
  69. ! prelhum = atmospheric relative humidity [% (0-1)]
  70. ! ptp1 = atmospheric temperature at time t+1 [K]
  71. ! pso4g = mass of gas phase sulfate [molec. cm-3]
  72. ! paerml = total aerosol mass for each compound
  73. ! [molec. cm-3 for sulphate and ug m-3 for bc, oc, ss, and dust]
  74. ! paernl = aerosol number for each mode [cm-3]
  75. ! prhop = mean mode particle density [g cm-3]
  76. ! pm6rp = mean mode actual radius (wet radius for soluble modes
  77. ! and dry radius for insoluble modes) [cm]
  78. ! pm6dry = dry radius for soluble modes [cm]
  79. ! pww = aerosol water content for each mode [kg(water) m-3(air)]
  80. !
  81. !--- Local variables:
  82. !
  83. ! zttn = average mass for single compound in each mode
  84. ! [in molec. for sulphate and in ug for bc, oc, ss, and dust]
  85. ! zhplus = number of h+ in mole [???] (kg water)-1
  86. ! zso4_x = mass of sulphate condensed on insoluble mode x [molec. cm-3]
  87. ! (calculated in dgas used in concoag)
  88. ! Parameters:
  89. INTEGER :: kproma, kbdim, klev
  90. REAL :: ptime
  91. REAL :: prelhum(kbdim,klev), papp1(kbdim,klev), &
  92. ptp1(kbdim,klev), &
  93. pso4g(kbdim,klev)
  94. REAL :: paerml(kbdim,klev,naermod), paernl(kbdim,klev,nmod), &
  95. pm6rp(kbdim,klev,nmod), pm6dry(kbdim,klev,nsol), &
  96. prhop(kbdim,klev,nmod), pww(kbdim,klev,nmod)
  97. #ifdef with_budgets
  98. Real :: pprocess(kbdim,klev,nm7procs)
  99. #endif
  100. ! Local variables:
  101. !--- m7_box:
  102. INTEGER :: i
  103. LOGICAL :: lofirst=.TRUE.
  104. !--- END m7_box
  105. REAL :: zso4_5(kbdim,klev), zso4_6(kbdim,klev), &
  106. zso4_7(kbdim,klev)
  107. REAL :: zhplus(kbdim,klev,nss)
  108. REAL :: zttn(kbdim,klev,naermod)
  109. !
  110. !--- 0) Initialisations: -------------------------------------------------
  111. !
  112. zhplus(:,:,:) = 0.
  113. pm6dry(:,:,:) = 0.
  114. pm6rp(:,:,:) = 0.
  115. zttn(:,:,:) = 0.
  116. prhop(:,:,:) = 0.
  117. pww(:,:,:) = 0.
  118. zso4_5(:,:) = 0.
  119. zso4_6(:,:) = 0.
  120. zso4_7(:,:) = 0.
  121. #ifdef with_budgets
  122. pprocess(:,:,:) = 0.0
  123. #endif
  124. ! write(*,*) 'in2', 'h2so4= ', pso4g(2100,1), 'num1= ', paernl(2100,1,1)
  125. ! write(*,*) 'in2', 'BCsol= ', paerml(2100,1,5),'BCins= ', paerml(2100,1,8)
  126. ! write(*,*) 'in2', 'POsol= ', paerml(2100,1,9),'POins= ', paerml(2100,1,12)
  127. ! write(*,*) 'in2', 'num2= ', paernl(2100,1,2), 'num5= ', paernl(2100,1,5)
  128. !
  129. ! write(*,*) 'in2', 'BCtot= ', paerml(2100,1,5)+ paerml(2100,1,8)+paerml(2100,1,6)+paerml(2100,1,7)
  130. !
  131. !--- 1) Calculation of particle properties under ambient conditions: -----
  132. !
  133. !--- 1.1) Calculate mean particle mass for all modes
  134. ! and dry radius and density for the insoluble modes.
  135. !
  136. CALL m7_averageproperties(kproma, kbdim, klev, paernl, paerml, zttn, pm6rp, prhop)
  137. !
  138. !--- 1.2) Calculate ambient count median radii and density
  139. ! for lognormal distribution of particles.
  140. !
  141. ! Sulfate particles:
  142. !
  143. CALL m7_equiz(kproma, kbdim, klev, &
  144. papp1, zttn, ptp1, &
  145. prelhum, pm6rp, pm6dry, &
  146. prhop, pww, paernl )
  147. !
  148. ! Mixed particles with sulfate, b/o carbon and dust:
  149. !
  150. CALL m7_equimix(kproma, kbdim, klev, &
  151. papp1, zttn, ptp1, &
  152. prelhum, pm6rp, pm6dry, &
  153. prhop, pww, paernl )
  154. !
  155. ! Accumulation and coarse mode particles in presence of
  156. ! sea salt particles:
  157. !
  158. CALL m7_equil(kproma, kbdim, klev, prelhum, paerml, paernl, &
  159. pm6rp, pm6dry, zhplus, pww, prhop, ptp1 )
  160. !
  161. !--- m7_box: Write initial particle distribution -------------------------
  162. IF (lofirst) THEN
  163. lofirst=.FALSE.
  164. !AJS: for debugging only ?
  165. !WRITE(16,FMT='(8(1x,e12.4))') 0.0, (pm6rp(1,1,i), i=1,7)
  166. !WRITE(20,FMT='(1x,f5.1,7x,7(1x,e12.4))') 0.0, (pm6dry(1,1,i), i=1,4), (pm6rp(1,1,i), i=5,7)
  167. END IF
  168. !--- END m7_box ----------------------------------------------------------
  169. !
  170. !--- 2) Calculate changes in aerosol mass and gas phase sulfate ----------
  171. ! due to sulfate condensation:
  172. ! No change in particle mass/number relationships.
  173. !
  174. #ifdef with_budgets
  175. IF (lscond) CALL m7_dgas(kproma, kbdim, klev, pso4g, paerml, paernl, &
  176. ptp1, papp1, pm6rp, zso4_5, zso4_6, zso4_7, &
  177. ptime,pprocess)
  178. #else
  179. IF (lscond) CALL m7_dgas(kproma, kbdim, klev, pso4g, paerml, paernl, &
  180. ptp1, papp1, pm6rp, zso4_5, zso4_6, zso4_7, &
  181. ptime)
  182. #endif
  183. !
  184. !
  185. !--- 3) Calculate change in particle number concentrations ---------------
  186. ! due to nucleation and coagulation:
  187. ! Change particle mass/number relationships.
  188. !
  189. ! JadB: Removed "If (lsnucl .OR. lscoag)".
  190. ! If only lscond is set, the m7_dnum is required for storing sulfuric acid on insoluble aerosols (making the soluble).
  191. ! Without m7_dnum, the sulfuric acid condensed on insoluble particles is turned into void.
  192. ! IF (lsnucl.OR.lscoag) CALL m7_dnum(kproma, kbdim, klev, &
  193. ! pso4g, paerml, paernl, ptp1, &
  194. ! papp1, prelhum, pm6rp, prhop, &
  195. ! zso4_5, zso4_6, zso4_7, ptime )
  196. #ifdef with_budgets
  197. CALL m7_dnum(kproma, kbdim, klev, &
  198. pso4g, paerml, paernl, ptp1, &
  199. papp1, prelhum, pm6rp, prhop, &
  200. zso4_5, zso4_6, zso4_7, ptime,pprocess )
  201. #else
  202. CALL m7_dnum(kproma, kbdim, klev, &
  203. pso4g, paerml, paernl, ptp1, &
  204. papp1, prelhum, pm6rp, prhop, &
  205. zso4_5, zso4_6, zso4_7, ptime )
  206. #endif
  207. !
  208. !
  209. !--- 4) Recalculation of particle properties under ambient conditions: ---
  210. !
  211. !--- 4.1) Recalculate mean masses for all modes
  212. ! and dry radius and density for the insoluble modes.
  213. !
  214. CALL m7_averageproperties(kproma, kbdim, klev, paernl, paerml, zttn, pm6rp, prhop)
  215. !
  216. !--- 4.2) Calculate ambient count median radii and density
  217. ! for lognormal distribution of particles.
  218. !
  219. ! Sulfate particles:
  220. !
  221. CALL m7_equiz(kproma, kbdim, klev, &
  222. papp1, zttn, ptp1, &
  223. prelhum, pm6rp, pm6dry, &
  224. prhop, pww, paernl )
  225. !
  226. ! Mixed particles with sulfate, b/o carbon and dust:
  227. !
  228. CALL m7_equimix(kproma, kbdim, klev, &
  229. papp1, zttn, ptp1, &
  230. prelhum, pm6rp, pm6dry, &
  231. prhop, pww, paernl )
  232. !
  233. ! Accumulation and coarse mode particles in presence of
  234. ! sea salt particles:
  235. !
  236. CALL m7_equil(kproma, kbdim, klev, prelhum, paerml, paernl, &
  237. pm6rp, pm6dry, zhplus, pww, prhop, ptp1 )
  238. !
  239. !--- 5) Repartitition particles among the modes: -------------------------
  240. !
  241. IF (lscond.OR.lscoag) THEN
  242. #ifdef with_budgets
  243. CALL m7_dconc(kproma, kbdim, klev, paerml, paernl, pm6dry, pprocess)
  244. #else
  245. CALL m7_dconc(kproma, kbdim, klev, paerml, paernl, pm6dry)
  246. #endif
  247. END IF
  248. !
  249. !--- 6) Recalculation of particle properties under ambient conditions: ---
  250. !
  251. !--- 6.1) Calculate mean particle mass for all modes
  252. ! and dry radius and density for the insoluble modes:
  253. !
  254. CALL m7_averageproperties(kproma, kbdim, klev, paernl, paerml, zttn, pm6rp, prhop)
  255. !
  256. !--- 6.2) Calculate ambient count median radii and density
  257. ! for lognormal distribution of particles.
  258. !
  259. ! Sulfate particles:
  260. !
  261. CALL m7_equiz(kproma, kbdim, klev, &
  262. papp1, zttn, ptp1, &
  263. prelhum, pm6rp, pm6dry, &
  264. prhop, pww, paernl )
  265. !
  266. ! Mixed particles with sulfate, b/o carbon and dust:
  267. !
  268. CALL m7_equimix(kproma, kbdim, klev, &
  269. papp1, zttn, ptp1, &
  270. prelhum, pm6rp, pm6dry, &
  271. prhop, pww, paernl )
  272. !
  273. ! Accumulation and coarse mode particles in presence of
  274. ! sea salt particles:
  275. !
  276. CALL m7_equil(kproma, kbdim, klev, prelhum, paerml, paernl, &
  277. pm6rp, pm6dry, zhplus, pww, prhop, ptp1 )
  278. ! write(*,*) 'ou2', 'h2so4= ', pso4g(2100,1),'num1= ',paernl(2100,1,1)
  279. ! write(*,*) 'ou2', 'BCsol= ', paerml(2100,1,5),'BCins= ', paerml(2100,1,8)
  280. ! write(*,*) 'ou2', 'POsol= ', paerml(2100,1,9),'POins= ', paerml(2100,1,12)
  281. ! write(*,*) 'ou2', 'num2= ', paernl(2100,1,2), 'num5= ', paernl(2100,1,5)
  282. ! write(*,*) 'ou2', 'BCtot= ', paerml(2100,1,5)+ paerml(2100,1,8)+paerml(2100,1,6)+paerml(2100,1,7)
  283. ! write(*,*) 'ou2', 'cond5= ', zso4_5(2100,1), '6= ',zso4_6(2100,1), '7= ',zso4_7(2100,1)
  284. !
  285. END SUBROUTINE m7