Changeset 4047


Ignore:
Timestamp:
Jun 21, 2019 6:58:09 PM (5 years ago)
Author:
knoop
Message:

Initial introduction of the dynamics module with only dynamics_swap_timelevel implemented

Location:
palm/trunk/SOURCE
Files:
1 added
1 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/Makefile

    r4043 r4047  
    2525# -----------------
    2626# $Id$
     27# Introduction of the dynamics module and dissolution of swap_timelevel
     28#
     29# 4043 2019-06-18 16:59:00Z schwenkel
    2730# Delete droplet_interactions_ptq
    2831#
    2932# 4039 2019-06-18 10:32:41Z suehring
    3033# add dependency for diagnostic output quantities
    31 # 
     34#
    3235# 4017 2019-06-06 12:16:46Z schwenkel
    3336# add dependency for init_pegrid
    34 # 
     37#
    3538# 3994 2019-05-22 18:08:09Z suehring
    3639# new module for calculation and output of diagnostic quantities added
    37 # 
     40#
    3841# 3988 2019-05-22 11:32:37Z kanani
    3942# Add dependencies for virtual_measurement_mod
    40 # 
     43#
    4144# 3880 2019-04-08 21:43:02Z knoop
    4245# Add Netcdf data output for indoor model
    4346# Remove some dependencies
    44 # 
     47#
    4548# 3744 2019-02-15 18:38:58Z suehring
    46 # Enable mesoscale offline nesting for chemistry variables as well as 
     49# Enable mesoscale offline nesting for chemistry variables as well as
    4750# initialization of chemistry via dynamic input file.
    48 # 
     51#
    4952# 3727 2019-02-08 14:52:10Z gronemeier
    5053# surface_data_output_mod depends on netcdf_interface_mod
     
    5255# 3700 2019-01-26 17:03:42Z knoop
    5356# Rename surface_output_mod into surface_data_output_mod
    54 # 
     57#
    5558# 3637 2018-12-20 01:51:36Z knoop
    5659# Implementation of the PALM module interface
    57 # 
     60#
    5861# 3634 2018-12-18 12:31:28Z knoop
    5962# OpenACC port for SPEC
    60 # 
     63#
    6164# 3579 2018-11-29 15:32:39Z suehring
    6265# Dependency for check_parameters on nesting_offl_mod added
    63 # 
     66#
    6467# 3569 2018-11-27 17:03:40Z kanani
    6568# dom_dwd_user, Schrempf:
     
    6972# 3525 2018-11-14 16:06:14Z kanani
    7073# Changes related to clean-up of biometeorology (dom_dwd_user)
    71 # 
     74#
    7275# 3522 2018-11-13 12:14:36Z suehring
    7376# Dependencies for virtual measurement module added
    74 # 
     77#
    7578# 3494 2018-11-06 14:51:27Z suehring
    7679# Surface output revised
    77 # 
     80#
    7881# 3474 2018-10-30 21:07:39Z kanani
    7982# Add virtual measurement module
    80 # 
     83#
    8184# 3472 2018-10-30 20:43:50Z suehring
    8285# Add indoor model (kanani, srissman, tlang),
    8386# minor formatting
    84 # 
     87#
    8588# 3467 2018-10-30 19:05:21Z suehring
    8689# Implementation of a new aerosol module salsa.
    87 # 
    88 # 
     90#
     91#
    8992# 3458 2018-10-30 14:51:23Z kanani
    9093# from chemistry branch r3443, banzhafs, Russo, forkel, basit:
     
    9396# Added chemistry emission module
    9497# chemistry_model_mod added to flow_statistics
    95 # 
     98#
    9699# 3448 2018-10-29 18:14:31Z kanani
    97100# Adjustment of biometeorology dependencies
    98 # 
     101#
    99102# 3436 2018-10-26 18:35:15Z gronemeier
    100103# Add surface_mod to user_data_output_mask
    101 # 
     104#
    102105# 3435 2018-10-26 18:25:44Z gronemeier
    103106# - Add surface_mod to data_output_mask
    104107# - Add chemistry_model_mod and surface_mod to init_masks
    105 # 
     108#
    106109# 3421 2018-10-24 18:39:32Z gronemeier
    107110# Add netcdf_data_input_mod to netcdf_interface_mod
    108111# bugfix: add dependencies to chemistry_model_mod
    109112# Add module for surface data output
    110 # 
     113#
    111114# 3381 2018-10-19 13:09:06Z raasch
    112115# dependencies for ocean_mod fixed
    113 # 
     116#
    114117# 3355 2018-10-16 14:03:34Z knoop
    115118# Add module for offline nesting;
     
    117120# Bugfix, missing dependency for turbulence generator in init_3d_model;
    118121# Some formatting ajdustments
    119 # 
     122#
    120123# 3343 2018-10-15 10:38:52Z suehring
    121124# (from branch resler)
    122125# Add biometeorology
    123 # 
    124 # 
     126#
     127#
    125128# 3322 2018-10-09 10:02:39Z kanani
    126129# Formatting and cleanup
    127 # 
     130#
    128131# 3298 2018-10-02 12:21:11Z kanani
    129132# Added missing dependencies and replaced blanks with tabs (forkel)
     
    134137# changes related to modularization of the ocean mode,
    135138# bugfix: dependency to advec_ws was missed in chemistry_model_mod
    136 # 
     139#
    137140# 3274 2018-09-24 15:42:55Z knoop
    138141# Added palm dependency of multi_agent_system_mod, because of mas_last_actions
    139142# call at the end of palm run
    140 # 
     143#
    141144# 3167 2018-07-24 18:17:30Z suehring
    142145# Bugfix, add missing dependencies for multi-agent system
    143 # 
     146#
    144147# 3159 2018-07-20 11:20:01Z sward
    145148# Added multi agent system
    146 # 
     149#
    147150# 3130 2018-07-16 11:08:55Z gronemeier
    148151# add surface_layer_fluxes_mod to turbulence_closure_mod
    149 # 
     152#
    150153# 3129 2018-07-16 07:45:13Z gronemeier
    151154# add turbulence_closure_mod to parin
    152 # 
     155#
    153156# 2963 2018-04-12 14:47:44Z suehring
    154 # Introduce index for vegetation/wall, pavement/green-wall and water/window 
     157# Introduce index for vegetation/wall, pavement/green-wall and water/window
    155158# surfaces, for clearer access of surface fraction, albedo, emissivity, etc. .
    156 # 
     159#
    157160# 2955 2018-04-09 15:14:01Z suehring
    158161# Add log-points to measure CPU time of NetCDF data input.
    159 # 
     162#
    160163# 2938 2018-03-27 15:52:42Z suehring
    161164# No initialization of child domains via dynamic input file, except for soil
    162165# moisture and temperature
    163166# Apply turbulence generator at non-cyclic lateral boundary in nesting case
    164 # 
     167#
    165168# 2936 2018-03-27 14:49:27Z suehring
    166169# Added dependencies for parent and child synchronization
    167 # 
     170#
    168171# 2921 2018-03-22 15:05:23Z Giersch
    169172# date_and_time_mod dependency has been added to read/write_restart_data_mod
    170 # 
     173#
    171174# 2918 2018-03-21 15:52:14Z gronemeier
    172 # read/write_3d_binary and read/write_var_list has been removed, 
     175# read/write_3d_binary and read/write_var_list has been removed,
    173176# read/write_restart_data_mod, wrd_write_string and
    174 # user_read/write_restart_data_mod has been added, dependencies with respect to 
     177# user_read/write_restart_data_mod has been added, dependencies with respect to
    175178# the aforementioned routines have been added/removed
    176179#
    177180# 2847 2018-03-02 21:45:58Z suehring
    178181# Changed format and enforced sorting
    179 # 
     182#
    180183# 2817 2018-02-19 16:32:21Z knoop
    181184# Preliminary gust module interface implemented
    182 # 
     185#
    183186# 2802 2018-02-14 16:21:39Z thiele
    184187# Changed lpm from subroutine to module.
    185188# Introduce particle transfer in nested models.
    186 # 
     189#
    187190# 2773 2018-01-30 14:12:54Z suehring
    188191# Nesting of chemical species
    189 # 
     192#
    190193# 2718 2018-01-02 08:49:38Z maronga
    191194# Corrected "Former revisions" section
    192 # 
     195#
    193196# 2697 2017-12-14 17:57:20Z kanani
    194197# Bugfix, missing dependencies
    195 # 
     198#
    196199# 2696 2017-12-14 17:12:51Z kanani
    197200# Change in file header (GPL part)
    198201# Implementation of uv exposure model (FK)
    199 # Bugfix, removed loop dependcy for vertical_nesting_mod and 
     202# Bugfix, removed loop dependcy for vertical_nesting_mod and
    200203# turbulence_closure_mod, added depencies for vertical_nesting_mod (TG)
    201204# implemented turbulence_closure_mod (TG)
     
    205208# For LSM, add dependency on calc_mean_profile (??)
    206209# poismg_noopt modularized and renamed into poismg_noopt_mod
    207 # add dependencies for netcdf_data_input_mod, calc_mean_profile, 
     210# add dependencies for netcdf_data_input_mod, calc_mean_profile,
    208211# radiation_module_mod, land_surface_model_mod (MS)
    209 # 
     212#
    210213# 2608 2017-11-13 14:04:26Z schwenkel
    211 # Added diagnostic_quantities_mod 
    212 # 
     214# Added diagnostic_quantities_mod
     215#
    213216# 2600 2017-11-01 14:11:20Z raasch
    214217# comment line concerning bound checks removed
    215 # 
     218#
    216219# 2599 2017-11-01 13:18:45Z hellstea
    217220# virtual_flight_mod, synthetic_turbulence_generator_mod and
     
    220223# 2563 2017-10-19 15:36:10Z Giersch
    221224# wind_turbine_model_mod and synthetic_turbulence_generator_mod were added to
    222 # write_var_list and virtual_flight_mod was deleted from read_var_list 
     225# write_var_list and virtual_flight_mod was deleted from read_var_list
    223226#
    224227# 2544 2017-10-13 18:09:32Z maronga
    225 # Added date_and_time_mod 
    226 # 
     228# Added date_and_time_mod
     229#
    227230# 2371 2017-08-24 13:01:17Z kanani
    228231# Corrected dependencies for vertical_nesting_mod
    229 # 
     232#
    230233# 2370 2017-08-23 06:11:43Z raasch
    231234# dependency bugfix for synthetic_turbulence_generator
    232 # 
     235#
    233236# 2365 2017-08-21 14:59:59Z kanani
    234237# Added dependencies for vertical_nesting_mod
    235 # 
     238#
    236239# 2339 2017-08-07 13:55:26Z gronemeier
    237240# corrected timestamp in header
    238 # 
     241#
    239242# 2338 2017-08-07 12:15:38Z gronemeier
    240243# Modularize 1D model
    241 # 
     244#
    242245# 2320 2017-07-21 12:47:43Z suehring
    243246# -ls_forcing nudging
    244247# +large_scale_forcing_nudging
    245 # 
     248#
    246249# 2318 2017-07-20 17:27:44Z suehring
    247250# Add further dependencies on surface_mod
    248 # 
     251#
    249252# 2317 2017-07-20 17:27:19Z suehring
    250253# Added time_integration_spinup
    251 # 
     254#
    252255# 2269 2017-06-09 11:57:32Z suehring
    253256# Add dependency in read_3d_binary
    254 # 
     257#
    255258# 2263 2017-06-08 14:59:01Z schwenkel
    256259# Implemented splitting and merging algorithm
    257 # 
     260#
    258261# 2259 2017-06-08 09:09:11Z gronemeier
    259262# Implemented synthetic turbulence generator
     
    261264# 2256 2017-06-07 13:58:08Z suehring
    262265# Remove ring dependency in init_pegrid
    263 # 
     266#
    264267# 2238 2017-05-31 16:49:16Z suehring
    265268# Bugfix, further missing dependency on surface_mod
    266 # 
     269#
    267270# 2237 2017-05-31 10:34:53Z suehring
    268 # Bugfix, add dependencies on surface_mod for surface_coupler, 
    269 # plant_canopy_model_mod and ls_forcing_mod 
    270 # 
     271# Bugfix, add dependencies on surface_mod for surface_coupler,
     272# plant_canopy_model_mod and ls_forcing_mod
     273#
    271274# 2233 2017-05-30 18:08:54Z suehring
    272275#
     
    274277# +dependencies for surface_mod
    275278# -wall_fluxes
    276 # 
     279#
    277280# 2130 2017-01-24 16:25:39Z raasch
    278281# dependency for timestep updated
     
    280283# 2118 2017-01-17 16:38:49Z raasch
    281284# -cuda_fft_interfaces_mod
    282 # 
     285#
    283286# 2050 2016-11-08 15:00:55Z gronemeier
    284287# Implement turbulent outflow method
    285 # 
     288#
    286289# 2007 2016-08-24 15:47:17Z kanani
    287290# urban surface module added,
    288291# cleaned up some lines (compiler flags/options), which were accidentally
    289292# added in rev1938
    290 # 
     293#
    291294# 1998 2016-08-20 18:45:34Z knoop
    292295# Bugfix: added netcdf_interface to dependency list for user_init_land_surface
     
    294297# 1986 2016-08-10 14:07:17Z gronemeier
    295298# POSIX-calls module added
    296 # 
     299#
    297300# 1972 2016-07-26 07:52:02Z maronga
    298301# Removed some dependencies due to further modularization of land surface model
    299 # 
     302#
    300303# 1957 2016-07-07 10:43:48Z suehring
    301304# flight module added
     
    305308#
    306309# 1938 2016-06-13 15:26:05Z hellstea
    307 # Some dependency errors corrected 
    308 # 
     310# Some dependency errors corrected
     311#
    309312# 1934 2016-06-13 09:46:57Z hellstea
    310313# poismg renamed poismg_noopt, poismg_fast_mod renamed poismg_mod
    311 # 
     314#
    312315# 1914 2016-05-26 14:44:07Z witha
    313316# Added wind_turbine_model_mod
     
    320323#
    321324# 1850 2016-04-08 13:29:27Z maronga
    322 # Adapted for modularization of microphysics 
     325# Adapted for modularization of microphysics
    323326# Several files renamed --> _mod
    324327# Bugfix for previous commit
     
    335338# 1833 2016-04-07 14:23:03Z raasch
    336339# spectrum renamed spectra_mod, depencies for spectra changed
    337 # 
     340#
    338341# 1826 2016-04-07 12:01:39Z maronga
    339342# Renamed radiation_model to radiation_model_mod.
    340343# Renamed plant_canopy_model to plant_canopy_model_mod.
    341 # 
     344#
    342345# 1822 2016-04-07 07:49:42Z hoffmann
    343346# Tails removed. lpm_release_set removed. calc_precipitation, impact_of_latent_heat
    344 # removed. 
     347# removed.
    345348#
    346349# 1817 2016-04-06 15:44:20Z maronga
    347350# Renamed land_surface_model to land_surface_model_mod.
    348 # 
     351#
    349352# 1808 2016-04-05 19:44:00Z raasch
    350353# -local_flush, -local_getenv
     
    372375#
    373376# 1762 2016-02-25 12:31:13Z hellstea
    374 # +pmc_interface, +pmc routines 
     377# +pmc_interface, +pmc routines
    375378#
    376379# 1747 2016-02-08 12:25:53Z raasch
     
    378381#
    379382# 1691 2015-10-26 16:17:44Z maronga
    380 # Replaced prandtl_fluxes with surface_layer_fluxes. Added radiation_model to 
     383# Replaced prandtl_fluxes with surface_layer_fluxes. Added radiation_model to
    381384# prognostic_equations
    382 # 
     385#
    383386# 1585 2015-04-30 07:05:52Z maronga
    384387# Added user_init_radiation.f90
    385 # 
     388#
    386389# 1575 2015-03-27 09:56:27Z raasch
    387390# +poismg_fast
     
    389392# 1551 2015-03-03 14:18:16Z maronga
    390393# Bugfix: further adjustments for the land surface model and radiation model
    391 # 
     394#
    392395# 1517 2015-01-07 19:12:25Z hoffmann
    393396# advec_s_bc added to prognostic_equations
     
    395398# 1500 2014-12-03 17:42:41Z maronga
    396399# Bugfix: missing adjustments for land surface model and radiation model
    397 # 
     400#
    398401# 1496 2014-12-02 17:25:50Z maronga
    399 # Added land surface model and radiation model files: land_surface_model, 
     402# Added land surface model and radiation model files: land_surface_model,
    400403# radiation_model, user_init_land_surface
    401 # 
     404#
    402405# 1484 2014-10-21 10:53:05Z kanani
    403406# plant_canopy_model-dependency added for check_parameters, header, init_3d_model,
    404407# package_parin, read_var_list, user_init_plant_canopy, write_var_list
    405 # 
     408#
    406409# 1444 2014-08-02 20:10:32Z letzel
    407410# bugfix: cpulog added to lpm_advec
    408 # 
     411#
    409412# 1404 2014-05-14 09:01:39Z keck
    410413# bugfix: dependencies added for progress_bar
     
    412415# 1402 2014-05-09 14:25:13Z raasch
    413416# progress_bar added
    414 # 
     417#
    415418# 1400 2014-05-09 14:03:54Z knoop
    416419# Added new module random_generator_parallel
    417 # 
     420#
    418421# 1380 2014-04-28 12:40:45Z heinze
    419422# bugfix: mod_particle_attributes  added to check_open
    420 # nudging added to time_integration 
     423# nudging added to time_integration
    421424#
    422425# 1374 2014-04-25 12:55:07Z raasch
     
    426429# Added new module calc_mean_profile, previously in module buoyancy,
    427430# removed buoyancy dependency from nudging
    428 # 
     431#
    429432# 1363 2014-04-17 12:28:49Z keck
    430433# bugfix: cpulog added to lpm_pack_arrays
     
    432435# 1361 2014-04-16 15:17:48Z hoffmann
    433436# cpulog added to microphysics
    434 # 
     437#
    435438# 1359 2014-04-11 17:15:14Z hoffmann
    436 # mod_particle_attributes added, lpm_sort_arrays removed, 
     439# mod_particle_attributes added, lpm_sort_arrays removed,
    437440# lpm_extend_particle_array removed
    438441#
     
    606609        disturb_field.f90 \
    607610        disturb_heatflux.f90 \
     611        dynamics_mod.f90 \
    608612        exchange_horiz_2d.f90 \
    609613        exchange_horiz.f90 \
     
    679683        surface_mod.f90 \
    680684        surface_data_output_mod.f90 \
    681         swap_timelevel.f90 \
    682685        synthetic_turbulence_generator_mod.f90 \
    683686        temperton_fft_mod.f90 \
     
    715718
    716719CC = cc
    717 CFLAGS = -O 
     720CFLAGS = -O
    718721
    719722F90 =
     
    736739
    737740clean:
    738         rm -f $(PROG) $(OBJS) *.mod *.smod *.i *.lst 
     741        rm -f $(PROG) $(OBJS) *.mod *.smod *.i *.lst
    739742
    740743.f90.o:
     
    994997        random_generator_parallel_mod.o \
    995998        surface_mod.o
     999dynamics_mod.o: \
     1000        mod_kinds.o \
     1001        modules.o
    9961002exchange_horiz.o: \
    9971003        cpulog_mod.o \
     
    11791185        chemistry_model_mod.o \
    11801186        diagnostic_output_quantities_mod.o \
     1187        dynamics_mod.o \
    11811188        gust_mod.o \
    11821189        indoor_model_mod.o \
     
    11941201        surface_data_output_mod.o \
    11951202        synthetic_turbulence_generator_mod.o \
     1203        turbulence_closure_mod.o \
    11961204        urban_surface_mod.o \
    11971205        user_module.o \
     
    15081516        netcdf_interface_mod.o \
    15091517        surface_mod.o
    1510 swap_timelevel.o: \
    1511         cpulog_mod.o \
    1512         mod_kinds.o \
    1513         module_interface.o \
    1514         modules.o \
    1515         pmc_interface_mod.o \
    1516         turbulence_closure_mod.o
    15171518synthetic_turbulence_generator_mod.o: \
    15181519        basic_constants_and_equations_mod.o \
  • palm/trunk/SOURCE/module_interface.f90

    r4039 r4047  
    2525! -----------------
    2626! $Id$
     27! Introduction of the dynamics module
     28!
     29! 4039 2019-06-18 10:32:41Z suehring
    2730! Introduce diagnostic output
    28 ! 
     31!
    2932! 4028 2019-06-13 12:21:37Z schwenkel
    3033! Further modularization of particle code components
    31 ! 
     34!
    3235! 4017 2019-06-06 12:16:46Z schwenkel
    33 ! local_pf need INTENT(INOUT) attribute rather than INTENT(OUT). This is 
     36! local_pf need INTENT(INOUT) attribute rather than INTENT(OUT). This is
    3437! because INTENT(OUT) sets the array to not-defined. Especially for outputs that
    35 ! are not defined everywhere, e.g. land-surface outputs, this will be 
    36 ! problematic as NaN will be output.   
    37 ! 
     38! are not defined everywhere, e.g. land-surface outputs, this will be
     39! problematic as NaN will be output.
     40!
    3841! 3987 2019-05-22 09:52:13Z kanani
    3942! Introduce switchable DEBUG file output via debug_message routine
    40 ! 
     43!
    4144! 3956 2019-05-07 12:32:52Z monakurppa
    42 ! - Added calls for salsa_non_advective_processes and 
     45! - Added calls for salsa_non_advective_processes and
    4346!   salsa_exchange_horiz_bounds
    4447! - Moved the call for salsa_data_output_2d/3d before that of
     
    4649!   salsa output variable and encounters a segmentation fault for "Ntot" due
    4750!   to the shortoutput name
    48 ! 
     51!
    4952! 3931 2019-04-24 16:34:28Z schwenkel
    5053! Changed non_transport_physics to non_advective_processes
    51 ! 
     54!
    5255! 3930 2019-04-24 14:57:18Z forkel
    5356! Correct/complete module_interface introduction for chemistry model
    5457!
    5558! 3887 2019 -04-12 08:47:41Z schwenkel
    56 ! Changes related to global restructuring of location messages and introduction 
     59! Changes related to global restructuring of location messages and introduction
    5760! of additional debug messages
    58 ! 
     61!
    5962! 3880 2019 -04-08 21:43:02Z knoop
    6063! Add a call for salsa_prognostic_equations
    61 ! 
     64!
    6265! 3840 2019-03-29 10:35:52Z knoop
    6366! bugfix: intent of dummy arguments changed to inout
    64 ! 
     67!
    6568! 3770 2019-02-28 11:22:32Z moh.hefny
    6669! removed unused variables in module_interface_check_data_output_ts
     
    6871! 3767 08:18:02Z raasch
    6972! unused variable file_index removed from subroutine parameter list
    70 ! 
     73!
    7174! 3766 2019-02-26 16:23:41Z raasch
    7275! first argument removed from module_interface_rrd_*, statement added to avoid
    7376! compiler warning about unused variable, file reformatted with respect to coding
    7477! standards
    75 ! 
     78!
    7679! 3762 2019-02-25 16:54:16Z suehring
    7780! only pass required arguments to surface_data_output_rrd_local
    78 ! 
     81!
    7982! 3747 2019-02-16 15:15:23Z gronemeier
    8083! Call user_init_arrays
    81 ! 
     84!
    8285! 3745 2019-02-15 18:57:56Z suehring
    8386! Add indoor model
    84 ! 
     87!
    8588! 3744 2019-02-15 18:38:58Z suehring
    8689! Removed bio_check_parameters as the method is empty.
    87 ! 
     90!
    8891! 3735 2019-02-12 09:52:40Z dom_dwd_user
    89 ! Accepting variable j from check_parameters and passing it to 
     92! Accepting variable j from check_parameters and passing it to
    9093! bio_check_data_output
    9194! Add required restart data for surface output module
    92 ! 
     95!
    9396! 3731 2019-02-11 13:06:27Z suehring
    9497! Add check_parameters routine for virtual measurements
    95 ! 
     98!
    9699! 3711 2019-01-31 13:44:26Z knoop
    97100! Introduced module_interface_init_checks for post-init checks
    98 ! 
     101!
    99102! 3705 2019-01-29 19:56:39Z suehring
    100103! Add last_actions for virtual measurements
    101 ! 
     104!
    102105! 3704 2019-01-29 19:51:41Z suehring
    103106! Some interface calls moved to module_interface + cleanup
    104 ! 
     107!
    105108! 3684 2019-01-20 20:20:58Z knoop
    106109! Bugfix: made unit intend INOUT
    107 ! 
     110!
    108111! 3650 2019-01-04 13:01:33Z kanani
    109112! Add restart routines for biometeorology
    110 ! 
     113!
    111114! 3649 2019-01-02 16:52:21Z suehring
    112115! Initialize strings, in order to avoid compiler warnings for non-initialized
    113116! characters with intent(out) attribute
    114 ! 
     117!
    115118! 3648 2019-01-02 16:35:46Z suehring
    116119! Rename subroutines for surface-data output
    117 ! 
     120!
    118121! 3641 2018-12-23 22:10:01Z knoop
    119122! Initial implementation of the PALM module interface
    120123!
    121 ! 
     124!
    122125! Description:
    123126! ------------
     
    136139!-- load module-specific control parameters.
    137140!-- ToDo: move all of them to respective module or a dedicated central module
     141
     142    USE dynamics_mod, &
     143        ONLY:  dynamics_parin, &
     144               dynamics_check_parameters, &
     145               dynamics_check_data_output_ts, &
     146               dynamics_check_data_output_pr, &
     147               dynamics_check_data_output, &
     148               dynamics_init_masks, &
     149               dynamics_define_netcdf_grid, &
     150               dynamics_init_arrays, &
     151               dynamics_init, &
     152               dynamics_init_checks, &
     153               dynamics_header, &
     154               dynamics_actions, &
     155               dynamics_non_advective_processes, &
     156               dynamics_exchange_horiz, &
     157               dynamics_prognostic_equations, &
     158               dynamics_swap_timelevel, &
     159               dynamics_3d_data_averaging, &
     160               dynamics_data_output_2d, &
     161               dynamics_data_output_3d, &
     162               dynamics_statistics, &
     163               dynamics_rrd_global, &
     164               dynamics_rrd_local, &
     165               dynamics_wrd_global, &
     166               dynamics_wrd_local, &
     167               dynamics_last_actions
     168
     169    USE turbulence_closure_mod, &
     170        ONLY:  tcm_swap_timelevel
     171
    138172    USE control_parameters,                                                    &
    139173        ONLY:  air_chemistry,                                                  &
     
    213247              chem_rrd_local,                                                  &
    214248              chem_wrd_local
    215      
    216     USE diagnostic_output_quantities_mod,                                      & 
     249
     250    USE diagnostic_output_quantities_mod,                                      &
    217251        ONLY:  doq_3d_data_averaging,                                          &
    218252               doq_check_data_output,                                          &
     
    257291               im_data_output_3d,                                              &
    258292               im_init
    259                
     293
    260294    USE lagrangian_particle_model_mod,                                         &
    261295        ONLY:  lpm_parin,                                                      &
    262296               lpm_header,                                                     &
    263297               lpm_check_parameters,                                           &
    264                lpm_init_arrays,                                                &                             
     298               lpm_init_arrays,                                                &
    265299               lpm_init,                                                       &
    266300               lpm_actions,                                                    &
     
    269303               lpm_wrd_local,                                                  &
    270304               lpm_wrd_global
    271                
     305
    272306    USE land_surface_model_mod,                                                &
    273307        ONLY:  lsm_parin,                                                      &
     
    317351               ocean_rrd_local,                                                &
    318352               ocean_wrd_local
    319                
     353
    320354    USE particle_attributes,                                                   &
    321         ONLY:  particle_advection               
     355        ONLY:  particle_advection
    322356
    323357    USE plant_canopy_model_mod,                                                &
     
    394428               usm_rrd_local,                                                  &
    395429               usm_wrd_local
     430
     431    USE virtual_measurement_mod,                                               &
     432        ONLY:  vm_check_parameters,                                            &
     433               vm_init,                                                        &
     434               vm_last_actions,                                                &
     435               vm_parin
     436
     437    USE wind_turbine_model_mod,                                                &
     438        ONLY:  wtm_parin,                                                      &
     439               wtm_check_parameters,                                           &
     440               wtm_init_arrays,                                                &
     441               wtm_init,                                                       &
     442               wtm_actions,                                                    &
     443               wtm_rrd_global,                                                 &
     444               wtm_wrd_global
    396445
    397446    USE user,                                                                  &
     
    415464               user_wrd_local,                                                 &
    416465               user_last_actions
    417 
    418     USE virtual_measurement_mod,                                               &
    419         ONLY:  vm_check_parameters,                                            &
    420                vm_init,                                                        &
    421                vm_last_actions,                                                &
    422                vm_parin
    423 
    424     USE wind_turbine_model_mod,                                                &
    425         ONLY:  wtm_parin,                                                      &
    426                wtm_check_parameters,                                           &
    427                wtm_init_arrays,                                                &
    428                wtm_init,                                                       &
    429                wtm_actions,                                                    &
    430                wtm_rrd_global,                                                 &
    431                wtm_wrd_global
    432466
    433467    IMPLICIT NONE
     
    518552       MODULE PROCEDURE module_interface_non_advective_processes_ij
    519553    END INTERFACE module_interface_non_advective_processes
    520    
     554
    521555    INTERFACE module_interface_exchange_horiz
    522556       MODULE PROCEDURE module_interface_exchange_horiz
    523557    END INTERFACE module_interface_exchange_horiz
    524    
     558
    525559    INTERFACE module_interface_prognostic_equations
    526560       MODULE PROCEDURE module_interface_prognostic_equations
     
    581615
    582616    IF ( debug_output )  CALL debug_message( 'reading module-specific parameters', 'start' )
     617
     618    CALL dynamics_parin
    583619
    584620    CALL bio_parin
     
    588624    CALL gust_parin
    589625    CALL im_parin
    590     CALL lpm_parin     
     626    CALL lpm_parin
    591627    CALL lsm_parin
    592628    ! ToDo: create parin routine for large_scale_forcing and nudging (should be seperate modules or new module switch)
     
    600636    CALL surface_data_output_parin
    601637    CALL stg_parin
    602     CALL user_parin ! ToDo: make user code a single Fortran module
    603638    CALL usm_parin
    604639    CALL vm_parin
    605640    CALL wtm_parin
    606641
     642    CALL user_parin
     643
    607644    IF ( debug_output )  CALL debug_message( 'reading module-specific parameters', 'end' )
    608645
     
    620657
    621658    IF ( debug_output )  CALL debug_message( 'checking module-specific parameters', 'start' )
     659
     660    CALL dynamics_check_parameters
    622661
    623662    IF ( bulk_cloud_model )     CALL bcm_check_parameters
     
    625664    IF ( gust_module_enabled )  CALL gust_check_parameters
    626665    IF ( indoor_model )         CALL im_check_parameters
    627     IF ( particle_advection )   CALL lpm_check_parameters       
     666    IF ( particle_advection )   CALL lpm_check_parameters
    628667    IF ( land_surface )         CALL lsm_check_parameters
    629668    IF ( large_scale_forcing  .OR.  nudging )  CALL lsf_nudging_check_parameters ! ToDo: create single module switch
     
    639678    IF ( virtual_measurement )  CALL vm_check_parameters
    640679    IF ( wind_turbine )         CALL wtm_check_parameters
     680
    641681    IF ( user_module_enabled )  CALL user_check_parameters
    642682
     
    663703    IF ( debug_output )  CALL debug_message( 'checking module-specific data output ts', 'start' )
    664704
     705    CALL dynamics_check_data_output_ts( dots_max, dots_num, dots_label, dots_unit )
     706
    665707    IF ( radiation )  THEN
    666708       CALL radiation_check_data_output_ts( dots_max, dots_num )
     
    694736    IF ( debug_output )  CALL debug_message( 'checking module-specific data output pr', 'start' )
    695737
     738    CALL dynamics_check_data_output_pr( variable, var_count, unit, dopr_unit )
     739
    696740    IF ( unit == 'illegal' .AND.  bulk_cloud_model )  THEN
    697741       CALL bcm_check_data_output_pr( variable, var_count, unit, dopr_unit )
     
    751795    IF ( debug_output )  CALL debug_message( 'checking module-specific data output 2d/3d', 'start' )
    752796
     797    CALL dynamics_check_data_output( variable, unit )
     798
    753799    IF ( unit == 'illegal'  .AND.  biometeorology )  THEN
    754800       CALL bio_check_data_output( variable, unit, i, j, ilen, k )
     
    763809       CALL chem_check_data_output( variable, unit, i, ilen, k )
    764810    ENDIF
    765    
     811
    766812    IF ( unit == 'illegal' )  THEN
    767813       CALL doq_check_data_output( variable, unit )
     
    796842       CALL im_check_data_output( variable, unit )
    797843    ENDIF
    798    
     844
    799845    IF ( unit == 'illegal'  .AND.  urban_surface                      &
    800846        .AND.  variable(1:4) == 'usm_' )  THEN  ! ToDo: remove aditional conditions
     
    827873
    828874    IF ( debug_output )  CALL debug_message( 'initializing module-specific masks', 'start' )
     875
     876    CALL dynamics_init_masks( variable, unit )
    829877
    830878    IF ( unit == 'illegal'  .AND.  air_chemistry                               &
     
    897945    IF ( debug_output )  CALL debug_message( 'initializing module-specific arrays', 'start' )
    898946
     947    CALL dynamics_init_arrays
     948
    899949    IF ( bulk_cloud_model    )  CALL bcm_init_arrays
    900950    IF ( air_chemistry       )  CALL chem_init_arrays
    901951    IF ( gust_module_enabled )  CALL gust_init_arrays
    902     IF ( particle_advection  )  CALL lpm_init_arrays       
     952    IF ( particle_advection  )  CALL lpm_init_arrays
    903953    IF ( land_surface        )  CALL lsm_init_arrays
    904954    IF ( ocean_mode          )  CALL ocean_init_arrays
     
    907957    IF ( surface_output      )  CALL surface_data_output_init_arrays
    908958    IF ( wind_turbine        )  CALL wtm_init_arrays
     959
    909960    IF ( user_module_enabled )  CALL user_init_arrays
    910961
     
    924975
    925976    IF ( debug_output )  CALL debug_message( 'module-specific initialization', 'start' )
     977
     978    CALL dynamics_init
    926979
    927980    IF ( biometeorology      )  CALL bio_init
     
    931984    IF ( gust_module_enabled )  CALL gust_init
    932985    IF ( indoor_model        )  CALL im_init
    933     IF ( particle_advection  )  CALL lpm_init   
     986    IF ( particle_advection  )  CALL lpm_init
    934987    IF ( large_scale_forcing )  CALL lsf_init
    935988    IF ( land_surface        )  CALL lsm_init
     
    942995    IF ( wind_turbine        )  CALL wtm_init
    943996    IF ( radiation           )  CALL radiation_init
     997
    944998    IF ( user_module_enabled )  CALL user_init
    945999
     
    9601014    IF ( debug_output )  CALL debug_message( 'module-specific post-initialization checks', 'start' )
    9611015
     1016    CALL dynamics_init_checks
     1017
    9621018    IF ( biometeorology      )  CALL bio_init_checks
    9631019
     
    9801036
    9811037    IF ( debug_output )  CALL debug_message( 'module-specific header output', 'start' )
     1038
     1039    CALL dynamics_header( io )
    9821040
    9831041    IF ( biometeorology      )  CALL bio_header ( io )
     
    9861044    IF ( virtual_flight      )  CALL flight_header( io )
    9871045    IF ( gust_module_enabled )  CALL gust_header( io )
    988     IF ( particle_advection  )  CALL lpm_header( io )   
     1046    IF ( particle_advection  )  CALL lpm_header( io )
    9891047    IF ( land_surface        )  CALL lsm_header( io )
    9901048    IF ( large_scale_forcing )  CALL lsf_nudging_header( io )
     
    9961054    IF ( calculate_spectra   )  CALL spectra_header( io )
    9971055    IF ( syn_turb_gen        )  CALL stg_header( io )
     1056
    9981057    IF ( user_module_enabled )  CALL user_header( io )
    9991058
     
    10141073    CHARACTER (LEN=*), INTENT(IN) ::  location !< call location string
    10151074
     1075    CALL dynamics_actions( location )
    10161076
    10171077    IF ( bulk_cloud_model    )  CALL bcm_actions( location )
    10181078    IF ( air_chemistry       )  CALL chem_actions( location )
    10191079    IF ( gust_module_enabled )  CALL gust_actions( location )
    1020     IF ( particle_advection  )  CALL lpm_actions( location )   
     1080    IF ( particle_advection  )  CALL lpm_actions( location )
    10211081    IF ( ocean_mode          )  CALL ocean_actions( location )
    10221082    IF ( salsa               )  CALL salsa_actions( location )
    10231083    IF ( wind_turbine        )  CALL wtm_actions( location )
     1084
    10241085    IF ( user_module_enabled )  CALL user_actions( location )
    10251086
     
    10401101    CHARACTER (LEN=*), INTENT(IN) ::  location  !< call location string
    10411102
     1103    CALL dynamics_actions( i, j, location )
    10421104
    10431105    IF ( bulk_cloud_model    )  CALL bcm_actions( i, j, location )
     
    10471109    IF ( salsa               )  CALL salsa_actions( i, j, location )
    10481110    IF ( wind_turbine        )  CALL wtm_actions( i, j, location )
     1111
    10491112    IF ( user_module_enabled )  CALL user_actions( i, j, location )
    10501113
     
    10581121!> Compute module-specific non_advective_processes (vector-optimized)
    10591122!------------------------------------------------------------------------------!
    1060  SUBROUTINE module_interface_non_advective_processes()
    1061 
    1062 
    1063     IF ( bulk_cloud_model    )  CALL bcm_non_advective_processes()
    1064     IF ( air_chemistry       )  CALL chem_non_advective_processes()
    1065     IF ( salsa               )  CALL salsa_non_advective_processes()
     1123 SUBROUTINE module_interface_non_advective_processes
     1124
     1125
     1126    CALL dynamics_non_advective_processes
     1127
     1128    IF ( bulk_cloud_model    )  CALL bcm_non_advective_processes
     1129    IF ( air_chemistry       )  CALL chem_non_advective_processes
     1130    IF ( salsa               )  CALL salsa_non_advective_processes
    10661131
    10671132
     
    10801145    INTEGER(iwp), INTENT(IN) ::  j            !< grid index in y-direction
    10811146
     1147    CALL dynamics_non_advective_processes( i, j )
    10821148
    10831149    IF ( bulk_cloud_model    )  CALL bcm_non_advective_processes( i, j )
     
    10871153
    10881154 END SUBROUTINE module_interface_non_advective_processes_ij
    1089  
    1090 !------------------------------------------------------------------------------!
    1091 ! Description:
    1092 ! ------------
    1093 !> Exchange horiz for module-specific quantities 
    1094 !------------------------------------------------------------------------------!
    1095  SUBROUTINE module_interface_exchange_horiz()
     1155
     1156!------------------------------------------------------------------------------!
     1157! Description:
     1158! ------------
     1159!> Exchange horiz for module-specific quantities
     1160!------------------------------------------------------------------------------!
     1161 SUBROUTINE module_interface_exchange_horiz
    10961162
    10971163
    10981164    IF ( debug_output_timestep )  CALL debug_message( 'module-specific exchange_horiz', 'start' )
    10991165
    1100     IF ( bulk_cloud_model    )  CALL bcm_exchange_horiz()
    1101     IF ( air_chemistry       )  CALL chem_exchange_horiz_bounds()
    1102     IF ( salsa               )  CALL salsa_exchange_horiz_bounds()
     1166    CALL dynamics_exchange_horiz
     1167
     1168    IF ( bulk_cloud_model    )  CALL bcm_exchange_horiz
     1169    IF ( air_chemistry       )  CALL chem_exchange_horiz_bounds
     1170    IF ( salsa               )  CALL salsa_exchange_horiz_bounds
    11031171
    11041172    IF ( debug_output_timestep )  CALL debug_message( 'module-specific exchange_horiz', 'end' )
     
    11131181!> Compute module-specific prognostic_equations (vector-optimized)
    11141182!------------------------------------------------------------------------------!
    1115  SUBROUTINE module_interface_prognostic_equations()
    1116 
    1117 
    1118     IF ( bulk_cloud_model    )  CALL bcm_prognostic_equations()
    1119     IF ( air_chemistry       )  CALL chem_prognostic_equations()
    1120     IF ( gust_module_enabled )  CALL gust_prognostic_equations()
    1121     IF ( ocean_mode          )  CALL ocean_prognostic_equations()
    1122     IF ( salsa               )  CALL salsa_prognostic_equations()
     1183 SUBROUTINE module_interface_prognostic_equations
     1184
     1185
     1186    CALL dynamics_prognostic_equations
     1187
     1188    IF ( bulk_cloud_model    )  CALL bcm_prognostic_equations
     1189    IF ( air_chemistry       )  CALL chem_prognostic_equations
     1190    IF ( gust_module_enabled )  CALL gust_prognostic_equations
     1191    IF ( ocean_mode          )  CALL ocean_prognostic_equations
     1192    IF ( salsa               )  CALL salsa_prognostic_equations
    11231193
    11241194
     
    11391209    INTEGER(iwp), INTENT(IN) ::  tn           !< task number of openmp task
    11401210
     1211    CALL dynamics_prognostic_equations( i, j, i_omp_start, tn )
    11411212
    11421213    IF ( bulk_cloud_model    )  CALL bcm_prognostic_equations( i, j, i_omp_start, tn )
     
    11621233
    11631234    IF ( debug_output_timestep )  CALL debug_message( 'module-specific swap timelevel', 'start' )
     1235
     1236    CALL dynamics_swap_timelevel( swap_mode )
     1237    CALL tcm_swap_timelevel( swap_mode )
    11641238
    11651239    IF ( bulk_cloud_model    )  CALL bcm_swap_timelevel( swap_mode )
     
    11921266    IF ( debug_output_timestep )  CALL debug_message( 'module-specific 3d data averaging', 'start' )
    11931267
     1268    CALL dynamics_3d_data_averaging( mode, variable )
     1269
    11941270    IF ( biometeorology      )  CALL bio_3d_data_averaging( mode, variable )
    11951271    IF ( bulk_cloud_model    )  CALL bcm_3d_data_averaging( mode, variable )
    11961272    IF ( air_chemistry       )  CALL chem_3d_data_averaging( mode, variable )
    1197     CALL doq_3d_data_averaging( mode, variable )
     1273    CALL doq_3d_data_averaging( mode, variable )  ! ToDo: this seems to be not according to the design
    11981274    IF ( gust_module_enabled )  CALL gust_3d_data_averaging( mode, variable )
    11991275    IF ( land_surface        )  CALL lsm_3d_data_averaging( mode, variable )
     
    12021278    IF ( salsa               )  CALL salsa_3d_data_averaging( mode, variable )
    12031279    IF ( urban_surface       )  CALL usm_3d_data_averaging( mode, variable )
     1280
    12041281    IF ( user_module_enabled )  CALL user_3d_data_averaging( mode, variable )
    12051282
     
    12341311    IF ( debug_output_timestep )  CALL debug_message( 'module-specific 2d data output', 'start' )
    12351312
     1313    CALL dynamics_data_output_2d(                                                  &
     1314               av, variable, found, grid, mode, local_pf, two_d, nzb_do, nzt_do, fill_value &
     1315            )
     1316
    12361317    IF ( .NOT. found  .AND.  biometeorology )  THEN
    12371318       CALL bio_data_output_2d(                                                &
     
    12511332            )
    12521333    ENDIF
    1253    
     1334
    12541335    IF ( .NOT. found )  THEN
    12551336       CALL doq_output_2d(                                                     &
     
    13231404    IF ( debug_output_timestep )  CALL debug_message( 'module-specific 3d data output', 'start' )
    13241405
     1406    CALL dynamics_data_output_3d( av, variable, found, local_pf, fill_value, nzb_do, nzt_do )
     1407    resorted = .FALSE.
     1408
    13251409    IF ( .NOT. found  .AND.  biometeorology )  THEN
    13261410       CALL bio_data_output_3d( av, variable, found, local_pf, nzb_do, nzt_do )
     
    13371421       resorted = .TRUE.
    13381422    ENDIF
    1339    
     1423
    13401424    IF ( .NOT. found )  THEN
    13411425       CALL doq_output_3d( av, variable, found, local_pf, fill_value, nzb_do, nzt_do )
    13421426       resorted = .TRUE.
    13431427    ENDIF
    1344    
     1428
    13451429    IF ( .NOT. found  .AND.  gust_module_enabled )  THEN
    13461430       CALL gust_data_output_3d( av, variable, found, local_pf, fill_value, nzb_do, nzt_do )
    13471431       resorted = .TRUE.
    13481432    ENDIF
    1349    
     1433
    13501434    IF ( .NOT. found  .AND.  indoor_model )  THEN
    13511435       CALL im_data_output_3d( av, variable, found, local_pf, fill_value, nzb_do, nzt_do )
     
    14001484    IF ( debug_output_timestep )  CALL debug_message( 'module-specific statistics', 'start' )
    14011485
     1486    CALL dynamics_statistics( mode, sr, tn )
     1487
    14021488    IF ( gust_module_enabled )  CALL gust_statistics( mode, sr, tn, dots_max )
    14031489    IF ( air_chemistry       )  CALL chem_statistics( mode, sr, tn )
     1490
    14041491    IF ( user_module_enabled )  CALL user_statistics( mode, sr, tn )
    14051492
     
    14221509
    14231510    IF ( debug_output )  CALL debug_message( 'module-specific read global restart data', 'start' )
     1511
     1512    CALL dynamics_rrd_global( found ) ! ToDo: change interface to pass variable
    14241513
    14251514    IF ( .NOT. found )  CALL bio_rrd_global( found ) ! ToDo: change interface to pass variable
     
    14271516    IF ( .NOT. found )  CALL flight_rrd_global( found ) ! ToDo: change interface to pass variable
    14281517    IF ( .NOT. found )  CALL gust_rrd_global( found ) ! ToDo: change interface to pass variable
    1429     IF ( .NOT. found )  CALL lpm_rrd_global( found ) ! ToDo: change interface to pass variable       
     1518    IF ( .NOT. found )  CALL lpm_rrd_global( found ) ! ToDo: change interface to pass variable
    14301519    IF ( .NOT. found )  CALL ocean_rrd_global( found ) ! ToDo: change interface to pass variable
    14311520    IF ( .NOT. found )  CALL stg_rrd_global ( found ) ! ToDo: change interface to pass variable
    14321521    IF ( .NOT. found )  CALL wtm_rrd_global( found ) ! ToDo: change interface to pass variable
    14331522    IF ( .NOT. found )  CALL surface_data_output_rrd_global( found )
     1523
    14341524    IF ( .NOT. found )  CALL user_rrd_global( found ) ! ToDo: change interface to pass variable
    14351525
     
    14491539
    14501540    IF ( debug_output )  CALL debug_message( 'module-specific write global restart data', 'start' )
     1541
     1542    CALL dynamics_wrd_global
    14511543
    14521544    IF ( biometeorology )       CALL bio_wrd_global
     
    14581550    IF ( wind_turbine )         CALL wtm_wrd_global
    14591551    IF ( surface_output )       CALL surface_data_output_wrd_global
     1552
    14601553    IF ( user_module_enabled )  CALL user_wrd_global
    14611554
     
    15041597    IF ( debug_output )  CALL debug_message( 'module-specific read local restart data', 'start' )
    15051598
     1599    CALL dynamics_rrd_local(                                                   &
     1600           map_index,                                                          &
     1601           nxlf, nxlc, nxl_on_file,                                            &
     1602           nxrf, nxrc, nxr_on_file,                                            &
     1603           nynf, nync, nyn_on_file,                                            &
     1604           nysf, nysc, nys_on_file,                                            &
     1605           tmp_2d, tmp_3d, found                                               &
     1606        ) ! ToDo: change interface to pass variable
     1607
    15061608    IF ( .NOT. found )  CALL bio_rrd_local(                                    &
    15071609                               found                                           &
     
    15251627                               tmp_3d, found                                   &
    15261628                            ) ! ToDo: change interface to pass variable
    1527                            
     1629
    15281630!     IF ( .NOT. found )  CALL doq_rrd_local(                                    &
    15291631!                                map_index,                                      &
     
    16001702!-- Surface data do not need overlap data, so do not pass these information.
    16011703    IF ( .NOT. found )  CALL surface_data_output_rrd_local( found )
    1602                            
     1704
    16031705    IF ( .NOT. found )  CALL user_rrd_local(                                   &
    16041706                               map_index,                                      &
     
    16261728    IF ( debug_output )  CALL debug_message( 'module-specific write local restart data', 'start' )
    16271729
     1730    CALL dynamics_wrd_local
     1731
    16281732    IF ( biometeorology )       CALL bio_wrd_local
    16291733    IF ( bulk_cloud_model )     CALL bcm_wrd_local
     
    16311735    CALL doq_wrd_local
    16321736    IF ( gust_module_enabled )  CALL gust_wrd_local
    1633     IF ( particle_advection )   CALL lpm_wrd_local   
     1737    IF ( particle_advection )   CALL lpm_wrd_local
    16341738    IF ( land_surface )         CALL lsm_wrd_local
    16351739    IF ( ocean_mode )           CALL ocean_wrd_local
     
    16381742    IF ( urban_surface )        CALL usm_wrd_local
    16391743    IF ( surface_output )       CALL surface_data_output_wrd_local
     1744
    16401745    IF ( user_module_enabled )  CALL user_wrd_local
    16411746
     
    16561761    IF ( debug_output )  CALL debug_message( 'module-specific last actions', 'start' )
    16571762
     1763    CALL dynamics_last_actions
     1764
    16581765    IF ( virtual_measurement )  CALL vm_last_actions
     1766
    16591767    IF ( user_module_enabled )  CALL user_last_actions
    16601768
  • palm/trunk/SOURCE/time_integration.f90

    r4043 r4047  
    2525! -----------------
    2626! $Id$
     27! Added remainings of swap_timelevel upon its dissolution
     28!
     29! 4043 2019-06-18 16:59:00Z schwenkel
    2730! Further LPM modularization
    2831!
     
    575578               turbulent_inflow, turbulent_outflow, urban_surface,                                 &
    576579               use_initial_profile_as_reference, use_single_reference_value, u_gtrans, v_gtrans,   &
    577                virtual_flight, virtual_measurement, ws_scheme_mom, ws_scheme_sca
     580               virtual_flight, virtual_measurement, ws_scheme_mom, ws_scheme_sca, timestep_count
    578581
    579582    USE cpulog,                                                                                    &
     
    610613
    611614    USE module_interface,                                                                          &
    612         ONLY:  module_interface_actions
     615        ONLY:  module_interface_actions, module_interface_swap_timelevel
    613616
    614617    USE multi_agent_system_mod,                                                                    &
     
    631634    USE pmc_interface,                                                                             &
    632635        ONLY:  nested_run, nesting_mode, pmci_boundary_conds, pmci_datatrans, pmci_synchronize,    &
    633         pmci_ensure_nest_mass_conservation, pmci_ensure_nest_mass_conservation_vertical
     636        pmci_ensure_nest_mass_conservation, pmci_ensure_nest_mass_conservation_vertical,           &
     637        pmci_set_swaplevel
    634638
    635639    USE progress_bar,                                                                              &
     
    11351139
    11361140!
    1137 !--       Swap the time levels in preparation for the next time step.
    1138           CALL swap_timelevel
     1141!--       Incrementing timestep counter
     1142          timestep_count = timestep_count + 1
     1143
     1144          CALL cpu_log( log_point(28), 'swap_timelevel', 'start' )
     1145!
     1146!--       Set the swap level for all modules
     1147          CALL module_interface_swap_timelevel( MOD( timestep_count, 2) )
     1148!
     1149!--       Set the swap level for steering the pmc data transfer
     1150          IF ( nested_run )  CALL pmci_set_swaplevel( MOD( timestep_count, 2) + 1 )  !> @todo: why the +1 ?
     1151
     1152          CALL cpu_log( log_point(28), 'swap_timelevel', 'stop' )
    11391153
    11401154!
Note: See TracChangeset for help on using the changeset viewer.