[828] | 1 | MODULE lpm_collision_kernels_mod |
---|
[790] | 2 | |
---|
[1036] | 3 | !--------------------------------------------------------------------------------! |
---|
| 4 | ! This file is part of PALM. |
---|
| 5 | ! |
---|
| 6 | ! PALM is free software: you can redistribute it and/or modify it under the terms |
---|
| 7 | ! of the GNU General Public License as published by the Free Software Foundation, |
---|
| 8 | ! either version 3 of the License, or (at your option) any later version. |
---|
| 9 | ! |
---|
| 10 | ! PALM is distributed in the hope that it will be useful, but WITHOUT ANY |
---|
| 11 | ! WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR |
---|
| 12 | ! A PARTICULAR PURPOSE. See the GNU General Public License for more details. |
---|
| 13 | ! |
---|
| 14 | ! You should have received a copy of the GNU General Public License along with |
---|
| 15 | ! PALM. If not, see <http://www.gnu.org/licenses/>. |
---|
| 16 | ! |
---|
[1310] | 17 | ! Copyright 1997-2014 Leibniz Universitaet Hannover |
---|
[1036] | 18 | !--------------------------------------------------------------------------------! |
---|
| 19 | ! |
---|
[790] | 20 | ! Current revisions: |
---|
| 21 | ! ----------------- |
---|
[1321] | 22 | ! |
---|
[1323] | 23 | ! |
---|
[1321] | 24 | ! Former revisions: |
---|
| 25 | ! ----------------- |
---|
| 26 | ! $Id: lpm_collision_kernels.f90 1323 2014-03-20 17:09:54Z raasch $ |
---|
| 27 | ! |
---|
[1323] | 28 | ! 1322 2014-03-20 16:38:49Z raasch |
---|
| 29 | ! REAL constants defined as wp_kind |
---|
| 30 | ! |
---|
[1321] | 31 | ! 1320 2014-03-20 08:40:49Z |
---|
[1320] | 32 | ! ONLY-attribute added to USE-statements, |
---|
| 33 | ! kind-parameters added to all INTEGER and REAL declaration statements, |
---|
| 34 | ! kinds are defined in new module kinds, |
---|
| 35 | ! revision history before 2012 removed, |
---|
| 36 | ! comment fields (!:) to be used for variable explanations added to |
---|
| 37 | ! all variable declaration statements |
---|
[1008] | 38 | ! |
---|
[1093] | 39 | ! 1092 2013-02-02 11:24:22Z raasch |
---|
| 40 | ! unused variables removed |
---|
| 41 | ! |
---|
[1072] | 42 | ! 1071 2012-11-29 16:54:55Z franke |
---|
| 43 | ! Bugfix: collision efficiencies for Hall kernel should not be < 1.0E-20 |
---|
| 44 | ! |
---|
[1037] | 45 | ! 1036 2012-10-22 13:43:42Z raasch |
---|
| 46 | ! code put under GPL (PALM 3.9) |
---|
| 47 | ! |
---|
[1008] | 48 | ! 1007 2012-09-19 14:30:36Z franke |
---|
[1007] | 49 | ! converted all units to SI units and replaced some parameters by corresponding |
---|
| 50 | ! PALM parameters |
---|
| 51 | ! Bugfix: factor in calculation of enhancement factor for collision efficencies |
---|
| 52 | ! changed from 10. to 1.0 |
---|
[829] | 53 | ! |
---|
[850] | 54 | ! 849 2012-03-15 10:35:09Z raasch |
---|
| 55 | ! routine collision_efficiency_rogers added (moved from former advec_particles |
---|
| 56 | ! to here) |
---|
| 57 | ! |
---|
[836] | 58 | ! 835 2012-02-22 11:21:19Z raasch $ |
---|
| 59 | ! Bugfix: array diss can be used only in case of Wang kernel |
---|
| 60 | ! |
---|
[829] | 61 | ! 828 2012-02-21 12:00:36Z raasch |
---|
[828] | 62 | ! code has been completely reformatted, routine colker renamed |
---|
| 63 | ! recalculate_kernel, |
---|
| 64 | ! routine init_kernels added, radius is now communicated to the collision |
---|
| 65 | ! routines by array radclass |
---|
[790] | 66 | ! |
---|
[828] | 67 | ! Bugfix: transformation factor for dissipation changed from 1E5 to 1E4 |
---|
| 68 | ! |
---|
[826] | 69 | ! 825 2012-02-19 03:03:44Z raasch |
---|
| 70 | ! routine renamed from wang_kernel to lpm_collision_kernels, |
---|
| 71 | ! turbulence_effects on collision replaced by wang_kernel |
---|
| 72 | ! |
---|
[791] | 73 | ! 790 2011-11-29 03:11:20Z raasch |
---|
| 74 | ! initial revision |
---|
[790] | 75 | ! |
---|
| 76 | ! Description: |
---|
| 77 | ! ------------ |
---|
[828] | 78 | ! This module calculates collision efficiencies either due to pure gravitational |
---|
| 79 | ! effects (Hall kernel, see Hall, 1980: J. Atmos. Sci., 2486-2507) or |
---|
| 80 | ! including the effects of (SGS) turbulence (Wang kernel, see Wang and |
---|
| 81 | ! Grabowski, 2009: Atmos. Sci. Lett., 10, 1-8). The original code has been |
---|
| 82 | ! provided by L.-P. Wang but is substantially reformatted and speed optimized |
---|
| 83 | ! here. |
---|
| 84 | ! |
---|
| 85 | ! ATTENTION: |
---|
| 86 | ! Physical quantities (like g, densities, etc.) used in this module still |
---|
| 87 | ! have to be adjusted to those values used in the main PALM code. |
---|
| 88 | ! Also, quantities in CGS-units should be converted to SI-units eventually. |
---|
[790] | 89 | !------------------------------------------------------------------------------! |
---|
| 90 | |
---|
[1320] | 91 | USE constants, & |
---|
| 92 | ONLY: pi |
---|
| 93 | |
---|
| 94 | USE kinds |
---|
| 95 | |
---|
| 96 | USE particle_attributes, & |
---|
| 97 | ONLY: collision_kernel, dissipation_classes, particles, radius_classes |
---|
| 98 | |
---|
[828] | 99 | USE pegrid |
---|
[790] | 100 | |
---|
[828] | 101 | |
---|
[790] | 102 | IMPLICIT NONE |
---|
| 103 | |
---|
| 104 | PRIVATE |
---|
| 105 | |
---|
[849] | 106 | PUBLIC ckernel, collision_efficiency_rogers, init_kernels, & |
---|
[1007] | 107 | rclass_lbound, rclass_ubound, recalculate_kernel |
---|
[790] | 108 | |
---|
[1320] | 109 | REAL(wp) :: epsilon !: |
---|
| 110 | REAL(wp) :: eps2 !: |
---|
| 111 | REAL(wp) :: rclass_lbound !: |
---|
| 112 | REAL(wp) :: rclass_ubound !: |
---|
| 113 | REAL(wp) :: urms !: |
---|
| 114 | REAL(wp) :: urms2 !: |
---|
[790] | 115 | |
---|
[1320] | 116 | REAL(wp), DIMENSION(:), ALLOCATABLE :: epsclass !: |
---|
| 117 | REAL(wp), DIMENSION(:), ALLOCATABLE :: radclass !: |
---|
| 118 | REAL(wp), DIMENSION(:), ALLOCATABLE :: winf !: |
---|
| 119 | |
---|
| 120 | REAL(wp), DIMENSION(:,:), ALLOCATABLE :: ec !: |
---|
| 121 | REAL(wp), DIMENSION(:,:), ALLOCATABLE :: ecf !: |
---|
| 122 | REAL(wp), DIMENSION(:,:), ALLOCATABLE :: gck !: |
---|
| 123 | REAL(wp), DIMENSION(:,:), ALLOCATABLE :: hkernel !: |
---|
| 124 | REAL(wp), DIMENSION(:,:), ALLOCATABLE :: hwratio !: |
---|
| 125 | |
---|
| 126 | REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: ckernel !: |
---|
[792] | 127 | |
---|
[828] | 128 | SAVE |
---|
[792] | 129 | |
---|
[790] | 130 | ! |
---|
| 131 | !-- Public interfaces |
---|
[849] | 132 | INTERFACE collision_efficiency_rogers |
---|
| 133 | MODULE PROCEDURE collision_efficiency_rogers |
---|
| 134 | END INTERFACE collision_efficiency_rogers |
---|
| 135 | |
---|
[828] | 136 | INTERFACE init_kernels |
---|
| 137 | MODULE PROCEDURE init_kernels |
---|
| 138 | END INTERFACE init_kernels |
---|
[790] | 139 | |
---|
[828] | 140 | INTERFACE recalculate_kernel |
---|
| 141 | MODULE PROCEDURE recalculate_kernel |
---|
| 142 | END INTERFACE recalculate_kernel |
---|
[790] | 143 | |
---|
| 144 | |
---|
[828] | 145 | CONTAINS |
---|
[790] | 146 | |
---|
[792] | 147 | |
---|
[828] | 148 | SUBROUTINE init_kernels |
---|
| 149 | !------------------------------------------------------------------------------! |
---|
| 150 | ! Initialization of the collision efficiency matrix with fixed radius and |
---|
| 151 | ! dissipation classes, calculated at simulation start only. |
---|
| 152 | !------------------------------------------------------------------------------! |
---|
[792] | 153 | |
---|
[828] | 154 | IMPLICIT NONE |
---|
[792] | 155 | |
---|
[1320] | 156 | INTEGER(iwp) :: i !: |
---|
| 157 | INTEGER(iwp) :: j !: |
---|
| 158 | INTEGER(iwp) :: k !: |
---|
[790] | 159 | |
---|
[828] | 160 | |
---|
| 161 | ! |
---|
| 162 | !-- Calculate collision efficiencies for fixed radius- and dissipation |
---|
| 163 | !-- classes |
---|
| 164 | IF ( collision_kernel(6:9) == 'fast' ) THEN |
---|
| 165 | |
---|
| 166 | ALLOCATE( ckernel(1:radius_classes,1:radius_classes, & |
---|
| 167 | 0:dissipation_classes), epsclass(1:dissipation_classes), & |
---|
| 168 | radclass(1:radius_classes) ) |
---|
| 169 | |
---|
| 170 | ! |
---|
| 171 | !-- Calculate the radius class bounds with logarithmic distances |
---|
| 172 | !-- in the interval [1.0E-6, 2.0E-4] m |
---|
[1322] | 173 | rclass_lbound = LOG( 1.0E-6_wp ) |
---|
| 174 | rclass_ubound = LOG( 2.0E-4_wp ) |
---|
[828] | 175 | radclass(1) = 1.0E-6 |
---|
| 176 | DO i = 2, radius_classes |
---|
| 177 | radclass(i) = EXP( rclass_lbound + & |
---|
| 178 | ( rclass_ubound - rclass_lbound ) * ( i-1.0 ) /& |
---|
| 179 | ( radius_classes - 1.0 ) ) |
---|
| 180 | ! IF ( myid == 0 ) THEN |
---|
| 181 | ! PRINT*, 'i=', i, ' r = ', radclass(i)*1.0E6 |
---|
| 182 | ! ENDIF |
---|
| 183 | ENDDO |
---|
| 184 | |
---|
| 185 | ! |
---|
[1007] | 186 | !-- Set the class bounds for dissipation in interval [0.0, 0.1] m**2/s**3 |
---|
[828] | 187 | DO i = 1, dissipation_classes |
---|
[1322] | 188 | epsclass(i) = 0.1 * REAL( i, KIND=wp ) / dissipation_classes |
---|
[828] | 189 | ! IF ( myid == 0 ) THEN |
---|
| 190 | ! PRINT*, 'i=', i, ' eps = ', epsclass(i) |
---|
| 191 | ! ENDIF |
---|
| 192 | ENDDO |
---|
| 193 | ! |
---|
| 194 | !-- Calculate collision efficiencies of the Wang/ayala kernel |
---|
| 195 | ALLOCATE( ec(1:radius_classes,1:radius_classes), & |
---|
| 196 | ecf(1:radius_classes,1:radius_classes), & |
---|
| 197 | gck(1:radius_classes,1:radius_classes), & |
---|
| 198 | winf(1:radius_classes) ) |
---|
| 199 | |
---|
| 200 | DO k = 1, dissipation_classes |
---|
| 201 | |
---|
| 202 | epsilon = epsclass(k) |
---|
[1322] | 203 | urms = 2.02 * ( epsilon / 0.04_wp )**( 1.0_wp / 3.0_wp ) |
---|
[828] | 204 | |
---|
| 205 | CALL turbsd |
---|
| 206 | CALL turb_enhance_eff |
---|
| 207 | CALL effic |
---|
| 208 | |
---|
| 209 | DO j = 1, radius_classes |
---|
| 210 | DO i = 1, radius_classes |
---|
| 211 | ckernel(i,j,k) = ec(i,j) * gck(i,j) * ecf(i,j) |
---|
| 212 | ENDDO |
---|
| 213 | ENDDO |
---|
| 214 | |
---|
| 215 | ENDDO |
---|
| 216 | |
---|
| 217 | ! |
---|
| 218 | !-- Calculate collision efficiencies of the Hall kernel |
---|
| 219 | ALLOCATE( hkernel(1:radius_classes,1:radius_classes), & |
---|
| 220 | hwratio(1:radius_classes,1:radius_classes) ) |
---|
| 221 | |
---|
| 222 | CALL fallg |
---|
| 223 | CALL effic |
---|
| 224 | |
---|
| 225 | DO j = 1, radius_classes |
---|
| 226 | DO i = 1, radius_classes |
---|
| 227 | hkernel(i,j) = pi * ( radclass(j) + radclass(i) )**2 & |
---|
| 228 | * ec(i,j) * ABS( winf(j) - winf(i) ) |
---|
| 229 | ckernel(i,j,0) = hkernel(i,j) ! hall kernel stored on index 0 |
---|
| 230 | ENDDO |
---|
| 231 | ENDDO |
---|
| 232 | |
---|
| 233 | ! |
---|
| 234 | !-- Test output of efficiencies |
---|
| 235 | IF ( j == -1 ) THEN |
---|
| 236 | |
---|
| 237 | PRINT*, '*** Hall kernel' |
---|
[1007] | 238 | WRITE ( *,'(5X,20(F4.0,1X))' ) ( radclass(i)*1.0E6, & |
---|
| 239 | i = 1,radius_classes ) |
---|
[828] | 240 | DO j = 1, radius_classes |
---|
[1007] | 241 | WRITE ( *,'(F4.0,1X,20(F8.4,1X))' ) radclass(j), & |
---|
| 242 | ( hkernel(i,j), i = 1,radius_classes ) |
---|
[828] | 243 | ENDDO |
---|
| 244 | |
---|
| 245 | DO k = 1, dissipation_classes |
---|
| 246 | DO i = 1, radius_classes |
---|
| 247 | DO j = 1, radius_classes |
---|
| 248 | IF ( hkernel(i,j) == 0.0 ) THEN |
---|
| 249 | hwratio(i,j) = 9999999.9 |
---|
| 250 | ELSE |
---|
| 251 | hwratio(i,j) = ckernel(i,j,k) / hkernel(i,j) |
---|
| 252 | ENDIF |
---|
| 253 | ENDDO |
---|
| 254 | ENDDO |
---|
| 255 | |
---|
| 256 | PRINT*, '*** epsilon = ', epsclass(k) |
---|
[1007] | 257 | WRITE ( *,'(5X,20(F4.0,1X))' ) ( radclass(i)*1.0E6, & |
---|
| 258 | i = 1,radius_classes ) |
---|
[828] | 259 | DO j = 1, radius_classes |
---|
[1007] | 260 | ! WRITE ( *,'(F4.0,1X,20(F4.2,1X))' ) radclass(j)*1.0E6, & |
---|
| 261 | ! ( ckernel(i,j,k), i = 1,radius_classes ) |
---|
| 262 | WRITE ( *,'(F4.0,1X,20(F8.4,1X))' ) radclass(j)*1.0E6, & |
---|
| 263 | ( hwratio(i,j), i = 1,radius_classes ) |
---|
[828] | 264 | ENDDO |
---|
| 265 | ENDDO |
---|
| 266 | |
---|
| 267 | ENDIF |
---|
| 268 | |
---|
| 269 | DEALLOCATE( ec, ecf, epsclass, gck, hkernel, winf ) |
---|
| 270 | |
---|
| 271 | ELSEIF( collision_kernel == 'hall' .OR. collision_kernel == 'wang' ) & |
---|
| 272 | THEN |
---|
| 273 | ! |
---|
| 274 | !-- Initial settings for Hall- and Wang-Kernel |
---|
| 275 | !-- To be done: move here parts from turbsd, fallg, ecoll, etc. |
---|
| 276 | ENDIF |
---|
| 277 | |
---|
| 278 | END SUBROUTINE init_kernels |
---|
| 279 | |
---|
| 280 | |
---|
[790] | 281 | !------------------------------------------------------------------------------! |
---|
[828] | 282 | ! Calculation of collision kernels during each timestep and for each grid box |
---|
[790] | 283 | !------------------------------------------------------------------------------! |
---|
[828] | 284 | SUBROUTINE recalculate_kernel( i1, j1, k1 ) |
---|
[790] | 285 | |
---|
[1320] | 286 | USE arrays_3d, & |
---|
| 287 | ONLY: diss |
---|
[790] | 288 | |
---|
[1320] | 289 | USE particle_attributes, & |
---|
| 290 | ONLY: prt_count, prt_start_index, radius_classes, wang_kernel |
---|
| 291 | |
---|
[790] | 292 | IMPLICIT NONE |
---|
| 293 | |
---|
[1320] | 294 | INTEGER(iwp) :: i !: |
---|
| 295 | INTEGER(iwp) :: i1 !: |
---|
| 296 | INTEGER(iwp) :: j !: |
---|
| 297 | INTEGER(iwp) :: j1 !: |
---|
| 298 | INTEGER(iwp) :: k1 !: |
---|
| 299 | INTEGER(iwp) :: pend !: |
---|
| 300 | INTEGER(iwp) :: pstart !: |
---|
[790] | 301 | |
---|
| 302 | |
---|
[828] | 303 | pstart = prt_start_index(k1,j1,i1) |
---|
| 304 | pend = prt_start_index(k1,j1,i1) + prt_count(k1,j1,i1) - 1 |
---|
| 305 | radius_classes = prt_count(k1,j1,i1) |
---|
[792] | 306 | |
---|
[828] | 307 | ALLOCATE( ec(1:radius_classes,1:radius_classes), & |
---|
| 308 | radclass(1:radius_classes), winf(1:radius_classes) ) |
---|
[790] | 309 | |
---|
[828] | 310 | ! |
---|
[1007] | 311 | !-- Store particle radii on the radclass array |
---|
| 312 | radclass(1:radius_classes) = particles(pstart:pend)%radius |
---|
[790] | 313 | |
---|
[835] | 314 | IF ( wang_kernel ) THEN |
---|
[1007] | 315 | epsilon = diss(k1,j1,i1) ! dissipation rate in m**2/s**3 |
---|
[835] | 316 | ELSE |
---|
| 317 | epsilon = 0.0 |
---|
| 318 | ENDIF |
---|
[1322] | 319 | urms = 2.02 * ( epsilon / 0.04_wp )**( 0.33333333333_wp ) |
---|
[790] | 320 | |
---|
[1007] | 321 | IF ( wang_kernel .AND. epsilon > 1.0E-7 ) THEN |
---|
[828] | 322 | ! |
---|
| 323 | !-- Call routines to calculate efficiencies for the Wang kernel |
---|
| 324 | ALLOCATE( gck(1:radius_classes,1:radius_classes), & |
---|
| 325 | ecf(1:radius_classes,1:radius_classes) ) |
---|
[790] | 326 | |
---|
[828] | 327 | CALL turbsd |
---|
| 328 | CALL turb_enhance_eff |
---|
| 329 | CALL effic |
---|
[790] | 330 | |
---|
[828] | 331 | DO j = 1, radius_classes |
---|
| 332 | DO i = 1, radius_classes |
---|
| 333 | ckernel(pstart+i-1,pstart+j-1,1) = ec(i,j) * gck(i,j) * ecf(i,j) |
---|
[790] | 334 | ENDDO |
---|
[828] | 335 | ENDDO |
---|
[790] | 336 | |
---|
[828] | 337 | DEALLOCATE( gck, ecf ) |
---|
[790] | 338 | |
---|
| 339 | ELSE |
---|
[828] | 340 | ! |
---|
| 341 | !-- Call routines to calculate efficiencies for the Hall kernel |
---|
[790] | 342 | CALL fallg |
---|
| 343 | CALL effic |
---|
| 344 | |
---|
[828] | 345 | DO j = 1, radius_classes |
---|
| 346 | DO i = 1, radius_classes |
---|
| 347 | ckernel(pstart+i-1,pstart+j-1,1) = pi * & |
---|
| 348 | ( radclass(j) + radclass(i) )**2 & |
---|
| 349 | * ec(i,j) * ABS( winf(j) - winf(i) ) |
---|
[790] | 350 | ENDDO |
---|
| 351 | ENDDO |
---|
| 352 | |
---|
| 353 | ENDIF |
---|
| 354 | |
---|
[828] | 355 | DEALLOCATE( ec, radclass, winf ) |
---|
[790] | 356 | |
---|
[828] | 357 | END SUBROUTINE recalculate_kernel |
---|
[790] | 358 | |
---|
[828] | 359 | |
---|
[790] | 360 | !------------------------------------------------------------------------------! |
---|
[828] | 361 | ! Calculation of gck |
---|
| 362 | ! This is from Aayala 2008b, page 37ff. |
---|
| 363 | ! Necessary input parameters: water density, radii of droplets, air density, |
---|
| 364 | ! air viscosity, turbulent dissipation rate, taylor microscale reynolds number, |
---|
| 365 | ! gravitational acceleration --> to be replaced by PALM parameters |
---|
[790] | 366 | !------------------------------------------------------------------------------! |
---|
[792] | 367 | SUBROUTINE turbsd |
---|
[799] | 368 | |
---|
[1320] | 369 | USE control_parameters, & |
---|
| 370 | ONLY: g, molecular_viscosity |
---|
| 371 | |
---|
| 372 | USE particle_attributes, & |
---|
| 373 | ONLY: radius_classes |
---|
[790] | 374 | |
---|
| 375 | IMPLICIT NONE |
---|
[1320] | 376 | |
---|
| 377 | LOGICAL, SAVE :: first = .TRUE. !: |
---|
[790] | 378 | |
---|
[1320] | 379 | INTEGER(iwp) :: i !: |
---|
| 380 | INTEGER(iwp) :: j !: |
---|
[790] | 381 | |
---|
[1320] | 382 | REAL(wp) :: ao !: |
---|
| 383 | REAL(wp) :: ao_gr !: |
---|
| 384 | REAL(wp) :: bbb !: |
---|
| 385 | REAL(wp) :: be !: |
---|
| 386 | REAL(wp) :: b1 !: |
---|
| 387 | REAL(wp) :: b2 !: |
---|
| 388 | REAL(wp) :: ccc !: |
---|
| 389 | REAL(wp) :: c1 !: |
---|
| 390 | REAL(wp) :: c1_gr !: |
---|
| 391 | REAL(wp) :: c2 !: |
---|
| 392 | REAL(wp) :: d1 !: |
---|
| 393 | REAL(wp) :: d2 !: |
---|
| 394 | REAL(wp) :: eta !: |
---|
| 395 | REAL(wp) :: e1 !: |
---|
| 396 | REAL(wp) :: e2 !: |
---|
| 397 | REAL(wp) :: fao_gr !: |
---|
| 398 | REAL(wp) :: fr !: |
---|
| 399 | REAL(wp) :: grfin !: |
---|
| 400 | REAL(wp) :: lambda !: |
---|
| 401 | REAL(wp) :: lambda_re !: |
---|
| 402 | REAL(wp) :: lf !: |
---|
| 403 | REAL(wp) :: rc !: |
---|
| 404 | REAL(wp) :: rrp !: |
---|
| 405 | REAL(wp) :: sst !: |
---|
| 406 | REAL(wp) :: tauk !: |
---|
| 407 | REAL(wp) :: tl !: |
---|
| 408 | REAL(wp) :: t2 !: |
---|
| 409 | REAL(wp) :: tt !: |
---|
| 410 | REAL(wp) :: t1 !: |
---|
| 411 | REAL(wp) :: vk !: |
---|
| 412 | REAL(wp) :: vrms1xy !: |
---|
| 413 | REAL(wp) :: vrms2xy !: |
---|
| 414 | REAL(wp) :: v1 !: |
---|
| 415 | REAL(wp) :: v1v2xy !: |
---|
| 416 | REAL(wp) :: v1xysq !: |
---|
| 417 | REAL(wp) :: v2 !: |
---|
| 418 | REAL(wp) :: v2xysq !: |
---|
| 419 | REAL(wp) :: wrfin !: |
---|
| 420 | REAL(wp) :: wrgrav2 !: |
---|
| 421 | REAL(wp) :: wrtur2xy !: |
---|
| 422 | REAL(wp) :: xx !: |
---|
| 423 | REAL(wp) :: yy !: |
---|
| 424 | REAL(wp) :: z !: |
---|
[790] | 425 | |
---|
[1320] | 426 | REAL(wp), DIMENSION(1:radius_classes) :: st !: |
---|
| 427 | REAL(wp), DIMENSION(1:radius_classes) :: tau !: |
---|
| 428 | |
---|
[799] | 429 | ! |
---|
[828] | 430 | !-- Initial assignment of constants |
---|
[799] | 431 | IF ( first ) THEN |
---|
[790] | 432 | |
---|
[799] | 433 | first = .FALSE. |
---|
[790] | 434 | |
---|
[1007] | 435 | ENDIF |
---|
[790] | 436 | |
---|
[1322] | 437 | lambda = urms * SQRT( 15.0_wp * molecular_viscosity / epsilon ) ! in m |
---|
| 438 | lambda_re = urms**2 * SQRT( 15.0_wp / epsilon / molecular_viscosity ) |
---|
[828] | 439 | tl = urms**2 / epsilon ! in s |
---|
[1007] | 440 | lf = 0.5 * urms**3 / epsilon ! in m |
---|
| 441 | tauk = SQRT( molecular_viscosity / epsilon ) ! in s |
---|
[1322] | 442 | eta = ( molecular_viscosity**3 / epsilon )**0.25_wp ! in m |
---|
[1007] | 443 | vk = eta / tauk |
---|
[790] | 444 | |
---|
[828] | 445 | ao = ( 11.0 + 7.0 * lambda_re ) / ( 205.0 + lambda_re ) |
---|
[1322] | 446 | tt = SQRT( 2.0 * lambda_re / ( SQRT( 15.0_wp ) * ao ) ) * tauk ! in s |
---|
[799] | 447 | |
---|
[1007] | 448 | CALL fallg ! gives winf in m/s |
---|
[790] | 449 | |
---|
[828] | 450 | DO i = 1, radius_classes |
---|
[1007] | 451 | tau(i) = winf(i) / g ! in s |
---|
[828] | 452 | st(i) = tau(i) / tauk |
---|
[790] | 453 | ENDDO |
---|
| 454 | |
---|
[828] | 455 | ! |
---|
| 456 | !-- Calculate wr (from Aayala 2008b, page 38f) |
---|
| 457 | z = tt / tl |
---|
[1322] | 458 | be = SQRT( 2.0_wp ) * lambda / lf |
---|
[828] | 459 | bbb = SQRT( 1.0 - 2.0 * be**2 ) |
---|
| 460 | d1 = ( 1.0 + bbb ) / ( 2.0 * bbb ) |
---|
[1007] | 461 | e1 = lf * ( 1.0 + bbb ) * 0.5 ! in m |
---|
[828] | 462 | d2 = ( 1.0 - bbb ) * 0.5 / bbb |
---|
[1007] | 463 | e2 = lf * ( 1.0 - bbb ) * 0.5 ! in m |
---|
[828] | 464 | ccc = SQRT( 1.0 - 2.0 * z**2 ) |
---|
| 465 | b1 = ( 1.0 + ccc ) * 0.5 / ccc |
---|
| 466 | c1 = tl * ( 1.0 + ccc ) * 0.5 ! in s |
---|
| 467 | b2 = ( 1.0 - ccc ) * 0.5 / ccc |
---|
| 468 | c2 = tl * ( 1.0 - ccc ) * 0.5 ! in s |
---|
[790] | 469 | |
---|
[828] | 470 | DO i = 1, radius_classes |
---|
[790] | 471 | |
---|
[1007] | 472 | v1 = winf(i) ! in m/s |
---|
[828] | 473 | t1 = tau(i) ! in s |
---|
[790] | 474 | |
---|
[828] | 475 | DO j = 1, i |
---|
[1007] | 476 | rrp = radclass(i) + radclass(j) |
---|
| 477 | v2 = winf(j) ! in m/s |
---|
[828] | 478 | t2 = tau(j) ! in s |
---|
[790] | 479 | |
---|
[1007] | 480 | v1xysq = b1 * d1 * phi_w(c1,e1,v1,t1) - b1 * d2 * phi_w(c1,e2,v1,t1) & |
---|
| 481 | - b2 * d1 * phi_w(c2,e1,v1,t1) + b2 * d2 * phi_w(c2,e2,v1,t1) |
---|
| 482 | v1xysq = v1xysq * urms**2 / t1 ! in m**2/s**2 |
---|
| 483 | vrms1xy = SQRT( v1xysq ) ! in m/s |
---|
[790] | 484 | |
---|
[1007] | 485 | v2xysq = b1 * d1 * phi_w(c1,e1,v2,t2) - b1 * d2 * phi_w(c1,e2,v2,t2) & |
---|
| 486 | - b2 * d1 * phi_w(c2,e1,v2,t2) + b2 * d2 * phi_w(c2,e2,v2,t2) |
---|
| 487 | v2xysq = v2xysq * urms**2 / t2 ! in m**2/s**2 |
---|
| 488 | vrms2xy = SQRT( v2xysq ) ! in m/s |
---|
[790] | 489 | |
---|
[828] | 490 | IF ( winf(i) >= winf(j) ) THEN |
---|
[799] | 491 | v1 = winf(i) |
---|
[790] | 492 | t1 = tau(i) |
---|
[799] | 493 | v2 = winf(j) |
---|
[790] | 494 | t2 = tau(j) |
---|
| 495 | ELSE |
---|
[799] | 496 | v1 = winf(j) |
---|
[790] | 497 | t1 = tau(j) |
---|
[799] | 498 | v2 = winf(i) |
---|
[790] | 499 | t2 = tau(i) |
---|
| 500 | ENDIF |
---|
| 501 | |
---|
[828] | 502 | v1v2xy = b1 * d1 * zhi(c1,e1,v1,t1,v2,t2) - & |
---|
| 503 | b1 * d2 * zhi(c1,e2,v1,t1,v2,t2) - & |
---|
| 504 | b2 * d1 * zhi(c2,e1,v1,t1,v2,t2) + & |
---|
| 505 | b2 * d2* zhi(c2,e2,v1,t1,v2,t2) |
---|
| 506 | fr = d1 * EXP( -rrp / e1 ) - d2 * EXP( -rrp / e2 ) |
---|
[1007] | 507 | v1v2xy = v1v2xy * fr * urms**2 / tau(i) / tau(j) ! in m**2/s**2 |
---|
| 508 | wrtur2xy = vrms1xy**2 + vrms2xy**2 - 2.0 * v1v2xy ! in m**2/s**2 |
---|
[828] | 509 | IF ( wrtur2xy < 0.0 ) wrtur2xy = 0.0 |
---|
[1322] | 510 | wrgrav2 = pi / 8.0_wp * ( winf(j) - winf(i) )**2 |
---|
| 511 | wrfin = SQRT( ( 2.0_wp / pi ) * ( wrtur2xy + wrgrav2) ) ! in m/s |
---|
[790] | 512 | |
---|
[828] | 513 | ! |
---|
| 514 | !-- Calculate gr |
---|
| 515 | IF ( st(j) > st(i) ) THEN |
---|
| 516 | sst = st(j) |
---|
[790] | 517 | ELSE |
---|
[828] | 518 | sst = st(i) |
---|
[790] | 519 | ENDIF |
---|
| 520 | |
---|
[828] | 521 | xx = -0.1988 * sst**4 + 1.5275 * sst**3 - 4.2942 * sst**2 + & |
---|
| 522 | 5.3406 * sst |
---|
| 523 | IF ( xx < 0.0 ) xx = 0.0 |
---|
[1322] | 524 | yy = 0.1886 * EXP( 20.306_wp / lambda_re ) |
---|
[790] | 525 | |
---|
[1007] | 526 | c1_gr = xx / ( g / vk * tauk )**yy |
---|
[790] | 527 | |
---|
[1322] | 528 | ao_gr = ao + ( pi / 8.0_wp) * ( g / vk * tauk )**2 |
---|
[828] | 529 | fao_gr = 20.115 * SQRT( ao_gr / lambda_re ) |
---|
| 530 | rc = SQRT( fao_gr * ABS( st(j) - st(i) ) ) * eta ! in cm |
---|
[790] | 531 | |
---|
[828] | 532 | grfin = ( ( eta**2 + rc**2 ) / ( rrp**2 + rc**2) )**( c1_gr*0.5 ) |
---|
| 533 | IF ( grfin < 1.0 ) grfin = 1.0 |
---|
[790] | 534 | |
---|
[828] | 535 | gck(i,j) = 2.0 * pi * rrp**2 * wrfin * grfin ! in cm**3/s |
---|
[790] | 536 | gck(j,i) = gck(i,j) |
---|
| 537 | |
---|
| 538 | ENDDO |
---|
| 539 | ENDDO |
---|
| 540 | |
---|
[828] | 541 | END SUBROUTINE turbsd |
---|
[790] | 542 | |
---|
[828] | 543 | |
---|
[790] | 544 | !------------------------------------------------------------------------------! |
---|
[1007] | 545 | ! phi_w as a function |
---|
[790] | 546 | !------------------------------------------------------------------------------! |
---|
[1320] | 547 | REAL(wp) FUNCTION phi_w( a, b, vsett, tau0 ) |
---|
[790] | 548 | |
---|
| 549 | IMPLICIT NONE |
---|
| 550 | |
---|
[1320] | 551 | REAL(wp) :: a !: |
---|
| 552 | REAL(wp) :: aa1 !: |
---|
| 553 | REAL(wp) :: b !: |
---|
| 554 | REAL(wp) :: tau0 !: |
---|
| 555 | REAL(wp) :: vsett !: |
---|
[790] | 556 | |
---|
[828] | 557 | aa1 = 1.0 / tau0 + 1.0 / a + vsett / b |
---|
[1007] | 558 | phi_w = 1.0 / aa1 - 0.5 * vsett / b / aa1**2 ! in s |
---|
[790] | 559 | |
---|
[1007] | 560 | END FUNCTION phi_w |
---|
[792] | 561 | |
---|
[790] | 562 | |
---|
| 563 | !------------------------------------------------------------------------------! |
---|
[1007] | 564 | ! zhi as a function |
---|
[790] | 565 | !------------------------------------------------------------------------------! |
---|
[1320] | 566 | REAL(wp) FUNCTION zhi( a, b, vsett1, tau1, vsett2, tau2 ) |
---|
[790] | 567 | |
---|
| 568 | IMPLICIT NONE |
---|
| 569 | |
---|
[1320] | 570 | REAL(wp) :: a !: |
---|
| 571 | REAL(wp) :: aa1 !: |
---|
| 572 | REAL(wp) :: aa2 !: |
---|
| 573 | REAL(wp) :: aa3 !: |
---|
| 574 | REAL(wp) :: aa4 !: |
---|
| 575 | REAL(wp) :: aa5 !: |
---|
| 576 | REAL(wp) :: aa6 !: |
---|
| 577 | REAL(wp) :: b !: |
---|
| 578 | REAL(wp) :: tau1 !: |
---|
| 579 | REAL(wp) :: tau2 !: |
---|
| 580 | REAL(wp) :: vsett1 !: |
---|
| 581 | REAL(wp) :: vsett2 !: |
---|
[790] | 582 | |
---|
[828] | 583 | aa1 = vsett2 / b - 1.0 / tau2 - 1.0 / a |
---|
| 584 | aa2 = vsett1 / b + 1.0 / tau1 + 1.0 / a |
---|
| 585 | aa3 = ( vsett1 - vsett2 ) / b + 1.0 / tau1 + 1.0 / tau2 |
---|
| 586 | aa4 = ( vsett2 / b )**2 - ( 1.0 / tau2 + 1.0 / a )**2 |
---|
| 587 | aa5 = vsett2 / b + 1.0 / tau2 + 1.0 / a |
---|
| 588 | aa6 = 1.0 / tau1 - 1.0 / a + ( 1.0 / tau2 + 1.0 / a) * vsett1 / vsett2 |
---|
| 589 | zhi = (1.0 / aa1 - 1.0 / aa2 ) * ( vsett1 - vsett2 ) * 0.5 / b / aa3**2 & |
---|
| 590 | + (4.0 / aa4 - 1.0 / aa5**2 - 1.0 / aa1**2 ) * vsett2 * 0.5 / b /aa6& |
---|
| 591 | + (2.0 * ( b / aa2 - b / aa1 ) - vsett1 / aa2**2 + vsett2 / aa1**2 )& |
---|
| 592 | * 0.5 / b / aa3 ! in s**2 |
---|
[799] | 593 | |
---|
[828] | 594 | END FUNCTION zhi |
---|
[790] | 595 | |
---|
[828] | 596 | |
---|
[790] | 597 | !------------------------------------------------------------------------------! |
---|
[1007] | 598 | ! Calculation of terminal velocity winf following Equations 10-138 to 10-145 |
---|
| 599 | ! from (Pruppacher and Klett, 1997) |
---|
[790] | 600 | !------------------------------------------------------------------------------! |
---|
[828] | 601 | SUBROUTINE fallg |
---|
[1320] | 602 | |
---|
| 603 | USE cloud_parameters, & |
---|
| 604 | ONLY: rho_l |
---|
| 605 | |
---|
| 606 | USE control_parameters, & |
---|
| 607 | ONLY: g |
---|
[790] | 608 | |
---|
[1320] | 609 | USE particle_attributes, & |
---|
| 610 | ONLY: radius_classes |
---|
[790] | 611 | |
---|
[1320] | 612 | |
---|
[828] | 613 | IMPLICIT NONE |
---|
[790] | 614 | |
---|
[1320] | 615 | INTEGER(iwp) :: i !: |
---|
| 616 | INTEGER(iwp) :: j !: |
---|
[790] | 617 | |
---|
[1320] | 618 | LOGICAL, SAVE :: first = .TRUE. !: |
---|
[790] | 619 | |
---|
[1320] | 620 | REAL(wp), SAVE :: cunh !: |
---|
| 621 | REAL(wp), SAVE :: eta !: |
---|
| 622 | REAL(wp), SAVE :: phy !: |
---|
| 623 | REAL(wp), SAVE :: py !: |
---|
| 624 | REAL(wp), SAVE :: rho_a !: |
---|
| 625 | REAL(wp), SAVE :: sigma !: |
---|
| 626 | REAL(wp), SAVE :: stb !: |
---|
| 627 | REAL(wp), SAVE :: stok !: |
---|
| 628 | REAL(wp), SAVE :: xlamb !: |
---|
[790] | 629 | |
---|
[1320] | 630 | REAL(wp) :: bond !: |
---|
| 631 | REAL(wp) :: x !: |
---|
| 632 | REAL(wp) :: xrey !: |
---|
| 633 | REAL(wp) :: y !: |
---|
[799] | 634 | |
---|
[1320] | 635 | REAL(wp), DIMENSION(1:7), SAVE :: b !: |
---|
| 636 | REAL(wp), DIMENSION(1:6), SAVE :: c !: |
---|
[799] | 637 | |
---|
| 638 | ! |
---|
[828] | 639 | !-- Initial assignment of constants |
---|
| 640 | IF ( first ) THEN |
---|
[799] | 641 | |
---|
[828] | 642 | first = .FALSE. |
---|
| 643 | b = (/ -0.318657E1, 0.992696E0, -0.153193E-2, -0.987059E-3, & |
---|
| 644 | -0.578878E-3, 0.855176E-4, -0.327815E-5 /) |
---|
| 645 | c = (/ -0.500015E1, 0.523778E1, -0.204914E1, 0.475294E0, & |
---|
| 646 | -0.542819E-1, 0.238449E-2 /) |
---|
[790] | 647 | |
---|
[1007] | 648 | ! |
---|
| 649 | !-- Parameter values for p = 1013,25 hPa and T = 293,15 K |
---|
| 650 | eta = 1.818E-5 ! in kg/(m s) |
---|
| 651 | xlamb = 6.6E-8 ! in m |
---|
| 652 | rho_a = 1.204 ! in kg/m**3 |
---|
| 653 | cunh = 1.26 * xlamb ! in m |
---|
| 654 | sigma = 0.07363 ! in kg/s**2 |
---|
| 655 | stok = 2.0 * g * ( rho_l - rho_a ) / ( 9.0 * eta ) ! in 1/(m s) |
---|
| 656 | stb = 32.0 * rho_a * ( rho_l - rho_a) * g / (3.0 * eta * eta) |
---|
| 657 | phy = sigma**3 * rho_a**2 / ( eta**4 * g * ( rho_l - rho_a ) ) |
---|
[1322] | 658 | py = phy**( 1.0_wp / 6.0_wp ) |
---|
[790] | 659 | |
---|
[828] | 660 | ENDIF |
---|
[790] | 661 | |
---|
[828] | 662 | DO j = 1, radius_classes |
---|
[790] | 663 | |
---|
[1007] | 664 | IF ( radclass(j) <= 1.0E-5 ) THEN |
---|
[799] | 665 | |
---|
[1007] | 666 | winf(j) = stok * ( radclass(j)**2 + cunh * radclass(j) ) |
---|
[790] | 667 | |
---|
[1007] | 668 | ELSEIF ( radclass(j) > 1.0E-5 .AND. radclass(j) <= 5.35E-4 ) THEN |
---|
[790] | 669 | |
---|
[828] | 670 | x = LOG( stb * radclass(j)**3 ) |
---|
| 671 | y = 0.0 |
---|
[790] | 672 | |
---|
[828] | 673 | DO i = 1, 7 |
---|
| 674 | y = y + b(i) * x**(i-1) |
---|
| 675 | ENDDO |
---|
[1007] | 676 | ! |
---|
| 677 | !-- Note: this Eq. is wrong in (Pruppacher and Klett, 1997, p. 418) |
---|
| 678 | !-- for correct version see (Beard, 1976) |
---|
| 679 | xrey = ( 1.0 + cunh / radclass(j) ) * EXP( y ) |
---|
[790] | 680 | |
---|
[1007] | 681 | winf(j) = xrey * eta / ( 2.0 * rho_a * radclass(j) ) |
---|
[790] | 682 | |
---|
[1007] | 683 | ELSEIF ( radclass(j) > 5.35E-4 ) THEN |
---|
[790] | 684 | |
---|
[1007] | 685 | IF ( radclass(j) > 0.0035 ) THEN |
---|
| 686 | bond = g * ( rho_l - rho_a ) * 0.0035**2 / sigma |
---|
[828] | 687 | ELSE |
---|
[1007] | 688 | bond = g * ( rho_l - rho_a ) * radclass(j)**2 / sigma |
---|
[828] | 689 | ENDIF |
---|
[790] | 690 | |
---|
[1322] | 691 | x = LOG( 16.0 * bond * py / 3.0_wp ) |
---|
[828] | 692 | y = 0.0 |
---|
[790] | 693 | |
---|
[828] | 694 | DO i = 1, 6 |
---|
| 695 | y = y + c(i) * x**(i-1) |
---|
| 696 | ENDDO |
---|
[790] | 697 | |
---|
[828] | 698 | xrey = py * EXP( y ) |
---|
[790] | 699 | |
---|
[1007] | 700 | IF ( radclass(j) > 0.0035 ) THEN |
---|
[1322] | 701 | winf(j) = xrey * eta / ( 2.0 * rho_a * 0.0035_wp ) |
---|
[828] | 702 | ELSE |
---|
[1007] | 703 | winf(j) = xrey * eta / ( 2.0 * rho_a * radclass(j) ) |
---|
[828] | 704 | ENDIF |
---|
[790] | 705 | |
---|
[828] | 706 | ENDIF |
---|
[790] | 707 | |
---|
[828] | 708 | ENDDO |
---|
[790] | 709 | |
---|
[828] | 710 | END SUBROUTINE fallg |
---|
[790] | 711 | |
---|
[828] | 712 | |
---|
[790] | 713 | !------------------------------------------------------------------------------! |
---|
[1071] | 714 | ! Calculation of collision efficiencies for the Hall kernel |
---|
[790] | 715 | !------------------------------------------------------------------------------! |
---|
[828] | 716 | SUBROUTINE effic |
---|
[1320] | 717 | |
---|
| 718 | USE particle_attributes, & |
---|
| 719 | ONLY: radius_classes |
---|
[790] | 720 | |
---|
[828] | 721 | IMPLICIT NONE |
---|
[790] | 722 | |
---|
[1320] | 723 | INTEGER(iwp) :: i !: |
---|
| 724 | INTEGER(iwp) :: iq !: |
---|
| 725 | INTEGER(iwp) :: ir !: |
---|
| 726 | INTEGER(iwp) :: j !: |
---|
| 727 | INTEGER(iwp) :: k !: |
---|
[790] | 728 | |
---|
[1320] | 729 | INTEGER(iwp), DIMENSION(:), ALLOCATABLE :: ira !: |
---|
[790] | 730 | |
---|
[1320] | 731 | LOGICAL, SAVE :: first = .TRUE. !: |
---|
[790] | 732 | |
---|
[1320] | 733 | REAL(wp) :: ek !: |
---|
| 734 | REAL(wp) :: particle_radius !: |
---|
| 735 | REAL(wp) :: pp !: |
---|
| 736 | REAL(wp) :: qq !: |
---|
| 737 | REAL(wp) :: rq !: |
---|
[790] | 738 | |
---|
[1320] | 739 | REAL(wp), DIMENSION(1:21), SAVE :: rat !: |
---|
| 740 | |
---|
| 741 | REAL(wp), DIMENSION(1:15), SAVE :: r0 !: |
---|
| 742 | |
---|
| 743 | REAL(wp), DIMENSION(1:15,1:21), SAVE :: ecoll !: |
---|
[790] | 744 | |
---|
[792] | 745 | ! |
---|
[828] | 746 | !-- Initial assignment of constants |
---|
| 747 | IF ( first ) THEN |
---|
[790] | 748 | |
---|
[792] | 749 | first = .FALSE. |
---|
[828] | 750 | r0 = (/ 6.0, 8.0, 10.0, 15.0, 20.0, 25.0, 30.0, 40.0, 50.0, 60., & |
---|
| 751 | 70.0, 100.0, 150.0, 200.0, 300.0 /) |
---|
| 752 | rat = (/ 0.00, 0.05, 0.10, 0.15, 0.20, 0.25, 0.30, 0.35, 0.40, 0.45, & |
---|
| 753 | 0.50, 0.55, 0.60, 0.65, 0.70, 0.75, 0.80, 0.85, 0.90, 0.95, & |
---|
| 754 | 1.00 /) |
---|
[790] | 755 | |
---|
[828] | 756 | ecoll(:,1) = (/0.001, 0.001, 0.001, 0.001, 0.001, 0.001, 0.001, & |
---|
| 757 | 0.001, 0.001, 0.001, 0.001, 0.001, 0.001, 0.001, 0.001/) |
---|
| 758 | ecoll(:,2) = (/0.003, 0.003, 0.003, 0.004, 0.005, 0.005, 0.005, & |
---|
| 759 | 0.010, 0.100, 0.050, 0.200, 0.500, 0.770, 0.870, 0.970/) |
---|
| 760 | ecoll(:,3) = (/0.007, 0.007, 0.007, 0.008, 0.009, 0.010, 0.010, & |
---|
| 761 | 0.070, 0.400, 0.430, 0.580, 0.790, 0.930, 0.960, 1.000/) |
---|
| 762 | ecoll(:,4) = (/0.009, 0.009, 0.009, 0.012, 0.015, 0.010, 0.020, & |
---|
| 763 | 0.280, 0.600, 0.640, 0.750, 0.910, 0.970, 0.980, 1.000/) |
---|
| 764 | ecoll(:,5) = (/0.014, 0.014, 0.014, 0.015, 0.016, 0.030, 0.060, & |
---|
| 765 | 0.500, 0.700, 0.770, 0.840, 0.950, 0.970, 1.000, 1.000/) |
---|
| 766 | ecoll(:,6) = (/0.017, 0.017, 0.017, 0.020, 0.022, 0.060, 0.100, & |
---|
| 767 | 0.620, 0.780, 0.840, 0.880, 0.950, 1.000, 1.000, 1.000/) |
---|
| 768 | ecoll(:,7) = (/0.030, 0.030, 0.024, 0.022, 0.032, 0.062, 0.200, & |
---|
| 769 | 0.680, 0.830, 0.870, 0.900, 0.950, 1.000, 1.000, 1.000/) |
---|
| 770 | ecoll(:,8) = (/0.025, 0.025, 0.025, 0.036, 0.043, 0.130, 0.270, & |
---|
| 771 | 0.740, 0.860, 0.890, 0.920, 1.000, 1.000, 1.000, 1.000/) |
---|
| 772 | ecoll(:,9) = (/0.027, 0.027, 0.027, 0.040, 0.052, 0.200, 0.400, & |
---|
| 773 | 0.780, 0.880, 0.900, 0.940, 1.000, 1.000, 1.000, 1.000/) |
---|
| 774 | ecoll(:,10)= (/0.030, 0.030, 0.030, 0.047, 0.064, 0.250, 0.500, & |
---|
| 775 | 0.800, 0.900, 0.910, 0.950, 1.000, 1.000, 1.000, 1.000/) |
---|
| 776 | ecoll(:,11)= (/0.040, 0.040, 0.033, 0.037, 0.068, 0.240, 0.550, & |
---|
| 777 | 0.800, 0.900, 0.910, 0.950, 1.000, 1.000, 1.000, 1.000/) |
---|
| 778 | ecoll(:,12)= (/0.035, 0.035, 0.035, 0.055, 0.079, 0.290, 0.580, & |
---|
| 779 | 0.800, 0.900, 0.910, 0.950, 1.000, 1.000, 1.000, 1.000/) |
---|
| 780 | ecoll(:,13)= (/0.037, 0.037, 0.037, 0.062, 0.082, 0.290, 0.590, & |
---|
| 781 | 0.780, 0.900, 0.910, 0.950, 1.000, 1.000, 1.000, 1.000/) |
---|
| 782 | ecoll(:,14)= (/0.037, 0.037, 0.037, 0.060, 0.080, 0.290, 0.580, & |
---|
| 783 | 0.770, 0.890, 0.910, 0.950, 1.000, 1.000, 1.000, 1.000/) |
---|
| 784 | ecoll(:,15)= (/0.037, 0.037, 0.037, 0.041, 0.075, 0.250, 0.540, & |
---|
| 785 | 0.760, 0.880, 0.920, 0.950, 1.000, 1.000, 1.000, 1.000/) |
---|
| 786 | ecoll(:,16)= (/0.037, 0.037, 0.037, 0.052, 0.067, 0.250, 0.510, & |
---|
| 787 | 0.770, 0.880, 0.930, 0.970, 1.000, 1.000, 1.000, 1.000/) |
---|
| 788 | ecoll(:,17)= (/0.037, 0.037, 0.037, 0.047, 0.057, 0.250, 0.490, & |
---|
| 789 | 0.770, 0.890, 0.950, 1.000, 1.000, 1.000, 1.000, 1.000/) |
---|
| 790 | ecoll(:,18)= (/0.036, 0.036, 0.036, 0.042, 0.048, 0.230, 0.470, & |
---|
| 791 | 0.780, 0.920, 1.000, 1.020, 1.020, 1.020, 1.020, 1.020/) |
---|
| 792 | ecoll(:,19)= (/0.040, 0.040, 0.035, 0.033, 0.040, 0.112, 0.450, & |
---|
| 793 | 0.790, 1.010, 1.030, 1.040, 1.040, 1.040, 1.040, 1.040/) |
---|
| 794 | ecoll(:,20)= (/0.033, 0.033, 0.033, 0.033, 0.033, 0.119, 0.470, & |
---|
| 795 | 0.950, 1.300, 1.700, 2.300, 2.300, 2.300, 2.300, 2.300/) |
---|
| 796 | ecoll(:,21)= (/0.027, 0.027, 0.027, 0.027, 0.027, 0.125, 0.520, & |
---|
| 797 | 1.400, 2.300, 3.000, 4.000, 4.000, 4.000, 4.000, 4.000/) |
---|
| 798 | ENDIF |
---|
[790] | 799 | |
---|
[792] | 800 | ! |
---|
[828] | 801 | !-- Calculate the radius class index of particles with respect to array r |
---|
[1007] | 802 | !-- Radius has to be in µm |
---|
[828] | 803 | ALLOCATE( ira(1:radius_classes) ) |
---|
| 804 | DO j = 1, radius_classes |
---|
[1322] | 805 | particle_radius = radclass(j) * 1.0E6_wp |
---|
[828] | 806 | DO k = 1, 15 |
---|
| 807 | IF ( particle_radius < r0(k) ) THEN |
---|
| 808 | ira(j) = k |
---|
| 809 | EXIT |
---|
| 810 | ENDIF |
---|
| 811 | ENDDO |
---|
| 812 | IF ( particle_radius >= r0(15) ) ira(j) = 16 |
---|
| 813 | ENDDO |
---|
[790] | 814 | |
---|
[792] | 815 | ! |
---|
[828] | 816 | !-- Two-dimensional linear interpolation of the collision efficiency. |
---|
| 817 | !-- Radius has to be in µm |
---|
| 818 | DO j = 1, radius_classes |
---|
| 819 | DO i = 1, j |
---|
[792] | 820 | |
---|
[828] | 821 | ir = ira(j) |
---|
| 822 | rq = radclass(i) / radclass(j) |
---|
| 823 | iq = INT( rq * 20 ) + 1 |
---|
| 824 | iq = MAX( iq , 2) |
---|
[792] | 825 | |
---|
[828] | 826 | IF ( ir < 16 ) THEN |
---|
| 827 | IF ( ir >= 2 ) THEN |
---|
[1322] | 828 | pp = ( ( radclass(j) * 1.0E06_wp ) - r0(ir-1) ) / & |
---|
[828] | 829 | ( r0(ir) - r0(ir-1) ) |
---|
| 830 | qq = ( rq- rat(iq-1) ) / ( rat(iq) - rat(iq-1) ) |
---|
| 831 | ec(j,i) = ( 1.0-pp ) * ( 1.0-qq ) * ecoll(ir-1,iq-1) & |
---|
| 832 | + pp * ( 1.0-qq ) * ecoll(ir,iq-1) & |
---|
| 833 | + qq * ( 1.0-pp ) * ecoll(ir-1,iq) & |
---|
| 834 | + pp * qq * ecoll(ir,iq) |
---|
| 835 | ELSE |
---|
| 836 | qq = ( rq - rat(iq-1) ) / ( rat(iq) - rat(iq-1) ) |
---|
| 837 | ec(j,i) = (1.0-qq) * ecoll(1,iq-1) + qq * ecoll(1,iq) |
---|
| 838 | ENDIF |
---|
| 839 | ELSE |
---|
| 840 | qq = ( rq - rat(iq-1) ) / ( rat(iq) - rat(iq-1) ) |
---|
| 841 | ek = ( 1.0 - qq ) * ecoll(15,iq-1) + qq * ecoll(15,iq) |
---|
| 842 | ec(j,i) = MIN( ek, 1.0 ) |
---|
[1071] | 843 | ENDIF |
---|
[792] | 844 | |
---|
[1071] | 845 | IF ( ec(j,i) < 1.0E-20 ) ec(j,i) = 0.0 |
---|
| 846 | |
---|
[828] | 847 | ec(i,j) = ec(j,i) |
---|
[792] | 848 | |
---|
[828] | 849 | ENDDO |
---|
| 850 | ENDDO |
---|
[792] | 851 | |
---|
[828] | 852 | DEALLOCATE( ira ) |
---|
[792] | 853 | |
---|
[828] | 854 | END SUBROUTINE effic |
---|
[792] | 855 | |
---|
| 856 | |
---|
[790] | 857 | !------------------------------------------------------------------------------! |
---|
[828] | 858 | ! Calculation of enhancement factor for collision efficencies due to turbulence |
---|
[790] | 859 | !------------------------------------------------------------------------------! |
---|
[828] | 860 | SUBROUTINE turb_enhance_eff |
---|
[790] | 861 | |
---|
[1320] | 862 | USE particle_attributes, & |
---|
| 863 | ONLY: radius_classes |
---|
[790] | 864 | |
---|
[828] | 865 | IMPLICIT NONE |
---|
[790] | 866 | |
---|
[1320] | 867 | INTEGER(iwp) :: i !: |
---|
| 868 | INTEGER(iwp) :: iq !: |
---|
| 869 | INTEGER(iwp) :: ir !: |
---|
| 870 | INTEGER(iwp) :: j !: |
---|
| 871 | INTEGER(iwp) :: k !: |
---|
| 872 | INTEGER(iwp) :: kk !: |
---|
[790] | 873 | |
---|
[1320] | 874 | INTEGER(iwp), DIMENSION(:), ALLOCATABLE :: ira !: |
---|
| 875 | |
---|
| 876 | LOGICAL, SAVE :: first = .TRUE. !: |
---|
[790] | 877 | |
---|
[1320] | 878 | REAL(wp) :: particle_radius !: |
---|
| 879 | REAL(wp) :: pp !: |
---|
| 880 | REAL(wp) :: qq !: |
---|
| 881 | REAL(wp) :: rq !: |
---|
| 882 | REAL(wp) :: y1 !: |
---|
| 883 | REAL(wp) :: y2 !: |
---|
| 884 | REAL(wp) :: y3 !: |
---|
[790] | 885 | |
---|
[1320] | 886 | REAL(wp), DIMENSION(1:11), SAVE :: rat !: |
---|
| 887 | |
---|
| 888 | REAL(wp), DIMENSION(1:7), SAVE :: r0 !: |
---|
| 889 | |
---|
| 890 | REAL(wp), DIMENSION(1:7,1:11), SAVE :: ecoll_100 !: |
---|
| 891 | REAL(wp), DIMENSION(1:7,1:11), SAVE :: ecoll_400 !: |
---|
[799] | 892 | |
---|
| 893 | ! |
---|
[828] | 894 | !-- Initial assignment of constants |
---|
| 895 | IF ( first ) THEN |
---|
[799] | 896 | |
---|
[828] | 897 | first = .FALSE. |
---|
[799] | 898 | |
---|
[828] | 899 | r0 = (/ 10.0, 20.0, 30.0, 40.0, 50.0, 60.0, 100.0 /) |
---|
| 900 | rat = (/ 0.0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1.0 /) |
---|
| 901 | ! |
---|
[1007] | 902 | !-- for 100 cm**2/s**3 |
---|
[828] | 903 | ecoll_100(:,1) = (/1.74, 1.74, 1.773, 1.49, 1.207, 1.207, 1.0 /) |
---|
| 904 | ecoll_100(:,2) = (/1.46, 1.46, 1.421, 1.245, 1.069, 1.069, 1.0 /) |
---|
| 905 | ecoll_100(:,3) = (/1.32, 1.32, 1.245, 1.123, 1.000, 1.000, 1.0 /) |
---|
| 906 | ecoll_100(:,4) = (/1.250, 1.250, 1.148, 1.087, 1.025, 1.025, 1.0 /) |
---|
| 907 | ecoll_100(:,5) = (/1.186, 1.186, 1.066, 1.060, 1.056, 1.056, 1.0 /) |
---|
| 908 | ecoll_100(:,6) = (/1.045, 1.045, 1.000, 1.014, 1.028, 1.028, 1.0 /) |
---|
| 909 | ecoll_100(:,7) = (/1.070, 1.070, 1.030, 1.038, 1.046, 1.046, 1.0 /) |
---|
| 910 | ecoll_100(:,8) = (/1.000, 1.000, 1.054, 1.042, 1.029, 1.029, 1.0 /) |
---|
| 911 | ecoll_100(:,9) = (/1.223, 1.223, 1.117, 1.069, 1.021, 1.021, 1.0 /) |
---|
| 912 | ecoll_100(:,10)= (/1.570, 1.570, 1.244, 1.166, 1.088, 1.088, 1.0 /) |
---|
| 913 | ecoll_100(:,11)= (/20.3, 20.3, 14.6 , 8.61, 2.60, 2.60 , 1.0 /) |
---|
| 914 | ! |
---|
[1007] | 915 | !-- for 400 cm**2/s**3 |
---|
[828] | 916 | ecoll_400(:,1) = (/4.976, 4.976, 3.593, 2.519, 1.445, 1.445, 1.0 /) |
---|
| 917 | ecoll_400(:,2) = (/2.984, 2.984, 2.181, 1.691, 1.201, 1.201, 1.0 /) |
---|
| 918 | ecoll_400(:,3) = (/1.988, 1.988, 1.475, 1.313, 1.150, 1.150, 1.0 /) |
---|
| 919 | ecoll_400(:,4) = (/1.490, 1.490, 1.187, 1.156, 1.126, 1.126, 1.0 /) |
---|
| 920 | ecoll_400(:,5) = (/1.249, 1.249, 1.088, 1.090, 1.092, 1.092, 1.0 /) |
---|
| 921 | ecoll_400(:,6) = (/1.139, 1.139, 1.130, 1.091, 1.051, 1.051, 1.0 /) |
---|
| 922 | ecoll_400(:,7) = (/1.220, 1.220, 1.190, 1.138, 1.086, 1.086, 1.0 /) |
---|
| 923 | ecoll_400(:,8) = (/1.325, 1.325, 1.267, 1.165, 1.063, 1.063, 1.0 /) |
---|
| 924 | ecoll_400(:,9) = (/1.716, 1.716, 1.345, 1.223, 1.100, 1.100, 1.0 /) |
---|
| 925 | ecoll_400(:,10)= (/3.788, 3.788, 1.501, 1.311, 1.120, 1.120, 1.0 /) |
---|
| 926 | ecoll_400(:,11)= (/36.52, 36.52, 19.16, 22.80, 26.0, 26.0, 1.0 /) |
---|
[799] | 927 | |
---|
[828] | 928 | ENDIF |
---|
[790] | 929 | |
---|
[828] | 930 | ! |
---|
| 931 | !-- Calculate the radius class index of particles with respect to array r0 |
---|
[1007] | 932 | !-- Radius has to be in µm |
---|
[828] | 933 | ALLOCATE( ira(1:radius_classes) ) |
---|
[790] | 934 | |
---|
[828] | 935 | DO j = 1, radius_classes |
---|
[1322] | 936 | particle_radius = radclass(j) * 1.0E6_wp |
---|
[828] | 937 | DO k = 1, 7 |
---|
| 938 | IF ( particle_radius < r0(k) ) THEN |
---|
| 939 | ira(j) = k |
---|
| 940 | EXIT |
---|
| 941 | ENDIF |
---|
| 942 | ENDDO |
---|
| 943 | IF ( particle_radius >= r0(7) ) ira(j) = 8 |
---|
| 944 | ENDDO |
---|
[799] | 945 | |
---|
| 946 | ! |
---|
[828] | 947 | !-- Two-dimensional linear interpolation of the collision efficiencies |
---|
[1007] | 948 | !-- Radius has to be in µm |
---|
[828] | 949 | DO j = 1, radius_classes |
---|
| 950 | DO i = 1, j |
---|
[799] | 951 | |
---|
[828] | 952 | ir = ira(j) |
---|
| 953 | rq = radclass(i) / radclass(j) |
---|
[799] | 954 | |
---|
[828] | 955 | DO kk = 2, 11 |
---|
| 956 | IF ( rq <= rat(kk) ) THEN |
---|
| 957 | iq = kk |
---|
| 958 | EXIT |
---|
| 959 | ENDIF |
---|
| 960 | ENDDO |
---|
[790] | 961 | |
---|
[1007] | 962 | y1 = 0.0001 ! for 0 m**2/s**3 |
---|
| 963 | |
---|
[828] | 964 | IF ( ir < 8 ) THEN |
---|
| 965 | IF ( ir >= 2 ) THEN |
---|
[1007] | 966 | pp = ( radclass(j)*1.0E6 - r0(ir-1) ) / ( r0(ir) - r0(ir-1) ) |
---|
[828] | 967 | qq = ( rq - rat(iq-1) ) / ( rat(iq) - rat(iq-1) ) |
---|
| 968 | y2 = ( 1.0-pp ) * ( 1.0-qq ) * ecoll_100(ir-1,iq-1) + & |
---|
| 969 | pp * ( 1.0-qq ) * ecoll_100(ir,iq-1) + & |
---|
[1007] | 970 | qq * ( 1.0-pp ) * ecoll_100(ir-1,iq) + & |
---|
[828] | 971 | pp * qq * ecoll_100(ir,iq) |
---|
| 972 | y3 = ( 1.0-pp ) * ( 1.0-qq ) * ecoll_400(ir-1,iq-1) + & |
---|
| 973 | pp * ( 1.0-qq ) * ecoll_400(ir,iq-1) + & |
---|
| 974 | qq * ( 1.0-pp ) * ecoll_400(ir-1,iq) + & |
---|
| 975 | pp * qq * ecoll_400(ir,iq) |
---|
| 976 | ELSE |
---|
| 977 | qq = ( rq - rat(iq-1) ) / ( rat(iq) - rat(iq-1) ) |
---|
| 978 | y2 = ( 1.0-qq ) * ecoll_100(1,iq-1) + qq * ecoll_100(1,iq) |
---|
| 979 | y3 = ( 1.0-qq ) * ecoll_400(1,iq-1) + qq * ecoll_400(1,iq) |
---|
| 980 | ENDIF |
---|
| 981 | ELSE |
---|
| 982 | qq = ( rq - rat(iq-1) ) / ( rat(iq) - rat(iq-1) ) |
---|
| 983 | y2 = ( 1.0-qq ) * ecoll_100(7,iq-1) + qq * ecoll_100(7,iq) |
---|
| 984 | y3 = ( 1.0-qq ) * ecoll_400(7,iq-1) + qq * ecoll_400(7,iq) |
---|
| 985 | ENDIF |
---|
| 986 | ! |
---|
[1007] | 987 | !-- Linear interpolation of dissipation rate in m**2/s**3 |
---|
| 988 | IF ( epsilon <= 0.01 ) THEN |
---|
| 989 | ecf(j,i) = ( epsilon - 0.01 ) / ( 0.0 - 0.01 ) * y1 & |
---|
| 990 | + ( epsilon - 0.0 ) / ( 0.01 - 0.0 ) * y2 |
---|
| 991 | ELSEIF ( epsilon <= 0.06 ) THEN |
---|
| 992 | ecf(j,i) = ( epsilon - 0.04 ) / ( 0.01 - 0.04 ) * y2 & |
---|
| 993 | + ( epsilon - 0.01 ) / ( 0.04 - 0.01 ) * y3 |
---|
[828] | 994 | ELSE |
---|
[1007] | 995 | ecf(j,i) = ( 0.06 - 0.04 ) / ( 0.01 - 0.04 ) * y2 & |
---|
| 996 | + ( 0.06 - 0.01 ) / ( 0.04 - 0.01 ) * y3 |
---|
[828] | 997 | ENDIF |
---|
[790] | 998 | |
---|
[828] | 999 | IF ( ecf(j,i) < 1.0 ) ecf(j,i) = 1.0 |
---|
[790] | 1000 | |
---|
[828] | 1001 | ecf(i,j) = ecf(j,i) |
---|
[790] | 1002 | |
---|
[828] | 1003 | ENDDO |
---|
| 1004 | ENDDO |
---|
[790] | 1005 | |
---|
[828] | 1006 | END SUBROUTINE turb_enhance_eff |
---|
[790] | 1007 | |
---|
[849] | 1008 | |
---|
| 1009 | |
---|
| 1010 | SUBROUTINE collision_efficiency_rogers( mean_r, r, e) |
---|
| 1011 | !------------------------------------------------------------------------------! |
---|
| 1012 | ! Collision efficiencies from table 8.2 in Rogers and Yau (1989, 3rd edition). |
---|
| 1013 | ! Values are calculated from table by bilinear interpolation. |
---|
| 1014 | !------------------------------------------------------------------------------! |
---|
| 1015 | |
---|
| 1016 | IMPLICIT NONE |
---|
| 1017 | |
---|
[1320] | 1018 | INTEGER(iwp) :: i !: |
---|
| 1019 | INTEGER(iwp) :: j !: |
---|
| 1020 | INTEGER(iwp) :: k !: |
---|
[849] | 1021 | |
---|
[1320] | 1022 | LOGICAL, SAVE :: first = .TRUE. !: |
---|
[849] | 1023 | |
---|
[1320] | 1024 | REAL(wp) :: aa !: |
---|
| 1025 | REAL(wp) :: bb !: |
---|
| 1026 | REAL(wp) :: cc !: |
---|
| 1027 | REAL(wp) :: dd !: |
---|
| 1028 | REAL(wp) :: dx !: |
---|
| 1029 | REAL(wp) :: dy !: |
---|
| 1030 | REAL(wp) :: e !: |
---|
| 1031 | REAL(wp) :: gg !: |
---|
| 1032 | REAL(wp) :: mean_r !: |
---|
| 1033 | REAL(wp) :: mean_rm !: |
---|
| 1034 | REAL(wp) :: r !: |
---|
| 1035 | REAL(wp) :: rm !: |
---|
| 1036 | REAL(wp) :: x !: |
---|
| 1037 | REAL(wp) :: y !: |
---|
| 1038 | |
---|
| 1039 | REAL(wp), DIMENSION(1:9), SAVE :: collected_r = 0.0 !: |
---|
| 1040 | |
---|
| 1041 | REAL(wp), DIMENSION(1:19), SAVE :: collector_r = 0.0 !: |
---|
| 1042 | |
---|
| 1043 | REAL(wp), DIMENSION(1:9,1:19), SAVE :: ef = 0.0 !: |
---|
[849] | 1044 | |
---|
[1322] | 1045 | mean_rm = mean_r * 1.0E06_wp |
---|
| 1046 | rm = r * 1.0E06_wp |
---|
[849] | 1047 | |
---|
| 1048 | IF ( first ) THEN |
---|
| 1049 | |
---|
| 1050 | collected_r = (/ 2.0, 3.0, 4.0, 6.0, 8.0, 10.0, 15.0, 20.0, 25.0 /) |
---|
| 1051 | collector_r = (/ 10.0, 20.0, 30.0, 40.0, 50.0, 60.0, 80.0, 100.0, & |
---|
| 1052 | 150.0, 200.0, 300.0, 400.0, 500.0, 600.0, 1000.0, & |
---|
| 1053 | 1400.0, 1800.0, 2400.0, 3000.0 /) |
---|
| 1054 | |
---|
| 1055 | ef(:,1) = (/0.017, 0.027, 0.037, 0.052, 0.052, 0.052, 0.052, 0.0, & |
---|
| 1056 | 0.0 /) |
---|
| 1057 | ef(:,2) = (/0.001, 0.016, 0.027, 0.060, 0.12, 0.17, 0.17, 0.17, 0.0 /) |
---|
| 1058 | ef(:,3) = (/0.001, 0.001, 0.02, 0.13, 0.28, 0.37, 0.54, 0.55, 0.47/) |
---|
| 1059 | ef(:,4) = (/0.001, 0.001, 0.02, 0.23, 0.4, 0.55, 0.7, 0.75, 0.75/) |
---|
| 1060 | ef(:,5) = (/0.01, 0.01, 0.03, 0.3, 0.4, 0.58, 0.73, 0.75, 0.79/) |
---|
| 1061 | ef(:,6) = (/0.01, 0.01, 0.13, 0.38, 0.57, 0.68, 0.80, 0.86, 0.91/) |
---|
| 1062 | ef(:,7) = (/0.01, 0.085, 0.23, 0.52, 0.68, 0.76, 0.86, 0.92, 0.95/) |
---|
| 1063 | ef(:,8) = (/0.01, 0.14, 0.32, 0.60, 0.73, 0.81, 0.90, 0.94, 0.96/) |
---|
| 1064 | ef(:,9) = (/0.025, 0.25, 0.43, 0.66, 0.78, 0.83, 0.92, 0.95, 0.96/) |
---|
| 1065 | ef(:,10)= (/0.039, 0.3, 0.46, 0.69, 0.81, 0.87, 0.93, 0.95, 0.96/) |
---|
| 1066 | ef(:,11)= (/0.095, 0.33, 0.51, 0.72, 0.82, 0.87, 0.93, 0.96, 0.97/) |
---|
| 1067 | ef(:,12)= (/0.098, 0.36, 0.51, 0.73, 0.83, 0.88, 0.93, 0.96, 0.97/) |
---|
| 1068 | ef(:,13)= (/0.1, 0.36, 0.52, 0.74, 0.83, 0.88, 0.93, 0.96, 0.97/) |
---|
| 1069 | ef(:,14)= (/0.17, 0.4, 0.54, 0.72, 0.83, 0.88, 0.94, 0.98, 1.0 /) |
---|
| 1070 | ef(:,15)= (/0.15, 0.37, 0.52, 0.74, 0.82, 0.88, 0.94, 0.98, 1.0 /) |
---|
| 1071 | ef(:,16)= (/0.11, 0.34, 0.49, 0.71, 0.83, 0.88, 0.94, 0.95, 1.0 /) |
---|
| 1072 | ef(:,17)= (/0.08, 0.29, 0.45, 0.68, 0.8, 0.86, 0.96, 0.94, 1.0 /) |
---|
| 1073 | ef(:,18)= (/0.04, 0.22, 0.39, 0.62, 0.75, 0.83, 0.92, 0.96, 1.0 /) |
---|
| 1074 | ef(:,19)= (/0.02, 0.16, 0.33, 0.55, 0.71, 0.81, 0.90, 0.94, 1.0 /) |
---|
| 1075 | |
---|
| 1076 | ENDIF |
---|
| 1077 | |
---|
| 1078 | DO k = 1, 8 |
---|
| 1079 | IF ( collected_r(k) <= mean_rm ) i = k |
---|
| 1080 | ENDDO |
---|
| 1081 | |
---|
| 1082 | DO k = 1, 18 |
---|
| 1083 | IF ( collector_r(k) <= rm ) j = k |
---|
| 1084 | ENDDO |
---|
| 1085 | |
---|
| 1086 | IF ( rm < 10.0 ) THEN |
---|
| 1087 | e = 0.0 |
---|
| 1088 | ELSEIF ( mean_rm < 2.0 ) THEN |
---|
| 1089 | e = 0.001 |
---|
| 1090 | ELSEIF ( mean_rm >= 25.0 ) THEN |
---|
| 1091 | IF( j <= 2 ) e = 0.0 |
---|
| 1092 | IF( j == 3 ) e = 0.47 |
---|
| 1093 | IF( j == 4 ) e = 0.8 |
---|
| 1094 | IF( j == 5 ) e = 0.9 |
---|
| 1095 | IF( j >=6 ) e = 1.0 |
---|
| 1096 | ELSEIF ( rm >= 3000.0 ) THEN |
---|
| 1097 | IF( i == 1 ) e = 0.02 |
---|
| 1098 | IF( i == 2 ) e = 0.16 |
---|
| 1099 | IF( i == 3 ) e = 0.33 |
---|
| 1100 | IF( i == 4 ) e = 0.55 |
---|
| 1101 | IF( i == 5 ) e = 0.71 |
---|
| 1102 | IF( i == 6 ) e = 0.81 |
---|
| 1103 | IF( i == 7 ) e = 0.90 |
---|
| 1104 | IF( i >= 8 ) e = 0.94 |
---|
| 1105 | ELSE |
---|
| 1106 | x = mean_rm - collected_r(i) |
---|
| 1107 | y = rm - collector_r(j) |
---|
| 1108 | dx = collected_r(i+1) - collected_r(i) |
---|
| 1109 | dy = collector_r(j+1) - collector_r(j) |
---|
| 1110 | aa = x**2 + y**2 |
---|
| 1111 | bb = ( dx - x )**2 + y**2 |
---|
| 1112 | cc = x**2 + ( dy - y )**2 |
---|
| 1113 | dd = ( dx - x )**2 + ( dy - y )**2 |
---|
| 1114 | gg = aa + bb + cc + dd |
---|
| 1115 | |
---|
| 1116 | e = ( (gg-aa)*ef(i,j) + (gg-bb)*ef(i+1,j) + (gg-cc)*ef(i,j+1) + & |
---|
| 1117 | (gg-dd)*ef(i+1,j+1) ) / (3.0*gg) |
---|
| 1118 | ENDIF |
---|
| 1119 | |
---|
| 1120 | END SUBROUTINE collision_efficiency_rogers |
---|
| 1121 | |
---|
[825] | 1122 | END MODULE lpm_collision_kernels_mod |
---|