source: palm/trunk/SOURCE/header.f90 @ 1764

Last change on this file since 1764 was 1764, checked in by raasch, 8 years ago

update of the nested domain system + some bugfixes

  • Property svn:keywords set to Id
File size: 93.3 KB
Line 
1!> @file header.f90
2!--------------------------------------------------------------------------------!
3! This file is part of PALM.
4!
5! PALM is free software: you can redistribute it and/or modify it under the terms
6! of the GNU General Public License as published by the Free Software Foundation,
7! either version 3 of the License, or (at your option) any later version.
8!
9! PALM is distributed in the hope that it will be useful, but WITHOUT ANY
10! WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
11! A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
12!
13! You should have received a copy of the GNU General Public License along with
14! PALM. If not, see <http://www.gnu.org/licenses/>.
15!
16! Copyright 1997-2015 Leibniz Universitaet Hannover
17!--------------------------------------------------------------------------------!
18!
19! Current revisions:
20! -----------------
21! output of nesting informations
22!
23! Former revisions:
24! -----------------
25! $Id: header.f90 1764 2016-02-28 12:45:19Z raasch $
26!
27! 1697 2015-10-28 17:14:10Z raasch
28! small E- and F-FORMAT changes to avoid informative compiler messages about
29! insufficient field width
30!
31! 1691 2015-10-26 16:17:44Z maronga
32! Renamed prandtl_layer to constant_flux_layer, renames rif_min/rif_max to
33! zeta_min/zeta_max.
34!
35! 1682 2015-10-07 23:56:08Z knoop
36! Code annotations made doxygen readable
37!
38! 1675 2015-10-02 08:28:59Z gronemeier
39! Bugfix: Definition of topography grid levels
40!
41! 1660 2015-09-21 08:15:16Z gronemeier
42! Bugfix: Definition of building/street canyon height if vertical grid stretching
43!         starts below the maximum topography height.
44!
45! 1590 2015-05-08 13:56:27Z maronga
46! Bugfix: Added TRIM statements for character strings for LSM and radiation code
47!
48! 1585 2015-04-30 07:05:52Z maronga
49! Further output for radiation model(s).
50!
51! 1575 2015-03-27 09:56:27Z raasch
52! adjustments for psolver-queries, output of seed_follows_topography
53!
54! 1560 2015-03-06 10:48:54Z keck
55! output for recycling y shift
56!
57! 1557 2015-03-05 16:43:04Z suehring
58! output for monotonic limiter
59!
60! 1551 2015-03-03 14:18:16Z maronga
61! Added informal output for land surface model and radiation model. Removed typo.
62!
63! 1496 2014-12-02 17:25:50Z maronga
64! Renamed: "radiation -> "cloud_top_radiation"
65!
66! 1484 2014-10-21 10:53:05Z kanani
67! Changes due to new module structure of the plant canopy model:
68!   module plant_canopy_model_mod and output for new canopy model parameters
69!   (alpha_lad, beta_lad, lai_beta,...) added,
70!   drag_coefficient, leaf_surface_concentration and scalar_exchange_coefficient
71!   renamed to canopy_drag_coeff, leaf_surface_conc and leaf_scalar_exch_coeff,
72!   learde renamed leaf_area_density.
73! Bugfix: DO-WHILE-loop for lad header information additionally restricted
74! by maximum number of gradient levels (currently 10)
75!
76! 1482 2014-10-18 12:34:45Z raasch
77! information about calculated or predefined virtual processor topology adjusted
78!
79! 1468 2014-09-24 14:06:57Z maronga
80! Adapted for use on up to 6-digit processor cores
81!
82! 1429 2014-07-15 12:53:45Z knoop
83! header exended to provide ensemble_member_nr if specified
84!
85! 1376 2014-04-26 11:21:22Z boeske
86! Correction of typos
87!
88! 1365 2014-04-22 15:03:56Z boeske
89! New section 'Large scale forcing and nudging':
90! output of large scale forcing and nudging information,
91! new section for initial profiles created
92!
93! 1359 2014-04-11 17:15:14Z hoffmann
94! dt_sort_particles removed
95!
96! 1353 2014-04-08 15:21:23Z heinze
97! REAL constants provided with KIND-attribute
98!
99! 1327 2014-03-21 11:00:16Z raasch
100! parts concerning iso2d and avs output removed,
101! -netcdf output queries
102!
103! 1324 2014-03-21 09:13:16Z suehring
104! Bugfix: module spectrum added
105!
106! 1322 2014-03-20 16:38:49Z raasch
107! REAL functions provided with KIND-attribute,
108! some REAL constants defined as wp-kind
109!
110! 1320 2014-03-20 08:40:49Z raasch
111! ONLY-attribute added to USE-statements,
112! kind-parameters added to all INTEGER and REAL declaration statements,
113! kinds are defined in new module kinds,
114! revision history before 2012 removed,
115! comment fields (!:) to be used for variable explanations added to
116! all variable declaration statements
117!
118! 1308 2014-03-13 14:58:42Z fricke
119! output of the fixed number of output time levels
120! output_format adjusted for masked data if netcdf_data_format > 5
121!
122! 1299 2014-03-06 13:15:21Z heinze
123! output for using large_scale subsidence in combination
124! with large_scale_forcing
125! reformatting, more detailed explanations
126!
127! 1241 2013-10-30 11:36:58Z heinze
128! output for nudging + large scale forcing from external file
129!
130! 1216 2013-08-26 09:31:42Z raasch
131! output for transpose_compute_overlap
132!
133! 1212 2013-08-15 08:46:27Z raasch
134! output for poisfft_hybrid removed
135!
136! 1179 2013-06-14 05:57:58Z raasch
137! output of reference_state, use_reference renamed use_single_reference_value
138!
139! 1159 2013-05-21 11:58:22Z fricke
140! +use_cmax
141!
142! 1115 2013-03-26 18:16:16Z hoffmann
143! descriptions for Seifert-Beheng-cloud-physics-scheme added
144!
145! 1111 2013-03-08 23:54:10Z raasch
146! output of accelerator board information
147! ibc_p_b = 2 removed
148!
149! 1108 2013-03-05 07:03:32Z raasch
150! bugfix for r1106
151!
152! 1106 2013-03-04 05:31:38Z raasch
153! some format changes for coupled runs
154!
155! 1092 2013-02-02 11:24:22Z raasch
156! unused variables removed
157!
158! 1036 2012-10-22 13:43:42Z raasch
159! code put under GPL (PALM 3.9)
160!
161! 1031 2012-10-19 14:35:30Z raasch
162! output of netCDF data format modified
163!
164! 1015 2012-09-27 09:23:24Z raasch
165! output of Adjustment of mixing length to the Prandtl mixing length at first
166! grid point above ground removed
167!
168! 1003 2012-09-14 14:35:53Z raasch
169! output of information about equal/unequal subdomain size removed
170!
171! 1001 2012-09-13 14:08:46Z raasch
172! all actions concerning leapfrog- and upstream-spline-scheme removed
173!
174! 978 2012-08-09 08:28:32Z fricke
175! -km_damp_max, outflow_damping_width
176! +pt_damping_factor, pt_damping_width
177! +z0h
178!
179! 964 2012-07-26 09:14:24Z raasch
180! output of profil-related quantities removed
181!
182! 940 2012-07-09 14:31:00Z raasch
183! Output in case of simulations for pure neutral stratification (no pt-equation
184! solved)
185!
186! 927 2012-06-06 19:15:04Z raasch
187! output of masking_method for mg-solver
188!
189! 868 2012-03-28 12:21:07Z raasch
190! translation velocity in Galilean transformation changed to 0.6 * ug
191!
192! 833 2012-02-22 08:55:55Z maronga
193! Adjusted format for leaf area density
194!
195! 828 2012-02-21 12:00:36Z raasch
196! output of dissipation_classes + radius_classes
197!
198! 825 2012-02-19 03:03:44Z raasch
199! Output of cloud physics parameters/quantities complemented and restructured
200!
201! Revision 1.1  1997/08/11 06:17:20  raasch
202! Initial revision
203!
204!
205! Description:
206! ------------
207!> Writing a header with all important information about the current run.
208!> This subroutine is called three times, two times at the beginning
209!> (writing information on files RUN_CONTROL and HEADER) and one time at the
210!> end of the run, then writing additional information about CPU-usage on file
211!> header.
212!-----------------------------------------------------------------------------!
213 SUBROUTINE header
214 
215
216    USE arrays_3d,                                                             &
217        ONLY:  pt_init, qsws, q_init, sa_init, shf, ug, vg, w_subs, zu, zw
218       
219    USE control_parameters
220       
221    USE cloud_parameters,                                                      &
222        ONLY:  cp, curvature_solution_effects, c_sedimentation,                &
223               limiter_sedimentation, l_v, nc_const, r_d, ventilation_effect
224       
225    USE cpulog,                                                                &
226        ONLY:  log_point_s
227       
228    USE dvrp_variables,                                                        &
229        ONLY:  use_seperate_pe_for_dvrp_output
230       
231    USE grid_variables,                                                        &
232        ONLY:  dx, dy
233       
234    USE indices,                                                               &
235        ONLY:  mg_loc_ind, nnx, nny, nnz, nx, ny, nxl_mg, nxr_mg, nyn_mg,      &
236               nys_mg, nzt, nzt_mg
237       
238    USE kinds
239   
240    USE land_surface_model_mod,                                                &
241        ONLY:  conserve_water_content, dewfall, land_surface, nzb_soil,        &
242               nzt_soil, root_fraction, soil_moisture, soil_temperature,       &
243               soil_type, soil_type_name, veg_type, veg_type_name, zs
244 
245    USE model_1d,                                                              &
246        ONLY:  damp_level_ind_1d, dt_pr_1d, dt_run_control_1d, end_time_1d
247       
248    USE particle_attributes,                                                   &
249        ONLY:  bc_par_b, bc_par_lr, bc_par_ns, bc_par_t, collision_kernel,     &
250               density_ratio, dissipation_classes, dt_min_part, dt_prel,       &
251               dt_write_particle_data, end_time_prel,                          &
252               maximum_number_of_tailpoints, maximum_tailpoint_age,            &
253               minimum_tailpoint_distance, number_of_particle_groups,          &
254               particle_advection, particle_advection_start,                   &
255               particles_per_point, pdx, pdy, pdz,  psb, psl, psn, psr, pss,   &
256               pst, radius, radius_classes, random_start_position,             &
257               seed_follows_topography,                                        &
258               total_number_of_particles, use_particle_tails,                  &
259               use_sgs_for_particles, total_number_of_tails,                   &
260               vertical_particle_advection, write_particle_statistics
261       
262    USE pegrid
263
264    USE plant_canopy_model_mod,                                                &
265        ONLY:  alpha_lad, beta_lad, calc_beta_lad_profile, canopy_drag_coeff,  &
266               canopy_mode, cthf, lad, lad_surface, lad_vertical_gradient,     &
267               lad_vertical_gradient_level, lad_vertical_gradient_level_ind,   &
268               lai_beta, leaf_scalar_exch_coeff, leaf_surface_conc, pch_index, &
269               plant_canopy
270
271    USE pmc_interface,                                                         &
272        ONLY:  cpl_id, cpl_parent_id, cpl_name, lower_left_coord_x,            &
273               lower_left_coord_y, nested_run, nesting_mode
274
275    USE radiation_model_mod,                                                   &
276        ONLY:  albedo, albedo_type, albedo_type_name, constant_albedo,         &
277               day_init, dt_radiation, lambda, lw_radiation, net_radiation,    &
278               radiation, radiation_scheme, sw_radiation, time_utc_init
279   
280    USE spectrum,                                                              &
281        ONLY:  comp_spectra_level, data_output_sp, plot_spectra_level,         &
282               spectra_direction
283
284    IMPLICIT NONE
285
286    CHARACTER (LEN=1)  ::  prec                !<
287   
288    CHARACTER (LEN=2)  ::  do2d_mode           !<
289   
290    CHARACTER (LEN=5)  ::  section_chr         !<
291   
292    CHARACTER (LEN=10) ::  coor_chr            !<
293    CHARACTER (LEN=10) ::  host_chr            !<
294   
295    CHARACTER (LEN=16) ::  begin_chr           !<
296   
297    CHARACTER (LEN=26) ::  ver_rev             !<
298   
299    CHARACTER (LEN=40) ::  output_format       !<
300   
301    CHARACTER (LEN=70) ::  char1               !<
302    CHARACTER (LEN=70) ::  char2               !<
303    CHARACTER (LEN=70) ::  dopr_chr            !<
304    CHARACTER (LEN=70) ::  do2d_xy             !<
305    CHARACTER (LEN=70) ::  do2d_xz             !<
306    CHARACTER (LEN=70) ::  do2d_yz             !<
307    CHARACTER (LEN=70) ::  do3d_chr            !<
308    CHARACTER (LEN=70) ::  domask_chr          !<
309    CHARACTER (LEN=70) ::  run_classification  !<
310   
311    CHARACTER (LEN=85) ::  roben               !<
312    CHARACTER (LEN=85) ::  runten              !<
313   
314    CHARACTER (LEN=86) ::  coordinates         !<
315    CHARACTER (LEN=86) ::  gradients           !<
316    CHARACTER (LEN=86) ::  leaf_area_density   !<
317    CHARACTER (LEN=86) ::  roots               !<
318    CHARACTER (LEN=86) ::  slices              !<
319    CHARACTER (LEN=86) ::  temperatures        !<
320    CHARACTER (LEN=86) ::  ugcomponent         !<
321    CHARACTER (LEN=86) ::  vgcomponent         !<
322
323    CHARACTER (LEN=1), DIMENSION(1:3) ::  dir = (/ 'x', 'y', 'z' /)  !<
324
325    INTEGER(iwp) ::  av        !<
326    INTEGER(iwp) ::  bh        !<
327    INTEGER(iwp) ::  blx       !<
328    INTEGER(iwp) ::  bly       !<
329    INTEGER(iwp) ::  bxl       !<
330    INTEGER(iwp) ::  bxr       !<
331    INTEGER(iwp) ::  byn       !<
332    INTEGER(iwp) ::  bys       !<
333    INTEGER(iwp) ::  ch        !<
334    INTEGER(iwp) ::  count     !<
335    INTEGER(iwp) ::  cwx       !<
336    INTEGER(iwp) ::  cwy       !<
337    INTEGER(iwp) ::  cxl       !<
338    INTEGER(iwp) ::  cxr       !<
339    INTEGER(iwp) ::  cyn       !<
340    INTEGER(iwp) ::  cys       !<
341    INTEGER(iwp) ::  dim       !<
342    INTEGER(iwp) ::  i         !<
343    INTEGER(iwp) ::  io        !<
344    INTEGER(iwp) ::  j         !<
345    INTEGER(iwp) ::  k         !<
346    INTEGER(iwp) ::  l         !<
347    INTEGER(iwp) ::  ll        !<
348    INTEGER(iwp) ::  mpi_type  !<
349   
350    REAL(wp) ::  canopy_height                    !< canopy height (in m)
351    REAL(wp) ::  cpuseconds_per_simulated_second  !<
352
353!
354!-- Open the output file. At the end of the simulation, output is directed
355!-- to unit 19.
356    IF ( ( runnr == 0 .OR. force_print_header )  .AND. &
357         .NOT. simulated_time_at_begin /= simulated_time )  THEN
358       io = 15   !  header output on file RUN_CONTROL
359    ELSE
360       io = 19   !  header output on file HEADER
361    ENDIF
362    CALL check_open( io )
363
364!
365!-- At the end of the run, output file (HEADER) will be rewritten with
366!-- new information
367    IF ( io == 19 .AND. simulated_time_at_begin /= simulated_time ) REWIND( 19 )
368
369!
370!-- Determine kind of model run
371    IF ( TRIM( initializing_actions ) == 'read_restart_data' )  THEN
372       run_classification = 'restart run'
373    ELSEIF ( TRIM( initializing_actions ) == 'cyclic_fill' )  THEN
374       run_classification = 'run with cyclic fill of 3D - prerun data'
375    ELSEIF ( INDEX( initializing_actions, 'set_constant_profiles' ) /= 0 )  THEN
376       run_classification = 'run without 1D - prerun'
377    ELSEIF ( INDEX( initializing_actions, 'set_1d-model_profiles' ) /= 0 )  THEN
378       run_classification = 'run with 1D - prerun'
379    ELSEIF ( INDEX( initializing_actions, 'by_user' ) /=0 )  THEN
380       run_classification = 'run initialized by user'
381    ELSE
382       message_string = ' unknown action(s): ' // TRIM( initializing_actions )
383       CALL message( 'header', 'PA0191', 0, 0, 0, 6, 0 )
384    ENDIF
385    IF ( nested_run )  run_classification = 'nested ' // run_classification
386    IF ( ocean )  THEN
387       run_classification = 'ocean - ' // run_classification
388    ELSE
389       run_classification = 'atmosphere - ' // run_classification
390    ENDIF
391
392!
393!-- Run-identification, date, time, host
394    host_chr = host(1:10)
395    ver_rev = TRIM( version ) // '  ' // TRIM( revision )
396    WRITE ( io, 100 )  ver_rev, TRIM( run_classification )
397    IF ( TRIM( coupling_mode ) /= 'uncoupled' )  THEN
398#if defined( __mpi2 )
399       mpi_type = 2
400#else
401       mpi_type = 1
402#endif
403       WRITE ( io, 101 )  mpi_type, coupling_mode
404    ENDIF
405#if defined( __parallel )
406    IF ( coupling_start_time /= 0.0_wp )  THEN
407       IF ( coupling_start_time > simulated_time_at_begin )  THEN
408          WRITE ( io, 109 )
409       ELSE
410          WRITE ( io, 114 )
411       ENDIF
412    ENDIF
413#endif
414    IF ( ensemble_member_nr /= 0 )  THEN
415       WRITE ( io, 512 )  run_date, run_identifier, run_time, runnr,           &
416                       ADJUSTR( host_chr ), ensemble_member_nr
417    ELSE
418       WRITE ( io, 102 )  run_date, run_identifier, run_time, runnr,           &
419                       ADJUSTR( host_chr )
420    ENDIF
421#if defined( __parallel )
422    IF ( npex == -1  .AND.  npey == -1 )  THEN
423       char1 = 'calculated'
424    ELSE
425       char1 = 'predefined'
426    ENDIF
427    IF ( threads_per_task == 1 )  THEN
428       WRITE ( io, 103 )  numprocs, pdims(1), pdims(2), TRIM( char1 )
429    ELSE
430       WRITE ( io, 104 )  numprocs*threads_per_task, numprocs, &
431                          threads_per_task, pdims(1), pdims(2), TRIM( char1 )
432    ENDIF
433    IF ( num_acc_per_node /= 0 )  WRITE ( io, 117 )  num_acc_per_node   
434    IF ( ( host(1:3) == 'ibm'  .OR.  host(1:3) == 'nec'  .OR.    &
435           host(1:2) == 'lc'   .OR.  host(1:3) == 'dec' )  .AND. &
436         npex == -1  .AND.  pdims(2) == 1 )                      &
437    THEN
438       WRITE ( io, 106 )
439    ELSEIF ( pdims(2) == 1 )  THEN
440       WRITE ( io, 107 )  'x'
441    ELSEIF ( pdims(1) == 1 )  THEN
442       WRITE ( io, 107 )  'y'
443    ENDIF
444    IF ( use_seperate_pe_for_dvrp_output )  WRITE ( io, 105 )
445    IF ( numprocs /= maximum_parallel_io_streams )  THEN
446       WRITE ( io, 108 )  maximum_parallel_io_streams
447    ENDIF
448#else
449    IF ( num_acc_per_node /= 0 )  WRITE ( io, 120 )  num_acc_per_node
450#endif
451
452!
453!-- Nesting informations
454    IF ( nested_run )  THEN
455       WRITE ( io, 600 )  cpl_id, TRIM( cpl_name ), cpl_parent_id,             &
456                          nesting_mode, lower_left_coord_x, lower_left_coord_y
457    ENDIF
458    WRITE ( io, 99 )
459
460!
461!-- Numerical schemes
462    WRITE ( io, 110 )
463    IF ( psolver(1:7) == 'poisfft' )  THEN
464       WRITE ( io, 111 )  TRIM( fft_method )
465       IF ( transpose_compute_overlap )  WRITE( io, 115 )
466    ELSEIF ( psolver == 'sor' )  THEN
467       WRITE ( io, 112 )  nsor_ini, nsor, omega_sor
468    ELSEIF ( psolver(1:9) == 'multigrid' )  THEN
469       WRITE ( io, 135 )  TRIM(psolver), cycle_mg, maximum_grid_level, ngsrb
470       IF ( mg_cycles == -1 )  THEN
471          WRITE ( io, 140 )  residual_limit
472       ELSE
473          WRITE ( io, 141 )  mg_cycles
474       ENDIF
475       IF ( mg_switch_to_pe0_level == 0 )  THEN
476          WRITE ( io, 136 )  nxr_mg(1)-nxl_mg(1)+1, nyn_mg(1)-nys_mg(1)+1, &
477                             nzt_mg(1)
478       ELSEIF (  mg_switch_to_pe0_level /= -1 )  THEN
479          WRITE ( io, 137 )  mg_switch_to_pe0_level,            &
480                             mg_loc_ind(2,0)-mg_loc_ind(1,0)+1, &
481                             mg_loc_ind(4,0)-mg_loc_ind(3,0)+1, &
482                             nzt_mg(mg_switch_to_pe0_level),    &
483                             nxr_mg(1)-nxl_mg(1)+1, nyn_mg(1)-nys_mg(1)+1, &
484                             nzt_mg(1)
485       ENDIF
486       IF ( masking_method )  WRITE ( io, 144 )
487    ENDIF
488    IF ( call_psolver_at_all_substeps  .AND. timestep_scheme(1:5) == 'runge' ) &
489    THEN
490       WRITE ( io, 142 )
491    ENDIF
492
493    IF ( momentum_advec == 'pw-scheme' )  THEN
494       WRITE ( io, 113 )
495    ELSEIF (momentum_advec == 'ws-scheme' )  THEN
496       WRITE ( io, 503 )
497    ENDIF
498    IF ( scalar_advec == 'pw-scheme' )  THEN
499       WRITE ( io, 116 )
500    ELSEIF ( scalar_advec == 'ws-scheme' )  THEN
501       WRITE ( io, 504 )
502    ELSEIF ( scalar_advec == 'ws-scheme-mono' )  THEN
503       WRITE ( io, 513 )
504    ELSE
505       WRITE ( io, 118 )
506    ENDIF
507
508    WRITE ( io, 139 )  TRIM( loop_optimization )
509
510    IF ( galilei_transformation )  THEN
511       IF ( use_ug_for_galilei_tr )  THEN
512          char1 = '0.6 * geostrophic wind'
513       ELSE
514          char1 = 'mean wind in model domain'
515       ENDIF
516       IF ( simulated_time_at_begin == simulated_time )  THEN
517          char2 = 'at the start of the run'
518       ELSE
519          char2 = 'at the end of the run'
520       ENDIF
521       WRITE ( io, 119 )  TRIM( char1 ), TRIM( char2 ),                        &
522                          advected_distance_x/1000.0_wp,                       &
523                          advected_distance_y/1000.0_wp
524    ENDIF
525    WRITE ( io, 122 )  timestep_scheme
526    IF ( use_upstream_for_tke )  WRITE ( io, 143 )
527    IF ( rayleigh_damping_factor /= 0.0_wp )  THEN
528       IF ( .NOT. ocean )  THEN
529          WRITE ( io, 123 )  'above', rayleigh_damping_height, &
530               rayleigh_damping_factor
531       ELSE
532          WRITE ( io, 123 )  'below', rayleigh_damping_height, &
533               rayleigh_damping_factor
534       ENDIF
535    ENDIF
536    IF ( neutral )  WRITE ( io, 131 )  pt_surface
537    IF ( humidity )  THEN
538       IF ( .NOT. cloud_physics )  THEN
539          WRITE ( io, 129 )
540       ELSE
541          WRITE ( io, 130 )
542       ENDIF
543    ENDIF
544    IF ( passive_scalar )  WRITE ( io, 134 )
545    IF ( conserve_volume_flow )  THEN
546       WRITE ( io, 150 )  conserve_volume_flow_mode
547       IF ( TRIM( conserve_volume_flow_mode ) == 'bulk_velocity' )  THEN
548          WRITE ( io, 151 )  u_bulk, v_bulk
549       ENDIF
550    ELSEIF ( dp_external )  THEN
551       IF ( dp_smooth )  THEN
552          WRITE ( io, 152 )  dpdxy, dp_level_b, ', vertically smoothed.'
553       ELSE
554          WRITE ( io, 152 )  dpdxy, dp_level_b, '.'
555       ENDIF
556    ENDIF
557    WRITE ( io, 99 )
558
559!
560!-- Runtime and timestep information
561    WRITE ( io, 200 )
562    IF ( .NOT. dt_fixed )  THEN
563       WRITE ( io, 201 )  dt_max, cfl_factor
564    ELSE
565       WRITE ( io, 202 )  dt
566    ENDIF
567    WRITE ( io, 203 )  simulated_time_at_begin, end_time
568
569    IF ( time_restart /= 9999999.9_wp  .AND. &
570         simulated_time_at_begin == simulated_time )  THEN
571       IF ( dt_restart == 9999999.9_wp )  THEN
572          WRITE ( io, 204 )  ' Restart at:       ',time_restart
573       ELSE
574          WRITE ( io, 205 )  ' Restart at:       ',time_restart, dt_restart
575       ENDIF
576    ENDIF
577
578    IF ( simulated_time_at_begin /= simulated_time )  THEN
579       i = MAX ( log_point_s(10)%counts, 1 )
580       IF ( ( simulated_time - simulated_time_at_begin ) == 0.0_wp )  THEN
581          cpuseconds_per_simulated_second = 0.0_wp
582       ELSE
583          cpuseconds_per_simulated_second = log_point_s(10)%sum / &
584                                            ( simulated_time -    &
585                                              simulated_time_at_begin )
586       ENDIF
587       WRITE ( io, 206 )  simulated_time, log_point_s(10)%sum,      &
588                          log_point_s(10)%sum / REAL( i, KIND=wp ), &
589                          cpuseconds_per_simulated_second
590       IF ( time_restart /= 9999999.9_wp  .AND.  time_restart < end_time )  THEN
591          IF ( dt_restart == 9999999.9_wp )  THEN
592             WRITE ( io, 204 )  ' Next restart at:     ',time_restart
593          ELSE
594             WRITE ( io, 205 )  ' Next restart at:     ',time_restart, dt_restart
595          ENDIF
596       ENDIF
597    ENDIF
598
599
600!
601!-- Start time for coupled runs, if independent precursor runs for atmosphere
602!-- and ocean are used or have been used. In this case, coupling_start_time
603!-- defines the time when the coupling is switched on.
604    IF ( coupling_start_time /= 0.0_wp )  THEN
605       WRITE ( io, 207 )  coupling_start_time
606    ENDIF
607
608!
609!-- Computational grid
610    IF ( .NOT. ocean )  THEN
611       WRITE ( io, 250 )  dx, dy, dz, (nx+1)*dx, (ny+1)*dy, zu(nzt+1)
612       IF ( dz_stretch_level_index < nzt+1 )  THEN
613          WRITE ( io, 252 )  dz_stretch_level, dz_stretch_level_index, &
614                             dz_stretch_factor, dz_max
615       ENDIF
616    ELSE
617       WRITE ( io, 250 )  dx, dy, dz, (nx+1)*dx, (ny+1)*dy, zu(0)
618       IF ( dz_stretch_level_index > 0 )  THEN
619          WRITE ( io, 252 )  dz_stretch_level, dz_stretch_level_index, &
620                             dz_stretch_factor, dz_max
621       ENDIF
622    ENDIF
623    WRITE ( io, 254 )  nx, ny, nzt+1, MIN( nnx, nx+1 ), MIN( nny, ny+1 ), &
624                       MIN( nnz+2, nzt+2 )
625    IF ( sloping_surface )  WRITE ( io, 260 )  alpha_surface
626
627!
628!-- Large scale forcing and nudging
629    WRITE ( io, 160 )
630    IF ( large_scale_forcing )  THEN
631       WRITE ( io, 162 )
632       WRITE ( io, 163 )
633
634       IF ( large_scale_subsidence )  THEN
635          IF ( .NOT. use_subsidence_tendencies )  THEN
636             WRITE ( io, 164 )
637          ELSE
638             WRITE ( io, 165 )
639          ENDIF
640       ENDIF
641
642       IF ( bc_pt_b == 'dirichlet' )  THEN
643          WRITE ( io, 180 )
644       ELSEIF ( bc_pt_b == 'neumann' )  THEN
645          WRITE ( io, 181 )
646       ENDIF
647
648       IF ( bc_q_b == 'dirichlet' )  THEN
649          WRITE ( io, 182 )
650       ELSEIF ( bc_q_b == 'neumann' )  THEN
651          WRITE ( io, 183 )
652       ENDIF
653
654       WRITE ( io, 167 )
655       IF ( nudging )  THEN
656          WRITE ( io, 170 )
657       ENDIF
658    ELSE
659       WRITE ( io, 161 )
660       WRITE ( io, 171 )
661    ENDIF
662    IF ( large_scale_subsidence )  THEN
663       WRITE ( io, 168 )
664       WRITE ( io, 169 )
665    ENDIF
666
667!
668!-- Profile for the large scale vertial velocity
669!-- Building output strings, starting with surface value
670    IF ( large_scale_subsidence )  THEN
671       temperatures = '   0.0'
672       gradients = '------'
673       slices = '     0'
674       coordinates = '   0.0'
675       i = 1
676       DO  WHILE ( subs_vertical_gradient_level_i(i) /= -9999 )
677
678          WRITE (coor_chr,'(E10.2,7X)')  &
679                                w_subs(subs_vertical_gradient_level_i(i))
680          temperatures = TRIM( temperatures ) // ' ' // TRIM( coor_chr )
681
682          WRITE (coor_chr,'(E10.2,7X)')  subs_vertical_gradient(i)
683          gradients = TRIM( gradients ) // ' ' // TRIM( coor_chr )
684
685          WRITE (coor_chr,'(I10,7X)')  subs_vertical_gradient_level_i(i)
686          slices = TRIM( slices ) // ' ' // TRIM( coor_chr )
687
688          WRITE (coor_chr,'(F10.2,7X)')  subs_vertical_gradient_level(i)
689          coordinates = TRIM( coordinates ) // ' '  // TRIM( coor_chr )
690
691          IF ( i == 10 )  THEN
692             EXIT
693          ELSE
694             i = i + 1
695          ENDIF
696
697       ENDDO
698
699 
700       IF ( .NOT. large_scale_forcing )  THEN
701          WRITE ( io, 426 )  TRIM( coordinates ), TRIM( temperatures ), &
702                             TRIM( gradients ), TRIM( slices )
703       ENDIF
704
705
706    ENDIF
707
708!-- Profile of the geostrophic wind (component ug)
709!-- Building output strings
710    WRITE ( ugcomponent, '(F6.2)' )  ug_surface
711    gradients = '------'
712    slices = '     0'
713    coordinates = '   0.0'
714    i = 1
715    DO  WHILE ( ug_vertical_gradient_level_ind(i) /= -9999 )
716     
717       WRITE (coor_chr,'(F6.2,1X)')  ug(ug_vertical_gradient_level_ind(i))
718       ugcomponent = TRIM( ugcomponent ) // '  ' // TRIM( coor_chr )
719
720       WRITE (coor_chr,'(F6.2,1X)')  ug_vertical_gradient(i)
721       gradients = TRIM( gradients ) // '  ' // TRIM( coor_chr )
722
723       WRITE (coor_chr,'(I6,1X)')  ug_vertical_gradient_level_ind(i)
724       slices = TRIM( slices ) // '  ' // TRIM( coor_chr )
725
726       WRITE (coor_chr,'(F6.1,1X)')  ug_vertical_gradient_level(i)
727       coordinates = TRIM( coordinates ) // '  ' // TRIM( coor_chr )
728
729       IF ( i == 10 )  THEN
730          EXIT
731       ELSE
732          i = i + 1
733       ENDIF
734
735    ENDDO
736
737    IF ( .NOT. large_scale_forcing )  THEN
738       WRITE ( io, 423 )  TRIM( coordinates ), TRIM( ugcomponent ), &
739                          TRIM( gradients ), TRIM( slices )
740    ENDIF
741
742!-- Profile of the geostrophic wind (component vg)
743!-- Building output strings
744    WRITE ( vgcomponent, '(F6.2)' )  vg_surface
745    gradients = '------'
746    slices = '     0'
747    coordinates = '   0.0'
748    i = 1
749    DO  WHILE ( vg_vertical_gradient_level_ind(i) /= -9999 )
750
751       WRITE (coor_chr,'(F6.2,1X)')  vg(vg_vertical_gradient_level_ind(i))
752       vgcomponent = TRIM( vgcomponent ) // '  ' // TRIM( coor_chr )
753
754       WRITE (coor_chr,'(F6.2,1X)')  vg_vertical_gradient(i)
755       gradients = TRIM( gradients ) // '  ' // TRIM( coor_chr )
756
757       WRITE (coor_chr,'(I6,1X)')  vg_vertical_gradient_level_ind(i)
758       slices = TRIM( slices ) // '  ' // TRIM( coor_chr )
759
760       WRITE (coor_chr,'(F6.1,1X)')  vg_vertical_gradient_level(i)
761       coordinates = TRIM( coordinates ) // '  ' // TRIM( coor_chr )
762
763       IF ( i == 10 )  THEN
764          EXIT
765       ELSE
766          i = i + 1
767       ENDIF
768 
769    ENDDO
770
771    IF ( .NOT. large_scale_forcing )  THEN
772       WRITE ( io, 424 )  TRIM( coordinates ), TRIM( vgcomponent ), &
773                          TRIM( gradients ), TRIM( slices )
774    ENDIF
775
776!
777!-- Topography
778    WRITE ( io, 270 )  topography
779    SELECT CASE ( TRIM( topography ) )
780
781       CASE ( 'flat' )
782          ! no actions necessary
783
784       CASE ( 'single_building' )
785          blx = INT( building_length_x / dx )
786          bly = INT( building_length_y / dy )
787          bh  = MINLOC( ABS( zw - building_height ), 1 ) - 1
788          IF ( ABS( zw(bh  ) - building_height ) == &
789               ABS( zw(bh+1) - building_height )    )  bh = bh + 1
790
791          IF ( building_wall_left == 9999999.9_wp )  THEN
792             building_wall_left = ( nx + 1 - blx ) / 2 * dx
793          ENDIF
794          bxl = INT ( building_wall_left / dx + 0.5_wp )
795          bxr = bxl + blx
796
797          IF ( building_wall_south == 9999999.9_wp )  THEN
798             building_wall_south = ( ny + 1 - bly ) / 2 * dy
799          ENDIF
800          bys = INT ( building_wall_south / dy + 0.5_wp )
801          byn = bys + bly
802
803          WRITE ( io, 271 )  building_length_x, building_length_y, &
804                             building_height, bxl, bxr, bys, byn
805
806       CASE ( 'single_street_canyon' )
807          ch  = MINLOC( ABS( zw - canyon_height ), 1 ) - 1
808          IF ( ABS( zw(ch  ) - canyon_height ) == &
809               ABS( zw(ch+1) - canyon_height )    )  ch = ch + 1
810          IF ( canyon_width_x /= 9999999.9_wp )  THEN
811!
812!--          Street canyon in y direction
813             cwx = NINT( canyon_width_x / dx )
814             IF ( canyon_wall_left == 9999999.9_wp )  THEN
815                canyon_wall_left = ( nx + 1 - cwx ) / 2 * dx
816             ENDIF
817             cxl = NINT( canyon_wall_left / dx )
818             cxr = cxl + cwx
819             WRITE ( io, 272 )  'y', canyon_height, ch, 'u', cxl, cxr
820
821          ELSEIF ( canyon_width_y /= 9999999.9_wp )  THEN
822!
823!--          Street canyon in x direction
824             cwy = NINT( canyon_width_y / dy )
825             IF ( canyon_wall_south == 9999999.9_wp )  THEN
826                canyon_wall_south = ( ny + 1 - cwy ) / 2 * dy
827             ENDIF
828             cys = NINT( canyon_wall_south / dy )
829             cyn = cys + cwy
830             WRITE ( io, 272 )  'x', canyon_height, ch, 'v', cys, cyn
831          ENDIF
832
833    END SELECT
834
835    IF ( TRIM( topography ) /= 'flat' )  THEN
836       IF ( TRIM( topography_grid_convention ) == ' ' )  THEN
837          IF ( TRIM( topography ) == 'single_building' .OR.  &
838               TRIM( topography ) == 'single_street_canyon' )  THEN
839             WRITE ( io, 278 )
840          ELSEIF ( TRIM( topography ) == 'read_from_file' )  THEN
841             WRITE ( io, 279 )
842          ENDIF
843       ELSEIF ( TRIM( topography_grid_convention ) == 'cell_edge' )  THEN
844          WRITE ( io, 278 )
845       ELSEIF ( TRIM( topography_grid_convention ) == 'cell_center' )  THEN
846          WRITE ( io, 279 )
847       ENDIF
848    ENDIF
849
850    IF ( plant_canopy )  THEN
851   
852       canopy_height = pch_index * dz
853
854       WRITE ( io, 280 )  canopy_mode, canopy_height, pch_index,               &
855                          canopy_drag_coeff
856       IF ( passive_scalar )  THEN
857          WRITE ( io, 281 )  leaf_scalar_exch_coeff,                           &
858                             leaf_surface_conc
859       ENDIF
860
861!
862!--    Heat flux at the top of vegetation
863       WRITE ( io, 282 )  cthf
864
865!
866!--    Leaf area density profile, calculated either from given vertical
867!--    gradients or from beta probability density function.
868       IF (  .NOT.  calc_beta_lad_profile )  THEN
869
870!--       Building output strings, starting with surface value
871          WRITE ( leaf_area_density, '(F7.4)' )  lad_surface
872          gradients = '------'
873          slices = '     0'
874          coordinates = '   0.0'
875          i = 1
876          DO  WHILE ( i < 11  .AND.  lad_vertical_gradient_level_ind(i) /= -9999 )
877
878             WRITE (coor_chr,'(F7.2)')  lad(lad_vertical_gradient_level_ind(i))
879             leaf_area_density = TRIM( leaf_area_density ) // ' ' // TRIM( coor_chr )
880 
881             WRITE (coor_chr,'(F7.2)')  lad_vertical_gradient(i)
882             gradients = TRIM( gradients ) // ' ' // TRIM( coor_chr )
883
884             WRITE (coor_chr,'(I7)')  lad_vertical_gradient_level_ind(i)
885             slices = TRIM( slices ) // ' ' // TRIM( coor_chr )
886
887             WRITE (coor_chr,'(F7.1)')  lad_vertical_gradient_level(i)
888             coordinates = TRIM( coordinates ) // ' '  // TRIM( coor_chr )
889
890             i = i + 1
891          ENDDO
892
893          WRITE ( io, 283 )  TRIM( coordinates ), TRIM( leaf_area_density ),              &
894                             TRIM( gradients ), TRIM( slices )
895
896       ELSE
897       
898          WRITE ( leaf_area_density, '(F7.4)' )  lad_surface
899          coordinates = '   0.0'
900         
901          DO  k = 1, pch_index
902
903             WRITE (coor_chr,'(F7.2)')  lad(k)
904             leaf_area_density = TRIM( leaf_area_density ) // ' ' // TRIM( coor_chr )
905 
906             WRITE (coor_chr,'(F7.1)')  zu(k)
907             coordinates = TRIM( coordinates ) // ' '  // TRIM( coor_chr )
908
909          ENDDO       
910
911          WRITE ( io, 284 ) TRIM( coordinates ), TRIM( leaf_area_density ), alpha_lad,    &
912                            beta_lad, lai_beta
913
914       ENDIF 
915
916    ENDIF
917
918
919    IF ( land_surface )  THEN
920
921       temperatures = ''
922       gradients    = '' ! use for humidity here
923       coordinates  = '' ! use for height
924       roots        = '' ! use for root fraction
925       slices       = '' ! use for index
926
927       i = 1
928       DO i = nzb_soil, nzt_soil
929          WRITE (coor_chr,'(F10.2,7X)') soil_temperature(i)
930          temperatures = TRIM( temperatures ) // ' ' // TRIM( coor_chr )
931
932          WRITE (coor_chr,'(F10.2,7X)') soil_moisture(i)
933          gradients = TRIM( gradients ) // ' ' // TRIM( coor_chr )
934
935          WRITE (coor_chr,'(F10.2,7X)')  - zs(i)
936          coordinates = TRIM( coordinates ) // ' '  // TRIM( coor_chr )
937
938          WRITE (coor_chr,'(F10.2,7X)')  root_fraction(i)
939          roots = TRIM( roots ) // ' '  // TRIM( coor_chr )
940
941          WRITE (coor_chr,'(I10,7X)')  i
942          slices = TRIM( slices ) // ' '  // TRIM( coor_chr )
943
944
945       ENDDO
946
947!
948!--    Write land surface model header
949       WRITE( io, 419 )
950       IF ( conserve_water_content )  THEN
951          WRITE( io, 440 )
952       ELSE
953          WRITE( io, 441 )
954       ENDIF
955
956       IF ( dewfall )  THEN
957          WRITE( io, 442 )
958       ELSE
959          WRITE( io, 443 )
960       ENDIF
961
962       WRITE( io, 438 ) TRIM( veg_type_name(veg_type) ),                       &
963                        TRIM (soil_type_name(soil_type) )
964       WRITE( io, 439 ) TRIM( coordinates ), TRIM( temperatures ),             &
965                        TRIM( gradients ), TRIM( roots ), TRIM( slices )
966
967
968    ENDIF
969
970    IF ( radiation )  THEN
971!
972!--    Write radiation model header
973       WRITE( io, 444 )
974
975       IF ( radiation_scheme == "constant" )  THEN
976          WRITE( io, 445 ) net_radiation
977       ELSEIF ( radiation_scheme == "clear-sky" )  THEN
978          WRITE( io, 446 )
979       ELSEIF ( radiation_scheme == "rrtmg" )  THEN
980          WRITE( io, 447 )
981          IF ( .NOT. lw_radiation )  WRITE( io, 458 )
982          IF ( .NOT. sw_radiation )  WRITE( io, 459 )
983       ENDIF
984
985       IF ( albedo_type == 0 )  THEN
986          WRITE( io, 448 ) albedo
987       ELSE
988          WRITE( io, 456 ) TRIM( albedo_type_name(albedo_type) )
989       ENDIF
990       IF ( constant_albedo )  THEN
991          WRITE( io, 457 )
992       ENDIF
993       WRITE( io, 449 ) dt_radiation
994    ENDIF
995
996
997!
998!-- Boundary conditions
999    IF ( ibc_p_b == 0 )  THEN
1000       runten = 'p(0)     = 0      |'
1001    ELSEIF ( ibc_p_b == 1 )  THEN
1002       runten = 'p(0)     = p(1)   |'
1003    ENDIF
1004    IF ( ibc_p_t == 0 )  THEN
1005       roben  = 'p(nzt+1) = 0      |'
1006    ELSE
1007       roben  = 'p(nzt+1) = p(nzt) |'
1008    ENDIF
1009
1010    IF ( ibc_uv_b == 0 )  THEN
1011       runten = TRIM( runten ) // ' uv(0)     = -uv(1)                |'
1012    ELSE
1013       runten = TRIM( runten ) // ' uv(0)     = uv(1)                 |'
1014    ENDIF
1015    IF ( TRIM( bc_uv_t ) == 'dirichlet_0' )  THEN
1016       roben  = TRIM( roben  ) // ' uv(nzt+1) = 0                     |'
1017    ELSEIF ( ibc_uv_t == 0 )  THEN
1018       roben  = TRIM( roben  ) // ' uv(nzt+1) = ug(nzt+1), vg(nzt+1)  |'
1019    ELSE
1020       roben  = TRIM( roben  ) // ' uv(nzt+1) = uv(nzt)               |'
1021    ENDIF
1022
1023    IF ( ibc_pt_b == 0 )  THEN
1024       IF ( land_surface )  THEN
1025          runten = TRIM( runten ) // ' pt(0)     = from soil model'
1026       ELSE
1027          runten = TRIM( runten ) // ' pt(0)     = pt_surface'
1028       ENDIF
1029    ELSEIF ( ibc_pt_b == 1 )  THEN
1030       runten = TRIM( runten ) // ' pt(0)     = pt(1)'
1031    ELSEIF ( ibc_pt_b == 2 )  THEN
1032       runten = TRIM( runten ) // ' pt(0)     = from coupled model'
1033    ENDIF
1034    IF ( ibc_pt_t == 0 )  THEN
1035       roben  = TRIM( roben  ) // ' pt(nzt+1) = pt_top'
1036    ELSEIF( ibc_pt_t == 1 )  THEN
1037       roben  = TRIM( roben  ) // ' pt(nzt+1) = pt(nzt)'
1038    ELSEIF( ibc_pt_t == 2 )  THEN
1039       roben  = TRIM( roben  ) // ' pt(nzt+1) = pt(nzt) + dpt/dz_ini'
1040
1041    ENDIF
1042
1043    WRITE ( io, 300 )  runten, roben
1044
1045    IF ( .NOT. constant_diffusion )  THEN
1046       IF ( ibc_e_b == 1 )  THEN
1047          runten = 'e(0)     = e(1)'
1048       ELSE
1049          runten = 'e(0)     = e(1) = (u*/0.1)**2'
1050       ENDIF
1051       roben = 'e(nzt+1) = e(nzt) = e(nzt-1)'
1052
1053       WRITE ( io, 301 )  'e', runten, roben       
1054
1055    ENDIF
1056
1057    IF ( ocean )  THEN
1058       runten = 'sa(0)    = sa(1)'
1059       IF ( ibc_sa_t == 0 )  THEN
1060          roben =  'sa(nzt+1) = sa_surface'
1061       ELSE
1062          roben =  'sa(nzt+1) = sa(nzt)'
1063       ENDIF
1064       WRITE ( io, 301 ) 'sa', runten, roben
1065    ENDIF
1066
1067    IF ( humidity )  THEN
1068       IF ( ibc_q_b == 0 )  THEN
1069          IF ( land_surface )  THEN
1070             runten = 'q(0)     = from soil model'
1071          ELSE
1072             runten = 'q(0)     = q_surface'
1073          ENDIF
1074
1075       ELSE
1076          runten = 'q(0)     = q(1)'
1077       ENDIF
1078       IF ( ibc_q_t == 0 )  THEN
1079          roben =  'q(nzt)   = q_top'
1080       ELSE
1081          roben =  'q(nzt)   = q(nzt-1) + dq/dz'
1082       ENDIF
1083       WRITE ( io, 301 ) 'q', runten, roben
1084    ENDIF
1085
1086    IF ( passive_scalar )  THEN
1087       IF ( ibc_q_b == 0 )  THEN
1088          runten = 's(0)     = s_surface'
1089       ELSE
1090          runten = 's(0)     = s(1)'
1091       ENDIF
1092       IF ( ibc_q_t == 0 )  THEN
1093          roben =  's(nzt)   = s_top'
1094       ELSE
1095          roben =  's(nzt)   = s(nzt-1) + ds/dz'
1096       ENDIF
1097       WRITE ( io, 301 ) 's', runten, roben
1098    ENDIF
1099
1100    IF ( use_surface_fluxes )  THEN
1101       WRITE ( io, 303 )
1102       IF ( constant_heatflux )  THEN
1103          IF ( large_scale_forcing .AND. lsf_surf )  THEN
1104             WRITE ( io, 306 )  shf(0,0)
1105          ELSE
1106             WRITE ( io, 306 )  surface_heatflux
1107          ENDIF
1108          IF ( random_heatflux )  WRITE ( io, 307 )
1109       ENDIF
1110       IF ( humidity  .AND.  constant_waterflux )  THEN
1111          IF ( large_scale_forcing .AND. lsf_surf )  THEN
1112             WRITE ( io, 311 ) qsws(0,0)
1113          ELSE
1114             WRITE ( io, 311 ) surface_waterflux
1115          ENDIF
1116       ENDIF
1117       IF ( passive_scalar  .AND.  constant_waterflux )  THEN
1118          WRITE ( io, 313 ) surface_waterflux
1119       ENDIF
1120    ENDIF
1121
1122    IF ( use_top_fluxes )  THEN
1123       WRITE ( io, 304 )
1124       IF ( coupling_mode == 'uncoupled' )  THEN
1125          WRITE ( io, 320 )  top_momentumflux_u, top_momentumflux_v
1126          IF ( constant_top_heatflux )  THEN
1127             WRITE ( io, 306 )  top_heatflux
1128          ENDIF
1129       ELSEIF ( coupling_mode == 'ocean_to_atmosphere' )  THEN
1130          WRITE ( io, 316 )
1131       ENDIF
1132       IF ( ocean  .AND.  constant_top_salinityflux )  THEN
1133          WRITE ( io, 309 )  top_salinityflux
1134       ENDIF
1135       IF ( humidity  .OR.  passive_scalar )  THEN
1136          WRITE ( io, 315 )
1137       ENDIF
1138    ENDIF
1139
1140    IF ( constant_flux_layer )  THEN
1141       WRITE ( io, 305 )  (zu(1)-zu(0)), roughness_length,                     &
1142                          z0h_factor*roughness_length, kappa,                  &
1143                          zeta_min, zeta_max
1144       IF ( .NOT. constant_heatflux )  WRITE ( io, 308 )
1145       IF ( humidity  .AND.  .NOT. constant_waterflux )  THEN
1146          WRITE ( io, 312 )
1147       ENDIF
1148       IF ( passive_scalar  .AND.  .NOT. constant_waterflux )  THEN
1149          WRITE ( io, 314 )
1150       ENDIF
1151    ELSE
1152       IF ( INDEX(initializing_actions, 'set_1d-model_profiles') /= 0 )  THEN
1153          WRITE ( io, 310 )  zeta_min, zeta_max
1154       ENDIF
1155    ENDIF
1156
1157    WRITE ( io, 317 )  bc_lr, bc_ns
1158    IF ( .NOT. bc_lr_cyc  .OR.  .NOT. bc_ns_cyc )  THEN
1159       WRITE ( io, 318 )  use_cmax, pt_damping_width, pt_damping_factor       
1160       IF ( turbulent_inflow )  THEN
1161          IF ( .NOT. recycling_yshift ) THEN
1162             WRITE ( io, 319 )  recycling_width, recycling_plane, &
1163                                inflow_damping_height, inflow_damping_width
1164          ELSE
1165             WRITE ( io, 322 )  recycling_width, recycling_plane, &
1166                                inflow_damping_height, inflow_damping_width
1167          END IF
1168       ENDIF
1169    ENDIF
1170
1171!
1172!-- Initial Profiles
1173    WRITE ( io, 321 )
1174!
1175!-- Initial wind profiles
1176    IF ( u_profile(1) /= 9999999.9_wp )  WRITE ( io, 427 )
1177
1178!
1179!-- Initial temperature profile
1180!-- Building output strings, starting with surface temperature
1181    WRITE ( temperatures, '(F6.2)' )  pt_surface
1182    gradients = '------'
1183    slices = '     0'
1184    coordinates = '   0.0'
1185    i = 1
1186    DO  WHILE ( pt_vertical_gradient_level_ind(i) /= -9999 )
1187
1188       WRITE (coor_chr,'(F7.2)')  pt_init(pt_vertical_gradient_level_ind(i))
1189       temperatures = TRIM( temperatures ) // ' ' // TRIM( coor_chr )
1190
1191       WRITE (coor_chr,'(F7.2)')  pt_vertical_gradient(i)
1192       gradients = TRIM( gradients ) // ' ' // TRIM( coor_chr )
1193
1194       WRITE (coor_chr,'(I7)')  pt_vertical_gradient_level_ind(i)
1195       slices = TRIM( slices ) // ' ' // TRIM( coor_chr )
1196
1197       WRITE (coor_chr,'(F7.1)')  pt_vertical_gradient_level(i)
1198       coordinates = TRIM( coordinates ) // ' '  // TRIM( coor_chr )
1199
1200       IF ( i == 10 )  THEN
1201          EXIT
1202       ELSE
1203          i = i + 1
1204       ENDIF
1205
1206    ENDDO
1207
1208    IF ( .NOT. nudging )  THEN
1209       WRITE ( io, 420 )  TRIM( coordinates ), TRIM( temperatures ), &
1210                          TRIM( gradients ), TRIM( slices )
1211    ELSE
1212       WRITE ( io, 428 ) 
1213    ENDIF
1214
1215!
1216!-- Initial humidity profile
1217!-- Building output strings, starting with surface humidity
1218    IF ( humidity  .OR.  passive_scalar )  THEN
1219       WRITE ( temperatures, '(E8.1)' )  q_surface
1220       gradients = '--------'
1221       slices = '       0'
1222       coordinates = '     0.0'
1223       i = 1
1224       DO  WHILE ( q_vertical_gradient_level_ind(i) /= -9999 )
1225         
1226          WRITE (coor_chr,'(E8.1,4X)')  q_init(q_vertical_gradient_level_ind(i))
1227          temperatures = TRIM( temperatures ) // '  ' // TRIM( coor_chr )
1228
1229          WRITE (coor_chr,'(E8.1,4X)')  q_vertical_gradient(i)
1230          gradients = TRIM( gradients ) // '  ' // TRIM( coor_chr )
1231         
1232          WRITE (coor_chr,'(I8,4X)')  q_vertical_gradient_level_ind(i)
1233          slices = TRIM( slices ) // '  ' // TRIM( coor_chr )
1234         
1235          WRITE (coor_chr,'(F8.1,4X)')  q_vertical_gradient_level(i)
1236          coordinates = TRIM( coordinates ) // '  '  // TRIM( coor_chr )
1237
1238          IF ( i == 10 )  THEN
1239             EXIT
1240          ELSE
1241             i = i + 1
1242          ENDIF
1243
1244       ENDDO
1245
1246       IF ( humidity )  THEN
1247          IF ( .NOT. nudging )  THEN
1248             WRITE ( io, 421 )  TRIM( coordinates ), TRIM( temperatures ), &
1249                                TRIM( gradients ), TRIM( slices )
1250          ENDIF
1251       ELSE
1252          WRITE ( io, 422 )  TRIM( coordinates ), TRIM( temperatures ), &
1253                             TRIM( gradients ), TRIM( slices )
1254       ENDIF
1255    ENDIF
1256
1257!
1258!-- Initial salinity profile
1259!-- Building output strings, starting with surface salinity
1260    IF ( ocean )  THEN
1261       WRITE ( temperatures, '(F6.2)' )  sa_surface
1262       gradients = '------'
1263       slices = '     0'
1264       coordinates = '   0.0'
1265       i = 1
1266       DO  WHILE ( sa_vertical_gradient_level_ind(i) /= -9999 )
1267
1268          WRITE (coor_chr,'(F7.2)')  sa_init(sa_vertical_gradient_level_ind(i))
1269          temperatures = TRIM( temperatures ) // ' ' // TRIM( coor_chr )
1270
1271          WRITE (coor_chr,'(F7.2)')  sa_vertical_gradient(i)
1272          gradients = TRIM( gradients ) // ' ' // TRIM( coor_chr )
1273
1274          WRITE (coor_chr,'(I7)')  sa_vertical_gradient_level_ind(i)
1275          slices = TRIM( slices ) // ' ' // TRIM( coor_chr )
1276
1277          WRITE (coor_chr,'(F7.1)')  sa_vertical_gradient_level(i)
1278          coordinates = TRIM( coordinates ) // ' '  // TRIM( coor_chr )
1279
1280          IF ( i == 10 )  THEN
1281             EXIT
1282          ELSE
1283             i = i + 1
1284          ENDIF
1285
1286       ENDDO
1287
1288       WRITE ( io, 425 )  TRIM( coordinates ), TRIM( temperatures ), &
1289                          TRIM( gradients ), TRIM( slices )
1290    ENDIF
1291
1292
1293!
1294!-- Listing of 1D-profiles
1295    WRITE ( io, 325 )  dt_dopr_listing
1296    IF ( averaging_interval_pr /= 0.0_wp )  THEN
1297       WRITE ( io, 326 )  averaging_interval_pr, dt_averaging_input_pr
1298    ENDIF
1299
1300!
1301!-- DATA output
1302    WRITE ( io, 330 )
1303    IF ( averaging_interval_pr /= 0.0_wp )  THEN
1304       WRITE ( io, 326 )  averaging_interval_pr, dt_averaging_input_pr
1305    ENDIF
1306
1307!
1308!-- 1D-profiles
1309    dopr_chr = 'Profile:'
1310    IF ( dopr_n /= 0 )  THEN
1311       WRITE ( io, 331 )
1312
1313       output_format = ''
1314       output_format = output_format_netcdf
1315       WRITE ( io, 344 )  output_format
1316
1317       DO  i = 1, dopr_n
1318          dopr_chr = TRIM( dopr_chr ) // ' ' // TRIM( data_output_pr(i) ) // ','
1319          IF ( LEN_TRIM( dopr_chr ) >= 60 )  THEN
1320             WRITE ( io, 332 )  dopr_chr
1321             dopr_chr = '       :'
1322          ENDIF
1323       ENDDO
1324
1325       IF ( dopr_chr /= '' )  THEN
1326          WRITE ( io, 332 )  dopr_chr
1327       ENDIF
1328       WRITE ( io, 333 )  dt_dopr, averaging_interval_pr, dt_averaging_input_pr
1329       IF ( skip_time_dopr /= 0.0_wp )  WRITE ( io, 339 )  skip_time_dopr
1330    ENDIF
1331
1332!
1333!-- 2D-arrays
1334    DO  av = 0, 1
1335
1336       i = 1
1337       do2d_xy = ''
1338       do2d_xz = ''
1339       do2d_yz = ''
1340       DO  WHILE ( do2d(av,i) /= ' ' )
1341
1342          l = MAX( 2, LEN_TRIM( do2d(av,i) ) )
1343          do2d_mode = do2d(av,i)(l-1:l)
1344
1345          SELECT CASE ( do2d_mode )
1346             CASE ( 'xy' )
1347                ll = LEN_TRIM( do2d_xy )
1348                do2d_xy = do2d_xy(1:ll) // ' ' // do2d(av,i)(1:l-3) // ','
1349             CASE ( 'xz' )
1350                ll = LEN_TRIM( do2d_xz )
1351                do2d_xz = do2d_xz(1:ll) // ' ' // do2d(av,i)(1:l-3) // ','
1352             CASE ( 'yz' )
1353                ll = LEN_TRIM( do2d_yz )
1354                do2d_yz = do2d_yz(1:ll) // ' ' // do2d(av,i)(1:l-3) // ','
1355          END SELECT
1356
1357          i = i + 1
1358
1359       ENDDO
1360
1361       IF ( ( ( do2d_xy /= ''  .AND.  section(1,1) /= -9999 )  .OR.    &
1362              ( do2d_xz /= ''  .AND.  section(1,2) /= -9999 )  .OR.    &
1363              ( do2d_yz /= ''  .AND.  section(1,3) /= -9999 ) ) )  THEN
1364
1365          IF (  av == 0 )  THEN
1366             WRITE ( io, 334 )  ''
1367          ELSE
1368             WRITE ( io, 334 )  '(time-averaged)'
1369          ENDIF
1370
1371          IF ( do2d_at_begin )  THEN
1372             begin_chr = 'and at the start'
1373          ELSE
1374             begin_chr = ''
1375          ENDIF
1376
1377          output_format = ''
1378          output_format = output_format_netcdf
1379          WRITE ( io, 344 )  output_format
1380
1381          IF ( do2d_xy /= ''  .AND.  section(1,1) /= -9999 )  THEN
1382             i = 1
1383             slices = '/'
1384             coordinates = '/'
1385!
1386!--          Building strings with index and coordinate information of the
1387!--          slices
1388             DO  WHILE ( section(i,1) /= -9999 )
1389
1390                WRITE (section_chr,'(I5)')  section(i,1)
1391                section_chr = ADJUSTL( section_chr )
1392                slices = TRIM( slices ) // TRIM( section_chr ) // '/'
1393
1394                IF ( section(i,1) == -1 )  THEN
1395                   WRITE (coor_chr,'(F10.1)')  -1.0_wp
1396                ELSE
1397                   WRITE (coor_chr,'(F10.1)')  zu(section(i,1))
1398                ENDIF
1399                coor_chr = ADJUSTL( coor_chr )
1400                coordinates = TRIM( coordinates ) // TRIM( coor_chr ) // '/'
1401
1402                i = i + 1
1403             ENDDO
1404             IF ( av == 0 )  THEN
1405                WRITE ( io, 335 )  'XY', do2d_xy, dt_do2d_xy, &
1406                                   TRIM( begin_chr ), 'k', TRIM( slices ), &
1407                                   TRIM( coordinates )
1408                IF ( skip_time_do2d_xy /= 0.0_wp )  THEN
1409                   WRITE ( io, 339 )  skip_time_do2d_xy
1410                ENDIF
1411             ELSE
1412                WRITE ( io, 342 )  'XY', do2d_xy, dt_data_output_av, &
1413                                   TRIM( begin_chr ), averaging_interval, &
1414                                   dt_averaging_input, 'k', TRIM( slices ), &
1415                                   TRIM( coordinates )
1416                IF ( skip_time_data_output_av /= 0.0_wp )  THEN
1417                   WRITE ( io, 339 )  skip_time_data_output_av
1418                ENDIF
1419             ENDIF
1420             IF ( netcdf_data_format > 4 )  THEN
1421                WRITE ( io, 352 )  ntdim_2d_xy(av)
1422             ELSE
1423                WRITE ( io, 353 )
1424             ENDIF
1425          ENDIF
1426
1427          IF ( do2d_xz /= ''  .AND.  section(1,2) /= -9999 )  THEN
1428             i = 1
1429             slices = '/'
1430             coordinates = '/'
1431!
1432!--          Building strings with index and coordinate information of the
1433!--          slices
1434             DO  WHILE ( section(i,2) /= -9999 )
1435
1436                WRITE (section_chr,'(I5)')  section(i,2)
1437                section_chr = ADJUSTL( section_chr )
1438                slices = TRIM( slices ) // TRIM( section_chr ) // '/'
1439
1440                WRITE (coor_chr,'(F10.1)')  section(i,2) * dy
1441                coor_chr = ADJUSTL( coor_chr )
1442                coordinates = TRIM( coordinates ) // TRIM( coor_chr ) // '/'
1443
1444                i = i + 1
1445             ENDDO
1446             IF ( av == 0 )  THEN
1447                WRITE ( io, 335 )  'XZ', do2d_xz, dt_do2d_xz, &
1448                                   TRIM( begin_chr ), 'j', TRIM( slices ), &
1449                                   TRIM( coordinates )
1450                IF ( skip_time_do2d_xz /= 0.0_wp )  THEN
1451                   WRITE ( io, 339 )  skip_time_do2d_xz
1452                ENDIF
1453             ELSE
1454                WRITE ( io, 342 )  'XZ', do2d_xz, dt_data_output_av, &
1455                                   TRIM( begin_chr ), averaging_interval, &
1456                                   dt_averaging_input, 'j', TRIM( slices ), &
1457                                   TRIM( coordinates )
1458                IF ( skip_time_data_output_av /= 0.0_wp )  THEN
1459                   WRITE ( io, 339 )  skip_time_data_output_av
1460                ENDIF
1461             ENDIF
1462             IF ( netcdf_data_format > 4 )  THEN
1463                WRITE ( io, 352 )  ntdim_2d_xz(av)
1464             ELSE
1465                WRITE ( io, 353 )
1466             ENDIF
1467          ENDIF
1468
1469          IF ( do2d_yz /= ''  .AND.  section(1,3) /= -9999 )  THEN
1470             i = 1
1471             slices = '/'
1472             coordinates = '/'
1473!
1474!--          Building strings with index and coordinate information of the
1475!--          slices
1476             DO  WHILE ( section(i,3) /= -9999 )
1477
1478                WRITE (section_chr,'(I5)')  section(i,3)
1479                section_chr = ADJUSTL( section_chr )
1480                slices = TRIM( slices ) // TRIM( section_chr ) // '/'
1481
1482                WRITE (coor_chr,'(F10.1)')  section(i,3) * dx
1483                coor_chr = ADJUSTL( coor_chr )
1484                coordinates = TRIM( coordinates ) // TRIM( coor_chr ) // '/'
1485
1486                i = i + 1
1487             ENDDO
1488             IF ( av == 0 )  THEN
1489                WRITE ( io, 335 )  'YZ', do2d_yz, dt_do2d_yz, &
1490                                   TRIM( begin_chr ), 'i', TRIM( slices ), &
1491                                   TRIM( coordinates )
1492                IF ( skip_time_do2d_yz /= 0.0_wp )  THEN
1493                   WRITE ( io, 339 )  skip_time_do2d_yz
1494                ENDIF
1495             ELSE
1496                WRITE ( io, 342 )  'YZ', do2d_yz, dt_data_output_av, &
1497                                   TRIM( begin_chr ), averaging_interval, &
1498                                   dt_averaging_input, 'i', TRIM( slices ), &
1499                                   TRIM( coordinates )
1500                IF ( skip_time_data_output_av /= 0.0_wp )  THEN
1501                   WRITE ( io, 339 )  skip_time_data_output_av
1502                ENDIF
1503             ENDIF
1504             IF ( netcdf_data_format > 4 )  THEN
1505                WRITE ( io, 352 )  ntdim_2d_yz(av)
1506             ELSE
1507                WRITE ( io, 353 )
1508             ENDIF
1509          ENDIF
1510
1511       ENDIF
1512
1513    ENDDO
1514
1515!
1516!-- 3d-arrays
1517    DO  av = 0, 1
1518
1519       i = 1
1520       do3d_chr = ''
1521       DO  WHILE ( do3d(av,i) /= ' ' )
1522
1523          do3d_chr = TRIM( do3d_chr ) // ' ' // TRIM( do3d(av,i) ) // ','
1524          i = i + 1
1525
1526       ENDDO
1527
1528       IF ( do3d_chr /= '' )  THEN
1529          IF ( av == 0 )  THEN
1530             WRITE ( io, 336 )  ''
1531          ELSE
1532             WRITE ( io, 336 )  '(time-averaged)'
1533          ENDIF
1534
1535          output_format = output_format_netcdf
1536          WRITE ( io, 344 )  output_format
1537
1538          IF ( do3d_at_begin )  THEN
1539             begin_chr = 'and at the start'
1540          ELSE
1541             begin_chr = ''
1542          ENDIF
1543          IF ( av == 0 )  THEN
1544             WRITE ( io, 337 )  do3d_chr, dt_do3d, TRIM( begin_chr ), &
1545                                zu(nz_do3d), nz_do3d
1546          ELSE
1547             WRITE ( io, 343 )  do3d_chr, dt_data_output_av,           &
1548                                TRIM( begin_chr ), averaging_interval, &
1549                                dt_averaging_input, zu(nz_do3d), nz_do3d
1550          ENDIF
1551
1552          IF ( netcdf_data_format > 4 )  THEN
1553             WRITE ( io, 352 )  ntdim_3d(av)
1554          ELSE
1555             WRITE ( io, 353 )
1556          ENDIF
1557
1558          IF ( av == 0 )  THEN
1559             IF ( skip_time_do3d /= 0.0_wp )  THEN
1560                WRITE ( io, 339 )  skip_time_do3d
1561             ENDIF
1562          ELSE
1563             IF ( skip_time_data_output_av /= 0.0_wp )  THEN
1564                WRITE ( io, 339 )  skip_time_data_output_av
1565             ENDIF
1566          ENDIF
1567
1568       ENDIF
1569
1570    ENDDO
1571
1572!
1573!-- masked arrays
1574    IF ( masks > 0 )  WRITE ( io, 345 )  &
1575         mask_scale_x, mask_scale_y, mask_scale_z
1576    DO  mid = 1, masks
1577       DO  av = 0, 1
1578
1579          i = 1
1580          domask_chr = ''
1581          DO  WHILE ( domask(mid,av,i) /= ' ' )
1582             domask_chr = TRIM( domask_chr ) // ' ' //  &
1583                          TRIM( domask(mid,av,i) ) // ','
1584             i = i + 1
1585          ENDDO
1586
1587          IF ( domask_chr /= '' )  THEN
1588             IF ( av == 0 )  THEN
1589                WRITE ( io, 346 )  '', mid
1590             ELSE
1591                WRITE ( io, 346 )  ' (time-averaged)', mid
1592             ENDIF
1593
1594             output_format = output_format_netcdf
1595!--          Parallel output not implemented for mask data, hence
1596!--          output_format must be adjusted.
1597             IF ( netcdf_data_format == 5 ) output_format = 'netCDF4/HDF5'
1598             IF ( netcdf_data_format == 6 ) output_format = 'netCDF4/HDF5 classic'
1599             WRITE ( io, 344 )  output_format
1600
1601             IF ( av == 0 )  THEN
1602                WRITE ( io, 347 )  domask_chr, dt_domask(mid)
1603             ELSE
1604                WRITE ( io, 348 )  domask_chr, dt_data_output_av, &
1605                                   averaging_interval, dt_averaging_input
1606             ENDIF
1607
1608             IF ( av == 0 )  THEN
1609                IF ( skip_time_domask(mid) /= 0.0_wp )  THEN
1610                   WRITE ( io, 339 )  skip_time_domask(mid)
1611                ENDIF
1612             ELSE
1613                IF ( skip_time_data_output_av /= 0.0_wp )  THEN
1614                   WRITE ( io, 339 )  skip_time_data_output_av
1615                ENDIF
1616             ENDIF
1617!
1618!--          output locations
1619             DO  dim = 1, 3
1620                IF ( mask(mid,dim,1) >= 0.0_wp )  THEN
1621                   count = 0
1622                   DO  WHILE ( mask(mid,dim,count+1) >= 0.0_wp )
1623                      count = count + 1
1624                   ENDDO
1625                   WRITE ( io, 349 )  dir(dim), dir(dim), mid, dir(dim), &
1626                                      mask(mid,dim,:count)
1627                ELSEIF ( mask_loop(mid,dim,1) < 0.0_wp .AND.  &
1628                         mask_loop(mid,dim,2) < 0.0_wp .AND.  &
1629                         mask_loop(mid,dim,3) == 0.0_wp )  THEN
1630                   WRITE ( io, 350 )  dir(dim), dir(dim)
1631                ELSEIF ( mask_loop(mid,dim,3) == 0.0_wp )  THEN
1632                   WRITE ( io, 351 )  dir(dim), dir(dim), mid, dir(dim), &
1633                                      mask_loop(mid,dim,1:2)
1634                ELSE
1635                   WRITE ( io, 351 )  dir(dim), dir(dim), mid, dir(dim), &
1636                                      mask_loop(mid,dim,1:3)
1637                ENDIF
1638             ENDDO
1639          ENDIF
1640
1641       ENDDO
1642    ENDDO
1643
1644!
1645!-- Timeseries
1646    IF ( dt_dots /= 9999999.9_wp )  THEN
1647       WRITE ( io, 340 )
1648
1649       output_format = output_format_netcdf
1650       WRITE ( io, 344 )  output_format
1651       WRITE ( io, 341 )  dt_dots
1652    ENDIF
1653
1654#if defined( __dvrp_graphics )
1655!
1656!-- Dvrp-output
1657    IF ( dt_dvrp /= 9999999.9_wp )  THEN
1658       WRITE ( io, 360 )  dt_dvrp, TRIM( dvrp_output ), TRIM( dvrp_host ), &
1659                          TRIM( dvrp_username ), TRIM( dvrp_directory )
1660       i = 1
1661       l = 0
1662       m = 0
1663       DO WHILE ( mode_dvrp(i) /= ' ' )
1664          IF ( mode_dvrp(i)(1:10) == 'isosurface' )  THEN
1665             READ ( mode_dvrp(i), '(10X,I2)' )  j
1666             l = l + 1
1667             IF ( do3d(0,j) /= ' ' )  THEN
1668                WRITE ( io, 361 )  TRIM( do3d(0,j) ), threshold(l), &
1669                                   isosurface_color(:,l)
1670             ENDIF
1671          ELSEIF ( mode_dvrp(i)(1:6) == 'slicer' )  THEN
1672             READ ( mode_dvrp(i), '(6X,I2)' )  j
1673             m = m + 1
1674             IF ( do2d(0,j) /= ' ' )  THEN
1675                WRITE ( io, 362 )  TRIM( do2d(0,j) ), &
1676                                   slicer_range_limits_dvrp(:,m)
1677             ENDIF
1678          ELSEIF ( mode_dvrp(i)(1:9) == 'particles' )  THEN
1679             WRITE ( io, 363 )  dvrp_psize
1680             IF ( particle_dvrpsize /= 'none' )  THEN
1681                WRITE ( io, 364 )  'size', TRIM( particle_dvrpsize ), &
1682                                   dvrpsize_interval
1683             ENDIF
1684             IF ( particle_color /= 'none' )  THEN
1685                WRITE ( io, 364 )  'color', TRIM( particle_color ), &
1686                                   color_interval
1687             ENDIF
1688          ENDIF
1689          i = i + 1
1690       ENDDO
1691
1692       WRITE ( io, 365 )  groundplate_color, superelevation_x, &
1693                          superelevation_y, superelevation, clip_dvrp_l, &
1694                          clip_dvrp_r, clip_dvrp_s, clip_dvrp_n
1695
1696       IF ( TRIM( topography ) /= 'flat' )  THEN
1697          WRITE ( io, 366 )  topography_color
1698          IF ( cluster_size > 1 )  THEN
1699             WRITE ( io, 367 )  cluster_size
1700          ENDIF
1701       ENDIF
1702
1703    ENDIF
1704#endif
1705
1706#if defined( __spectra )
1707!
1708!-- Spectra output
1709    IF ( dt_dosp /= 9999999.9_wp )  THEN
1710       WRITE ( io, 370 )
1711
1712       output_format = output_format_netcdf
1713       WRITE ( io, 344 )  output_format
1714       WRITE ( io, 371 )  dt_dosp
1715       IF ( skip_time_dosp /= 0.0_wp )  WRITE ( io, 339 )  skip_time_dosp
1716       WRITE ( io, 372 )  ( data_output_sp(i), i = 1,10 ),     &
1717                          ( spectra_direction(i), i = 1,10 ),  &
1718                          ( comp_spectra_level(i), i = 1,100 ), &
1719                          ( plot_spectra_level(i), i = 1,100 ), &
1720                          averaging_interval_sp, dt_averaging_input_pr
1721    ENDIF
1722#endif
1723
1724    WRITE ( io, 99 )
1725
1726!
1727!-- Physical quantities
1728    WRITE ( io, 400 )
1729
1730!
1731!-- Geostrophic parameters
1732    IF ( radiation .AND. radiation_scheme /= 'constant' )  THEN
1733       WRITE ( io, 417 )  lambda
1734    ENDIF
1735    WRITE ( io, 410 )  phi, omega, f, fs
1736
1737!
1738!-- Other quantities
1739    WRITE ( io, 411 )  g
1740    IF ( radiation .AND. radiation_scheme /= 'constant' )  THEN
1741       WRITE ( io, 418 )  day_init, time_utc_init
1742    ENDIF
1743
1744    WRITE ( io, 412 )  TRIM( reference_state )
1745    IF ( use_single_reference_value )  THEN
1746       IF ( ocean )  THEN
1747          WRITE ( io, 413 )  prho_reference
1748       ELSE
1749          WRITE ( io, 414 )  pt_reference
1750       ENDIF
1751    ENDIF
1752
1753!
1754!-- Cloud physics parameters
1755    IF ( cloud_physics )  THEN
1756       WRITE ( io, 415 )
1757       WRITE ( io, 416 ) surface_pressure, r_d, rho_surface, cp, l_v
1758       IF ( icloud_scheme == 0 )  THEN
1759          WRITE ( io, 510 ) 1.0E-6_wp * nc_const
1760          IF ( precipitation )  WRITE ( io, 511 ) c_sedimentation
1761       ENDIF
1762    ENDIF
1763
1764!
1765!-- Cloud physcis parameters / quantities / numerical methods
1766    WRITE ( io, 430 )
1767    IF ( humidity .AND. .NOT. cloud_physics .AND. .NOT. cloud_droplets)  THEN
1768       WRITE ( io, 431 )
1769    ELSEIF ( humidity  .AND.  cloud_physics )  THEN
1770       WRITE ( io, 432 )
1771       IF ( cloud_top_radiation )  WRITE ( io, 132 )
1772       IF ( icloud_scheme == 1 )  THEN
1773          IF ( precipitation )  WRITE ( io, 133 )
1774       ELSEIF ( icloud_scheme == 0 )  THEN
1775          IF ( drizzle )  WRITE ( io, 506 )
1776          IF ( precipitation )  THEN
1777             WRITE ( io, 505 )
1778             IF ( turbulence )  WRITE ( io, 507 )
1779             IF ( ventilation_effect )  WRITE ( io, 508 )
1780             IF ( limiter_sedimentation )  WRITE ( io, 509 )
1781          ENDIF
1782       ENDIF
1783    ELSEIF ( humidity  .AND.  cloud_droplets )  THEN
1784       WRITE ( io, 433 )
1785       IF ( curvature_solution_effects )  WRITE ( io, 434 )
1786       IF ( collision_kernel /= 'none' )  THEN
1787          WRITE ( io, 435 )  TRIM( collision_kernel )
1788          IF ( collision_kernel(6:9) == 'fast' )  THEN
1789             WRITE ( io, 436 )  radius_classes, dissipation_classes
1790          ENDIF
1791       ELSE
1792          WRITE ( io, 437 )
1793       ENDIF
1794    ENDIF
1795
1796!
1797!-- LES / turbulence parameters
1798    WRITE ( io, 450 )
1799
1800!--
1801! ... LES-constants used must still be added here
1802!--
1803    IF ( constant_diffusion )  THEN
1804       WRITE ( io, 451 )  km_constant, km_constant/prandtl_number, &
1805                          prandtl_number
1806    ENDIF
1807    IF ( .NOT. constant_diffusion)  THEN
1808       IF ( e_init > 0.0_wp )  WRITE ( io, 455 )  e_init
1809       IF ( e_min > 0.0_wp )  WRITE ( io, 454 )  e_min
1810       IF ( wall_adjustment )  WRITE ( io, 453 )  wall_adjustment_factor
1811    ENDIF
1812
1813!
1814!-- Special actions during the run
1815    WRITE ( io, 470 )
1816    IF ( create_disturbances )  THEN
1817       WRITE ( io, 471 )  dt_disturb, disturbance_amplitude,                   &
1818                          zu(disturbance_level_ind_b), disturbance_level_ind_b,&
1819                          zu(disturbance_level_ind_t), disturbance_level_ind_t
1820       IF ( .NOT. bc_lr_cyc  .OR.  .NOT. bc_ns_cyc )  THEN
1821          WRITE ( io, 472 )  inflow_disturbance_begin, inflow_disturbance_end
1822       ELSE
1823          WRITE ( io, 473 )  disturbance_energy_limit
1824       ENDIF
1825       WRITE ( io, 474 )  TRIM( random_generator )
1826    ENDIF
1827    IF ( pt_surface_initial_change /= 0.0_wp )  THEN
1828       WRITE ( io, 475 )  pt_surface_initial_change
1829    ENDIF
1830    IF ( humidity  .AND.  q_surface_initial_change /= 0.0_wp )  THEN
1831       WRITE ( io, 476 )  q_surface_initial_change       
1832    ENDIF
1833    IF ( passive_scalar  .AND.  q_surface_initial_change /= 0.0_wp )  THEN
1834       WRITE ( io, 477 )  q_surface_initial_change       
1835    ENDIF
1836
1837    IF ( particle_advection )  THEN
1838!
1839!--    Particle attributes
1840       WRITE ( io, 480 )  particle_advection_start, dt_prel, bc_par_lr, &
1841                          bc_par_ns, bc_par_b, bc_par_t, particle_maximum_age, &
1842                          end_time_prel
1843       IF ( use_sgs_for_particles )  WRITE ( io, 488 )  dt_min_part
1844       IF ( random_start_position )  WRITE ( io, 481 )
1845       IF ( seed_follows_topography )  WRITE ( io, 496 )
1846       IF ( particles_per_point > 1 )  WRITE ( io, 489 )  particles_per_point
1847       WRITE ( io, 495 )  total_number_of_particles
1848       IF ( use_particle_tails  .AND.  maximum_number_of_tailpoints /= 0 )  THEN
1849          WRITE ( io, 483 )  maximum_number_of_tailpoints
1850          IF ( minimum_tailpoint_distance /= 0 )  THEN
1851             WRITE ( io, 484 )  total_number_of_tails,      &
1852                                minimum_tailpoint_distance, &
1853                                maximum_tailpoint_age
1854          ENDIF
1855       ENDIF
1856       IF ( dt_write_particle_data /= 9999999.9_wp )  THEN
1857          WRITE ( io, 485 )  dt_write_particle_data
1858          IF ( netcdf_data_format > 1 )  THEN
1859             output_format = 'netcdf (64 bit offset) and binary'
1860          ELSE
1861             output_format = 'netcdf and binary'
1862          ENDIF
1863          WRITE ( io, 344 )  output_format
1864       ENDIF
1865       IF ( dt_dopts /= 9999999.9_wp )  WRITE ( io, 494 )  dt_dopts
1866       IF ( write_particle_statistics )  WRITE ( io, 486 )
1867
1868       WRITE ( io, 487 )  number_of_particle_groups
1869
1870       DO  i = 1, number_of_particle_groups
1871          IF ( i == 1  .AND.  density_ratio(i) == 9999999.9_wp )  THEN
1872             WRITE ( io, 490 )  i, 0.0_wp
1873             WRITE ( io, 492 )
1874          ELSE
1875             WRITE ( io, 490 )  i, radius(i)
1876             IF ( density_ratio(i) /= 0.0_wp )  THEN
1877                WRITE ( io, 491 )  density_ratio(i)
1878             ELSE
1879                WRITE ( io, 492 )
1880             ENDIF
1881          ENDIF
1882          WRITE ( io, 493 )  psl(i), psr(i), pss(i), psn(i), psb(i), pst(i), &
1883                             pdx(i), pdy(i), pdz(i)
1884          IF ( .NOT. vertical_particle_advection(i) )  WRITE ( io, 482 )
1885       ENDDO
1886
1887    ENDIF
1888
1889
1890!
1891!-- Parameters of 1D-model
1892    IF ( INDEX( initializing_actions, 'set_1d-model_profiles' ) /= 0 )  THEN
1893       WRITE ( io, 500 )  end_time_1d, dt_run_control_1d, dt_pr_1d, &
1894                          mixing_length_1d, dissipation_1d
1895       IF ( damp_level_ind_1d /= nzt+1 )  THEN
1896          WRITE ( io, 502 )  zu(damp_level_ind_1d), damp_level_ind_1d
1897       ENDIF
1898    ENDIF
1899
1900!
1901!-- User-defined information
1902    CALL user_header( io )
1903
1904    WRITE ( io, 99 )
1905
1906!
1907!-- Write buffer contents to disc immediately
1908    CALL local_flush( io )
1909
1910!
1911!-- Here the FORMATs start
1912
1913 99 FORMAT (1X,78('-'))
1914100 FORMAT (/1X,'******************************',4X,44('-')/        &
1915            1X,'* ',A,' *',4X,A/                               &
1916            1X,'******************************',4X,44('-'))
1917101 FORMAT (35X,'coupled run using MPI-',I1,': ',A/ &
1918            35X,42('-'))
1919102 FORMAT (/' Date:                 ',A8,4X,'Run:       ',A20/      &
1920            ' Time:                 ',A8,4X,'Run-No.:   ',I2.2/     &
1921            ' Run on host:        ',A10)
1922#if defined( __parallel )
1923103 FORMAT (' Number of PEs:',10X,I6,4X,'Processor grid (x,y): (',I4,',',I4, &
1924              ')',1X,A)
1925104 FORMAT (' Number of PEs:',10X,I6,4X,'Tasks:',I4,'   threads per task:',I4/ &
1926              35X,'Processor grid (x,y): (',I4,',',I4,')',1X,A)
1927105 FORMAT (35X,'One additional PE is used to handle'/37X,'the dvrp output!')
1928106 FORMAT (35X,'A 1d-decomposition along x is forced'/ &
1929            35X,'because the job is running on an SMP-cluster')
1930107 FORMAT (35X,'A 1d-decomposition along ',A,' is used')
1931108 FORMAT (35X,'Max. # of parallel I/O streams is ',I5)
1932109 FORMAT (35X,'Precursor run for coupled atmos-ocean run'/ &
1933            35X,42('-'))
1934114 FORMAT (35X,'Coupled atmosphere-ocean run following'/ &
1935            35X,'independent precursor runs'/             &
1936            35X,42('-'))
1937117 FORMAT (' Accelerator boards / node:  ',I2)
1938#endif
1939110 FORMAT (/' Numerical Schemes:'/ &
1940             ' -----------------'/)
1941111 FORMAT (' --> Solve perturbation pressure via FFT using ',A,' routines')
1942112 FORMAT (' --> Solve perturbation pressure via SOR-Red/Black-Schema'/ &
1943            '     Iterations (initial/other): ',I3,'/',I3,'  omega =',F6.3)
1944113 FORMAT (' --> Momentum advection via Piascek-Williams-Scheme (Form C3)', &
1945                  ' or Upstream')
1946115 FORMAT ('     FFT and transpositions are overlapping')
1947116 FORMAT (' --> Scalar advection via Piascek-Williams-Scheme (Form C3)', &
1948                  ' or Upstream')
1949118 FORMAT (' --> Scalar advection via Bott-Chlond-Scheme')
1950119 FORMAT (' --> Galilei-Transform applied to horizontal advection:'/ &
1951            '     translation velocity = ',A/ &
1952            '     distance advected ',A,':  ',F8.3,' km(x)  ',F8.3,' km(y)')
1953120 FORMAT (' Accelerator boards: ',8X,I2)
1954122 FORMAT (' --> Time differencing scheme: ',A)
1955123 FORMAT (' --> Rayleigh-Damping active, starts ',A,' z = ',F8.2,' m'/ &
1956            '     maximum damping coefficient:',F6.3, ' 1/s')
1957129 FORMAT (' --> Additional prognostic equation for the specific humidity')
1958130 FORMAT (' --> Additional prognostic equation for the total water content')
1959131 FORMAT (' --> No pt-equation solved. Neutral stratification with pt = ', &
1960                  F6.2, ' K assumed')
1961132 FORMAT ('     Parameterization of long-wave radiation processes via'/ &
1962            '     effective emissivity scheme')
1963133 FORMAT ('     Precipitation parameterization via Kessler-Scheme')
1964134 FORMAT (' --> Additional prognostic equation for a passive scalar')
1965135 FORMAT (' --> Solve perturbation pressure via ',A,' method (', &
1966                  A,'-cycle)'/ &
1967            '     number of grid levels:                   ',I2/ &
1968            '     Gauss-Seidel red/black iterations:       ',I2)
1969136 FORMAT ('     gridpoints of coarsest subdomain (x,y,z): (',I3,',',I3,',', &
1970                  I3,')')
1971137 FORMAT ('     level data gathered on PE0 at level:     ',I2/ &
1972            '     gridpoints of coarsest subdomain (x,y,z): (',I3,',',I3,',', &
1973                  I3,')'/ &
1974            '     gridpoints of coarsest domain (x,y,z):    (',I3,',',I3,',', &
1975                  I3,')')
1976139 FORMAT (' --> Loop optimization method: ',A)
1977140 FORMAT ('     maximum residual allowed:                ',E10.3)
1978141 FORMAT ('     fixed number of multigrid cycles:        ',I4)
1979142 FORMAT ('     perturbation pressure is calculated at every Runge-Kutta ', &
1980                  'step')
1981143 FORMAT ('     Euler/upstream scheme is used for the SGS turbulent ', &
1982                  'kinetic energy')
1983144 FORMAT ('     masking method is used')
1984150 FORMAT (' --> Volume flow at the right and north boundary will be ', &
1985                  'conserved'/ &
1986            '     using the ',A,' mode')
1987151 FORMAT ('     with u_bulk = ',F7.3,' m/s and v_bulk = ',F7.3,' m/s')
1988152 FORMAT (' --> External pressure gradient directly prescribed by the user:',&
1989           /'     ',2(1X,E12.5),'Pa/m in x/y direction', &
1990           /'     starting from dp_level_b =', F8.3, 'm', A /)
1991160 FORMAT (//' Large scale forcing and nudging:'/ &
1992              ' -------------------------------'/)
1993161 FORMAT (' --> No large scale forcing from external is used (default) ')
1994162 FORMAT (' --> Large scale forcing from external file LSF_DATA is used: ')
1995163 FORMAT ('     - large scale advection tendencies ')
1996164 FORMAT ('     - large scale subsidence velocity w_subs ')
1997165 FORMAT ('     - large scale subsidence tendencies ')
1998167 FORMAT ('     - and geostrophic wind components ug and vg')
1999168 FORMAT (' --> Large-scale vertical motion is used in the ', &
2000                  'prognostic equation(s) for')
2001169 FORMAT ('     the scalar(s) only')
2002170 FORMAT (' --> Nudging is used')
2003171 FORMAT (' --> No nudging is used (default) ')
2004180 FORMAT ('     - prescribed surface values for temperature')
2005181 FORMAT ('     - prescribed surface fluxes for temperature')
2006182 FORMAT ('     - prescribed surface values for humidity')
2007183 FORMAT ('     - prescribed surface fluxes for humidity')
2008200 FORMAT (//' Run time and time step information:'/ &
2009             ' ----------------------------------'/)
2010201 FORMAT ( ' Timestep:             variable     maximum value: ',F6.3,' s', &
2011             '    CFL-factor:',F5.2)
2012202 FORMAT ( ' Timestep:          dt = ',F6.3,' s'/)
2013203 FORMAT ( ' Start time:          ',F9.3,' s'/ &
2014             ' End time:            ',F9.3,' s')
2015204 FORMAT ( A,F9.3,' s')
2016205 FORMAT ( A,F9.3,' s',5X,'restart every',17X,F9.3,' s')
2017206 FORMAT (/' Time reached:        ',F9.3,' s'/ &
2018             ' CPU-time used:       ',F9.3,' s     per timestep:               ', &
2019               '  ',F9.3,' s'/                                                    &
2020             '                                      per second of simulated tim', &
2021               'e: ',F9.3,' s')
2022207 FORMAT ( ' Coupling start time: ',F9.3,' s')
2023250 FORMAT (//' Computational grid and domain size:'/ &
2024              ' ----------------------------------'// &
2025              ' Grid length:      dx =    ',F7.3,' m    dy =    ',F7.3, &
2026              ' m    dz =    ',F7.3,' m'/ &
2027              ' Domain size:       x = ',F10.3,' m     y = ',F10.3, &
2028              ' m  z(u) = ',F10.3,' m'/)
2029252 FORMAT (' dz constant up to ',F10.3,' m (k=',I4,'), then stretched by', &
2030              ' factor:',F6.3/ &
2031            ' maximum dz not to be exceeded is dz_max = ',F10.3,' m'/)
2032254 FORMAT (' Number of gridpoints (x,y,z):  (0:',I4,', 0:',I4,', 0:',I4,')'/ &
2033            ' Subdomain size (x,y,z):        (  ',I4,',   ',I4,',   ',I4,')'/)
2034260 FORMAT (/' The model has a slope in x-direction. Inclination angle: ',F6.2,&
2035             ' degrees')
2036270 FORMAT (//' Topography information:'/ &
2037              ' ----------------------'// &
2038              1X,'Topography: ',A)
2039271 FORMAT (  ' Building size (x/y/z) in m: ',F5.1,' / ',F5.1,' / ',F5.1/ &
2040              ' Horizontal index bounds (l/r/s/n): ',I4,' / ',I4,' / ',I4, &
2041                ' / ',I4)
2042272 FORMAT (  ' Single quasi-2D street canyon of infinite length in ',A, &
2043              ' direction' / &
2044              ' Canyon height: ', F6.2, 'm, ch = ', I4, '.'      / &
2045              ' Canyon position (',A,'-walls): cxl = ', I4,', cxr = ', I4, '.')
2046278 FORMAT (' Topography grid definition convention:'/ &
2047            ' cell edge (staggered grid points'/  &
2048            ' (u in x-direction, v in y-direction))' /)
2049279 FORMAT (' Topography grid definition convention:'/ &
2050            ' cell center (scalar grid points)' /)
2051280 FORMAT (//' Vegetation canopy (drag) model:'/ &
2052              ' ------------------------------'// &
2053              ' Canopy mode: ', A / &
2054              ' Canopy height: ',F6.2,'m (',I4,' grid points)' / &
2055              ' Leaf drag coefficient: ',F6.2 /)
2056281 FORMAT (/ ' Scalar exchange coefficient: ',F6.2 / &
2057              ' Scalar concentration at leaf surfaces in kg/m**3: ',F6.2 /)
2058282 FORMAT (' Predefined constant heatflux at the top of the vegetation: ',F6.2,' K m/s')
2059283 FORMAT (/ ' Characteristic levels of the leaf area density:'// &
2060              ' Height:              ',A,'  m'/ &
2061              ' Leaf area density:   ',A,'  m**2/m**3'/ &
2062              ' Gradient:            ',A,'  m**2/m**4'/ &
2063              ' Gridpoint:           ',A)
2064284 FORMAT (//' Characteristic levels of the leaf area density and coefficients:'// &
2065              ' Height:              ',A,'  m'/ &
2066              ' Leaf area density:   ',A,'  m**2/m**3'/ &
2067              ' Coefficient alpha: ',F6.2 / &
2068              ' Coefficient beta: ',F6.2 / &
2069              ' Leaf area index: ',F6.2,'  m**2/m**2' /)
2070               
2071300 FORMAT (//' Boundary conditions:'/ &
2072             ' -------------------'// &
2073             '                     p                    uv             ', &
2074             '                     pt'// &
2075             ' B. bound.: ',A/ &
2076             ' T. bound.: ',A)
2077301 FORMAT (/'                     ',A// &
2078             ' B. bound.: ',A/ &
2079             ' T. bound.: ',A)
2080303 FORMAT (/' Bottom surface fluxes are used in diffusion terms at k=1')
2081304 FORMAT (/' Top surface fluxes are used in diffusion terms at k=nzt')
2082305 FORMAT (//'    Prandtl-Layer between bottom surface and first ', &
2083               'computational u,v-level:'// &
2084             '       zp = ',F6.2,' m   z0 =',F7.4,' m   z0h =',F8.5,&
2085             ' m   kappa =',F5.2/ &
2086             '       Rif value range:   ',F8.2,' <= rif <=',F6.2)
2087306 FORMAT ('       Predefined constant heatflux:   ',F9.6,' K m/s')
2088307 FORMAT ('       Heatflux has a random normal distribution')
2089308 FORMAT ('       Predefined surface temperature')
2090309 FORMAT ('       Predefined constant salinityflux:   ',F9.6,' psu m/s')
2091310 FORMAT (//'    1D-Model:'// &
2092             '       Rif value range:   ',F6.2,' <= rif <=',F6.2)
2093311 FORMAT ('       Predefined constant humidity flux: ',E10.3,' m/s')
2094312 FORMAT ('       Predefined surface humidity')
2095313 FORMAT ('       Predefined constant scalar flux: ',E10.3,' kg/(m**2 s)')
2096314 FORMAT ('       Predefined scalar value at the surface')
2097315 FORMAT ('       Humidity / scalar flux at top surface is 0.0')
2098316 FORMAT ('       Sensible heatflux and momentum flux from coupled ', &
2099                    'atmosphere model')
2100317 FORMAT (//' Lateral boundaries:'/ &
2101            '       left/right:  ',A/    &
2102            '       north/south: ',A)
2103318 FORMAT (/'       use_cmax: ',L1 / &
2104            '       pt damping layer width = ',F8.2,' m, pt ', &
2105                    'damping factor =',F7.4)
2106319 FORMAT ('       turbulence recycling at inflow switched on'/ &
2107            '       width of recycling domain: ',F7.1,' m   grid index: ',I4/ &
2108            '       inflow damping height: ',F6.1,' m   width: ',F6.1,' m')
2109320 FORMAT ('       Predefined constant momentumflux:  u: ',F9.6,' m**2/s**2'/ &
2110            '                                          v: ',F9.6,' m**2/s**2')
2111321 FORMAT (//' Initial profiles:'/ &
2112              ' ----------------')
2113322 FORMAT ('       turbulence recycling at inflow switched on'/ &
2114            '       y shift of the recycled inflow turbulence switched on'/ &
2115            '       width of recycling domain: ',F7.1,' m   grid index: ',I4/ &
2116            '       inflow damping height: ',F6.1,' m   width: ',F6.1,' m'/)
2117325 FORMAT (//' List output:'/ &
2118             ' -----------'//  &
2119            '    1D-Profiles:'/    &
2120            '       Output every             ',F8.2,' s')
2121326 FORMAT ('       Time averaged over       ',F8.2,' s'/ &
2122            '       Averaging input every    ',F8.2,' s')
2123330 FORMAT (//' Data output:'/ &
2124             ' -----------'/)
2125331 FORMAT (/'    1D-Profiles:')
2126332 FORMAT (/'       ',A)
2127333 FORMAT ('       Output every             ',F8.2,' s',/ &
2128            '       Time averaged over       ',F8.2,' s'/ &
2129            '       Averaging input every    ',F8.2,' s')
2130334 FORMAT (/'    2D-Arrays',A,':')
2131335 FORMAT (/'       ',A2,'-cross-section  Arrays: ',A/ &
2132            '       Output every             ',F8.2,' s  ',A/ &
2133            '       Cross sections at ',A1,' = ',A/ &
2134            '       scalar-coordinates:   ',A,' m'/)
2135336 FORMAT (/'    3D-Arrays',A,':')
2136337 FORMAT (/'       Arrays: ',A/ &
2137            '       Output every             ',F8.2,' s  ',A/ &
2138            '       Upper output limit at    ',F8.2,' m  (GP ',I4,')'/)
2139339 FORMAT ('       No output during initial ',F8.2,' s')
2140340 FORMAT (/'    Time series:')
2141341 FORMAT ('       Output every             ',F8.2,' s'/)
2142342 FORMAT (/'       ',A2,'-cross-section  Arrays: ',A/ &
2143            '       Output every             ',F8.2,' s  ',A/ &
2144            '       Time averaged over       ',F8.2,' s'/ &
2145            '       Averaging input every    ',F8.2,' s'/ &
2146            '       Cross sections at ',A1,' = ',A/ &
2147            '       scalar-coordinates:   ',A,' m'/)
2148343 FORMAT (/'       Arrays: ',A/ &
2149            '       Output every             ',F8.2,' s  ',A/ &
2150            '       Time averaged over       ',F8.2,' s'/ &
2151            '       Averaging input every    ',F8.2,' s'/ &
2152            '       Upper output limit at    ',F8.2,' m  (GP ',I4,')'/)
2153344 FORMAT ('       Output format: ',A/)
2154345 FORMAT (/'    Scaling lengths for output locations of all subsequent mask IDs:',/ &
2155            '       mask_scale_x (in x-direction): ',F9.3, ' m',/ &
2156            '       mask_scale_y (in y-direction): ',F9.3, ' m',/ &
2157            '       mask_scale_z (in z-direction): ',F9.3, ' m' )
2158346 FORMAT (/'    Masked data output',A,' for mask ID ',I2, ':')
2159347 FORMAT ('       Variables: ',A/ &
2160            '       Output every             ',F8.2,' s')
2161348 FORMAT ('       Variables: ',A/ &
2162            '       Output every             ',F8.2,' s'/ &
2163            '       Time averaged over       ',F8.2,' s'/ &
2164            '       Averaging input every    ',F8.2,' s')
2165349 FORMAT (/'       Output locations in ',A,'-direction in multiples of ', &
2166            'mask_scale_',A,' predefined by array mask_',I2.2,'_',A,':'/ &
2167            13('       ',8(F8.2,',')/) )
2168350 FORMAT (/'       Output locations in ',A,'-direction: ', &
2169            'all gridpoints along ',A,'-direction (default).' )
2170351 FORMAT (/'       Output locations in ',A,'-direction in multiples of ', &
2171            'mask_scale_',A,' constructed from array mask_',I2.2,'_',A,'_loop:'/ &
2172            '          loop begin:',F8.2,', end:',F8.2,', stride:',F8.2 )
2173352 FORMAT  (/'       Number of output time levels allowed: ',I3 /)
2174353 FORMAT  (/'       Number of output time levels allowed: unlimited' /)
2175#if defined( __dvrp_graphics )
2176360 FORMAT ('    Plot-Sequence with dvrp-software:'/ &
2177            '       Output every      ',F7.1,' s'/ &
2178            '       Output mode:      ',A/ &
2179            '       Host / User:      ',A,' / ',A/ &
2180            '       Directory:        ',A// &
2181            '       The sequence contains:')
2182361 FORMAT (/'       Isosurface of "',A,'"    Threshold value: ', E12.3/ &
2183            '          Isosurface color: (',F4.2,',',F4.2,',',F4.2,') (R,G,B)')
2184362 FORMAT (/'       Slicer plane ',A/ &
2185            '       Slicer limits: [',F6.2,',',F6.2,']')
2186363 FORMAT (/'       Particles'/ &
2187            '          particle size:  ',F7.2,' m')
2188364 FORMAT ('          particle ',A,' controlled by "',A,'" with interval [', &
2189                       F6.2,',',F6.2,']')
2190365 FORMAT (/'       Groundplate color: (',F4.2,',',F4.2,',',F4.2,') (R,G,B)'/ &
2191            '       Superelevation along (x,y,z): (',F4.1,',',F4.1,',',F4.1, &
2192                     ')'/ &
2193            '       Clipping limits: from x = ',F9.1,' m to x = ',F9.1,' m'/ &
2194            '                        from y = ',F9.1,' m to y = ',F9.1,' m')
2195366 FORMAT (/'       Topography color: (',F4.2,',',F4.2,',',F4.2,') (R,G,B)')
2196367 FORMAT ('       Polygon reduction for topography: cluster_size = ', I1)
2197#endif
2198#if defined( __spectra )
2199370 FORMAT ('    Spectra:')
2200371 FORMAT ('       Output every ',F7.1,' s'/)
2201372 FORMAT ('       Arrays:     ', 10(A5,',')/                         &
2202            '       Directions: ', 10(A5,',')/                         &
2203            '       height levels  k = ', 20(I3,',')/                  &
2204            '                          ', 20(I3,',')/                  &
2205            '                          ', 20(I3,',')/                  &
2206            '                          ', 20(I3,',')/                  &
2207            '                          ', 19(I3,','),I3,'.'/           &
2208            '       height levels selected for standard plot:'/        &
2209            '                      k = ', 20(I3,',')/                  &
2210            '                          ', 20(I3,',')/                  &
2211            '                          ', 20(I3,',')/                  &
2212            '                          ', 20(I3,',')/                  &
2213            '                          ', 19(I3,','),I3,'.'/           &
2214            '       Time averaged over ', F7.1, ' s,' /                &
2215            '       Profiles for the time averaging are taken every ', &
2216                    F6.1,' s')
2217#endif
2218400 FORMAT (//' Physical quantities:'/ &
2219              ' -------------------'/)
2220410 FORMAT ('    Geograph. latitude  :   phi    = ',F4.1,' degr'/   &
2221            '    Angular velocity    :   omega  =',E10.3,' rad/s'/  &
2222            '    Coriolis parameter  :   f      = ',F9.6,' 1/s'/    &
2223            '                            f*     = ',F9.6,' 1/s')
2224411 FORMAT (/'    Gravity             :   g      = ',F4.1,' m/s**2')
2225412 FORMAT (/'    Reference state used in buoyancy terms: ',A)
2226413 FORMAT ('       Reference density in buoyancy terms: ',F8.3,' kg/m**3')
2227414 FORMAT ('       Reference temperature in buoyancy terms: ',F8.4,' K')
2228415 FORMAT (/' Cloud physics parameters:'/ &
2229             ' ------------------------'/)
2230416 FORMAT ('    Surface pressure   :   p_0   = ',F7.2,' hPa'/      &
2231            '    Gas constant       :   R     = ',F5.1,' J/(kg K)'/ &
2232            '    Density of air     :   rho_0 =',F6.3,' kg/m**3'/  &
2233            '    Specific heat cap. :   c_p   = ',F6.1,' J/(kg K)'/ &
2234            '    Vapourization heat :   L_v   =',E9.2,' J/kg')
2235417 FORMAT ('    Geograph. longitude :   lambda = ',F4.1,' degr')
2236418 FORMAT (/'    Day of the year at model start :   day_init      =     ',I3 &
2237            /'    UTC time at model start        :   time_utc_init = ',F7.1' s')
2238419 FORMAT (//' Land surface model information:'/ &
2239              ' ------------------------------'/)
2240420 FORMAT (/'    Characteristic levels of the initial temperature profile:'// &
2241            '       Height:        ',A,'  m'/ &
2242            '       Temperature:   ',A,'  K'/ &
2243            '       Gradient:      ',A,'  K/100m'/ &
2244            '       Gridpoint:     ',A)
2245421 FORMAT (/'    Characteristic levels of the initial humidity profile:'// &
2246            '       Height:      ',A,'  m'/ &
2247            '       Humidity:    ',A,'  kg/kg'/ &
2248            '       Gradient:    ',A,'  (kg/kg)/100m'/ &
2249            '       Gridpoint:   ',A)
2250422 FORMAT (/'    Characteristic levels of the initial scalar profile:'// &
2251            '       Height:                  ',A,'  m'/ &
2252            '       Scalar concentration:    ',A,'  kg/m**3'/ &
2253            '       Gradient:                ',A,'  (kg/m**3)/100m'/ &
2254            '       Gridpoint:               ',A)
2255423 FORMAT (/'    Characteristic levels of the geo. wind component ug:'// &
2256            '       Height:      ',A,'  m'/ &
2257            '       ug:          ',A,'  m/s'/ &
2258            '       Gradient:    ',A,'  1/100s'/ &
2259            '       Gridpoint:   ',A)
2260424 FORMAT (/'    Characteristic levels of the geo. wind component vg:'// &
2261            '       Height:      ',A,'  m'/ &
2262            '       vg:          ',A,'  m/s'/ &
2263            '       Gradient:    ',A,'  1/100s'/ &
2264            '       Gridpoint:   ',A)
2265425 FORMAT (/'    Characteristic levels of the initial salinity profile:'// &
2266            '       Height:     ',A,'  m'/ &
2267            '       Salinity:   ',A,'  psu'/ &
2268            '       Gradient:   ',A,'  psu/100m'/ &
2269            '       Gridpoint:  ',A)
2270426 FORMAT (/'    Characteristic levels of the subsidence/ascent profile:'// &
2271            '       Height:      ',A,'  m'/ &
2272            '       w_subs:      ',A,'  m/s'/ &
2273            '       Gradient:    ',A,'  (m/s)/100m'/ &
2274            '       Gridpoint:   ',A)
2275427 FORMAT (/'    Initial wind profiles (u,v) are interpolated from given'// &
2276                  ' profiles')
2277428 FORMAT (/'    Initial profiles (u, v, pt, q) are taken from file '/ &
2278             '    NUDGING_DATA')
2279430 FORMAT (//' Cloud physics quantities / methods:'/ &
2280              ' ----------------------------------'/)
2281431 FORMAT ('    Humidity is treated as purely passive scalar (no condensati', &
2282                 'on)')
2283432 FORMAT ('    Bulk scheme with liquid water potential temperature and'/ &
2284            '    total water content is used.'/ &
2285            '    Condensation is parameterized via 0% - or 100% scheme.')
2286433 FORMAT ('    Cloud droplets treated explicitly using the Lagrangian part', &
2287                 'icle model')
2288434 FORMAT ('    Curvature and solution effecs are considered for growth of', &
2289                 ' droplets < 1.0E-6 m')
2290435 FORMAT ('    Droplet collision is handled by ',A,'-kernel')
2291436 FORMAT ('       Fast kernel with fixed radius- and dissipation classes ', &
2292                    'are used'/ &
2293            '          number of radius classes:       ',I3,'    interval ', &
2294                       '[1.0E-6,2.0E-4] m'/ &
2295            '          number of dissipation classes:   ',I2,'    interval ', &
2296                       '[0,1000] cm**2/s**3')
2297437 FORMAT ('    Droplet collision is switched off')
2298438 FORMAT (' --> Land surface type  : ',A,/ &
2299            ' --> Soil porosity type : ',A)
2300439 FORMAT (/'    Initial soil temperature and moisture profile:'// &
2301            '       Height:        ',A,'  m'/ &
2302            '       Temperature:   ',A,'  K'/ &
2303            '       Moisture:      ',A,'  m**3/m**3'/ &
2304            '       Root fraction: ',A,'  '/ &
2305            '       Gridpoint:     ',A)
2306440 FORMAT (/' --> Dewfall is allowed (default)')
2307441 FORMAT (' --> Dewfall is inhibited')
2308442 FORMAT (' --> Soil bottom is closed (water content is conserved, default)')
2309443 FORMAT (' --> Soil bottom is open (water content is not conserved)')
2310444 FORMAT (//' Radiation model information:'/                                 &
2311              ' ----------------------------'/)
2312445 FORMAT (' --> Using constant net radiation: net_radiation = ', F6.2, '  W/m**2')
2313446 FORMAT (' --> Simple radiation scheme for clear sky is used (no clouds,',  &
2314                   ' default)')
2315447 FORMAT (' --> RRTMG scheme is used')
2316448 FORMAT (/'     User-specific surface albedo: albedo =', F6.3)
2317449 FORMAT  ('     Timestep: dt_radiation = ', F5.2, '  s')
2318
2319450 FORMAT (//' LES / Turbulence quantities:'/ &
2320              ' ---------------------------'/)
2321451 FORMAT ('    Diffusion coefficients are constant:'/ &
2322            '    Km = ',F6.2,' m**2/s   Kh = ',F6.2,' m**2/s   Pr = ',F5.2)
2323453 FORMAT ('    Mixing length is limited to',F5.2,' * z')
2324454 FORMAT ('    TKE is not allowed to fall below ',E9.2,' (m/s)**2')
2325455 FORMAT ('    initial TKE is prescribed as ',E9.2,' (m/s)**2')
2326456 FORMAT (/'    Albedo is set for land surface type: ', A)
2327457 FORMAT (/'    --> Albedo is fixed during the run')
2328458 FORMAT (/'    --> Longwave radiation is disabled')
2329459 FORMAT (/'    --> Shortwave radiation is disabled.')
2330470 FORMAT (//' Actions during the simulation:'/ &
2331              ' -----------------------------'/)
2332471 FORMAT ('    Disturbance impulse (u,v) every :   ',F6.2,' s'/            &
2333            '    Disturbance amplitude           :    ',F5.2, ' m/s'/       &
2334            '    Lower disturbance level         : ',F8.2,' m (GP ',I4,')'/  &
2335            '    Upper disturbance level         : ',F8.2,' m (GP ',I4,')')
2336472 FORMAT ('    Disturbances continued during the run from i/j =',I4, &
2337                 ' to i/j =',I4)
2338473 FORMAT ('    Disturbances cease as soon as the disturbance energy exceeds',&
2339                 F6.3, ' m**2/s**2')
2340474 FORMAT ('    Random number generator used    : ',A/)
2341475 FORMAT ('    The surface temperature is increased (or decreased, ', &
2342                 'respectively, if'/ &
2343            '    the value is negative) by ',F5.2,' K at the beginning of the',&
2344                 ' 3D-simulation'/)
2345476 FORMAT ('    The surface humidity is increased (or decreased, ',&
2346                 'respectively, if the'/ &
2347            '    value is negative) by ',E8.1,' kg/kg at the beginning of', &
2348                 ' the 3D-simulation'/)
2349477 FORMAT ('    The scalar value is increased at the surface (or decreased, ',&
2350                 'respectively, if the'/ &
2351            '    value is negative) by ',E8.1,' kg/m**3 at the beginning of', &
2352                 ' the 3D-simulation'/)
2353480 FORMAT ('    Particles:'/ &
2354            '    ---------'// &
2355            '       Particle advection is active (switched on at t = ', F7.1, &
2356                    ' s)'/ &
2357            '       Start of new particle generations every  ',F6.1,' s'/ &
2358            '       Boundary conditions: left/right: ', A, ' north/south: ', A/&
2359            '                            bottom:     ', A, ' top:         ', A/&
2360            '       Maximum particle age:                 ',F9.1,' s'/ &
2361            '       Advection stopped at t = ',F9.1,' s'/)
2362481 FORMAT ('       Particles have random start positions'/)
2363482 FORMAT ('          Particles are advected only horizontally'/)
2364483 FORMAT ('       Particles have tails with a maximum of ',I3,' points')
2365484 FORMAT ('            Number of tails of the total domain: ',I10/ &
2366            '            Minimum distance between tailpoints: ',F8.2,' m'/ &
2367            '            Maximum age of the end of the tail:  ',F8.2,' s')
2368485 FORMAT ('       Particle data are written on file every ', F9.1, ' s')
2369486 FORMAT ('       Particle statistics are written on file'/)
2370487 FORMAT ('       Number of particle groups: ',I2/)
2371488 FORMAT ('       SGS velocity components are used for particle advection'/ &
2372            '          minimum timestep for advection:', F8.5/)
2373489 FORMAT ('       Number of particles simultaneously released at each ', &
2374                    'point: ', I5/)
2375490 FORMAT ('       Particle group ',I2,':'/ &
2376            '          Particle radius: ',E10.3, 'm')
2377491 FORMAT ('          Particle inertia is activated'/ &
2378            '             density_ratio (rho_fluid/rho_particle) =',F6.3/)
2379492 FORMAT ('          Particles are advected only passively (no inertia)'/)
2380493 FORMAT ('          Boundaries of particle source: x:',F8.1,' - ',F8.1,' m'/&
2381            '                                         y:',F8.1,' - ',F8.1,' m'/&
2382            '                                         z:',F8.1,' - ',F8.1,' m'/&
2383            '          Particle distances:  dx = ',F8.1,' m  dy = ',F8.1, &
2384                       ' m  dz = ',F8.1,' m'/)
2385494 FORMAT ('       Output of particle time series in NetCDF format every ', &
2386                    F8.2,' s'/)
2387495 FORMAT ('       Number of particles in total domain: ',I10/)
2388496 FORMAT ('       Initial vertical particle positions are interpreted ', &
2389                    'as relative to the given topography')
2390500 FORMAT (//' 1D-Model parameters:'/                           &
2391              ' -------------------'//                           &
2392            '    Simulation time:                   ',F8.1,' s'/ &
2393            '    Run-controll output every:         ',F8.1,' s'/ &
2394            '    Vertical profile output every:     ',F8.1,' s'/ &
2395            '    Mixing length calculation:         ',A/         &
2396            '    Dissipation calculation:           ',A/)
2397502 FORMAT ('    Damping layer starts from ',F7.1,' m (GP ',I4,')'/)
2398503 FORMAT (' --> Momentum advection via Wicker-Skamarock-Scheme 5th order')
2399504 FORMAT (' --> Scalar advection via Wicker-Skamarock-Scheme 5th order')
2400505 FORMAT ('    Precipitation parameterization via Seifert-Beheng-Scheme')
2401506 FORMAT ('    Drizzle parameterization via Stokes law')
2402507 FORMAT ('    Turbulence effects on precipitation process')
2403508 FORMAT ('    Ventilation effects on evaporation of rain drops')
2404509 FORMAT ('    Slope limiter used for sedimentation process')
2405510 FORMAT ('    Droplet density    :   N_c   = ',F6.1,' 1/cm**3')
2406511 FORMAT ('    Sedimentation Courant number:                  '/&
2407            '                               C_s   =',F4.1,'        ')
2408512 FORMAT (/' Date:                 ',A8,6X,'Run:       ',A20/      &
2409            ' Time:                 ',A8,6X,'Run-No.:   ',I2.2/     &
2410            ' Run on host:        ',A10,6X,'En-No.:    ',I2.2)
2411513 FORMAT (' --> Scalar advection via Wicker-Skamarock-Scheme 5th order ' // & 
2412            '+ monotonic adjustment')
2413600 FORMAT (/' Nesting informations:'/                                        &
2414            ' Nest id / name:                   ',I2.2,' / ',A,' (parent id: ',I2.2,')'/ &
2415            ' Nesting mode:                     ',A/ &
2416            ' Lower left corner coordinates:    ','x = ',F8.2,' m, y = ',F8.2,' m'/)
2417
2418 END SUBROUTINE header
Note: See TracBrowser for help on using the repository browser.