Changeset 1786
- Timestamp:
- Mar 8, 2016 5:49:27 AM (9 years ago)
- Location:
- palm/trunk/SOURCE
- Files:
-
- 12 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/Makefile
r1784 r1786 20 20 # Current revisions: 21 21 # ------------------ 22 # 22 # rename calc_spectra to spectrum + modularization of spectrum 23 23 # 24 24 # Former revisions: … … 231 231 advec_w_pw.f90 advec_w_up.f90 average_3d_data.f90 boundary_conds.f90 \ 232 232 buoyancy.f90 calc_liquid_water_content.f90 calc_mean_profile.f90 \ 233 calc_precipitation.f90 calc_radiation.f90 calc_spectra.f90\233 calc_precipitation.f90 calc_radiation.f90 \ 234 234 check_for_restart.f90 check_open.f90 check_parameters.f90 \ 235 235 close_file.f90 compute_vpt.f90 coriolis.f90 cpulog.f90 \ … … 268 268 random_function.f90 random_gauss.f90 random_generator_parallel.f90 \ 269 269 read_3d_binary.f90 read_var_list.f90 run_control.f90 \ 270 set_slicer_attributes_dvrp.f90 singleton.f90 sor.f90 \270 set_slicer_attributes_dvrp.f90 singleton.f90 sor.f90 spectrum.f90 \ 271 271 subsidence.f90 sum_up_3d_data.f90 \ 272 272 surface_coupler.f90 surface_layer_fluxes.f90 swap_timelevel.f90 temperton_fft.f90 \ … … 336 336 calc_precipitation.o: modules.o mod_kinds.o 337 337 calc_radiation.o: modules.o mod_kinds.o 338 calc_spectra.o: modules.o cpulog.o fft_xy.o mod_kinds.o339 338 check_for_restart.o: modules.o mod_kinds.o 340 339 check_open.o: modules.o mod_kinds.o mod_particle_attributes.o netcdf_interface.o … … 355 354 data_output_ptseries.o: modules.o cpulog.o mod_kinds.o \ 356 355 netcdf_interface.o mod_particle_attributes.o 357 data_output_spectra.o: modules.o cpulog.o mod_kinds.o netcdf_interface.o 356 data_output_spectra.o: modules.o cpulog.o mod_kinds.o netcdf_interface.o \ 357 spectrum.o 358 358 data_output_tseries.o: modules.o cpulog.o mod_kinds.o netcdf_interface.o 359 359 data_output_2d.o: modules.o cpulog.o mod_kinds.o mod_particle_attributes.o\ … … 378 378 global_min_max.o: modules.o mod_kinds.o 379 379 header.o: modules.o cpulog.o mod_kinds.o netcdf_interface.o land_surface_model.o\ 380 plant_canopy_model.o pmc_interface.o radiation_model.o subsidence.o 380 plant_canopy_model.o pmc_interface.o radiation_model.o spectrum.o \ 381 subsidence.o 381 382 impact_of_latent_heat.o: modules.o mod_kinds.o 382 383 inflow_turbulence.o: modules.o cpulog.o mod_kinds.o … … 440 441 mod_kinds.o: mod_kinds.f90 441 442 mod_particle_attributes.o: mod_particle_attributes.f90 mod_kinds.o 442 netcdf_interface.o: netcdf_interface.f90 modules.o mod_kinds.o land_surface_model.o 443 netcdf_interface.o: netcdf_interface.f90 modules.o mod_kinds.o \ 444 land_surface_model.o spectrum.o 443 445 nudging.o: modules.o cpulog.o mod_kinds.o 444 package_parin.o: modules.o mod_kinds.o land_surface_model.o \445 plant_canopy_model.o radiation_model.o446 package_parin.o: modules.o mod_kinds.o land_surface_model.o \ 447 plant_canopy_model.o radiation_model.o spectrum.o 446 448 palm.o: modules.o cpulog.o ls_forcing.o mod_kinds.o nudging.o\ 447 449 pmc_interface.o surface_layer_fluxes.o … … 483 485 singleton.o: mod_kinds.o singleton.f90 484 486 sor.o: modules.o mod_kinds.o 487 spectrum.o: spectrum.f90 modules.o mod_kinds.o cpulog.o fft_xy.o 485 488 subsidence.o: modules.o mod_kinds.o 486 489 sum_up_3d_data.o: modules.o cpulog.o mod_kinds.o land_surface_model.o\ … … 495 498 ls_forcing.o mod_kinds.o nudging.o pmc_interface.o production_e.o \ 496 499 prognostic_equations.o progress_bar.o radiation_model.o \ 497 user_actions.o surface_layer_fluxes.o500 spectrum.o user_actions.o surface_layer_fluxes.o 498 501 time_to_string.o: mod_kinds.o 499 502 timestep.o: modules.o cpulog.o mod_kinds.o … … 528 531 user_parin.o: modules.o mod_kinds.o user_module.o 529 532 user_read_restart_data.o: modules.o mod_kinds.o user_module.o 530 user_spectra.o: modules.o mod_kinds.o user_module.o533 user_spectra.o: modules.o mod_kinds.o spectrum.o user_module.o 531 534 user_statistics.o: modules.o mod_kinds.o netcdf_interface.o user_module.o 532 535 wall_fluxes.o: modules.o mod_kinds.o -
palm/trunk/SOURCE/check_parameters.f90
r1784 r1786 19 19 ! Current revisions: 20 20 ! ----------------- 21 ! 21 ! cpp-direktives for spectra removed, check of spectra level removed 22 22 ! 23 23 ! Former revisions: … … 326 326 USE profil_parameter 327 327 USE radiation_model_mod 328 USE spectrum329 328 USE statistics 330 329 USE subsidence_mod … … 3752 3751 END SELECT 3753 3752 3754 #if defined( __spectra )3755 !3756 !-- Check the number of spectra level to be output3757 i = 13758 DO WHILE ( comp_spectra_level(i) /= 999999 .AND. i <= 100 )3759 i = i + 13760 ENDDO3761 i = i - 13762 IF ( i == 0 ) THEN3763 WRITE( message_string, * ) 'no spectra levels given'3764 CALL message( 'check_parameters', 'PA0019', 1, 2, 0, 6, 0 )3765 ENDIF3766 #endif3767 3768 3753 ! 3769 3754 !-- Check mask conditions -
palm/trunk/SOURCE/data_output_spectra.f90
r1784 r1786 19 19 ! Current revisions: 20 20 ! ------------------ 21 ! 21 ! cpp-directives for spectra removed, immediate return if no spectra levels are 22 ! given 22 23 ! 23 24 ! Former revisions: … … 73 74 74 75 #if defined( __netcdf ) 75 #if defined( __spectra )76 77 76 USE control_parameters, & 78 77 ONLY: average_count_sp, averaging_interval_sp, dosp_time_count, & … … 93 92 94 93 USE spectrum, & 95 ONLY: data_output_sp, spectra_direction94 ONLY: comp_spectra_level, data_output_sp, spectra_direction 96 95 97 96 USE statistics, & … … 110 109 111 110 CALL cpu_log( log_point(31), 'data_output_spectra', 'start' ) 111 112 ! 113 !-- Check if user gave any levels for spectra to be calculated 114 IF ( comp_spectra_level(1) == 999999 ) RETURN 112 115 113 116 ! … … 206 209 207 210 #endif 208 #endif209 211 END SUBROUTINE data_output_spectra 210 212 … … 299 301 300 302 301 #if defined( __spectra )302 303 !------------------------------------------------------------------------------! 303 304 ! Description: … … 714 715 715 716 END SUBROUTINE data_output_spectra_y 716 #endif -
palm/trunk/SOURCE/header.f90
r1784 r1786 19 19 ! Current revisions: 20 20 ! ----------------- 21 ! 21 ! cpp-direktives for spectra removed 22 22 ! 23 23 ! Former revisions: … … 1733 1733 #endif 1734 1734 1735 #if defined( __spectra )1736 1735 ! 1737 1736 !-- Spectra output … … 1753 1752 averaging_interval_sp, dt_averaging_input_pr 1754 1753 ENDIF 1755 #endif1756 1754 1757 1755 WRITE ( io, 99 ) … … 2234 2232 367 FORMAT (' Polygon reduction for topography: cluster_size = ', I1) 2235 2233 #endif 2236 #if defined( __spectra )2237 2234 370 FORMAT (' Spectra:') 2238 2235 371 FORMAT (' Output every ',F7.1,' s'/) … … 2253 2250 ' Profiles for the time averaging are taken every ', & 2254 2251 F6.1,' s') 2255 #endif2256 2252 400 FORMAT (//' Physical quantities:'/ & 2257 2253 ' -------------------'/) -
palm/trunk/SOURCE/modules.f90
r1784 r1786 19 19 ! Current revisions: 20 20 ! ------------------ 21 ! 21 ! module spectrum moved to new separate module 22 22 ! 23 23 ! Former revisions: … … 1277 1277 END MODULE profil_parameter 1278 1278 1279 1280 !------------------------------------------------------------------------------!1281 ! Description:1282 ! ------------1283 !> Definition of quantities used for computing spectra.1284 !------------------------------------------------------------------------------!1285 MODULE spectrum1286 1287 USE kinds1288 1289 CHARACTER (LEN=6), DIMENSION(1:5) :: header_char = (/ 'PS(u) ', 'PS(v) ',&1290 'PS(w) ', 'PS(pt)', 'PS(q) ' /)1291 CHARACTER (LEN=2), DIMENSION(10) :: spectra_direction = 'x'1292 CHARACTER (LEN=10), DIMENSION(10) :: data_output_sp = ' '1293 CHARACTER (LEN=25), DIMENSION(1:5) :: utext_char = &1294 (/ '-power spectrum of u ', &1295 '-power spectrum of v ', &1296 '-power spectrum of w ', &1297 '-power spectrum of ^1185 ', &1298 '-power spectrum of q ' /)1299 CHARACTER (LEN=39), DIMENSION(1:5) :: ytext_char = &1300 (/ 'k ^2236 ^2566^2569<u(k) in m>2s>->2 ', &1301 'k ^2236 ^2566^2569<v(k) in m>2s>->2 ', &1302 'k ^2236 ^2566^2569<w(k) in m>2s>->2 ', &1303 'k ^2236 ^2566^2569<^1185(k) in m>2s>->2', &1304 'k ^2236 ^2566^2569<q(k) in m>2s>->2 ' /)1305 1306 INTEGER(iwp) :: klist_x = 0, klist_y = 0, n_sp_x = 0, n_sp_y = 01307 1308 INTEGER(iwp) :: comp_spectra_level(100) = 999999, &1309 lstyles(100) = (/ 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1310 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1311 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1312 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1313 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1314 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1315 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1316 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1317 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, &1318 0, 7, 3, 10, 1, 4, 9, 2, 6, 8 /), &1319 plot_spectra_level(100) = 9999991320 1321 REAL(wp) :: time_to_start_sp = 0.0_wp1322 1323 SAVE1324 1325 END MODULE spectrum1326 1327 1328 1279 !------------------------------------------------------------------------------! 1329 1280 ! Description: … … 1365 1316 1366 1317 1318 1367 1319 !------------------------------------------------------------------------------! 1368 1320 ! Description: -
palm/trunk/SOURCE/netcdf_interface.f90
r1784 r1786 19 19 ! Current revisions: 20 20 ! ------------------ 21 ! 21 ! Bugfix: id_var_time_sp made public 22 22 ! 23 23 ! Former revisions: … … 296 296 id_var_dopr, id_var_dopts, id_var_dospx, id_var_dospy, & 297 297 id_var_dots, id_var_do2d, id_var_do3d, id_var_norm_dopr, & 298 id_var_time_mask, id_var_time_pr, id_var_time_pts, id_var_time_ts, & 299 id_var_time_xy, id_var_time_xz, id_var_time_yz,id_var_time_3d, & 300 nc_stat, netcdf_data_format, netcdf_data_format_string, & 301 netcdf_deflate, netcdf_precision, output_for_t0 298 id_var_time_mask, id_var_time_pr, id_var_time_pts, id_var_time_sp, & 299 id_var_time_ts, id_var_time_xy, id_var_time_xz, id_var_time_yz, & 300 id_var_time_3d, nc_stat, netcdf_data_format, & 301 netcdf_data_format_string, netcdf_deflate, netcdf_precision, & 302 output_for_t0 302 303 303 304 SAVE -
palm/trunk/SOURCE/package_parin.f90
r1758 r1786 19 19 ! Current revisions: 20 20 ! ----------------- 21 ! 21 ! cpp-direktives for spectra removed 22 22 ! 23 23 ! Former revisions: … … 318 318 30 CONTINUE 319 319 320 321 #if defined( __spectra )322 320 REWIND ( 11 ) 323 321 line = ' ' … … 337 335 338 336 40 CONTINUE 339 #endif340 337 341 338 ! -
palm/trunk/SOURCE/pmc_client.f90
r1784 r1786 20 20 ! Current revisions: 21 21 ! ------------------ 22 ! 22 ! change in client-server data transfer: server now gets data from client 23 ! instead that client put's it to the server 23 24 ! 24 25 ! Former revisions: … … 361 362 do i=1,me%inter_npes 362 363 aPE => me%PEs(i) 363 ar => aPE%array_list(next_array_in_list) !actual array is last array in list364 ar => aPE%array_list(next_array_in_list) 364 365 ar%NrDims = NrDims 365 366 ar%A_dim = dims … … 407 408 IMPLICIT none 408 409 409 INTEGER :: i, ierr, j 410 !-- naming convention: appending _sc -> server to client transfer 411 !-- _cs -> client to server transfer 412 !-- Recv -> server to client transfer 413 !-- Send -> client to server transfer 414 415 INTEGER :: i, istat, ierr, j 416 INTEGER,PARAMETER :: NoINdex=-1 417 INTEGER :: rcount 410 418 INTEGER :: arlen, myIndex, tag 411 419 INTEGER(idp) :: bufsize ! Size of MPI data Window 412 420 TYPE(PeDef),POINTER :: aPE 413 421 TYPE(ArrayDef),POINTER :: ar 422 INTEGER,DIMENSION(1024) :: req 414 423 character(len=DA_Namelen) :: myName 415 424 Type(c_ptr) :: base_ptr 416 REAL(kind=wp),DIMENSION(:),POINTER :: base_array 425 REAL(kind=wp),DIMENSION(:),POINTER,save :: base_array_sc !Base array 426 REAL(kind=wp),DIMENSION(:),POINTER,save :: base_array_cs !Base array 417 427 INTEGER(KIND=MPI_ADDRESS_KIND) :: WinSize 418 428 … … 420 430 bufsize = 8 421 431 422 ! First stride, Compute size and set index 432 !-- Server to client direction 433 434 !-- First stride, Compute size and set index 423 435 424 436 do i=1,me%inter_npes … … 433 445 CALL MPI_Recv (myIndex, 1, MPI_INTEGER, i-1, tag, me%inter_comm, MPI_STATUS_IGNORE, ierr) 434 446 435 if(ar%NrDims == 3) then ! PALM has k in first dimension447 if(ar%NrDims == 3) then 436 448 bufsize = max(bufsize,ar%A_dim(1)*ar%A_dim(2)*ar%A_dim(3)) ! determine max, because client buffer is allocated only once 437 449 else 438 450 bufsize = max(bufsize,ar%A_dim(1)*ar%A_dim(2)) 439 451 end if 440 ar%BufIndex = myIndex 441 end do 452 ar%RecvIndex = myIndex 453 454 end do 442 455 end do 443 456 444 ! Create RMA (One Sided Communication) window for data buffer 445 446 CALL PMC_Alloc_mem (base_array, bufsize, base_ptr) 447 me%TotalBufferSize = bufsize*wp !Total buffer size in Byte 448 449 WinSize = me%TotalBufferSize 450 ! write(9,'(a,8i7)') 'PMC_S_SetInd_and_Mem ',m_model_rank,me%inter_npes,WinSize,ar%A_dim 451 CALL MPI_Win_create (base_array, WinSize, wp, MPI_INFO_NULL, me%intra_comm, me%BufWin, ierr); 452 CALL MPI_Win_fence (0, me%BufWin, ierr); ! Open Window to set data 453 CALL MPI_Barrier(me%intra_comm, ierr) 457 458 !-- Create RMA (One Sided Communication) data buffer 459 !-- The buffer for MPI_Get can be PE local, i.e. it can but must not be part of the MPI RMA window 460 461 CALL PMC_Alloc_mem (base_array_sc, bufsize, base_ptr) 462 me%TotalBufferSize = bufsize*wp ! Total buffer size in Byte 463 464 !-- Second stride, Set Buffer pointer 454 465 455 466 do i=1,me%inter_npes … … 458 469 do j=1,aPE%Nr_arrays 459 470 ar => aPE%array_list(j) 460 ar%SendBuf = base_ptr 471 ar%RecvBuf = base_ptr 472 end do 473 end do 474 475 !-- Client to server direction 476 477 myIndex = 1 478 rCount = 0 479 bufsize = 8 480 481 do i=1,me%inter_npes 482 aPE => me%PEs(i) 483 tag = 300 484 do j=1,aPE%Nr_arrays 485 ar => aPE%array_list(j) 486 if(ar%NrDims == 2) then 487 arlen = aPE%NrEle ! 2D 488 else if(ar%NrDims == 3) then 489 arlen = aPE%NrEle*ar%A_dim(1) ! 3D 490 end if 491 492 tag = tag+1 493 rCount = rCount+1 494 if(aPE%NrEle > 0) then 495 CALL MPI_Isend (myIndex, 1, MPI_INTEGER, i-1, tag, me%inter_comm, req(rCount),ierr) 496 ar%SendIndex = myIndex 497 else 498 CALL MPI_Isend (NoIndex, 1, MPI_INTEGER, i-1, tag, me%inter_comm, req(rCount),ierr) 499 ar%SendIndex = NoIndex 500 end if 501 502 if(rCount == 1024) then ! Maximum of 1024 outstanding requests 503 CALL MPI_Waitall (rCount, req, MPI_STATUSES_IGNORE, ierr) 504 rCount = 0; 505 end if 506 507 if(aPE%NrEle > 0) then 508 ar%SendSize = arlen 509 myIndex = myIndex+arlen 510 bufsize = bufsize+arlen 511 end if 512 end do 513 if(rCount > 0) then ! Wait for all send completed 514 CALL MPI_Waitall (rCount, req, MPI_STATUSES_IGNORE, ierr) 515 end if 516 end do 517 518 !-- Create RMA (One Sided Communication) window for data buffer client to server transfer 519 !-- The buffer of MPI_Get (counter part of transfer) can be PE-local, i.e. it can but must not be part of the MPI RMA window 520 !-- Only one RMA window is required to prepare the data for server -> client transfer on the server side and 521 !-- for client -> server transfer on the client side 522 523 CALL PMC_Alloc_mem (base_array_cs, bufsize) 524 me%TotalBufferSize = bufsize*wp !Total buffer size in Byte 525 526 WinSize = me%TotalBufferSize 527 CALL MPI_Win_create (base_array_cs, WinSize, wp, MPI_INFO_NULL, me%intra_comm, me%win_server_client, ierr); 528 CALL MPI_Win_fence (0, me%win_server_client, ierr); ! Open Window to set data 529 CALL MPI_Barrier(me%intra_comm, ierr) 530 531 !-- Second stride, Set Buffer pointer 532 533 do i=1,me%inter_npes 534 aPE => me%PEs(i) 535 536 do j=1,aPE%Nr_arrays 537 ar => aPE%array_list(j) 538 if(aPE%NrEle > 0) then 539 ar%SendBuf = c_loc(base_array_cs(ar%SendIndex)) 540 if(ar%SendIndex+ar%SendSize > bufsize) then 541 write(0,'(a,i4,4i7,1x,a)') 'Client Buffer too small ',i,ar%SendIndex,ar%SendSize,ar%SendIndex+ar%SendSize,bufsize,trim(ar%name) 542 CALL MPI_Abort (MPI_COMM_WORLD, istat, ierr) 543 end if 544 end if 461 545 end do 462 546 end do … … 504 588 505 589 buf_shape(1) = nr 506 CALL c_f_pointer(ar% SendBuf, buf, buf_shape)590 CALL c_f_pointer(ar%RecvBuf, buf, buf_shape) 507 591 ! 508 592 !-- MPI passive target RMA 509 593 if(nr > 0) then 510 target_disp = (ar% BufIndex-1)511 CALL MPI_Win_lock (MPI_LOCK_SHARED , ip-1, 0, me% BufWin, ierr)512 CALL MPI_Get (buf, nr, MPI_REAL, ip-1, target_disp, nr, MPI_REAL, me% BufWin, ierr)513 CALL MPI_Win_unlock (ip-1, me% BufWin, ierr)594 target_disp = (ar%RecvIndex-1) 595 CALL MPI_Win_lock (MPI_LOCK_SHARED , ip-1, 0, me%win_server_client, ierr) 596 CALL MPI_Get (buf, nr, MPI_REAL, ip-1, target_disp, nr, MPI_REAL, me%win_server_client, ierr) 597 CALL MPI_Win_unlock (ip-1, me%win_server_client, ierr) 514 598 end if 515 599 … … 555 639 INTEGER(kind=MPI_ADDRESS_KIND) :: target_disp 556 640 641 t1 = PMC_Time() 642 CALL MPI_Barrier(me%intra_comm, ierr) ! Wait for empty buffer 643 t2 = PMC_Time() 644 if(present(WaitTime)) WaitTime = t2-t1 557 645 558 646 do ip=1,me%inter_npes … … 561 649 do j=1,aPE%Nr_arrays 562 650 ar => aPE%array_list(j) 651 myIndex=1 563 652 if(ar%NrDims == 2) then 564 nr = aPE%NrEle 565 else if(ar%NrDims == 3) then 566 nr = aPE%NrEle*ar%A_dim(1) 567 end if 568 569 buf_shape(1) = nr 570 CALL c_f_pointer(ar%SendBuf, buf, buf_shape) 571 572 myIndex = 1 573 if(ar%NrDims == 2) then 653 buf_shape(1) = aPE%NrEle 654 CALL c_f_pointer(ar%SendBuf, buf, buf_shape) 574 655 CALL c_f_pointer(ar%data, data_2d, ar%A_dim(1:2)) 575 656 do ij=1,aPE%NrEle … … 578 659 end do 579 660 else if(ar%NrDims == 3) then 661 buf_shape(1) = aPE%NrEle*ar%A_dim(1) 662 CALL c_f_pointer(ar%SendBuf, buf, buf_shape) 580 663 CALL c_f_pointer(ar%data, data_3d, ar%A_dim(1:3)) 581 664 do ij=1,aPE%NrEle … … 584 667 end do 585 668 end if 586 !587 !-- MPI passiv target RMA588 if(nr > 0) then589 target_disp = (ar%BufIndex-1)590 CALL MPI_Win_lock (MPI_LOCK_SHARED , ip-1, 0, me%BufWin, ierr)591 CALL MPI_Put (buf, nr, MPI_REAL, ip-1, target_disp, nr, MPI_REAL, me%BufWin, ierr)592 CALL MPI_Win_unlock (ip-1, me%BufWin, ierr)593 end if594 595 669 end do 596 670 end do 597 671 598 672 599 t1 = PMC_Time() 600 CALL MPI_Barrier(me%intra_comm, ierr) ! Wait for server to fill buffer 601 t2 = PMC_Time() 602 if(present(WaitTime)) WaitTime = t2-t1 603 604 CALL MPI_Barrier(me%intra_comm, ierr) ! Wait for buffer is filled 605 673 ! CALL MPI_Win_fence (0, me%win_server_client, ierr) ! Fence might do it, test later 674 CALL MPI_Barrier(me%intra_comm, ierr) ! buffer is filled 606 675 607 676 return -
palm/trunk/SOURCE/pmc_general.f90
r1780 r1786 20 20 ! Current revisions: 21 21 ! ------------------ 22 ! 22 ! change in client-server data transfer: server now gets data from client 23 ! instead that client put's it to the server 23 24 ! 24 25 ! Former revisions: … … 82 83 TYPE(c_ptr) :: data ! Pointer of data in server space 83 84 TYPE(c_ptr), DIMENSION(2) :: po_data ! Base Pointers, PMC_S_Set_Active_data_array sets active pointer 84 INTEGER(idp) :: BufIndex ! index in Send Buffer 85 INTEGER :: BufSize ! size in Send Buffer 85 INTEGER(idp) :: SendIndex ! index in Send Buffer 86 INTEGER(idp) :: RecvIndex ! index in Receive Buffer 87 INTEGER :: SendSize ! size in Send Buffer 88 INTEGER :: RecvSize ! size in Receiver Buffer 86 89 TYPE (c_ptr) :: SendBuf ! Pointer of Data in Send buffer 90 TYPE (c_ptr) :: RecvBuf ! Pointer of Data in ReceiveS buffer 87 91 CHARACTER(len=8) :: Name ! Name of Array 88 92 … … 108 112 INTEGER :: inter_npes ! Number of PEs client model 109 113 INTEGER :: intra_rank ! rank within intra_comm 110 INTEGER :: BufWin ! MPI RMA windows114 INTEGER :: win_server_client ! MPI RMA for preparing data on server AND client side 111 115 TYPE (PeDef), DIMENSION(:), POINTER :: PEs ! List of all Client PEs 112 116 END TYPE ClientDef -
palm/trunk/SOURCE/pmc_handle_communicator.f90
r1780 r1786 20 20 ! Current revisions: 21 21 ! ------------------ 22 ! 22 ! Bugfix: nesting_mode is broadcast now 23 23 ! 24 24 ! Former revisions: … … 211 211 CALL MPI_BCAST( m_couplers(i)%lower_left_x, 1, MPI_REAL, 0, MPI_COMM_WORLD, istat ) 212 212 CALL MPI_BCAST( m_couplers(i)%lower_left_y, 1, MPI_REAL, 0, MPI_COMM_WORLD, istat ) 213 CALL MPI_BCAST( nesting_mode, LEN( nesting_mode ), MPI_CHARACTER, 0, MPI_COMM_WORLD, istat ) 213 214 ENDDO 214 215 -
palm/trunk/SOURCE/pmc_server.f90
r1780 r1786 20 20 ! Current revisions: 21 21 ! ------------------ 22 ! 22 ! change in client-server data transfer: server now gets data from client 23 ! instead that client put's it to the server 23 24 ! 24 25 ! Former revisions: … … 336 337 IMPLICIT none 337 338 339 ! 340 !-- Naming convention for appendices: _sc -> server to client transfer 341 !-- _cs -> client to server transfer 342 !-- Send -> Server to client transfer 343 !-- Recv -> client to server transfer 338 344 INTEGER,INTENT(IN) :: ClientId 339 345 … … 347 353 INTEGER,DIMENSION(1024) :: req 348 354 Type(c_ptr) :: base_ptr 349 REAL(kind=wp),DIMENSION(:),POINTER :: base_array 355 REAL(wp),DIMENSION(:),POINTER,SAVE :: base_array_sc !Base array for server to client transfer 356 REAL(wp),DIMENSION(:),POINTER,SAVE :: base_array_cs !Base array for client to server transfer 350 357 INTEGER(KIND=MPI_ADDRESS_KIND) :: WinSize 351 358 359 ! 360 !-- Server to client direction 352 361 myIndex = 1 353 362 rCount = 0 354 363 bufsize = 8 355 364 356 ! First stride, Compute size and set index 357 365 ! 366 !-- First stride: Compute size and set index 358 367 do i=1,Clients(ClientId)%inter_npes 359 368 aPE => Clients(ClientId)%PEs(i) … … 362 371 ar => aPE%array_list(j) 363 372 if(ar%NrDims == 2) then 364 arlen = aPE%NrEle ;! 2D373 arlen = aPE%NrEle ! 2D 365 374 else if(ar%NrDims == 3) then 366 arlen = aPE%NrEle * ar%A_dim(4); ! PALM3D375 arlen = aPE%NrEle * ar%A_dim(4); ! 3D 367 376 else 368 377 arlen = -1 369 378 end if 370 ar% BufIndex = myIndex379 ar%SendIndex = myIndex 371 380 372 381 tag = tag+1 … … 381 390 myIndex = myIndex+arlen 382 391 bufsize = bufsize+arlen 383 ar% BufSize = arlen392 ar%SendSize = arlen 384 393 385 394 end do 386 if(rCount > 0) then 395 if(rCount > 0) then ! Wait for all send completed 387 396 CALL MPI_Waitall (rCount, req, MPI_STATUSES_IGNORE, ierr) 388 397 end if 389 398 end do 390 399 391 ! Create RMA (One Sided Communication) window for data buffer 392 393 CALL PMC_Alloc_mem (base_array, bufsize, base_ptr) 394 Clients(ClientId)%TotalBufferSize = bufsize*wp !Total buffer size in Byte 400 ! 401 !-- Create RMA (One Sided Communication) window for data buffer server to 402 !-- client transfer. 403 !-- The buffer of MPI_Get (counter part of transfer) can be PE-local, i.e. 404 !-- it can but must not be part of the MPI RMA window. 405 !-- Only one RMA window is required to prepare the data 406 !-- for server -> client transfer on the server side and 407 !-- for client -> server transfer on the client side 408 CALL PMC_Alloc_mem (base_array_sc, bufsize) 409 Clients(ClientId)%TotalBufferSize = bufsize*wp !Total buffer size in Byte 395 410 396 411 WinSize = bufsize*wp 397 ! write(9,*) 'PMC_S_SetInd_and_Mem ',m_model_rank,Clients(ClientId)%inter_npes,WinSize,bufsize 398 CALL MPI_Win_create (base_array, WinSize, wp, MPI_INFO_NULL, Clients(ClientId)%intra_comm, Clients(ClientId)%BufWin, ierr); 399 CALL MPI_Win_fence (0, Clients(ClientId)%BufWin, ierr); ! Open Window to set data 400 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) 401 402 ! Second stride, Set Buffer pointer 403 412 CALL MPI_Win_create (base_array_sc, WinSize, wp, MPI_INFO_NULL, & 413 Clients(ClientId)%intra_comm, Clients(ClientId)%win_server_client, ierr) 414 CALL MPI_Win_fence (0, Clients(ClientId)%win_server_client, ierr); ! Open Window to set data 415 ! 416 !-- Second stride: Set Buffer pointer 404 417 do i=1,Clients(ClientId)%inter_npes 405 418 aPE => Clients(ClientId)%PEs(i) 406 419 do j=1,aPE%Nr_arrays 407 420 ar => aPE%array_list(j) 408 !-- TO_DO: Adressrechnung ueberlegen? 409 ar%SendBuf = c_loc(base_array(ar%BufIndex)) !kk Adressrechnung ueberlegen 410 if(ar%BufIndex+ar%BufSize > bufsize) then 411 !-- TO_DO: can this error really happen, and what can be the reason? 412 write(0,'(a,i4,4i7,1x,a)') 'Buffer too small ',i,ar%BufIndex,ar%BufSize,ar%BufIndex+ar%BufSize,bufsize,trim(ar%name) 421 ar%SendBuf = c_loc(base_array_sc(ar%SendIndex)) 422 if(ar%SendIndex+ar%SendSize > bufsize) then 423 write(0,'(a,i4,4i7,1x,a)') 'Server Buffer too small ',i,ar%SendIndex,ar%SendSize,ar%SendIndex+ar%SendSize,bufsize,trim(ar%name) 413 424 CALL MPI_Abort (MPI_COMM_WORLD, istat, ierr) 414 425 end if 426 end do 427 end do 428 429 !-- Client to server direction 430 431 bufsize = 8 432 433 !-- First stride, Compute size and set index 434 435 do i=1,Clients(ClientId)%inter_npes 436 aPE => Clients(ClientId)%PEs(i) 437 tag = 300 438 439 do j=1,aPE%Nr_arrays 440 ar => aPE%array_list(j) 441 442 ! Receive Index from client 443 tag = tag+1 444 CALL MPI_Recv (myIndex, 1, MPI_INTEGER, i-1, tag, Clients(ClientId)%inter_comm, MPI_STATUS_IGNORE, ierr) 445 446 if(ar%NrDims == 3) then 447 bufsize = max(bufsize,aPE%NrEle * ar%A_dim(4)) ! 3D 448 else 449 bufsize = max(bufsize,aPE%NrEle) ! 2D 450 end if 451 ar%RecvIndex = myIndex 452 end do 453 454 end do 455 456 !-- Create RMA (One Sided Communication) data buffer 457 !-- The buffer for MPI_Get can be PE local, i.e. it can but must not be part of the MPI RMA window 458 459 CALL PMC_Alloc_mem (base_array_cs, bufsize, base_ptr) 460 Clients(ClientId)%TotalBufferSize = bufsize*wp !Total buffer size in Byte 461 462 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) 463 464 !-- Second stride, Set Buffer pointer 465 466 do i=1,Clients(ClientId)%inter_npes 467 aPE => Clients(ClientId)%PEs(i) 468 469 do j=1,aPE%Nr_arrays 470 ar => aPE%array_list(j) 471 ar%RecvBuf = base_ptr 415 472 end do 416 473 end do … … 465 522 end do 466 523 467 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) ! buffer is f ull524 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) ! buffer is filled 468 525 469 526 return … … 480 537 INTEGER :: ip,ij,istat,ierr,j 481 538 INTEGER :: myIndex 539 INTEGER :: nr 482 540 REAL(wp) :: t1,t2 483 541 TYPE(PeDef),POINTER :: aPE … … 488 546 REAL(wp), POINTER, DIMENSION(:,:) :: data_2d 489 547 REAL(wp), POINTER, DIMENSION(:,:,:) :: data_3d 548 INTEGER :: target_pe 549 INTEGER(kind=MPI_ADDRESS_KIND) :: target_disp 490 550 491 551 t1 = PMC_Time() 492 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) ! Wait for MPI_Put from client 493 t2 = PMC_Time() 494 if(present(WaitTime)) WaitTime = t2-t1 552 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) ! Wait for client to fill buffer 553 t2 = PMC_Time()-t1 554 if(present(WaitTime)) WaitTime = t2 555 556 ! CALL MPI_Win_fence (0, Clients(ClientId)%win_server_client, ierr) ! Fence might do it, test later 557 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) ! Wait for buffer is filled 495 558 496 559 do ip=1,Clients(ClientId)%inter_npes … … 498 561 do j=1,aPE%Nr_arrays 499 562 ar => aPE%array_list(j) 563 564 if(ar%RecvIndex < 0) CYCLE 565 566 if(ar%NrDims == 2) then 567 nr = aPE%NrEle 568 else if(ar%NrDims == 3) then 569 nr = aPE%NrEle*ar%A_dim(4) 570 end if 571 572 buf_shape(1) = nr 573 CALL c_f_pointer(ar%RecvBuf, buf, buf_shape) 574 ! 575 !-- MPI passive target RMA 576 577 if(nr > 0) then 578 target_disp = ar%RecvIndex-1 579 target_pe = ip-1+m_model_npes ! client PEs are located behind server PEs 580 CALL MPI_Win_lock (MPI_LOCK_SHARED , target_pe, 0, Clients(ClientId)%win_server_client, ierr) 581 CALL MPI_Get (buf, nr, MPI_REAL, target_pe, target_disp, nr, MPI_REAL, Clients(ClientId)%win_server_client, ierr) 582 CALL MPI_Win_unlock (target_pe, Clients(ClientId)%win_server_client, ierr) 583 end if 584 500 585 myIndex=1 501 586 if(ar%NrDims == 2) then 502 buf_shape(1) = aPE%NrEle503 CALL c_f_pointer(ar%SendBuf, buf, buf_shape)504 587 CALL c_f_pointer(ar%data, data_2d, ar%A_dim(1:2)) 505 588 do ij=1,aPE%NrEle … … 508 591 end do 509 592 else if(ar%NrDims == 3) then 510 buf_shape(1) = aPE%NrEle*ar%A_dim(4)511 CALL c_f_pointer(ar%SendBuf, buf, buf_shape)512 593 CALL c_f_pointer(ar%data, data_3d, ar%A_dim(1:3)) 513 594 do ij=1,aPE%NrEle … … 519 600 end do 520 601 521 CALL MPI_Barrier(Clients(ClientId)%intra_comm, ierr) ! data copy finished, buffer is free for use agein522 523 return524 602 END SUBROUTINE PMC_S_GetData_from_Buffer 525 603 -
palm/trunk/SOURCE/spectrum.f90
r1785 r1786 1 !> @file calc_spectra.f901 !> @file spectrum.f90 2 2 !--------------------------------------------------------------------------------! 3 3 ! This file is part of PALM. … … 19 19 ! Current revisions: 20 20 ! ----------------- 21 ! 21 ! routine is modularized, filename renamed from calc_spectra to spectrum, 22 ! privious data module spectrum moved from modules.f90 to here, 23 ! cpp-direktives for spectra removed, immediate return if no spectra levels are 24 ! given 22 25 ! 23 26 ! Former revisions: … … 79 82 !> transpose_zyd needs modification). 80 83 !------------------------------------------------------------------------------! 81 SUBROUTINE calc_spectra 82 83 84 #if defined( __spectra ) 85 USE arrays_3d, & 86 ONLY: d, tend 87 88 USE control_parameters, & 89 ONLY: average_count_sp, bc_lr_cyc, bc_ns_cyc, message_string, psolver 90 91 USE cpulog, & 92 ONLY: cpu_log, log_point 93 94 USE fft_xy, & 95 ONLY: fft_init 96 97 USE indices, & 98 ONLY: nxl, nxr, nyn, nys, nzb, nzt 84 MODULE spectrum 99 85 100 86 USE kinds 101 87 102 USE pegrid 103 104 USE spectrum, & 105 ONLY: data_output_sp, spectra_direction 106 107 108 IMPLICIT NONE 109 110 INTEGER(iwp) :: m !< 111 INTEGER(iwp) :: pr !< 112 113 114 CALL cpu_log( log_point(30), 'calc_spectra', 'start' ) 115 116 ! 117 !-- Initialize ffts 118 CALL fft_init 119 120 ! 121 !-- Reallocate array d in required size 122 IF ( psolver(1:9) == 'multigrid' ) THEN 123 DEALLOCATE( d ) 124 ALLOCATE( d(nzb+1:nzt,nys:nyn,nxl:nxr) ) 125 ENDIF 126 127 m = 1 128 DO WHILE ( data_output_sp(m) /= ' ' .AND. m <= 10 ) 129 ! 130 !-- Transposition from z --> x ( y --> x in case of a 1d-decomposition 131 !-- along x) 132 IF ( INDEX( spectra_direction(m), 'x' ) /= 0 ) THEN 133 134 ! 135 !-- Calculation of spectra works for cyclic boundary conditions only 136 IF ( .NOT. bc_lr_cyc ) THEN 137 138 message_string = 'non-cyclic lateral boundaries along x do not'// & 139 '& allow calculation of spectra along x' 140 CALL message( 'calc_spectra', 'PA0160', 1, 2, 0, 6, 0 ) 88 PRIVATE 89 90 CHARACTER (LEN=6), DIMENSION(1:5) :: header_char = (/ 'PS(u) ', 'PS(v) ',& 91 'PS(w) ', 'PS(pt)', 'PS(q) ' /) 92 CHARACTER (LEN=2), DIMENSION(10) :: spectra_direction = 'x' 93 CHARACTER (LEN=10), DIMENSION(10) :: data_output_sp = ' ' 94 CHARACTER (LEN=25), DIMENSION(1:5) :: utext_char = & 95 (/ '-power spectrum of u ', & 96 '-power spectrum of v ', & 97 '-power spectrum of w ', & 98 '-power spectrum of ^1185 ', & 99 '-power spectrum of q ' /) 100 CHARACTER (LEN=39), DIMENSION(1:5) :: ytext_char = & 101 (/ 'k ^2236 ^2566^2569<u(k) in m>2s>->2 ', & 102 'k ^2236 ^2566^2569<v(k) in m>2s>->2 ', & 103 'k ^2236 ^2566^2569<w(k) in m>2s>->2 ', & 104 'k ^2236 ^2566^2569<^1185(k) in m>2s>->2', & 105 'k ^2236 ^2566^2569<q(k) in m>2s>->2 ' /) 106 107 INTEGER(iwp) :: klist_x = 0, klist_y = 0, n_sp_x = 0, n_sp_y = 0 108 109 INTEGER(iwp) :: comp_spectra_level(100) = 999999, & 110 lstyles(100) = (/ 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 111 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 112 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 113 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 114 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 115 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 116 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 117 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 118 0, 7, 3, 10, 1, 4, 9, 2, 6, 8, & 119 0, 7, 3, 10, 1, 4, 9, 2, 6, 8 /), & 120 plot_spectra_level(100) = 999999 121 122 REAL(wp) :: time_to_start_sp = 0.0_wp 123 124 PUBLIC comp_spectra_level, data_output_sp, header_char, klist_x, klist_y, & 125 lstyles, n_sp_x, n_sp_y, plot_spectra_level, spectra_direction, & 126 utext_char, ytext_char 127 128 SAVE 129 130 INTERFACE calc_spectra 131 MODULE PROCEDURE calc_spectra 132 END INTERFACE calc_spectra 133 134 INTERFACE preprocess_spectra 135 MODULE PROCEDURE preprocess_spectra 136 END INTERFACE preprocess_spectra 137 138 INTERFACE calc_spectra_x 139 MODULE PROCEDURE calc_spectra_x 140 END INTERFACE calc_spectra_x 141 142 INTERFACE calc_spectra_y 143 MODULE PROCEDURE calc_spectra_y 144 END INTERFACE calc_spectra_y 145 146 PUBLIC calc_spectra 147 148 149 CONTAINS 150 151 SUBROUTINE calc_spectra 152 153 USE arrays_3d, & 154 ONLY: d, tend 155 156 USE control_parameters, & 157 ONLY: average_count_sp, bc_lr_cyc, bc_ns_cyc, message_string, psolver 158 159 USE cpulog, & 160 ONLY: cpu_log, log_point 161 162 USE fft_xy, & 163 ONLY: fft_init 164 165 USE indices, & 166 ONLY: nxl, nxr, nyn, nys, nzb, nzt 167 168 USE kinds 169 170 USE pegrid, & 171 ONLY: myid, pdims 172 173 IMPLICIT NONE 174 175 INTEGER(iwp) :: m !< 176 INTEGER(iwp) :: pr !< 177 178 179 ! 180 !-- Check if user gave any levels for spectra to be calculated 181 IF ( comp_spectra_level(1) == 999999 ) RETURN 182 183 CALL cpu_log( log_point(30), 'calc_spectra', 'start' ) 184 185 ! 186 !-- Initialize ffts 187 CALL fft_init 188 189 ! 190 !-- Reallocate array d in required size 191 IF ( psolver(1:9) == 'multigrid' ) THEN 192 DEALLOCATE( d ) 193 ALLOCATE( d(nzb+1:nzt,nys:nyn,nxl:nxr) ) 194 ENDIF 195 196 m = 1 197 DO WHILE ( data_output_sp(m) /= ' ' .AND. m <= 10 ) 198 ! 199 !-- Transposition from z --> x ( y --> x in case of a 1d-decomposition 200 !-- along x) 201 IF ( INDEX( spectra_direction(m), 'x' ) /= 0 ) THEN 202 203 ! 204 !-- Calculation of spectra works for cyclic boundary conditions only 205 IF ( .NOT. bc_lr_cyc ) THEN 206 207 message_string = 'non-cyclic lateral boundaries along x do'// & 208 ' not & allow calculation of spectra along x' 209 CALL message( 'calc_spectra', 'PA0160', 1, 2, 0, 6, 0 ) 210 ENDIF 211 212 CALL preprocess_spectra( m, pr ) 213 214 #if defined( __parallel ) 215 IF ( pdims(2) /= 1 ) THEN 216 CALL resort_for_zx( d, tend ) 217 CALL transpose_zx( tend, d ) 218 ELSE 219 CALL transpose_yxd( d, d ) 220 ENDIF 221 CALL calc_spectra_x( d, pr, m ) 222 #else 223 message_string = 'sorry, calculation of spectra in non paral' // & 224 'lel mode& is still not realized' 225 CALL message( 'calc_spectra', 'PA0161', 1, 2, 0, 6, 0 ) 226 #endif 227 141 228 ENDIF 142 229 143 CALL preprocess_spectra( m, pr ) 230 ! 231 !-- Transposition from z --> y (d is rearranged only in case of a 232 !-- 1d-decomposition along x) 233 IF ( INDEX( spectra_direction(m), 'y' ) /= 0 ) THEN 234 235 ! 236 !-- Calculation of spectra works for cyclic boundary conditions only 237 IF ( .NOT. bc_ns_cyc ) THEN 238 IF ( myid == 0 ) THEN 239 message_string = 'non-cyclic lateral boundaries along y' // & 240 ' do not & allow calculation of spectr' // & 241 'a along y' 242 CALL message( 'calc_spectra', 'PA0162', 1, 2, 0, 6, 0 ) 243 ENDIF 244 CALL local_stop 245 ENDIF 246 247 CALL preprocess_spectra( m, pr ) 144 248 145 249 #if defined( __parallel ) 146 IF ( pdims(2) /= 1 ) THEN 147 CALL resort_for_zx( d, tend ) 148 CALL transpose_zx( tend, d ) 149 ELSE 150 CALL transpose_yxd( d, d ) 250 CALL transpose_zyd( d, d ) 251 CALL calc_spectra_y( d, pr, m ) 252 #else 253 message_string = 'sorry, calculation of spectra in non paral' // & 254 'lel mode& is still not realized' 255 CALL message( 'calc_spectra', 'PA0161', 1, 2, 0, 6, 0 ) 256 #endif 257 151 258 ENDIF 152 CALL calc_spectra_x( d, pr, m ) 153 #else 154 message_string = 'sorry, calculation of spectra in non parallel ' // & 155 'mode& is still not realized' 156 CALL message( 'calc_spectra', 'PA0161', 1, 2, 0, 6, 0 ) 157 #endif 158 159 ENDIF 160 161 ! 162 !-- Transposition from z --> y (d is rearranged only in case of a 163 !-- 1d-decomposition along x) 164 IF ( INDEX( spectra_direction(m), 'y' ) /= 0 ) THEN 165 166 ! 167 !-- Calculation of spectra works for cyclic boundary conditions only 168 IF ( .NOT. bc_ns_cyc ) THEN 169 IF ( myid == 0 ) THEN 170 message_string = 'non-cyclic lateral boundaries along y do' // & 171 ' not & allow calculation of spectra along y' 172 CALL message( 'calc_spectra', 'PA0162', 1, 2, 0, 6, 0 ) 173 ENDIF 174 CALL local_stop 175 ENDIF 176 177 CALL preprocess_spectra( m, pr ) 178 179 #if defined( __parallel ) 180 CALL transpose_zyd( d, d ) 181 CALL calc_spectra_y( d, pr, m ) 182 #else 183 message_string = 'sorry, calculation of spectra in non parallel' // & 184 'mode& is still not realized' 185 CALL message( 'calc_spectra', 'PA0161', 1, 2, 0, 6, 0 ) 186 #endif 187 188 ENDIF 189 190 ! 191 !-- Increase counter for next spectrum 192 m = m + 1 259 260 ! 261 !-- Increase counter for next spectrum 262 m = m + 1 193 263 194 ENDDO 195 196 ! 197 !-- Increase counter for averaging process in routine plot_spectra 198 average_count_sp = average_count_sp + 1 199 200 CALL cpu_log( log_point(30), 'calc_spectra', 'stop' ) 201 202 #endif 203 END SUBROUTINE calc_spectra 204 205 206 #if defined( __spectra ) 264 ENDDO 265 266 ! 267 !-- Increase counter for averaging process in routine plot_spectra 268 average_count_sp = average_count_sp + 1 269 270 CALL cpu_log( log_point(30), 'calc_spectra', 'stop' ) 271 272 END SUBROUTINE calc_spectra 273 274 207 275 !------------------------------------------------------------------------------! 208 276 ! Description: … … 210 278 !> @todo Missing subroutine description. 211 279 !------------------------------------------------------------------------------! 212 SUBROUTINE preprocess_spectra( m, pr ) 213 214 USE arrays_3d, & 215 ONLY: d, pt, q, u, v, w 216 217 USE indices, & 218 ONLY: ngp_2dh, nxl, nxr, nyn, nys, nzb, nzt 219 220 USE kinds 221 222 USE pegrid 223 224 USE spectrum, & 225 ONLY: data_output_sp 226 227 USE statistics, & 228 ONLY: hom, var_d 229 230 231 IMPLICIT NONE 232 233 INTEGER(iwp) :: i !< 234 INTEGER(iwp) :: j !< 235 INTEGER(iwp) :: k !< 236 INTEGER(iwp) :: m !< 237 INTEGER(iwp) :: pr !< 238 239 REAL(wp), DIMENSION(nzb:nzt+1) :: var_d_l 240 241 SELECT CASE ( TRIM( data_output_sp(m) ) ) 280 SUBROUTINE preprocess_spectra( m, pr ) 281 282 USE arrays_3d, & 283 ONLY: d, pt, q, u, v, w 284 285 USE indices, & 286 ONLY: ngp_2dh, nxl, nxr, nyn, nys, nzb, nzt 287 288 USE kinds 289 290 #if defined( __lc ) 291 USE MPI 292 #else 293 INCLUDE "mpif.h" 294 #endif 295 USE pegrid, & 296 ONLY: collective_wait, comm2d, ierr 297 298 USE statistics, & 299 ONLY: hom, var_d 300 301 302 IMPLICIT NONE 303 304 INTEGER(iwp) :: i !< 305 INTEGER(iwp) :: j !< 306 INTEGER(iwp) :: k !< 307 INTEGER(iwp) :: m !< 308 INTEGER(iwp) :: pr !< 309 310 REAL(wp), DIMENSION(nzb:nzt+1) :: var_d_l 311 312 SELECT CASE ( TRIM( data_output_sp(m) ) ) 242 313 243 CASE ( 'u' )244 pr = 1245 d(nzb+1:nzt,nys:nyn,nxl:nxr) = u(nzb+1:nzt,nys:nyn,nxl:nxr)314 CASE ( 'u' ) 315 pr = 1 316 d(nzb+1:nzt,nys:nyn,nxl:nxr) = u(nzb+1:nzt,nys:nyn,nxl:nxr) 246 317 247 CASE ( 'v' )248 pr = 2249 d(nzb+1:nzt,nys:nyn,nxl:nxr) = v(nzb+1:nzt,nys:nyn,nxl:nxr)318 CASE ( 'v' ) 319 pr = 2 320 d(nzb+1:nzt,nys:nyn,nxl:nxr) = v(nzb+1:nzt,nys:nyn,nxl:nxr) 250 321 251 CASE ( 'w' )252 pr = 3253 d(nzb+1:nzt,nys:nyn,nxl:nxr) = w(nzb+1:nzt,nys:nyn,nxl:nxr)322 CASE ( 'w' ) 323 pr = 3 324 d(nzb+1:nzt,nys:nyn,nxl:nxr) = w(nzb+1:nzt,nys:nyn,nxl:nxr) 254 325 255 CASE ( 'pt' )256 pr = 4257 d(nzb+1:nzt,nys:nyn,nxl:nxr) = pt(nzb+1:nzt,nys:nyn,nxl:nxr)326 CASE ( 'pt' ) 327 pr = 4 328 d(nzb+1:nzt,nys:nyn,nxl:nxr) = pt(nzb+1:nzt,nys:nyn,nxl:nxr) 258 329 259 CASE ( 'q' )260 pr = 41261 d(nzb+1:nzt,nys:nyn,nxl:nxr) = q(nzb+1:nzt,nys:nyn,nxl:nxr)330 CASE ( 'q' ) 331 pr = 41 332 d(nzb+1:nzt,nys:nyn,nxl:nxr) = q(nzb+1:nzt,nys:nyn,nxl:nxr) 262 333 263 CASE DEFAULT264 ! 265 !-- The DEFAULT case is reached either if the parameter data_output_sp(m)266 !-- contains a wrong character string or if the user has coded a special267 !-- case in the user interface. There, the subroutine user_spectra268 !-- checks which of these two conditions applies.269 CALL user_spectra( 'preprocess', m, pr )334 CASE DEFAULT 335 ! 336 !-- The DEFAULT case is reached either if the parameter data_output_sp(m) 337 !-- contains a wrong character string or if the user has coded a special 338 !-- case in the user interface. There, the subroutine user_spectra 339 !-- checks which of these two conditions applies. 340 CALL user_spectra( 'preprocess', m, pr ) 270 341 271 END SELECT 272 273 ! 274 !-- Subtract horizontal mean from the array, for which spectra have to be 275 !-- calculated 276 var_d_l(:) = 0.0_wp 277 DO i = nxl, nxr 278 DO j = nys, nyn 279 DO k = nzb+1, nzt 280 d(k,j,i) = d(k,j,i) - hom(k,1,pr,0) 281 var_d_l(k) = var_d_l(k) + d(k,j,i) * d(k,j,i) 342 END SELECT 343 344 ! 345 !-- Subtract horizontal mean from the array, for which spectra have to be 346 !-- calculated 347 var_d_l(:) = 0.0_wp 348 DO i = nxl, nxr 349 DO j = nys, nyn 350 DO k = nzb+1, nzt 351 d(k,j,i) = d(k,j,i) - hom(k,1,pr,0) 352 var_d_l(k) = var_d_l(k) + d(k,j,i) * d(k,j,i) 353 ENDDO 282 354 ENDDO 283 355 ENDDO 284 ENDDO 285 ! 286 !-- Compute total variance from local variances 287 var_d(:) = 0.0_wp 356 ! 357 !-- Compute total variance from local variances 358 var_d(:) = 0.0_wp 288 359 #if defined( __parallel ) 289 IF ( collective_wait ) CALL MPI_BARRIER( comm2d, ierr )290 CALL MPI_ALLREDUCE( var_d_l(0), var_d(0), nzt+1-nzb, MPI_REAL,&291 MPI_SUM,comm2d, ierr )292 #else 293 var_d(:) = var_d_l(:)294 #endif 295 var_d(:) = var_d(:) / ngp_2dh(0)296 297 END SUBROUTINE preprocess_spectra360 IF ( collective_wait ) CALL MPI_BARRIER( comm2d, ierr ) 361 CALL MPI_ALLREDUCE( var_d_l(0), var_d(0), nzt+1-nzb, MPI_REAL, MPI_SUM, & 362 comm2d, ierr ) 363 #else 364 var_d(:) = var_d_l(:) 365 #endif 366 var_d(:) = var_d(:) / ngp_2dh(0) 367 368 END SUBROUTINE preprocess_spectra 298 369 299 370 … … 303 374 !> @todo Missing subroutine description. 304 375 !------------------------------------------------------------------------------! 305 SUBROUTINE calc_spectra_x( ddd, pr, m )306 307 USE arrays_3d,&308 ONLY:309 310 USE control_parameters,&311 ONLY: fft_method312 313 USE fft_xy,&314 ONLY: fft_x_1d315 316 USE grid_variables,&317 ONLY: dx318 319 USE indices, &320 ONLY: nx, ny 321 322 USE kinds323 324 USE pegrid325 326 USE spectrum,&327 ONLY: comp_spectra_level, n_sp_x328 329 USE statistics,&330 ONLY: spectrum_x, var_d331 332 USE transpose_indices,&333 ONLY: nyn_x, nys_x, nzb_x, nzt_x334 335 336 IMPLICIT NONE337 338 INTEGER(iwp) :: i !<339 INTEGER(iwp) :: ishape(1) !<340 INTEGER(iwp) :: j !<341 INTEGER(iwp) :: k !<342 INTEGER(iwp) :: m !<343 INTEGER(iwp) :: n !<344 INTEGER(iwp) :: pr !<345 346 REAL(wp) :: exponent !<347 REAL(wp) :: sum_spec_dum !< wavenumber-integrated spectrum348 349 REAL(wp), DIMENSION(0:nx) :: work !<350 351 REAL(wp), DIMENSION(0:nx/2) :: sums_spectra_l !<352 353 REAL(wp), DIMENSION(0:nx/2,100) :: sums_spectra !<354 355 REAL(wp), DIMENSION(0:nx,nys_x:nyn_x,nzb_x:nzt_x) :: ddd !<356 357 ! 358 !-- Exponent for geometric average359 exponent = 1.0_wp / ( ny + 1.0_wp )360 361 ! 362 !-- Loop over all levels defined by the user363 n = 1364 DO WHILE ( comp_spectra_level(n) /= 999999 .AND. n <= 100 )365 366 k = comp_spectra_level(n)367 368 ! 369 !-- Calculate FFT only if the corresponding level is situated on this PE370 IF ( k >= nzb_x .AND. k <= nzt_x ) THEN376 SUBROUTINE calc_spectra_x( ddd, pr, m ) 377 378 USE control_parameters, & 379 ONLY: fft_method 380 381 USE fft_xy, & 382 ONLY: fft_x_1d 383 384 USE grid_variables, & 385 ONLY: dx 386 387 USE indices, & 388 ONLY: nx, ny 389 390 USE kinds 391 392 #if defined( __lc ) 393 USE MPI 394 #else 395 INCLUDE "mpif.h" 396 #endif 397 USE pegrid, & 398 ONLY: comm2d, ierr, myid 399 400 USE statistics, & 401 ONLY: spectrum_x, var_d 402 403 USE transpose_indices, & 404 ONLY: nyn_x, nys_x, nzb_x, nzt_x 405 406 407 IMPLICIT NONE 408 409 INTEGER(iwp) :: i !< 410 INTEGER(iwp) :: ishape(1) !< 411 INTEGER(iwp) :: j !< 412 INTEGER(iwp) :: k !< 413 INTEGER(iwp) :: m !< 414 INTEGER(iwp) :: n !< 415 INTEGER(iwp) :: pr !< 416 417 REAL(wp) :: exponent !< 418 REAL(wp) :: sum_spec_dum !< wavenumber-integrated spectrum 419 420 REAL(wp), DIMENSION(0:nx) :: work !< 421 422 REAL(wp), DIMENSION(0:nx/2) :: sums_spectra_l !< 423 424 REAL(wp), DIMENSION(0:nx/2,100) :: sums_spectra !< 425 426 REAL(wp), DIMENSION(0:nx,nys_x:nyn_x,nzb_x:nzt_x) :: ddd !< 427 428 ! 429 !-- Exponent for geometric average 430 exponent = 1.0_wp / ( ny + 1.0_wp ) 431 432 ! 433 !-- Loop over all levels defined by the user 434 n = 1 435 DO WHILE ( comp_spectra_level(n) /= 999999 .AND. n <= 100 ) 436 437 k = comp_spectra_level(n) 438 439 ! 440 !-- Calculate FFT only if the corresponding level is situated on this PE 441 IF ( k >= nzb_x .AND. k <= nzt_x ) THEN 371 442 372 DO j = nys_x, nyn_x 373 374 work = ddd(0:nx,j,k) 375 CALL fft_x_1d( work, 'forward' ) 376 377 ddd(0,j,k) = dx * work(0)**2 378 DO i = 1, nx/2 379 ddd(i,j,k) = dx * ( work(i)**2 + work(nx+1-i)**2 ) 443 DO j = nys_x, nyn_x 444 445 work = ddd(0:nx,j,k) 446 CALL fft_x_1d( work, 'forward' ) 447 448 ddd(0,j,k) = dx * work(0)**2 449 DO i = 1, nx/2 450 ddd(i,j,k) = dx * ( work(i)**2 + work(nx+1-i)**2 ) 451 ENDDO 452 380 453 ENDDO 381 454 455 ! 456 !-- Local sum and geometric average of these spectra 457 !-- (WARNING: no global sum should be performed, because floating 458 !-- point overflow may occur) 459 DO i = 0, nx/2 460 461 sums_spectra_l(i) = 1.0_wp 462 DO j = nys_x, nyn_x 463 sums_spectra_l(i) = sums_spectra_l(i) * ddd(i,j,k)**exponent 464 ENDDO 465 466 ENDDO 467 468 ELSE 469 470 sums_spectra_l = 1.0_wp 471 472 ENDIF 473 474 ! 475 !-- Global sum of spectra on PE0 (from where they are written on file) 476 sums_spectra(:,n) = 0.0_wp 477 #if defined( __parallel ) 478 CALL MPI_BARRIER( comm2d, ierr ) ! Necessary? 479 CALL MPI_REDUCE( sums_spectra_l(0), sums_spectra(0,n), nx/2+1, & 480 MPI_REAL, MPI_PROD, 0, comm2d, ierr ) 481 #else 482 sums_spectra(:,n) = sums_spectra_l 483 #endif 484 ! 485 !-- Normalize spectra by variance 486 sum_spec_dum = SUM( sums_spectra(:,n) ) 487 IF ( sum_spec_dum /= 0.0_wp ) THEN 488 sums_spectra(:,n) = sums_spectra(:,n) * var_d(k) / sum_spec_dum 489 ENDIF 490 n = n + 1 491 492 ENDDO 493 n = n - 1 494 495 IF ( myid == 0 ) THEN 496 ! 497 !-- Sum of spectra for later averaging (see routine data_output_spectra) 498 DO i = 1, nx/2 499 DO k = 1, n 500 spectrum_x(i,k,m) = spectrum_x(i,k,m) + sums_spectra(i,k) 501 ENDDO 382 502 ENDDO 383 503 384 !385 !-- Local sum and geometric average of these spectra386 !-- (WARNING: no global sum should be performed, because floating387 !-- point overflow may occur)388 DO i = 0, nx/2389 390 sums_spectra_l(i) = 1.0_wp391 DO j = nys_x, nyn_x392 sums_spectra_l(i) = sums_spectra_l(i) * ddd(i,j,k)**exponent393 ENDDO394 395 ENDDO396 397 ELSE398 399 sums_spectra_l = 1.0_wp400 401 504 ENDIF 402 403 ! 404 !-- Global sum of spectra on PE0 (from where they are written on file) 405 sums_spectra(:,n) = 0.0_wp 406 #if defined( __parallel ) 407 CALL MPI_BARRIER( comm2d, ierr ) ! Necessary? 408 CALL MPI_REDUCE( sums_spectra_l(0), sums_spectra(0,n), nx/2+1, & 409 MPI_REAL, MPI_PROD, 0, comm2d, ierr ) 410 #else 411 sums_spectra(:,n) = sums_spectra_l 412 #endif 413 ! 414 !-- Normalize spectra by variance 415 sum_spec_dum = SUM( sums_spectra(:,n) ) 416 IF ( sum_spec_dum /= 0.0_wp ) THEN 417 sums_spectra(:,n) = sums_spectra(:,n) * var_d(k) / sum_spec_dum 418 ENDIF 419 n = n + 1 420 421 ENDDO 422 n = n - 1 423 424 IF ( myid == 0 ) THEN 425 ! 426 !-- Sum of spectra for later averaging (see routine data_output_spectra) 427 DO i = 1, nx/2 428 DO k = 1, n 429 spectrum_x(i,k,m) = spectrum_x(i,k,m) + sums_spectra(i,k) 430 ENDDO 431 ENDDO 432 433 ENDIF 434 ! 435 !-- n_sp_x is needed by data_output_spectra_x 436 n_sp_x = n 437 438 END SUBROUTINE calc_spectra_x 505 ! 506 !-- n_sp_x is needed by data_output_spectra_x 507 n_sp_x = n 508 509 END SUBROUTINE calc_spectra_x 439 510 440 511 … … 444 515 !> @todo Missing subroutine description. 445 516 !------------------------------------------------------------------------------! 446 SUBROUTINE calc_spectra_y( ddd, pr, m )447 448 USE arrays_3d,&449 ONLY:450 451 USE control_parameters,&452 ONLY: fft_method453 454 USE fft_xy,&455 ONLY: fft_y_1d456 457 USE grid_variables,&458 ONLY: dy459 460 USE indices, &461 ONLY: nx, ny 462 463 USE kinds464 465 USE pegrid466 467 USE spectrum,&468 ONLY: comp_spectra_level, n_sp_y469 470 USE statistics,&471 ONLY: spectrum_y, var_d472 473 USE transpose_indices,&474 ONLY: nxl_yd, nxr_yd, nzb_yd, nzt_yd475 476 477 IMPLICIT NONE478 479 INTEGER(iwp) :: i !<480 INTEGER(iwp) :: j !<481 INTEGER(iwp) :: jshape(1) !<482 INTEGER(iwp) :: k !<483 INTEGER(iwp) :: m !<484 INTEGER(iwp) :: n !<485 INTEGER(iwp) :: pr !<486 487 REAL(wp) :: exponent !<488 REAL(wp) :: sum_spec_dum !< wavenumber-integrated spectrum489 490 REAL(wp), DIMENSION(0:ny) :: work !<491 492 REAL(wp), DIMENSION(0:ny/2) :: sums_spectra_l !<493 494 REAL(wp), DIMENSION(0:ny/2,100) :: sums_spectra !<495 496 REAL(wp), DIMENSION(0:ny,nxl_yd:nxr_yd,nzb_yd:nzt_yd) :: ddd !<497 498 499 ! 500 !-- Exponent for geometric average501 exponent = 1.0_wp / ( nx + 1.0_wp )502 503 ! 504 !-- Loop over all levels defined by the user505 n = 1506 DO WHILE ( comp_spectra_level(n) /= 999999 .AND. n <= 100 )507 508 k = comp_spectra_level(n)509 510 ! 511 !-- Calculate FFT only if the corresponding level is situated on this PE512 IF ( k >= nzb_yd .AND. k <= nzt_yd ) THEN517 SUBROUTINE calc_spectra_y( ddd, pr, m ) 518 519 USE control_parameters, & 520 ONLY: fft_method 521 522 USE fft_xy, & 523 ONLY: fft_y_1d 524 525 USE grid_variables, & 526 ONLY: dy 527 528 USE indices, & 529 ONLY: nx, ny 530 531 USE kinds 532 533 #if defined( __lc ) 534 USE MPI 535 #else 536 INCLUDE "mpif.h" 537 #endif 538 USE pegrid, & 539 ONLY: comm2d, ierr, myid 540 541 USE statistics, & 542 ONLY: spectrum_y, var_d 543 544 USE transpose_indices, & 545 ONLY: nxl_yd, nxr_yd, nzb_yd, nzt_yd 546 547 548 IMPLICIT NONE 549 550 INTEGER(iwp) :: i !< 551 INTEGER(iwp) :: j !< 552 INTEGER(iwp) :: jshape(1) !< 553 INTEGER(iwp) :: k !< 554 INTEGER(iwp) :: m !< 555 INTEGER(iwp) :: n !< 556 INTEGER(iwp) :: pr !< 557 558 REAL(wp) :: exponent !< 559 REAL(wp) :: sum_spec_dum !< wavenumber-integrated spectrum 560 561 REAL(wp), DIMENSION(0:ny) :: work !< 562 563 REAL(wp), DIMENSION(0:ny/2) :: sums_spectra_l !< 564 565 REAL(wp), DIMENSION(0:ny/2,100) :: sums_spectra !< 566 567 REAL(wp), DIMENSION(0:ny,nxl_yd:nxr_yd,nzb_yd:nzt_yd) :: ddd !< 568 569 570 ! 571 !-- Exponent for geometric average 572 exponent = 1.0_wp / ( nx + 1.0_wp ) 573 574 ! 575 !-- Loop over all levels defined by the user 576 n = 1 577 DO WHILE ( comp_spectra_level(n) /= 999999 .AND. n <= 100 ) 578 579 k = comp_spectra_level(n) 580 581 ! 582 !-- Calculate FFT only if the corresponding level is situated on this PE 583 IF ( k >= nzb_yd .AND. k <= nzt_yd ) THEN 513 584 514 DO i = nxl_yd, nxr_yd 515 516 work = ddd(0:ny,i,k) 517 CALL fft_y_1d( work, 'forward' ) 518 519 ddd(0,i,k) = dy * work(0)**2 520 DO j = 1, ny/2 521 ddd(j,i,k) = dy * ( work(j)**2 + work(ny+1-j)**2 ) 585 DO i = nxl_yd, nxr_yd 586 587 work = ddd(0:ny,i,k) 588 CALL fft_y_1d( work, 'forward' ) 589 590 ddd(0,i,k) = dy * work(0)**2 591 DO j = 1, ny/2 592 ddd(j,i,k) = dy * ( work(j)**2 + work(ny+1-j)**2 ) 593 ENDDO 594 522 595 ENDDO 523 596 597 ! 598 !-- Local sum and geometric average of these spectra 599 !-- (WARNING: no global sum should be performed, because floating 600 !-- point overflow may occur) 601 DO j = 0, ny/2 602 603 sums_spectra_l(j) = 1.0_wp 604 DO i = nxl_yd, nxr_yd 605 sums_spectra_l(j) = sums_spectra_l(j) * ddd(j,i,k)**exponent 606 ENDDO 607 608 ENDDO 609 610 ELSE 611 612 sums_spectra_l = 1.0_wp 613 614 ENDIF 615 616 ! 617 !-- Global sum of spectra on PE0 (from where they are written on file) 618 sums_spectra(:,n) = 0.0_wp 619 #if defined( __parallel ) 620 CALL MPI_BARRIER( comm2d, ierr ) ! Necessary? 621 CALL MPI_REDUCE( sums_spectra_l(0), sums_spectra(0,n), ny/2+1, & 622 MPI_REAL, MPI_PROD, 0, comm2d, ierr ) 623 #else 624 sums_spectra(:,n) = sums_spectra_l 625 #endif 626 ! 627 !-- Normalize spectra by variance 628 sum_spec_dum = SUM( sums_spectra(:,n) ) 629 IF ( SUM(sums_spectra(:,n)) /= 0.0_wp ) THEN 630 sums_spectra(:,n) = sums_spectra(:,n) * & 631 var_d(k) / SUM(sums_spectra(:,n)) 632 ENDIF 633 n = n + 1 634 635 ENDDO 636 n = n - 1 637 638 639 IF ( myid == 0 ) THEN 640 ! 641 !-- Sum of spectra for later averaging (see routine data_output_spectra) 642 DO j = 1, ny/2 643 DO k = 1, n 644 spectrum_y(j,k,m) = spectrum_y(j,k,m) + sums_spectra(j,k) 645 ENDDO 524 646 ENDDO 525 647 526 !527 !-- Local sum and geometric average of these spectra528 !-- (WARNING: no global sum should be performed, because floating529 !-- point overflow may occur)530 DO j = 0, ny/2531 532 sums_spectra_l(j) = 1.0_wp533 DO i = nxl_yd, nxr_yd534 sums_spectra_l(j) = sums_spectra_l(j) * ddd(j,i,k)**exponent535 ENDDO536 537 ENDDO538 539 ELSE540 541 sums_spectra_l = 1.0_wp542 543 648 ENDIF 544 649 545 650 ! 546 !-- Global sum of spectra on PE0 (from where they are written on file) 547 sums_spectra(:,n) = 0.0_wp 548 #if defined( __parallel ) 549 CALL MPI_BARRIER( comm2d, ierr ) ! Necessary? 550 CALL MPI_REDUCE( sums_spectra_l(0), sums_spectra(0,n), ny/2+1, & 551 MPI_REAL, MPI_PROD, 0, comm2d, ierr ) 552 #else 553 sums_spectra(:,n) = sums_spectra_l 554 #endif 555 ! 556 !-- Normalize spectra by variance 557 sum_spec_dum = SUM( sums_spectra(:,n) ) 558 IF ( SUM(sums_spectra(:,n)) /= 0.0_wp ) THEN 559 sums_spectra(:,n) = sums_spectra(:,n) * var_d(k) / SUM(sums_spectra(:,n)) 560 ENDIF 561 n = n + 1 562 563 ENDDO 564 n = n - 1 565 566 567 IF ( myid == 0 ) THEN 568 ! 569 !-- Sum of spectra for later averaging (see routine data_output_spectra) 570 DO j = 1, ny/2 571 DO k = 1, n 572 spectrum_y(j,k,m) = spectrum_y(j,k,m) + sums_spectra(j,k) 573 ENDDO 574 ENDDO 575 576 ENDIF 577 578 ! 579 !-- n_sp_y is needed by data_output_spectra_y 580 n_sp_y = n 581 582 END SUBROUTINE calc_spectra_y 583 #endif 651 !-- n_sp_y is needed by data_output_spectra_y 652 n_sp_y = n 653 654 END SUBROUTINE calc_spectra_y 655 656 END MODULE spectrum -
palm/trunk/SOURCE/time_integration.f90
r1784 r1786 19 19 ! Current revisions: 20 20 ! ------------------ 21 ! 21 ! +module spectrum 22 22 ! 23 23 ! Former revisions: … … 271 271 skip_time_do_radiation, time_radiation 272 272 273 USE spectrum, & 274 ONLY: calc_spectra 275 273 276 USE statistics, & 274 277 ONLY: flow_statistics_called, hom, pr_palm, sums_ls_l
Note: See TracChangeset
for help on using the changeset viewer.