Ignore:
Timestamp:
Jun 18, 2019 10:32:41 AM (5 years ago)
Author:
suehring
Message:

diagnostic output: Modularize diagnostic output, rename subroutines; formatting adjustments; allocate arrays only when required; add output of uu, vv, ww to enable variance calculation via temporal EC method; radiation: bugfix in masked data output; flow_statistics: Correct conversion to kinematic vertical scalar fluxes in case of pw-scheme and statistic regions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/module_interface.f90

    r4028 r4039  
    2525! -----------------
    2626! $Id$
     27! Introduce diagnostic output
     28!
     29! 4028 2019-06-13 12:21:37Z schwenkel
    2730! Further modularization of particle code components
    2831!
     
    210213              chem_rrd_local,                                                  &
    211214              chem_wrd_local
     215     
     216    USE diagnostic_output_quantities_mod,                                      &
     217        ONLY:  doq_3d_data_averaging,                                          &
     218               doq_check_data_output,                                          &
     219               doq_define_netcdf_grid,                                         &
     220               doq_output_2d,                                                  &
     221               doq_output_3d,                                                  &
     222               doq_wrd_local
     223!                doq_rrd_local,                                                  &
    212224
    213225    USE flight_mod,                                                            &
     
    751763       CALL chem_check_data_output( variable, unit, i, ilen, k )
    752764    ENDIF
     765   
     766    IF ( unit == 'illegal' )  THEN
     767       CALL doq_check_data_output( variable, unit )
     768    ENDIF
    753769
    754770    IF ( unit == 'illegal'  .AND.  gust_module_enabled  )  THEN
     
    11791195    IF ( bulk_cloud_model    )  CALL bcm_3d_data_averaging( mode, variable )
    11801196    IF ( air_chemistry       )  CALL chem_3d_data_averaging( mode, variable )
     1197    CALL doq_3d_data_averaging( mode, variable )
    11811198    IF ( gust_module_enabled )  CALL gust_3d_data_averaging( mode, variable )
    11821199    IF ( land_surface        )  CALL lsm_3d_data_averaging( mode, variable )
     
    12341251            )
    12351252    ENDIF
     1253   
     1254    IF ( .NOT. found )  THEN
     1255       CALL doq_output_2d(                                                     &
     1256               av, variable, found, grid, mode, local_pf, two_d,               &
     1257               nzb_do, nzt_do, fill_value )
     1258    ENDIF
    12361259
    12371260    IF ( .NOT. found  .AND.  gust_module_enabled )  THEN
     
    13141337       resorted = .TRUE.
    13151338    ENDIF
    1316 
     1339   
     1340    IF ( .NOT. found )  THEN
     1341       CALL doq_output_3d( av, variable, found, local_pf, fill_value, nzb_do, nzt_do )
     1342       resorted = .TRUE.
     1343    ENDIF
     1344   
    13171345    IF ( .NOT. found  .AND.  gust_module_enabled )  THEN
    13181346       CALL gust_data_output_3d( av, variable, found, local_pf, fill_value, nzb_do, nzt_do )
     
    14661494    LOGICAL,      INTENT(INOUT) ::  found        !< flag if variable was found
    14671495
    1468     REAL(wp), DIMENSION(nys_on_file-nbgp:nyn_on_file+nbgp,nxl_on_file-nbgp:nxr_on_file+nbgp), INTENT(OUT) :: tmp_2d   !<
    1469     REAL(wp), DIMENSION(nzb:nzt+1,nys_on_file-nbgp:nyn_on_file+nbgp,nxl_on_file-nbgp:nxr_on_file+nbgp), INTENT(OUT) :: tmp_3d   !<
     1496    REAL(wp), &
     1497       DIMENSION(nys_on_file-nbgp:nyn_on_file+nbgp,nxl_on_file-nbgp:nxr_on_file+nbgp), &
     1498       INTENT(OUT) :: tmp_2d   !<
     1499    REAL(wp), &
     1500       DIMENSION(nzb:nzt+1,nys_on_file-nbgp:nyn_on_file+nbgp,nxl_on_file-nbgp:nxr_on_file+nbgp), &
     1501       INTENT(OUT) :: tmp_3d   !<
    14701502
    14711503
    14721504    IF ( debug_output )  CALL debug_message( 'module-specific read local restart data', 'start' )
    14731505
    1474     IF ( .NOT. found ) CALL bio_rrd_local(                                     &
     1506    IF ( .NOT. found )  CALL bio_rrd_local(                                    &
    14751507                               found                                           &
    14761508                            )
    14771509
    1478     IF ( .NOT. found ) CALL bcm_rrd_local(                                     &
     1510    IF ( .NOT. found )  CALL bcm_rrd_local(                                    &
    14791511                               map_index,                                      &
    14801512                               nxlf, nxlc, nxl_on_file,                        &
     
    14851517                            ) ! ToDo: change interface to pass variable
    14861518
    1487     IF ( .NOT. found ) CALL chem_rrd_local(                                    &
     1519    IF ( .NOT. found )  CALL chem_rrd_local(                                   &
    14881520                               map_index,                                      &
    14891521                               nxlf, nxlc, nxl_on_file,                        &
     
    14931525                               tmp_3d, found                                   &
    14941526                            ) ! ToDo: change interface to pass variable
    1495 
    1496     IF ( .NOT. found ) CALL gust_rrd_local(                                    &
     1527                           
     1528!     IF ( .NOT. found )  CALL doq_rrd_local(                                    &
     1529!                                map_index,                                      &
     1530!                                nxlf, nxlc, nxl_on_file,                        &
     1531!                                nxrf, nxrc, nxr_on_file,                        &
     1532!                                nynf, nync, nyn_on_file,                        &
     1533!                                nysf, nysc, nys_on_file,                        &
     1534!                                tmp_3d_non_standard, found                      &
     1535!                             ) ! ToDo: change interface to pass variable CALL doq_wrd_local
     1536
     1537    IF ( .NOT. found )  CALL gust_rrd_local(                                   &
    14971538                               map_index,                                      &
    14981539                               nxlf, nxlc, nxl_on_file,                        &
     
    15031544                            ) ! ToDo: change interface to pass variable
    15041545
    1505     IF ( .NOT. found ) CALL lpm_rrd_local(                                     &
     1546    IF ( .NOT. found )  CALL lpm_rrd_local(                                    &
    15061547                               map_index,                                      &
    15071548                               nxlf, nxlc, nxl_on_file,                        &
     
    15121553                            ) ! ToDo: change interface to pass variable
    15131554
    1514     IF ( .NOT. found ) CALL lsm_rrd_local(                                     &
     1555    IF ( .NOT. found )  CALL lsm_rrd_local(                                    &
    15151556                               map_index,                                      &
    15161557                               nxlf, nxlc, nxl_on_file,                        &
     
    15211562                            ) ! ToDo: change interface to pass variable
    15221563
    1523     IF ( .NOT. found ) CALL ocean_rrd_local(                                   &
     1564    IF ( .NOT. found )  CALL ocean_rrd_local(                                  &
    15241565                               map_index,                                      &
    15251566                               nxlf, nxlc, nxl_on_file,                        &
     
    15301571                            ) ! ToDo: change interface to pass variable
    15311572
    1532     IF ( .NOT. found ) CALL radiation_rrd_local(                               &
     1573    IF ( .NOT. found )  CALL radiation_rrd_local(                              &
    15331574                               map_index,                                      &
    15341575                               nxlf, nxlc, nxl_on_file,                        &
     
    15391580                            ) ! ToDo: change interface to pass variable
    15401581
    1541     IF ( .NOT. found ) CALL salsa_rrd_local(                                   &
     1582    IF ( .NOT. found )  CALL salsa_rrd_local(                                  &
    15421583                               map_index,                                      &
    15431584                               nxlf, nxlc, nxl_on_file,                        &
     
    15481589                            ) ! ToDo: change interface to pass variable
    15491590
    1550     IF ( .NOT. found ) CALL usm_rrd_local(                                     &
     1591    IF ( .NOT. found )  CALL usm_rrd_local(                                    &
    15511592                               map_index,                                      &
    15521593                               nxlf, nxlc, nxl_on_file,                        &
     
    15581599!
    15591600!-- Surface data do not need overlap data, so do not pass these information.
    1560     IF ( .NOT. found ) CALL surface_data_output_rrd_local( found )
     1601    IF ( .NOT. found )  CALL surface_data_output_rrd_local( found )
    15611602                           
    1562     IF ( .NOT. found ) CALL user_rrd_local(                                    &
     1603    IF ( .NOT. found )  CALL user_rrd_local(                                   &
    15631604                               map_index,                                      &
    15641605                               nxlf, nxlc, nxl_on_file,                        &
     
    15881629    IF ( bulk_cloud_model )     CALL bcm_wrd_local
    15891630    IF ( air_chemistry )        CALL chem_wrd_local
     1631    CALL doq_wrd_local
    15901632    IF ( gust_module_enabled )  CALL gust_wrd_local
    15911633    IF ( particle_advection )   CALL lpm_wrd_local   
Note: See TracChangeset for help on using the changeset viewer.