[1682] | 1 | !> @file average_3d_data.f90 |
---|
[2000] | 2 | !------------------------------------------------------------------------------! |
---|
[2696] | 3 | ! This file is part of the PALM model system. |
---|
[1036] | 4 | ! |
---|
[2000] | 5 | ! PALM is free software: you can redistribute it and/or modify it under the |
---|
| 6 | ! terms of the GNU General Public License as published by the Free Software |
---|
| 7 | ! Foundation, either version 3 of the License, or (at your option) any later |
---|
| 8 | ! version. |
---|
[1036] | 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 | ! |
---|
[4360] | 17 | ! Copyright 1997-2020 Leibniz Universitaet Hannover |
---|
[2000] | 18 | !------------------------------------------------------------------------------! |
---|
[1036] | 19 | ! |
---|
[484] | 20 | ! Current revisions: |
---|
[1] | 21 | ! ----------------- |
---|
[3589] | 22 | ! |
---|
| 23 | ! |
---|
| 24 | ! Former revisions: |
---|
| 25 | ! ----------------- |
---|
| 26 | ! $Id: average_3d_data.f90 4457 2020-03-11 14:20:43Z suehring $ |
---|
[4457] | 27 | ! use statement for exchange horiz added, |
---|
| 28 | ! bugfix for call of exchange horiz 2d |
---|
| 29 | ! |
---|
| 30 | ! 4360 2020-01-07 11:25:50Z suehring |
---|
[4331] | 31 | ! Move 2-m potential temperature output to diagnostic_output_quantities |
---|
| 32 | ! |
---|
| 33 | ! 4182 2019-08-22 15:20:23Z scharf |
---|
[4182] | 34 | ! Corrected "Former revisions" section |
---|
| 35 | ! |
---|
| 36 | ! 4048 2019-06-21 21:00:21Z knoop |
---|
[4048] | 37 | ! Moved tcm_3d_data_averaging to module_interface |
---|
| 38 | ! |
---|
| 39 | ! 4039 2019-06-18 10:32:41Z suehring |
---|
[4039] | 40 | ! Modularize diagnostic output |
---|
| 41 | ! |
---|
| 42 | ! 3994 2019-05-22 18:08:09Z suehring |
---|
[3994] | 43 | ! output of turbulence intensity added |
---|
| 44 | ! |
---|
| 45 | ! 3933 2019-04-25 12:33:20Z kanani |
---|
[3933] | 46 | ! Bugfix in CASE theta_2m*, removal of redundant code |
---|
| 47 | ! |
---|
| 48 | ! 3773 2019-03-01 08:56:57Z maronga |
---|
[3773] | 49 | ! Added output of theta_2m*_xy_av |
---|
| 50 | ! |
---|
| 51 | ! 3655 2019-01-07 16:51:22Z knoop |
---|
[3637] | 52 | ! Implementation of the PALM module interface |
---|
[3582] | 53 | ! |
---|
[4182] | 54 | ! Revision 1.1 2006/02/23 09:48:58 raasch |
---|
| 55 | ! Initial revision |
---|
| 56 | ! |
---|
| 57 | ! |
---|
[1] | 58 | ! Description: |
---|
| 59 | ! ------------ |
---|
[1682] | 60 | !> Time-averaging of 3d-data-arrays. |
---|
[1] | 61 | !------------------------------------------------------------------------------! |
---|
[1682] | 62 | SUBROUTINE average_3d_data |
---|
| 63 | |
---|
[1] | 64 | |
---|
| 65 | USE averaging |
---|
| 66 | |
---|
[1320] | 67 | USE control_parameters, & |
---|
[3637] | 68 | ONLY: average_count_3d, doav, doav_n, varnamelength |
---|
[1320] | 69 | |
---|
| 70 | USE cpulog, & |
---|
| 71 | ONLY: cpu_log, log_point |
---|
| 72 | |
---|
[4457] | 73 | USE exchange_horiz_mod, & |
---|
| 74 | ONLY: exchange_horiz_2d |
---|
| 75 | |
---|
[1320] | 76 | USE indices, & |
---|
[4457] | 77 | ONLY: nxl, nxlg, nxr, nxrg, nyn, nyng, nys, nysg, nzb, nzt |
---|
[1320] | 78 | |
---|
| 79 | USE kinds |
---|
| 80 | |
---|
[3637] | 81 | USE module_interface, & |
---|
| 82 | ONLY: module_interface_3d_data_averaging |
---|
[1320] | 83 | |
---|
[2696] | 84 | |
---|
[1691] | 85 | |
---|
[2007] | 86 | |
---|
[1] | 87 | IMPLICIT NONE |
---|
| 88 | |
---|
[3294] | 89 | INTEGER(iwp) :: i !< loop index |
---|
| 90 | INTEGER(iwp) :: ii !< loop index |
---|
| 91 | INTEGER(iwp) :: j !< loop index |
---|
| 92 | INTEGER(iwp) :: k !< loop index |
---|
[1] | 93 | |
---|
[2011] | 94 | CHARACTER (LEN=varnamelength) :: trimvar !< TRIM of output-variable string |
---|
[1] | 95 | |
---|
[2007] | 96 | |
---|
[1] | 97 | CALL cpu_log (log_point(35),'average_3d_data','start') |
---|
| 98 | |
---|
| 99 | ! |
---|
| 100 | !-- Check, if averaging is necessary |
---|
| 101 | IF ( average_count_3d <= 1 ) RETURN |
---|
| 102 | |
---|
| 103 | ! |
---|
| 104 | !-- Loop of all variables to be averaged. |
---|
| 105 | DO ii = 1, doav_n |
---|
| 106 | |
---|
[2007] | 107 | trimvar = TRIM( doav(ii) ) |
---|
| 108 | |
---|
| 109 | ! |
---|
[1] | 110 | !-- Store the array chosen on the temporary array. |
---|
[2007] | 111 | SELECT CASE ( trimvar ) |
---|
[1] | 112 | |
---|
| 113 | CASE ( 'e' ) |
---|
[3004] | 114 | IF ( ALLOCATED( e_av ) ) THEN |
---|
| 115 | DO i = nxlg, nxrg |
---|
| 116 | DO j = nysg, nyng |
---|
| 117 | DO k = nzb, nzt+1 |
---|
| 118 | e_av(k,j,i) = e_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 119 | ENDDO |
---|
[1] | 120 | ENDDO |
---|
| 121 | ENDDO |
---|
[3004] | 122 | ENDIF |
---|
[1] | 123 | |
---|
[2797] | 124 | CASE ( 'ghf*' ) |
---|
[3004] | 125 | IF ( ALLOCATED( ghf_av ) ) THEN |
---|
| 126 | DO i = nxl, nxr |
---|
| 127 | DO j = nys, nyn |
---|
| 128 | ghf_av(j,i) = ghf_av(j,i) & |
---|
| 129 | / REAL( average_count_3d, KIND=wp ) |
---|
| 130 | ENDDO |
---|
[2797] | 131 | ENDDO |
---|
[4457] | 132 | CALL exchange_horiz_2d( ghf_av ) |
---|
[3004] | 133 | ENDIF |
---|
[2797] | 134 | |
---|
[354] | 135 | CASE ( 'qsws*' ) |
---|
[3004] | 136 | IF ( ALLOCATED( qsws_av ) ) THEN |
---|
| 137 | DO i = nxlg, nxrg |
---|
| 138 | DO j = nysg, nyng |
---|
| 139 | qsws_av(j,i) = qsws_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 140 | ENDDO |
---|
[354] | 141 | ENDDO |
---|
[4457] | 142 | CALL exchange_horiz_2d( qsws_av ) |
---|
[3004] | 143 | ENDIF |
---|
[354] | 144 | |
---|
[3421] | 145 | CASE ( 'thetal' ) |
---|
[3004] | 146 | IF ( ALLOCATED( lpt_av ) ) THEN |
---|
| 147 | DO i = nxlg, nxrg |
---|
| 148 | DO j = nysg, nyng |
---|
| 149 | DO k = nzb, nzt+1 |
---|
| 150 | lpt_av(k,j,i) = lpt_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 151 | ENDDO |
---|
[771] | 152 | ENDDO |
---|
| 153 | ENDDO |
---|
[3004] | 154 | ENDIF |
---|
[771] | 155 | |
---|
[1] | 156 | CASE ( 'lwp*' ) |
---|
[3004] | 157 | IF ( ALLOCATED( lwp_av ) ) THEN |
---|
| 158 | DO i = nxlg, nxrg |
---|
| 159 | DO j = nysg, nyng |
---|
| 160 | lwp_av(j,i) = lwp_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 161 | ENDDO |
---|
[1] | 162 | ENDDO |
---|
[3004] | 163 | ENDIF |
---|
[1] | 164 | |
---|
[1691] | 165 | CASE ( 'ol*' ) |
---|
[3004] | 166 | IF ( ALLOCATED( ol_av ) ) THEN |
---|
| 167 | DO i = nxlg, nxrg |
---|
| 168 | DO j = nysg, nyng |
---|
| 169 | ol_av(j,i) = ol_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 170 | ENDDO |
---|
[1691] | 171 | ENDDO |
---|
[4457] | 172 | CALL exchange_horiz_2d( ol_av ) |
---|
[3004] | 173 | ENDIF |
---|
[1691] | 174 | |
---|
[1] | 175 | CASE ( 'p' ) |
---|
[3004] | 176 | IF ( ALLOCATED( p_av ) ) THEN |
---|
| 177 | DO i = nxlg, nxrg |
---|
| 178 | DO j = nysg, nyng |
---|
| 179 | DO k = nzb, nzt+1 |
---|
| 180 | p_av(k,j,i) = p_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 181 | ENDDO |
---|
[1] | 182 | ENDDO |
---|
| 183 | ENDDO |
---|
[3004] | 184 | ENDIF |
---|
[1] | 185 | |
---|
| 186 | CASE ( 'pc' ) |
---|
[3004] | 187 | IF ( ALLOCATED( pc_av ) ) THEN |
---|
| 188 | DO i = nxl, nxr |
---|
| 189 | DO j = nys, nyn |
---|
| 190 | DO k = nzb, nzt+1 |
---|
| 191 | pc_av(k,j,i) = pc_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 192 | ENDDO |
---|
[1] | 193 | ENDDO |
---|
| 194 | ENDDO |
---|
[3004] | 195 | ENDIF |
---|
[1] | 196 | |
---|
| 197 | CASE ( 'pr' ) |
---|
[3004] | 198 | IF ( ALLOCATED( pr_av ) ) THEN |
---|
| 199 | DO i = nxl, nxr |
---|
| 200 | DO j = nys, nyn |
---|
| 201 | DO k = nzb, nzt+1 |
---|
| 202 | pr_av(k,j,i) = pr_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 203 | ENDDO |
---|
[1] | 204 | ENDDO |
---|
| 205 | ENDDO |
---|
[3004] | 206 | ENDIF |
---|
[1] | 207 | |
---|
[3421] | 208 | CASE ( 'theta' ) |
---|
[3004] | 209 | IF ( ALLOCATED( pt_av ) ) THEN |
---|
| 210 | DO i = nxlg, nxrg |
---|
| 211 | DO j = nysg, nyng |
---|
| 212 | DO k = nzb, nzt+1 |
---|
| 213 | pt_av(k,j,i) = pt_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 214 | ENDDO |
---|
[1] | 215 | ENDDO |
---|
| 216 | ENDDO |
---|
[3004] | 217 | ENDIF |
---|
[1] | 218 | |
---|
| 219 | CASE ( 'q' ) |
---|
[3004] | 220 | IF ( ALLOCATED( q_av ) ) THEN |
---|
| 221 | DO i = nxlg, nxrg |
---|
| 222 | DO j = nysg, nyng |
---|
| 223 | DO k = nzb, nzt+1 |
---|
| 224 | q_av(k,j,i) = q_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 225 | ENDDO |
---|
[1] | 226 | ENDDO |
---|
| 227 | ENDDO |
---|
[3004] | 228 | ENDIF |
---|
[367] | 229 | |
---|
[1] | 230 | CASE ( 'ql' ) |
---|
[3004] | 231 | IF ( ALLOCATED( ql_av ) ) THEN |
---|
| 232 | DO i = nxlg, nxrg |
---|
| 233 | DO j = nysg, nyng |
---|
| 234 | DO k = nzb, nzt+1 |
---|
| 235 | ql_av(k,j,i) = ql_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 236 | ENDDO |
---|
[1] | 237 | ENDDO |
---|
| 238 | ENDDO |
---|
[3004] | 239 | ENDIF |
---|
[1] | 240 | |
---|
| 241 | CASE ( 'ql_c' ) |
---|
[3004] | 242 | IF ( ALLOCATED( ql_c_av ) ) THEN |
---|
| 243 | DO i = nxlg, nxrg |
---|
| 244 | DO j = nysg, nyng |
---|
| 245 | DO k = nzb, nzt+1 |
---|
| 246 | ql_c_av(k,j,i) = ql_c_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 247 | ENDDO |
---|
[1] | 248 | ENDDO |
---|
| 249 | ENDDO |
---|
[3004] | 250 | ENDIF |
---|
[1] | 251 | |
---|
| 252 | CASE ( 'ql_v' ) |
---|
[3004] | 253 | IF ( ALLOCATED( ql_v_av ) ) THEN |
---|
| 254 | DO i = nxlg, nxrg |
---|
| 255 | DO j = nysg, nyng |
---|
| 256 | DO k = nzb, nzt+1 |
---|
| 257 | ql_v_av(k,j,i) = ql_v_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 258 | ENDDO |
---|
[1] | 259 | ENDDO |
---|
| 260 | ENDDO |
---|
[3004] | 261 | ENDIF |
---|
[1] | 262 | |
---|
| 263 | CASE ( 'ql_vp' ) |
---|
[3004] | 264 | IF ( ALLOCATED( ql_vp_av ) ) THEN |
---|
| 265 | DO i = nxlg, nxrg |
---|
| 266 | DO j = nysg, nyng |
---|
| 267 | DO k = nzb, nzt+1 |
---|
| 268 | ql_vp_av(k,j,i) = ql_vp_av(k,j,i) / & |
---|
| 269 | REAL( average_count_3d, KIND=wp ) |
---|
| 270 | ENDDO |
---|
[1] | 271 | ENDDO |
---|
| 272 | ENDDO |
---|
[3004] | 273 | ENDIF |
---|
[1] | 274 | |
---|
| 275 | CASE ( 'qv' ) |
---|
[3004] | 276 | IF ( ALLOCATED( qv_av ) ) THEN |
---|
| 277 | DO i = nxlg, nxrg |
---|
| 278 | DO j = nysg, nyng |
---|
| 279 | DO k = nzb, nzt+1 |
---|
| 280 | qv_av(k,j,i) = qv_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 281 | ENDDO |
---|
[1] | 282 | ENDDO |
---|
| 283 | ENDDO |
---|
[3004] | 284 | ENDIF |
---|
[367] | 285 | |
---|
[2735] | 286 | CASE ( 'r_a*' ) |
---|
[3004] | 287 | IF ( ALLOCATED( r_a_av ) ) THEN |
---|
| 288 | DO i = nxlg, nxrg |
---|
| 289 | DO j = nysg, nyng |
---|
| 290 | r_a_av(j,i) = r_a_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 291 | ENDDO |
---|
[2735] | 292 | ENDDO |
---|
[4457] | 293 | CALL exchange_horiz_2d( r_a_av ) |
---|
[3004] | 294 | ENDIF |
---|
[2735] | 295 | |
---|
[1] | 296 | CASE ( 's' ) |
---|
[3004] | 297 | IF ( ALLOCATED( s_av ) ) THEN |
---|
| 298 | DO i = nxlg, nxrg |
---|
| 299 | DO j = nysg, nyng |
---|
| 300 | DO k = nzb, nzt+1 |
---|
| 301 | s_av(k,j,i) = s_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 302 | ENDDO |
---|
[1] | 303 | ENDDO |
---|
| 304 | ENDDO |
---|
[3004] | 305 | ENDIF |
---|
[367] | 306 | |
---|
[354] | 307 | CASE ( 'shf*' ) |
---|
[3004] | 308 | IF ( ALLOCATED( shf_av ) ) THEN |
---|
| 309 | DO i = nxlg, nxrg |
---|
| 310 | DO j = nysg, nyng |
---|
| 311 | shf_av(j,i) = shf_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 312 | ENDDO |
---|
[354] | 313 | ENDDO |
---|
[4457] | 314 | CALL exchange_horiz_2d( shf_av ) |
---|
[3004] | 315 | ENDIF |
---|
[367] | 316 | |
---|
[1960] | 317 | CASE ( 'ssws*' ) |
---|
[3004] | 318 | IF ( ALLOCATED( ssws_av ) ) THEN |
---|
| 319 | DO i = nxlg, nxrg |
---|
| 320 | DO j = nysg, nyng |
---|
| 321 | ssws_av(j,i) = ssws_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 322 | ENDDO |
---|
[1960] | 323 | ENDDO |
---|
[4457] | 324 | CALL exchange_horiz_2d( ssws_av ) |
---|
[3004] | 325 | ENDIF |
---|
[1960] | 326 | |
---|
[1] | 327 | CASE ( 't*' ) |
---|
[3004] | 328 | IF ( ALLOCATED( ts_av ) ) THEN |
---|
| 329 | DO i = nxlg, nxrg |
---|
| 330 | DO j = nysg, nyng |
---|
| 331 | ts_av(j,i) = ts_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 332 | ENDDO |
---|
[1] | 333 | ENDDO |
---|
[4457] | 334 | CALL exchange_horiz_2d( ts_av ) |
---|
[3004] | 335 | ENDIF |
---|
[1] | 336 | |
---|
[2742] | 337 | CASE ( 'tsurf*' ) |
---|
[3004] | 338 | IF ( ALLOCATED( tsurf_av ) ) THEN |
---|
| 339 | DO i = nxlg, nxrg |
---|
| 340 | DO j = nysg, nyng |
---|
| 341 | tsurf_av(j,i) = tsurf_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 342 | ENDDO |
---|
[2742] | 343 | ENDDO |
---|
[4457] | 344 | CALL exchange_horiz_2d( tsurf_av ) |
---|
[3004] | 345 | ENDIF |
---|
[2742] | 346 | |
---|
[1] | 347 | CASE ( 'u' ) |
---|
[3004] | 348 | IF ( ALLOCATED( u_av ) ) THEN |
---|
| 349 | DO i = nxlg, nxrg |
---|
| 350 | DO j = nysg, nyng |
---|
| 351 | DO k = nzb, nzt+1 |
---|
| 352 | u_av(k,j,i) = u_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 353 | ENDDO |
---|
[1] | 354 | ENDDO |
---|
| 355 | ENDDO |
---|
[3004] | 356 | ENDIF |
---|
[1] | 357 | |
---|
[3421] | 358 | CASE ( 'us*' ) |
---|
[3004] | 359 | IF ( ALLOCATED( us_av ) ) THEN |
---|
| 360 | DO i = nxlg, nxrg |
---|
| 361 | DO j = nysg, nyng |
---|
| 362 | us_av(j,i) = us_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 363 | ENDDO |
---|
[1] | 364 | ENDDO |
---|
[4457] | 365 | CALL exchange_horiz_2d( us_av ) |
---|
[3004] | 366 | ENDIF |
---|
[1] | 367 | |
---|
| 368 | CASE ( 'v' ) |
---|
[3004] | 369 | IF ( ALLOCATED( v_av ) ) THEN |
---|
| 370 | DO i = nxlg, nxrg |
---|
| 371 | DO j = nysg, nyng |
---|
| 372 | DO k = nzb, nzt+1 |
---|
| 373 | v_av(k,j,i) = v_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 374 | ENDDO |
---|
[1] | 375 | ENDDO |
---|
| 376 | ENDDO |
---|
[3004] | 377 | ENDIF |
---|
[1] | 378 | |
---|
[3421] | 379 | CASE ( 'thetav' ) |
---|
[3004] | 380 | IF ( ALLOCATED( vpt_av ) ) THEN |
---|
| 381 | DO i = nxlg, nxrg |
---|
| 382 | DO j = nysg, nyng |
---|
| 383 | DO k = nzb, nzt+1 |
---|
| 384 | vpt_av(k,j,i) = vpt_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 385 | ENDDO |
---|
[1] | 386 | ENDDO |
---|
| 387 | ENDDO |
---|
[3004] | 388 | ENDIF |
---|
[1] | 389 | |
---|
| 390 | CASE ( 'w' ) |
---|
[3004] | 391 | IF ( ALLOCATED( w_av ) ) THEN |
---|
| 392 | DO i = nxlg, nxrg |
---|
| 393 | DO j = nysg, nyng |
---|
| 394 | DO k = nzb, nzt+1 |
---|
| 395 | w_av(k,j,i) = w_av(k,j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 396 | ENDDO |
---|
[1] | 397 | ENDDO |
---|
| 398 | ENDDO |
---|
[3004] | 399 | ENDIF |
---|
[1] | 400 | |
---|
[72] | 401 | CASE ( 'z0*' ) |
---|
[3004] | 402 | IF ( ALLOCATED( z0_av ) ) THEN |
---|
| 403 | DO i = nxlg, nxrg |
---|
| 404 | DO j = nysg, nyng |
---|
| 405 | z0_av(j,i) = z0_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 406 | ENDDO |
---|
[72] | 407 | ENDDO |
---|
[4457] | 408 | CALL exchange_horiz_2d( z0_av ) |
---|
[3004] | 409 | ENDIF |
---|
[72] | 410 | |
---|
[978] | 411 | CASE ( 'z0h*' ) |
---|
[3004] | 412 | IF ( ALLOCATED( z0h_av ) ) THEN |
---|
| 413 | DO i = nxlg, nxrg |
---|
| 414 | DO j = nysg, nyng |
---|
| 415 | z0h_av(j,i) = z0h_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 416 | ENDDO |
---|
[978] | 417 | ENDDO |
---|
[4457] | 418 | CALL exchange_horiz_2d( z0h_av ) |
---|
[3004] | 419 | ENDIF |
---|
| 420 | |
---|
| 421 | CASE ( 'z0q*' ) |
---|
| 422 | IF ( ALLOCATED( z0q_av ) ) THEN |
---|
| 423 | DO i = nxlg, nxrg |
---|
| 424 | DO j = nysg, nyng |
---|
| 425 | z0q_av(j,i) = z0q_av(j,i) / REAL( average_count_3d, KIND=wp ) |
---|
| 426 | ENDDO |
---|
| 427 | ENDDO |
---|
[4457] | 428 | CALL exchange_horiz_2d( z0q_av ) |
---|
[3004] | 429 | ENDIF |
---|
| 430 | |
---|
[1] | 431 | CASE DEFAULT |
---|
[1976] | 432 | ! |
---|
[3637] | 433 | !-- Averaging of data from all other modules |
---|
| 434 | CALL module_interface_3d_data_averaging( 'average', trimvar ) |
---|
[1] | 435 | |
---|
| 436 | END SELECT |
---|
| 437 | |
---|
| 438 | ENDDO |
---|
| 439 | |
---|
| 440 | ! |
---|
| 441 | !-- Reset the counter |
---|
| 442 | average_count_3d = 0.0 |
---|
| 443 | |
---|
[1318] | 444 | CALL cpu_log( log_point(35), 'average_3d_data', 'stop' ) |
---|
[1] | 445 | |
---|
| 446 | |
---|
| 447 | END SUBROUTINE average_3d_data |
---|