1 | !> @file write_restart_data_mod.f90 |
---|
2 | !------------------------------------------------------------------------------! |
---|
3 | ! This file is part of the PALM model system. |
---|
4 | ! |
---|
5 | ! PALM is free software: you can redistribute it and/or modify it under the |
---|
6 | ! terms of the GNU General Public License as published by the Free Software |
---|
7 | ! Foundation, either version 3 of the License, or (at your option) any later |
---|
8 | ! version. |
---|
9 | ! |
---|
10 | ! PALM is distributed in the hope that it will be useful, but WITHOUT ANY |
---|
11 | ! WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR |
---|
12 | ! A PARTICULAR PURPOSE. See the GNU General Public License for more details. |
---|
13 | ! |
---|
14 | ! You should have received a copy of the GNU General Public License along with |
---|
15 | ! PALM. If not, see <http://www.gnu.org/licenses/>. |
---|
16 | ! |
---|
17 | ! Copyright 1997-2018 Leibniz Universitaet Hannover |
---|
18 | !------------------------------------------------------------------------------! |
---|
19 | ! |
---|
20 | ! Current revisions: |
---|
21 | ! ----------------- |
---|
22 | ! |
---|
23 | ! |
---|
24 | ! Former revisions: |
---|
25 | ! ----------------- |
---|
26 | ! $Id: write_restart_data_mod.f90 3589 2018-11-30 15:09:51Z forkel $ |
---|
27 | ! Move the control parameter "salsa" from salsa_mod to control_parameters |
---|
28 | ! (M. Kurppa) |
---|
29 | ! |
---|
30 | ! |
---|
31 | ! 3582 2018-11-29 19:16:36Z suehring |
---|
32 | ! Implementation of a new aerosol module salsa. |
---|
33 | ! |
---|
34 | ! 3355 2018-10-16 14:03:34Z knoop |
---|
35 | ! changes concerning modularization of ocean option |
---|
36 | ! |
---|
37 | ! 3274 2018-09-24 15:42:55Z knoop |
---|
38 | ! Modularization of all bulk cloud physics code components |
---|
39 | ! |
---|
40 | ! 3065 2018-06-12 07:03:02Z Giersch |
---|
41 | ! New parameters concerning vertical grid stretching have been added |
---|
42 | ! |
---|
43 | ! 3004 2018-04-27 12:33:25Z Giersch |
---|
44 | ! precipitation_rate_av removed |
---|
45 | ! |
---|
46 | ! 3003 2018-04-23 10:22:58Z Giersch |
---|
47 | ! z_i is also written out to use the last known inversion height from the |
---|
48 | ! initial run as the first inversion height which is written into the |
---|
49 | ! run control file |
---|
50 | ! |
---|
51 | ! 2956 2018-04-10 11:01:03Z Giersch |
---|
52 | ! spectrum_x and spectrum_y have been moved to global data |
---|
53 | ! |
---|
54 | ! 2921 2018-03-22 15:05:23Z Giersch |
---|
55 | ! spinup_time, day_of_year_init and time_utc_init are also written out now |
---|
56 | ! |
---|
57 | ! 2912 2018-03-20 13:00:05Z knoop |
---|
58 | ! Added gust module interface calls |
---|
59 | ! |
---|
60 | ! 2894 2018-03-15 09:17:58Z Giersch |
---|
61 | ! Initial revision |
---|
62 | ! |
---|
63 | ! |
---|
64 | ! Description: |
---|
65 | ! ------------ |
---|
66 | !> Writes restart data into binary file(s) for restart runs. |
---|
67 | !------------------------------------------------------------------------------! |
---|
68 | MODULE write_restart_data_mod |
---|
69 | |
---|
70 | |
---|
71 | USE control_parameters |
---|
72 | |
---|
73 | USE kinds |
---|
74 | |
---|
75 | USE pegrid, & |
---|
76 | ONLY: myid, numprocs |
---|
77 | |
---|
78 | |
---|
79 | IMPLICIT NONE |
---|
80 | |
---|
81 | |
---|
82 | INTERFACE wrd_global |
---|
83 | MODULE PROCEDURE wrd_global |
---|
84 | END INTERFACE wrd_global |
---|
85 | |
---|
86 | INTERFACE wrd_local |
---|
87 | MODULE PROCEDURE wrd_local |
---|
88 | END INTERFACE wrd_local |
---|
89 | |
---|
90 | |
---|
91 | PUBLIC wrd_local, wrd_global |
---|
92 | |
---|
93 | |
---|
94 | CONTAINS |
---|
95 | |
---|
96 | |
---|
97 | ! Description: |
---|
98 | ! ------------ |
---|
99 | !> Global data of control variables and arrays is written out for |
---|
100 | !> restarts (binary format). |
---|
101 | !> This information is only written to the file opened by PE0. |
---|
102 | !------------------------------------------------------------------------------! |
---|
103 | SUBROUTINE wrd_global |
---|
104 | |
---|
105 | |
---|
106 | USE arrays_3d, & |
---|
107 | ONLY: inflow_damping_factor, mean_inflow_profiles, pt_init, & |
---|
108 | q_init, ref_state, s_init, u_init, ug, v_init, vg |
---|
109 | |
---|
110 | USE bulk_cloud_model_mod, & |
---|
111 | ONLY: bulk_cloud_model, bcm_wrd_global |
---|
112 | |
---|
113 | USE date_and_time_mod, & |
---|
114 | ONLY: day_of_year_init, time_utc_init |
---|
115 | |
---|
116 | USE flight_mod, & |
---|
117 | ONLY: flight_wrd_global |
---|
118 | |
---|
119 | USE grid_variables, & |
---|
120 | ONLY: dx, dy |
---|
121 | |
---|
122 | USE gust_mod, & |
---|
123 | ONLY : gust_module_enabled, gust_wrd_global |
---|
124 | |
---|
125 | USE indices, & |
---|
126 | ONLY: nx, ny, nz |
---|
127 | |
---|
128 | USE model_1d_mod, & |
---|
129 | ONLY: damp_level_1d, dt_pr_1d, dt_run_control_1d, end_time_1d |
---|
130 | |
---|
131 | USE netcdf_interface, & |
---|
132 | ONLY: netcdf_precision, output_for_t0 |
---|
133 | |
---|
134 | USE ocean_mod, & |
---|
135 | ONLY: ocean_wrd_global |
---|
136 | |
---|
137 | USE particle_attributes, & |
---|
138 | ONLY: curvature_solution_effects |
---|
139 | |
---|
140 | USE pegrid, & |
---|
141 | ONLY: hor_index_bounds, collective_wait |
---|
142 | |
---|
143 | USE radiation_model_mod, & |
---|
144 | ONLY: time_radiation |
---|
145 | |
---|
146 | USE spectra_mod, & |
---|
147 | ONLY: average_count_sp, spectrum_x, spectrum_y |
---|
148 | |
---|
149 | USE synthetic_turbulence_generator_mod, & |
---|
150 | ONLY: stg_wrd_global |
---|
151 | |
---|
152 | USE statistics, & |
---|
153 | ONLY: statistic_regions, hom, hom_sum, u_max, u_max_ijk, v_max, & |
---|
154 | v_max_ijk, w_max, w_max_ijk, z_i |
---|
155 | |
---|
156 | USE user_write_restart_data_mod, & |
---|
157 | ONLY: user_wrd_global |
---|
158 | |
---|
159 | USE vertical_nesting_mod, & |
---|
160 | ONLY: vnest_init |
---|
161 | |
---|
162 | USE wind_turbine_model_mod, & |
---|
163 | ONLY: wtm_wrd_global |
---|
164 | |
---|
165 | |
---|
166 | IMPLICIT NONE |
---|
167 | |
---|
168 | CHARACTER (LEN=10) :: binary_version_global !< |
---|
169 | |
---|
170 | |
---|
171 | binary_version_global = '4.7' |
---|
172 | |
---|
173 | CALL wrd_write_string( 'binary_version_global' ) |
---|
174 | WRITE ( 14 ) binary_version_global |
---|
175 | |
---|
176 | CALL wrd_write_string( 'numprocs' ) |
---|
177 | WRITE ( 14 ) numprocs |
---|
178 | |
---|
179 | CALL wrd_write_string( 'hor_index_bounds' ) |
---|
180 | WRITE ( 14 ) hor_index_bounds |
---|
181 | |
---|
182 | CALL wrd_write_string( 'nz' ) |
---|
183 | WRITE ( 14 ) nz |
---|
184 | |
---|
185 | CALL wrd_write_string( 'max_pr_user' ) |
---|
186 | WRITE ( 14 ) max_pr_user |
---|
187 | |
---|
188 | CALL wrd_write_string( 'statistic_regions' ) |
---|
189 | WRITE ( 14 ) statistic_regions |
---|
190 | |
---|
191 | ! |
---|
192 | !-- Caution: After changes in the following parameter-list, the |
---|
193 | !-- ------- version number stored in the variable binary_version_global has to |
---|
194 | !-- be increased. The same changes must also be done in the parameter- |
---|
195 | !-- list in rrd_global. |
---|
196 | |
---|
197 | CALL wrd_write_string( 'advected_distance_x' ) |
---|
198 | WRITE ( 14 ) advected_distance_x |
---|
199 | |
---|
200 | CALL wrd_write_string( 'advected_distance_y' ) |
---|
201 | WRITE ( 14 ) advected_distance_y |
---|
202 | |
---|
203 | CALL wrd_write_string( 'alpha_surface' ) |
---|
204 | WRITE ( 14 ) alpha_surface |
---|
205 | |
---|
206 | CALL wrd_write_string( 'average_count_pr' ) |
---|
207 | WRITE ( 14 ) average_count_pr |
---|
208 | |
---|
209 | CALL wrd_write_string( 'average_count_sp' ) |
---|
210 | WRITE ( 14 ) average_count_sp |
---|
211 | |
---|
212 | CALL wrd_write_string( 'average_count_3d' ) |
---|
213 | WRITE ( 14 ) average_count_3d |
---|
214 | |
---|
215 | CALL wrd_write_string( 'bc_e_b' ) |
---|
216 | WRITE ( 14 ) bc_e_b |
---|
217 | |
---|
218 | CALL wrd_write_string( 'bc_lr' ) |
---|
219 | WRITE ( 14 ) bc_lr |
---|
220 | |
---|
221 | CALL wrd_write_string( 'bc_ns' ) |
---|
222 | WRITE ( 14 ) bc_ns |
---|
223 | |
---|
224 | CALL wrd_write_string( 'bc_p_b' ) |
---|
225 | WRITE ( 14 ) bc_p_b |
---|
226 | |
---|
227 | CALL wrd_write_string( 'bc_p_t' ) |
---|
228 | WRITE ( 14 ) bc_p_t |
---|
229 | |
---|
230 | CALL wrd_write_string( 'bc_pt_b' ) |
---|
231 | WRITE ( 14 ) bc_pt_b |
---|
232 | |
---|
233 | CALL wrd_write_string( 'bc_pt_t' ) |
---|
234 | WRITE ( 14 ) bc_pt_t |
---|
235 | |
---|
236 | CALL wrd_write_string( 'bc_pt_t_val' ) |
---|
237 | WRITE ( 14 ) bc_pt_t_val |
---|
238 | |
---|
239 | CALL wrd_write_string( 'bc_q_b' ) |
---|
240 | WRITE ( 14 ) bc_q_b |
---|
241 | |
---|
242 | CALL wrd_write_string( 'bc_q_t' ) |
---|
243 | WRITE ( 14 ) bc_q_t |
---|
244 | |
---|
245 | CALL wrd_write_string( 'bc_q_t_val' ) |
---|
246 | WRITE ( 14 ) bc_q_t_val |
---|
247 | |
---|
248 | CALL wrd_write_string( 'bc_s_b' ) |
---|
249 | WRITE ( 14 ) bc_s_b |
---|
250 | |
---|
251 | CALL wrd_write_string( 'bc_s_t' ) |
---|
252 | WRITE ( 14 ) bc_s_t |
---|
253 | |
---|
254 | CALL wrd_write_string( 'bc_uv_b' ) |
---|
255 | WRITE ( 14 ) bc_uv_b |
---|
256 | |
---|
257 | CALL wrd_write_string( 'bc_uv_t' ) |
---|
258 | WRITE ( 14 ) bc_uv_t |
---|
259 | |
---|
260 | CALL wrd_write_string( 'building_height' ) |
---|
261 | WRITE ( 14 ) building_height |
---|
262 | |
---|
263 | CALL wrd_write_string( 'building_length_x' ) |
---|
264 | WRITE ( 14 ) building_length_x |
---|
265 | |
---|
266 | CALL wrd_write_string( 'building_length_y' ) |
---|
267 | WRITE ( 14 ) building_length_y |
---|
268 | |
---|
269 | CALL wrd_write_string( 'building_wall_left' ) |
---|
270 | WRITE ( 14 ) building_wall_left |
---|
271 | |
---|
272 | CALL wrd_write_string( 'building_wall_south' ) |
---|
273 | WRITE ( 14 ) building_wall_south |
---|
274 | |
---|
275 | CALL wrd_write_string( 'call_psolver_at_all_substeps' ) |
---|
276 | WRITE ( 14 ) call_psolver_at_all_substeps |
---|
277 | |
---|
278 | CALL wrd_write_string( 'canyon_height' ) |
---|
279 | WRITE ( 14 ) canyon_height |
---|
280 | |
---|
281 | CALL wrd_write_string( 'canyon_wall_left' ) |
---|
282 | WRITE ( 14 ) canyon_wall_left |
---|
283 | |
---|
284 | CALL wrd_write_string( 'canyon_wall_south' ) |
---|
285 | WRITE ( 14 ) canyon_wall_south |
---|
286 | |
---|
287 | CALL wrd_write_string( 'canyon_width_x' ) |
---|
288 | WRITE ( 14 ) canyon_width_x |
---|
289 | |
---|
290 | CALL wrd_write_string( 'canyon_width_y' ) |
---|
291 | WRITE ( 14 ) canyon_width_y |
---|
292 | |
---|
293 | CALL wrd_write_string( 'cfl_factor' ) |
---|
294 | WRITE ( 14 ) cfl_factor |
---|
295 | |
---|
296 | CALL wrd_write_string( 'cloud_droplets' ) |
---|
297 | WRITE ( 14 ) cloud_droplets |
---|
298 | |
---|
299 | CALL wrd_write_string( 'collective_wait' ) |
---|
300 | WRITE ( 14 ) collective_wait |
---|
301 | |
---|
302 | CALL wrd_write_string( 'conserve_volume_flow' ) |
---|
303 | WRITE ( 14 ) conserve_volume_flow |
---|
304 | |
---|
305 | CALL wrd_write_string( 'conserve_volume_flow_mode' ) |
---|
306 | WRITE ( 14 ) conserve_volume_flow_mode |
---|
307 | |
---|
308 | CALL wrd_write_string( 'constant_flux_layer' ) |
---|
309 | WRITE ( 14 ) constant_flux_layer |
---|
310 | |
---|
311 | CALL wrd_write_string( 'coupling_start_time' ) |
---|
312 | WRITE ( 14 ) coupling_start_time |
---|
313 | |
---|
314 | CALL wrd_write_string( 'current_timestep_number' ) |
---|
315 | WRITE ( 14 ) current_timestep_number |
---|
316 | |
---|
317 | CALL wrd_write_string( 'curvature_solution_effects' ) |
---|
318 | WRITE ( 14 ) curvature_solution_effects |
---|
319 | |
---|
320 | CALL wrd_write_string( 'cycle_mg' ) |
---|
321 | WRITE ( 14 ) cycle_mg |
---|
322 | |
---|
323 | CALL wrd_write_string( 'damp_level_1d' ) |
---|
324 | WRITE ( 14 ) damp_level_1d |
---|
325 | |
---|
326 | CALL wrd_write_string( 'day_of_year_init' ) |
---|
327 | WRITE ( 14 ) day_of_year_init |
---|
328 | |
---|
329 | CALL wrd_write_string( 'dissipation_1d' ) |
---|
330 | WRITE ( 14 ) dissipation_1d |
---|
331 | |
---|
332 | CALL wrd_write_string( 'do2d_xy_time_count' ) |
---|
333 | WRITE ( 14 ) do2d_xy_time_count |
---|
334 | |
---|
335 | CALL wrd_write_string( 'do2d_xz_time_count' ) |
---|
336 | WRITE ( 14 ) do2d_xz_time_count |
---|
337 | |
---|
338 | CALL wrd_write_string( 'do2d_yz_time_count' ) |
---|
339 | WRITE ( 14 ) do2d_yz_time_count |
---|
340 | |
---|
341 | CALL wrd_write_string( 'do3d_time_count' ) |
---|
342 | WRITE ( 14 ) do3d_time_count |
---|
343 | |
---|
344 | CALL wrd_write_string( 'dp_external' ) |
---|
345 | WRITE ( 14 ) dp_external |
---|
346 | |
---|
347 | CALL wrd_write_string( 'dp_level_b' ) |
---|
348 | WRITE ( 14 ) dp_level_b |
---|
349 | |
---|
350 | CALL wrd_write_string( 'dp_smooth' ) |
---|
351 | WRITE ( 14 ) dp_smooth |
---|
352 | |
---|
353 | CALL wrd_write_string( 'dpdxy' ) |
---|
354 | WRITE ( 14 ) dpdxy |
---|
355 | |
---|
356 | CALL wrd_write_string( 'dt_3d' ) |
---|
357 | WRITE ( 14 ) dt_3d |
---|
358 | |
---|
359 | CALL wrd_write_string( 'dt_pr_1d' ) |
---|
360 | WRITE ( 14 ) dt_pr_1d |
---|
361 | |
---|
362 | CALL wrd_write_string( 'dt_run_control_1d' ) |
---|
363 | WRITE ( 14 ) dt_run_control_1d |
---|
364 | |
---|
365 | CALL wrd_write_string( 'dvrp_filecount' ) |
---|
366 | WRITE ( 14 ) dvrp_filecount |
---|
367 | |
---|
368 | CALL wrd_write_string( 'dx' ) |
---|
369 | WRITE ( 14 ) dx |
---|
370 | |
---|
371 | CALL wrd_write_string( 'dy' ) |
---|
372 | WRITE ( 14 ) dy |
---|
373 | |
---|
374 | CALL wrd_write_string( 'dz' ) |
---|
375 | WRITE ( 14 ) dz |
---|
376 | |
---|
377 | CALL wrd_write_string( 'dz_max' ) |
---|
378 | WRITE ( 14 ) dz_max |
---|
379 | |
---|
380 | CALL wrd_write_string( 'dz_stretch_factor' ) |
---|
381 | WRITE ( 14 ) dz_stretch_factor |
---|
382 | |
---|
383 | CALL wrd_write_string( 'dz_stretch_factor_array' ) |
---|
384 | WRITE ( 14 ) dz_stretch_factor_array |
---|
385 | |
---|
386 | CALL wrd_write_string( 'dz_stretch_level' ) |
---|
387 | WRITE ( 14 ) dz_stretch_level |
---|
388 | |
---|
389 | CALL wrd_write_string( 'dz_stretch_level_end' ) |
---|
390 | WRITE ( 14 ) dz_stretch_level_end |
---|
391 | |
---|
392 | CALL wrd_write_string( 'dz_stretch_level_start' ) |
---|
393 | WRITE ( 14 ) dz_stretch_level_start |
---|
394 | |
---|
395 | CALL wrd_write_string( 'e_min' ) |
---|
396 | WRITE ( 14 ) e_min |
---|
397 | |
---|
398 | CALL wrd_write_string( 'end_time_1d' ) |
---|
399 | WRITE ( 14 ) end_time_1d |
---|
400 | |
---|
401 | CALL wrd_write_string( 'fft_method' ) |
---|
402 | WRITE ( 14 ) fft_method |
---|
403 | |
---|
404 | CALL wrd_write_string( 'first_call_lpm' ) |
---|
405 | WRITE ( 14 ) first_call_lpm |
---|
406 | |
---|
407 | CALL wrd_write_string( 'galilei_transformation' ) |
---|
408 | WRITE ( 14 ) galilei_transformation |
---|
409 | |
---|
410 | CALL wrd_write_string( 'hom' ) |
---|
411 | WRITE ( 14 ) hom |
---|
412 | |
---|
413 | CALL wrd_write_string( 'hom_sum' ) |
---|
414 | WRITE ( 14 ) hom_sum |
---|
415 | |
---|
416 | CALL wrd_write_string( 'humidity' ) |
---|
417 | WRITE ( 14 ) humidity |
---|
418 | |
---|
419 | IF ( ALLOCATED( inflow_damping_factor ) ) THEN |
---|
420 | CALL wrd_write_string( 'inflow_damping_factor' ) |
---|
421 | WRITE ( 14 ) inflow_damping_factor |
---|
422 | ENDIF |
---|
423 | |
---|
424 | CALL wrd_write_string( 'inflow_damping_height' ) |
---|
425 | WRITE ( 14 ) inflow_damping_height |
---|
426 | |
---|
427 | CALL wrd_write_string( 'inflow_damping_width' ) |
---|
428 | WRITE ( 14 ) inflow_damping_width |
---|
429 | |
---|
430 | CALL wrd_write_string( 'inflow_disturbance_begin' ) |
---|
431 | WRITE ( 14 ) inflow_disturbance_begin |
---|
432 | |
---|
433 | CALL wrd_write_string( 'inflow_disturbance_end' ) |
---|
434 | WRITE ( 14 ) inflow_disturbance_end |
---|
435 | |
---|
436 | CALL wrd_write_string( 'km_constant' ) |
---|
437 | WRITE ( 14 ) km_constant |
---|
438 | |
---|
439 | CALL wrd_write_string( 'large_scale_forcing' ) |
---|
440 | WRITE ( 14 ) large_scale_forcing |
---|
441 | |
---|
442 | CALL wrd_write_string( 'large_scale_subsidence' ) |
---|
443 | WRITE ( 14 ) large_scale_subsidence |
---|
444 | |
---|
445 | CALL wrd_write_string( 'latitude' ) |
---|
446 | WRITE ( 14 ) latitude |
---|
447 | |
---|
448 | CALL wrd_write_string( 'longitude' ) |
---|
449 | WRITE ( 14 ) longitude |
---|
450 | |
---|
451 | CALL wrd_write_string( 'loop_optimization' ) |
---|
452 | WRITE ( 14 ) loop_optimization |
---|
453 | |
---|
454 | CALL wrd_write_string( 'masking_method' ) |
---|
455 | WRITE ( 14 ) masking_method |
---|
456 | |
---|
457 | IF ( ALLOCATED( mean_inflow_profiles ) ) THEN |
---|
458 | CALL wrd_write_string( 'mean_inflow_profiles' ) |
---|
459 | WRITE ( 14 ) mean_inflow_profiles |
---|
460 | ENDIF |
---|
461 | |
---|
462 | CALL wrd_write_string( 'mg_cycles' ) |
---|
463 | WRITE ( 14 ) mg_cycles |
---|
464 | |
---|
465 | CALL wrd_write_string( 'mg_switch_to_pe0_level' ) |
---|
466 | WRITE ( 14 ) mg_switch_to_pe0_level |
---|
467 | |
---|
468 | CALL wrd_write_string( 'mixing_length_1d' ) |
---|
469 | WRITE ( 14 ) mixing_length_1d |
---|
470 | |
---|
471 | CALL wrd_write_string( 'momentum_advec' ) |
---|
472 | WRITE ( 14 ) momentum_advec |
---|
473 | |
---|
474 | CALL wrd_write_string( 'most_method' ) |
---|
475 | WRITE ( 14 ) most_method |
---|
476 | |
---|
477 | CALL wrd_write_string( 'netcdf_precision' ) |
---|
478 | WRITE ( 14 ) netcdf_precision |
---|
479 | |
---|
480 | CALL wrd_write_string( 'neutral' ) |
---|
481 | WRITE ( 14 ) neutral |
---|
482 | |
---|
483 | CALL wrd_write_string( 'ngsrb' ) |
---|
484 | WRITE ( 14 ) ngsrb |
---|
485 | |
---|
486 | CALL wrd_write_string( 'nsor' ) |
---|
487 | WRITE ( 14 ) nsor |
---|
488 | |
---|
489 | CALL wrd_write_string( 'nsor_ini' ) |
---|
490 | WRITE ( 14 ) nsor_ini |
---|
491 | |
---|
492 | CALL wrd_write_string( 'nudging' ) |
---|
493 | WRITE ( 14 ) nudging |
---|
494 | |
---|
495 | CALL wrd_write_string( 'num_leg' ) |
---|
496 | WRITE ( 14 ) num_leg |
---|
497 | |
---|
498 | CALL wrd_write_string( 'nx' ) |
---|
499 | WRITE ( 14 ) nx |
---|
500 | |
---|
501 | CALL wrd_write_string( 'ny' ) |
---|
502 | WRITE ( 14 ) ny |
---|
503 | |
---|
504 | CALL wrd_write_string( 'ocean_mode' ) |
---|
505 | WRITE ( 14 ) ocean_mode |
---|
506 | |
---|
507 | CALL wrd_write_string( 'old_dt' ) |
---|
508 | WRITE ( 14 ) old_dt |
---|
509 | |
---|
510 | CALL wrd_write_string( 'omega' ) |
---|
511 | WRITE ( 14 ) omega |
---|
512 | |
---|
513 | CALL wrd_write_string( 'omega_sor' ) |
---|
514 | WRITE ( 14 ) omega_sor |
---|
515 | |
---|
516 | CALL wrd_write_string( 'output_for_t0' ) |
---|
517 | WRITE ( 14 ) output_for_t0 |
---|
518 | |
---|
519 | CALL wrd_write_string( 'passive_scalar' ) |
---|
520 | WRITE ( 14 ) passive_scalar |
---|
521 | |
---|
522 | CALL wrd_write_string( 'prandtl_number' ) |
---|
523 | WRITE ( 14 ) prandtl_number |
---|
524 | |
---|
525 | CALL wrd_write_string( 'psolver' ) |
---|
526 | WRITE ( 14 ) psolver |
---|
527 | |
---|
528 | CALL wrd_write_string( 'pt_damping_factor' ) |
---|
529 | WRITE ( 14 ) pt_damping_factor |
---|
530 | |
---|
531 | CALL wrd_write_string( 'pt_damping_width' ) |
---|
532 | WRITE ( 14 ) pt_damping_width |
---|
533 | |
---|
534 | CALL wrd_write_string( 'pt_init' ) |
---|
535 | WRITE ( 14 ) pt_init |
---|
536 | |
---|
537 | CALL wrd_write_string( 'pt_reference' ) |
---|
538 | WRITE ( 14 ) pt_reference |
---|
539 | |
---|
540 | CALL wrd_write_string( 'pt_surface' ) |
---|
541 | WRITE ( 14 ) pt_surface |
---|
542 | |
---|
543 | CALL wrd_write_string( 'pt_surface_initial_change' ) |
---|
544 | WRITE ( 14 ) pt_surface_initial_change |
---|
545 | |
---|
546 | CALL wrd_write_string( 'pt_vertical_gradient' ) |
---|
547 | WRITE ( 14 ) pt_vertical_gradient |
---|
548 | |
---|
549 | CALL wrd_write_string( 'pt_vertical_gradient_level' ) |
---|
550 | WRITE ( 14 ) pt_vertical_gradient_level |
---|
551 | |
---|
552 | CALL wrd_write_string( 'pt_vertical_gradient_level_ind' ) |
---|
553 | WRITE ( 14 ) pt_vertical_gradient_level_ind |
---|
554 | |
---|
555 | CALL wrd_write_string( 'q_init' ) |
---|
556 | WRITE ( 14 ) q_init |
---|
557 | |
---|
558 | CALL wrd_write_string( 'q_surface' ) |
---|
559 | WRITE ( 14 ) q_surface |
---|
560 | |
---|
561 | CALL wrd_write_string( 'q_surface_initial_change' ) |
---|
562 | WRITE ( 14 ) q_surface_initial_change |
---|
563 | |
---|
564 | CALL wrd_write_string( 'q_vertical_gradient' ) |
---|
565 | WRITE ( 14 ) q_vertical_gradient |
---|
566 | |
---|
567 | CALL wrd_write_string( 'q_vertical_gradient_level' ) |
---|
568 | WRITE ( 14 ) q_vertical_gradient_level |
---|
569 | |
---|
570 | CALL wrd_write_string( 'q_vertical_gradient_level_ind' ) |
---|
571 | WRITE ( 14 ) q_vertical_gradient_level_ind |
---|
572 | |
---|
573 | CALL wrd_write_string( 'random_generator' ) |
---|
574 | WRITE ( 14 ) random_generator |
---|
575 | |
---|
576 | CALL wrd_write_string( 'random_heatflux' ) |
---|
577 | WRITE ( 14 ) random_heatflux |
---|
578 | |
---|
579 | CALL wrd_write_string( 'rans_mode' ) |
---|
580 | WRITE ( 14 ) rans_mode |
---|
581 | |
---|
582 | CALL wrd_write_string( 'rayleigh_damping_factor' ) |
---|
583 | WRITE ( 14 ) rayleigh_damping_factor |
---|
584 | |
---|
585 | CALL wrd_write_string( 'rayleigh_damping_height' ) |
---|
586 | WRITE ( 14 ) rayleigh_damping_height |
---|
587 | |
---|
588 | CALL wrd_write_string( 'recycling_width' ) |
---|
589 | WRITE ( 14 ) recycling_width |
---|
590 | |
---|
591 | CALL wrd_write_string( 'recycling_yshift' ) |
---|
592 | WRITE ( 14 ) recycling_yshift |
---|
593 | |
---|
594 | CALL wrd_write_string( 'ref_state' ) |
---|
595 | WRITE ( 14 ) ref_state |
---|
596 | |
---|
597 | CALL wrd_write_string( 'reference_state' ) |
---|
598 | WRITE ( 14 ) reference_state |
---|
599 | |
---|
600 | CALL wrd_write_string( 'residual_limit' ) |
---|
601 | WRITE ( 14 ) residual_limit |
---|
602 | |
---|
603 | CALL wrd_write_string( 'roughness_length' ) |
---|
604 | WRITE ( 14 ) roughness_length |
---|
605 | |
---|
606 | CALL wrd_write_string( 'run_coupled' ) |
---|
607 | WRITE ( 14 ) run_coupled |
---|
608 | |
---|
609 | CALL wrd_write_string( 'runnr' ) |
---|
610 | WRITE ( 14 ) runnr |
---|
611 | |
---|
612 | CALL wrd_write_string( 's_init' ) |
---|
613 | WRITE ( 14 ) s_init |
---|
614 | |
---|
615 | CALL wrd_write_string( 's_surface' ) |
---|
616 | WRITE ( 14 ) s_surface |
---|
617 | |
---|
618 | CALL wrd_write_string( 's_surface_initial_change' ) |
---|
619 | WRITE ( 14 ) s_surface_initial_change |
---|
620 | |
---|
621 | CALL wrd_write_string( 's_vertical_gradient' ) |
---|
622 | WRITE ( 14 ) s_vertical_gradient |
---|
623 | |
---|
624 | CALL wrd_write_string( 's_vertical_gradient_level' ) |
---|
625 | WRITE ( 14 ) s_vertical_gradient_level |
---|
626 | |
---|
627 | CALL wrd_write_string( 's_vertical_gradient_level_ind' ) |
---|
628 | WRITE ( 14 ) s_vertical_gradient_level_ind |
---|
629 | |
---|
630 | CALL wrd_write_string( 'scalar_advec' ) |
---|
631 | WRITE ( 14 ) scalar_advec |
---|
632 | |
---|
633 | CALL wrd_write_string( 'simulated_time' ) |
---|
634 | WRITE ( 14 ) simulated_time |
---|
635 | |
---|
636 | IF ( ALLOCATED( spectrum_x ) ) THEN |
---|
637 | CALL wrd_write_string( 'spectrum_x' ) |
---|
638 | WRITE ( 14 ) spectrum_x |
---|
639 | CALL wrd_write_string( 'spectrum_y' ) |
---|
640 | WRITE ( 14 ) spectrum_y |
---|
641 | ENDIF |
---|
642 | |
---|
643 | CALL wrd_write_string( 'spinup_time ' ) |
---|
644 | WRITE ( 14 ) spinup_time |
---|
645 | |
---|
646 | CALL wrd_write_string( 'surface_heatflux' ) |
---|
647 | WRITE ( 14 ) surface_heatflux |
---|
648 | |
---|
649 | CALL wrd_write_string( 'surface_pressure' ) |
---|
650 | WRITE ( 14 ) surface_pressure |
---|
651 | |
---|
652 | CALL wrd_write_string( 'surface_scalarflux' ) |
---|
653 | WRITE ( 14 ) surface_scalarflux |
---|
654 | |
---|
655 | CALL wrd_write_string( 'surface_waterflux' ) |
---|
656 | WRITE ( 14 ) surface_waterflux |
---|
657 | |
---|
658 | CALL wrd_write_string( 'time_coupling' ) |
---|
659 | WRITE ( 14 ) time_coupling |
---|
660 | |
---|
661 | CALL wrd_write_string( 'time_disturb' ) |
---|
662 | WRITE ( 14 ) time_disturb |
---|
663 | |
---|
664 | CALL wrd_write_string( 'time_do2d_xy' ) |
---|
665 | WRITE ( 14 ) time_do2d_xy |
---|
666 | |
---|
667 | CALL wrd_write_string( 'time_do2d_xz' ) |
---|
668 | WRITE ( 14 ) time_do2d_xz |
---|
669 | |
---|
670 | CALL wrd_write_string( 'time_do2d_yz' ) |
---|
671 | WRITE ( 14 ) time_do2d_yz |
---|
672 | |
---|
673 | CALL wrd_write_string( 'time_do3d' ) |
---|
674 | WRITE ( 14 ) time_do3d |
---|
675 | |
---|
676 | CALL wrd_write_string( 'time_do_av' ) |
---|
677 | WRITE ( 14 ) time_do_av |
---|
678 | |
---|
679 | CALL wrd_write_string( 'time_do_sla' ) |
---|
680 | WRITE ( 14 ) time_do_sla |
---|
681 | |
---|
682 | CALL wrd_write_string( 'time_domask' ) |
---|
683 | WRITE ( 14 ) time_domask |
---|
684 | |
---|
685 | CALL wrd_write_string( 'time_dopr' ) |
---|
686 | WRITE ( 14 ) time_dopr |
---|
687 | |
---|
688 | CALL wrd_write_string( 'time_dopr_av' ) |
---|
689 | WRITE ( 14 ) time_dopr_av |
---|
690 | |
---|
691 | CALL wrd_write_string( 'time_dopr_listing' ) |
---|
692 | WRITE ( 14 ) time_dopr_listing |
---|
693 | |
---|
694 | CALL wrd_write_string( 'time_dopts' ) |
---|
695 | WRITE ( 14 ) time_dopts |
---|
696 | |
---|
697 | CALL wrd_write_string( 'time_dosp' ) |
---|
698 | WRITE ( 14 ) time_dosp |
---|
699 | |
---|
700 | CALL wrd_write_string( 'time_dots' ) |
---|
701 | WRITE ( 14 ) time_dots |
---|
702 | |
---|
703 | CALL wrd_write_string( 'time_dvrp' ) |
---|
704 | WRITE ( 14 ) time_dvrp |
---|
705 | |
---|
706 | CALL wrd_write_string( 'time_radiation' ) |
---|
707 | WRITE ( 14 ) time_radiation |
---|
708 | |
---|
709 | CALL wrd_write_string( 'time_restart' ) |
---|
710 | WRITE ( 14 ) time_restart |
---|
711 | |
---|
712 | CALL wrd_write_string( 'time_run_control' ) |
---|
713 | WRITE ( 14 ) time_run_control |
---|
714 | |
---|
715 | CALL wrd_write_string( 'time_since_reference_point' ) |
---|
716 | WRITE ( 14 ) time_since_reference_point |
---|
717 | |
---|
718 | CALL wrd_write_string( 'time_utc_init' ) |
---|
719 | WRITE ( 14 ) time_utc_init |
---|
720 | |
---|
721 | CALL wrd_write_string( 'timestep_scheme' ) |
---|
722 | WRITE ( 14 ) timestep_scheme |
---|
723 | |
---|
724 | CALL wrd_write_string( 'top_heatflux' ) |
---|
725 | WRITE ( 14 ) top_heatflux |
---|
726 | |
---|
727 | CALL wrd_write_string( 'top_momentumflux_u' ) |
---|
728 | WRITE ( 14 ) top_momentumflux_u |
---|
729 | |
---|
730 | CALL wrd_write_string( 'top_momentumflux_v' ) |
---|
731 | WRITE ( 14 ) top_momentumflux_v |
---|
732 | |
---|
733 | CALL wrd_write_string( 'top_scalarflux' ) |
---|
734 | WRITE ( 14 ) top_scalarflux |
---|
735 | |
---|
736 | CALL wrd_write_string( 'topography' ) |
---|
737 | WRITE ( 14 ) topography |
---|
738 | |
---|
739 | CALL wrd_write_string( 'topography_grid_convention' ) |
---|
740 | WRITE ( 14 ) topography_grid_convention |
---|
741 | |
---|
742 | CALL wrd_write_string( 'tsc' ) |
---|
743 | WRITE ( 14 ) tsc |
---|
744 | |
---|
745 | CALL wrd_write_string( 'tunnel_height' ) |
---|
746 | WRITE ( 14 ) tunnel_height |
---|
747 | |
---|
748 | CALL wrd_write_string( 'tunnel_length' ) |
---|
749 | WRITE ( 14 ) tunnel_length |
---|
750 | |
---|
751 | CALL wrd_write_string( 'tunnel_wall_depth' ) |
---|
752 | WRITE ( 14 ) tunnel_wall_depth |
---|
753 | |
---|
754 | CALL wrd_write_string( 'tunnel_width_x' ) |
---|
755 | WRITE ( 14 ) tunnel_width_x |
---|
756 | |
---|
757 | CALL wrd_write_string( 'tunnel_width_y' ) |
---|
758 | WRITE ( 14 ) tunnel_width_y |
---|
759 | |
---|
760 | CALL wrd_write_string( 'turbulence_closure' ) |
---|
761 | WRITE ( 14 ) turbulence_closure |
---|
762 | |
---|
763 | CALL wrd_write_string( 'turbulent_inflow' ) |
---|
764 | WRITE ( 14 ) turbulent_inflow |
---|
765 | |
---|
766 | CALL wrd_write_string( 'u_bulk' ) |
---|
767 | WRITE ( 14 ) u_bulk |
---|
768 | |
---|
769 | CALL wrd_write_string( 'u_init' ) |
---|
770 | WRITE ( 14 ) u_init |
---|
771 | |
---|
772 | CALL wrd_write_string( 'u_max' ) |
---|
773 | WRITE ( 14 ) u_max |
---|
774 | |
---|
775 | CALL wrd_write_string( 'u_max_ijk' ) |
---|
776 | WRITE ( 14 ) u_max_ijk |
---|
777 | |
---|
778 | CALL wrd_write_string( 'ug' ) |
---|
779 | WRITE ( 14 ) ug |
---|
780 | |
---|
781 | CALL wrd_write_string( 'ug_surface' ) |
---|
782 | WRITE ( 14 ) ug_surface |
---|
783 | |
---|
784 | CALL wrd_write_string( 'ug_vertical_gradient' ) |
---|
785 | WRITE ( 14 ) ug_vertical_gradient |
---|
786 | |
---|
787 | CALL wrd_write_string( 'ug_vertical_gradient_level' ) |
---|
788 | WRITE ( 14 ) ug_vertical_gradient_level |
---|
789 | |
---|
790 | CALL wrd_write_string( 'ug_vertical_gradient_level_ind' ) |
---|
791 | WRITE ( 14 ) ug_vertical_gradient_level_ind |
---|
792 | |
---|
793 | CALL wrd_write_string( 'use_surface_fluxes' ) |
---|
794 | WRITE ( 14 ) use_surface_fluxes |
---|
795 | |
---|
796 | CALL wrd_write_string( 'use_top_fluxes' ) |
---|
797 | WRITE ( 14 ) use_top_fluxes |
---|
798 | |
---|
799 | CALL wrd_write_string( 'use_ug_for_galilei_tr' ) |
---|
800 | WRITE ( 14 ) use_ug_for_galilei_tr |
---|
801 | |
---|
802 | CALL wrd_write_string( 'use_upstream_for_tke' ) |
---|
803 | WRITE ( 14 ) use_upstream_for_tke |
---|
804 | |
---|
805 | CALL wrd_write_string( 'v_bulk' ) |
---|
806 | WRITE ( 14 ) v_bulk |
---|
807 | |
---|
808 | CALL wrd_write_string( 'v_init' ) |
---|
809 | WRITE ( 14 ) v_init |
---|
810 | |
---|
811 | CALL wrd_write_string( 'v_max' ) |
---|
812 | WRITE ( 14 ) v_max |
---|
813 | |
---|
814 | CALL wrd_write_string( 'v_max_ijk' ) |
---|
815 | WRITE ( 14 ) v_max_ijk |
---|
816 | |
---|
817 | CALL wrd_write_string( 'vg' ) |
---|
818 | WRITE ( 14 ) vg |
---|
819 | |
---|
820 | CALL wrd_write_string( 'vg_surface' ) |
---|
821 | WRITE ( 14 ) vg_surface |
---|
822 | |
---|
823 | CALL wrd_write_string( 'vg_vertical_gradient' ) |
---|
824 | WRITE ( 14 ) vg_vertical_gradient |
---|
825 | |
---|
826 | CALL wrd_write_string( 'vg_vertical_gradient_level' ) |
---|
827 | WRITE ( 14 ) vg_vertical_gradient_level |
---|
828 | |
---|
829 | CALL wrd_write_string( 'vg_vertical_gradient_level_ind' ) |
---|
830 | WRITE ( 14 ) vg_vertical_gradient_level_ind |
---|
831 | |
---|
832 | CALL wrd_write_string( 'virtual_flight' ) |
---|
833 | WRITE ( 14 ) virtual_flight |
---|
834 | |
---|
835 | CALL wrd_write_string( 'vnest_init' ) |
---|
836 | WRITE ( 14 ) vnest_init |
---|
837 | |
---|
838 | CALL wrd_write_string( 'volume_flow_area' ) |
---|
839 | WRITE ( 14 ) volume_flow_area |
---|
840 | |
---|
841 | CALL wrd_write_string( 'volume_flow_initial' ) |
---|
842 | WRITE ( 14 ) volume_flow_initial |
---|
843 | |
---|
844 | CALL wrd_write_string( 'subs_vertical_gradient' ) |
---|
845 | WRITE ( 14 ) subs_vertical_gradient |
---|
846 | |
---|
847 | CALL wrd_write_string( 'subs_vertical_gradient_level' ) |
---|
848 | WRITE ( 14 ) subs_vertical_gradient_level |
---|
849 | |
---|
850 | CALL wrd_write_string( 'subs_vertical_gradient_level_i' ) |
---|
851 | WRITE ( 14 ) subs_vertical_gradient_level_i |
---|
852 | |
---|
853 | CALL wrd_write_string( 'w_max' ) |
---|
854 | WRITE ( 14 ) w_max |
---|
855 | |
---|
856 | CALL wrd_write_string( 'w_max_ijk' ) |
---|
857 | WRITE ( 14 ) w_max_ijk |
---|
858 | |
---|
859 | CALL wrd_write_string( 'wall_adjustment' ) |
---|
860 | WRITE ( 14 ) wall_adjustment |
---|
861 | |
---|
862 | CALL wrd_write_string( 'wall_heatflux' ) |
---|
863 | WRITE ( 14 ) wall_heatflux |
---|
864 | |
---|
865 | CALL wrd_write_string( 'wall_humidityflux' ) |
---|
866 | WRITE ( 14 ) wall_humidityflux |
---|
867 | |
---|
868 | CALL wrd_write_string( 'wall_scalarflux' ) |
---|
869 | WRITE ( 14 ) wall_scalarflux |
---|
870 | |
---|
871 | CALL wrd_write_string( 'y_shift' ) |
---|
872 | WRITE ( 14 ) y_shift |
---|
873 | |
---|
874 | CALL wrd_write_string( 'z0h_factor' ) |
---|
875 | WRITE ( 14 ) z0h_factor |
---|
876 | |
---|
877 | CALL wrd_write_string( 'zeta_max' ) |
---|
878 | WRITE ( 14 ) zeta_max |
---|
879 | |
---|
880 | CALL wrd_write_string( 'zeta_min' ) |
---|
881 | WRITE ( 14 ) zeta_min |
---|
882 | |
---|
883 | CALL wrd_write_string( 'z_i' ) |
---|
884 | WRITE ( 14 ) z_i |
---|
885 | |
---|
886 | ! |
---|
887 | !-- Write restart data of the other modules |
---|
888 | !-- The order of the calls can be different as in read_restart_data_mod where |
---|
889 | !-- the restart data will be read |
---|
890 | IF ( bulk_cloud_model ) CALL bcm_wrd_global |
---|
891 | IF ( virtual_flight ) CALL flight_wrd_global |
---|
892 | IF ( gust_module_enabled ) CALL gust_wrd_global |
---|
893 | IF ( ocean_mode ) CALL ocean_wrd_global |
---|
894 | IF ( syn_turb_gen ) CALL stg_wrd_global |
---|
895 | IF ( wind_turbine ) CALL wtm_wrd_global |
---|
896 | ! |
---|
897 | !-- Write restart data of the user-interface |
---|
898 | CALL user_wrd_global |
---|
899 | |
---|
900 | |
---|
901 | END SUBROUTINE wrd_global |
---|
902 | |
---|
903 | |
---|
904 | !------------------------------------------------------------------------------! |
---|
905 | ! Description: |
---|
906 | ! ------------ |
---|
907 | !> Processor specific data of variables and arrays is written out for |
---|
908 | !> restarts (binary format). |
---|
909 | !> This information is written to the file opened by each PE. |
---|
910 | !------------------------------------------------------------------------------! |
---|
911 | SUBROUTINE wrd_local |
---|
912 | |
---|
913 | |
---|
914 | USE arrays_3d, & |
---|
915 | ONLY: e, kh, km, p, pt, q, ql, s, u, u_m_l, u_m_n, u_m_r, & |
---|
916 | u_m_s, v, v_m_l, v_m_n, v_m_r, v_m_s, vpt, w, w_m_l, w_m_n, & |
---|
917 | w_m_r, w_m_s |
---|
918 | |
---|
919 | USE averaging |
---|
920 | |
---|
921 | USE bulk_cloud_model_mod, & |
---|
922 | ONLY: bulk_cloud_model, bcm_wrd_local |
---|
923 | |
---|
924 | USE chemistry_model_mod, & |
---|
925 | ONLY: chem_wrd_local |
---|
926 | |
---|
927 | USE gust_mod, & |
---|
928 | ONLY : gust_module_enabled, gust_wrd_local |
---|
929 | |
---|
930 | USE indices, & |
---|
931 | ONLY: nxl, nxr, nys, nyn, nzb, nzt |
---|
932 | |
---|
933 | USE land_surface_model_mod, & |
---|
934 | ONLY: lsm_wrd_local |
---|
935 | |
---|
936 | USE ocean_mod, & |
---|
937 | ONLY: ocean_wrd_local |
---|
938 | |
---|
939 | USE particle_attributes, & |
---|
940 | ONLY: iran_part |
---|
941 | |
---|
942 | USE radiation_model_mod, & |
---|
943 | ONLY: radiation, radiation_wrd_local |
---|
944 | |
---|
945 | USE random_function_mod, & |
---|
946 | ONLY: random_iv, random_iy |
---|
947 | |
---|
948 | USE random_generator_parallel, & |
---|
949 | ONLY: id_random_array, seq_random_array |
---|
950 | |
---|
951 | USE salsa_mod, & |
---|
952 | ONLY: salsa_wrd_local |
---|
953 | |
---|
954 | USE surface_mod, & |
---|
955 | ONLY : surface_wrd_local |
---|
956 | |
---|
957 | USE urban_surface_mod, & |
---|
958 | ONLY: usm_wrd_local |
---|
959 | |
---|
960 | USE user_write_restart_data_mod, & |
---|
961 | ONLY: user_wrd_local |
---|
962 | |
---|
963 | |
---|
964 | IMPLICIT NONE |
---|
965 | |
---|
966 | CHARACTER (LEN=10) :: binary_version_local !< |
---|
967 | |
---|
968 | |
---|
969 | ! |
---|
970 | !-- Write arrays. |
---|
971 | binary_version_local = '4.7' |
---|
972 | |
---|
973 | CALL wrd_write_string( 'binary_version_local' ) |
---|
974 | WRITE ( 14 ) binary_version_local |
---|
975 | |
---|
976 | WRITE ( 14 ) numprocs, myid, nxl, nxr, nys, nyn, nzb, nzt |
---|
977 | |
---|
978 | ! |
---|
979 | !-- Attention: After changes to the following output commands the version number |
---|
980 | !-- --------- of the variable binary_version_local must be changed! |
---|
981 | !-- Also, the list of arrays to be read in rrd_local must be |
---|
982 | !-- adjusted accordingly. |
---|
983 | CALL wrd_write_string( 'e' ) |
---|
984 | WRITE ( 14 ) e |
---|
985 | |
---|
986 | IF ( ALLOCATED( e_av ) ) THEN |
---|
987 | CALL wrd_write_string( 'e_av' ) |
---|
988 | WRITE ( 14 ) e_av |
---|
989 | ENDIF |
---|
990 | |
---|
991 | CALL wrd_write_string( 'iran' ) |
---|
992 | WRITE ( 14 ) iran, iran_part |
---|
993 | |
---|
994 | CALL wrd_write_string( 'kh' ) |
---|
995 | WRITE ( 14 ) kh |
---|
996 | |
---|
997 | |
---|
998 | IF ( ALLOCATED( kh_av ) ) THEN |
---|
999 | CALL wrd_write_string( 'kh_av' ) |
---|
1000 | WRITE ( 14 ) kh_av |
---|
1001 | ENDIF |
---|
1002 | |
---|
1003 | CALL wrd_write_string( 'km' ) |
---|
1004 | WRITE ( 14 ) km |
---|
1005 | |
---|
1006 | IF ( ALLOCATED( km_av ) ) THEN |
---|
1007 | CALL wrd_write_string( 'km_av' ) |
---|
1008 | WRITE ( 14 ) km_av |
---|
1009 | ENDIF |
---|
1010 | |
---|
1011 | IF ( ALLOCATED( lpt_av ) ) THEN |
---|
1012 | CALL wrd_write_string( 'lpt_av' ) |
---|
1013 | WRITE ( 14 ) lpt_av |
---|
1014 | ENDIF |
---|
1015 | |
---|
1016 | IF ( ALLOCATED( lwp_av ) ) THEN |
---|
1017 | CALL wrd_write_string( 'lwp_av' ) |
---|
1018 | WRITE ( 14 ) lwp_av |
---|
1019 | ENDIF |
---|
1020 | |
---|
1021 | CALL wrd_write_string( 'p' ) |
---|
1022 | WRITE ( 14 ) p |
---|
1023 | |
---|
1024 | IF ( ALLOCATED( p_av ) ) THEN |
---|
1025 | CALL wrd_write_string( 'p_av' ) |
---|
1026 | WRITE ( 14 ) p_av |
---|
1027 | ENDIF |
---|
1028 | |
---|
1029 | IF ( ALLOCATED( pc_av ) ) THEN |
---|
1030 | CALL wrd_write_string( 'pc_av' ) |
---|
1031 | WRITE ( 14 ) pc_av |
---|
1032 | ENDIF |
---|
1033 | |
---|
1034 | IF ( ALLOCATED( pr_av ) ) THEN |
---|
1035 | CALL wrd_write_string( 'pr_av' ) |
---|
1036 | WRITE ( 14 ) pr_av |
---|
1037 | ENDIF |
---|
1038 | |
---|
1039 | CALL wrd_write_string( 'pt' ) |
---|
1040 | WRITE ( 14 ) pt |
---|
1041 | |
---|
1042 | IF ( ALLOCATED( pt_av ) ) THEN |
---|
1043 | CALL wrd_write_string( 'pt_av' ) |
---|
1044 | WRITE ( 14 ) pt_av |
---|
1045 | ENDIF |
---|
1046 | |
---|
1047 | IF ( humidity ) THEN |
---|
1048 | |
---|
1049 | CALL wrd_write_string( 'q' ) |
---|
1050 | WRITE ( 14 ) q |
---|
1051 | |
---|
1052 | IF ( ALLOCATED( q_av ) ) THEN |
---|
1053 | CALL wrd_write_string( 'q_av' ) |
---|
1054 | WRITE ( 14 ) q_av |
---|
1055 | ENDIF |
---|
1056 | |
---|
1057 | IF ( cloud_droplets ) THEN |
---|
1058 | |
---|
1059 | CALL wrd_write_string( 'ql' ) |
---|
1060 | WRITE ( 14 ) ql |
---|
1061 | |
---|
1062 | IF ( ALLOCATED( ql_av ) ) THEN |
---|
1063 | CALL wrd_write_string( 'ql_av' ) |
---|
1064 | WRITE ( 14 ) ql_av |
---|
1065 | ENDIF |
---|
1066 | |
---|
1067 | ENDIF |
---|
1068 | |
---|
1069 | IF ( ALLOCATED( qsws_av ) ) THEN |
---|
1070 | CALL wrd_write_string( 'qsws_av' ) |
---|
1071 | WRITE ( 14 ) qsws_av |
---|
1072 | ENDIF |
---|
1073 | |
---|
1074 | ENDIF |
---|
1075 | |
---|
1076 | IF ( passive_scalar ) THEN |
---|
1077 | |
---|
1078 | CALL wrd_write_string( 's' ) |
---|
1079 | WRITE ( 14 ) s |
---|
1080 | |
---|
1081 | IF ( ALLOCATED( s_av ) ) THEN |
---|
1082 | CALL wrd_write_string( 's_av' ) |
---|
1083 | WRITE ( 14 ) s_av |
---|
1084 | ENDIF |
---|
1085 | |
---|
1086 | IF ( ALLOCATED( ssws_av ) ) THEN |
---|
1087 | CALL wrd_write_string( 'ssws_av' ) |
---|
1088 | WRITE ( 14 ) ssws_av |
---|
1089 | ENDIF |
---|
1090 | |
---|
1091 | ENDIF |
---|
1092 | |
---|
1093 | IF ( ALLOCATED( ql_c_av ) ) THEN |
---|
1094 | CALL wrd_write_string( 'ql_c_av' ) |
---|
1095 | WRITE ( 14 ) ql_c_av |
---|
1096 | ENDIF |
---|
1097 | |
---|
1098 | IF ( ALLOCATED( ql_v_av ) ) THEN |
---|
1099 | CALL wrd_write_string( 'ql_v_av' ) |
---|
1100 | WRITE ( 14 ) ql_v_av |
---|
1101 | ENDIF |
---|
1102 | |
---|
1103 | IF ( ALLOCATED( ql_vp_av ) ) THEN |
---|
1104 | CALL wrd_write_string( 'ql_vp_av' ) |
---|
1105 | WRITE ( 14 ) ql_vp_av |
---|
1106 | ENDIF |
---|
1107 | |
---|
1108 | IF ( ALLOCATED( qv_av ) ) THEN |
---|
1109 | CALL wrd_write_string( 'qv_av' ) |
---|
1110 | WRITE ( 14 ) qv_av |
---|
1111 | ENDIF |
---|
1112 | |
---|
1113 | CALL wrd_write_string( 'random_iv' ) |
---|
1114 | WRITE ( 14 ) random_iv |
---|
1115 | WRITE ( 14 ) random_iy |
---|
1116 | |
---|
1117 | IF ( ALLOCATED( seq_random_array ) ) THEN |
---|
1118 | CALL wrd_write_string( 'seq_random_array' ) |
---|
1119 | WRITE ( 14 ) id_random_array |
---|
1120 | WRITE ( 14 ) seq_random_array |
---|
1121 | ENDIF |
---|
1122 | |
---|
1123 | IF ( ALLOCATED( s_av ) ) THEN |
---|
1124 | CALL wrd_write_string( 's_av' ) |
---|
1125 | WRITE ( 14 ) s_av |
---|
1126 | ENDIF |
---|
1127 | |
---|
1128 | IF ( ALLOCATED( shf_av ) ) THEN |
---|
1129 | CALL wrd_write_string( 'shf_av' ) |
---|
1130 | WRITE ( 14 ) shf_av |
---|
1131 | ENDIF |
---|
1132 | |
---|
1133 | IF ( ALLOCATED( ts_av ) ) THEN |
---|
1134 | CALL wrd_write_string( 'ts_av' ) |
---|
1135 | WRITE ( 14 ) ts_av |
---|
1136 | ENDIF |
---|
1137 | |
---|
1138 | CALL wrd_write_string( 'u' ) |
---|
1139 | WRITE ( 14 ) u |
---|
1140 | |
---|
1141 | IF ( ALLOCATED( u_av ) ) THEN |
---|
1142 | CALL wrd_write_string( 'u_av' ) |
---|
1143 | WRITE ( 14 ) u_av |
---|
1144 | ENDIF |
---|
1145 | |
---|
1146 | IF ( ALLOCATED( u_m_l ) ) THEN |
---|
1147 | CALL wrd_write_string( 'u_m_l' ) |
---|
1148 | WRITE ( 14 ) u_m_l |
---|
1149 | ENDIF |
---|
1150 | |
---|
1151 | IF ( ALLOCATED( u_m_n ) ) THEN |
---|
1152 | CALL wrd_write_string( 'u_m_n' ) |
---|
1153 | WRITE ( 14 ) u_m_n |
---|
1154 | ENDIF |
---|
1155 | |
---|
1156 | IF ( ALLOCATED( u_m_r ) ) THEN |
---|
1157 | CALL wrd_write_string( 'u_m_r' ) |
---|
1158 | WRITE ( 14 ) u_m_r |
---|
1159 | ENDIF |
---|
1160 | |
---|
1161 | IF ( ALLOCATED( u_m_s ) ) THEN |
---|
1162 | CALL wrd_write_string( 'u_m_s' ) |
---|
1163 | WRITE ( 14 ) u_m_s |
---|
1164 | ENDIF |
---|
1165 | |
---|
1166 | IF ( ALLOCATED( us_av ) ) THEN |
---|
1167 | CALL wrd_write_string( 'us_av' ) |
---|
1168 | WRITE ( 14 ) us_av |
---|
1169 | ENDIF |
---|
1170 | |
---|
1171 | CALL wrd_write_string( 'v' ) |
---|
1172 | WRITE ( 14 ) v |
---|
1173 | |
---|
1174 | IF ( ALLOCATED( v_av ) ) THEN |
---|
1175 | CALL wrd_write_string( 'v_av' ) |
---|
1176 | WRITE ( 14 ) v_av |
---|
1177 | ENDIF |
---|
1178 | |
---|
1179 | IF ( ALLOCATED( v_m_l ) ) THEN |
---|
1180 | CALL wrd_write_string( 'v_m_l' ) |
---|
1181 | WRITE ( 14 ) v_m_l |
---|
1182 | ENDIF |
---|
1183 | |
---|
1184 | IF ( ALLOCATED( v_m_n ) ) THEN |
---|
1185 | CALL wrd_write_string( 'v_m_n' ) |
---|
1186 | WRITE ( 14 ) v_m_n |
---|
1187 | ENDIF |
---|
1188 | |
---|
1189 | IF ( ALLOCATED( v_m_r ) ) THEN |
---|
1190 | CALL wrd_write_string( 'v_m_r' ) |
---|
1191 | WRITE ( 14 ) v_m_r |
---|
1192 | ENDIF |
---|
1193 | |
---|
1194 | IF ( ALLOCATED( v_m_s ) ) THEN |
---|
1195 | CALL wrd_write_string( 'v_m_s' ) |
---|
1196 | WRITE ( 14 ) v_m_s |
---|
1197 | ENDIF |
---|
1198 | |
---|
1199 | IF ( humidity ) THEN |
---|
1200 | |
---|
1201 | CALL wrd_write_string( 'vpt' ) |
---|
1202 | WRITE ( 14 ) vpt |
---|
1203 | |
---|
1204 | IF ( ALLOCATED( vpt_av ) ) THEN |
---|
1205 | CALL wrd_write_string( 'vpt_av' ) |
---|
1206 | WRITE ( 14 ) vpt_av |
---|
1207 | ENDIF |
---|
1208 | |
---|
1209 | ENDIF |
---|
1210 | |
---|
1211 | CALL wrd_write_string( 'w' ) |
---|
1212 | WRITE ( 14 ) w |
---|
1213 | |
---|
1214 | IF ( ALLOCATED( w_av ) ) THEN |
---|
1215 | CALL wrd_write_string( 'w_av' ) |
---|
1216 | WRITE ( 14 ) w_av |
---|
1217 | ENDIF |
---|
1218 | |
---|
1219 | IF ( ALLOCATED( w_m_l ) ) THEN |
---|
1220 | CALL wrd_write_string( 'w_m_l' ) |
---|
1221 | WRITE ( 14 ) w_m_l |
---|
1222 | ENDIF |
---|
1223 | |
---|
1224 | IF ( ALLOCATED( w_m_n ) ) THEN |
---|
1225 | CALL wrd_write_string( 'w_m_n' ) |
---|
1226 | WRITE ( 14 ) w_m_n |
---|
1227 | ENDIF |
---|
1228 | |
---|
1229 | IF ( ALLOCATED( w_m_r ) ) THEN |
---|
1230 | CALL wrd_write_string( 'w_m_r' ) |
---|
1231 | WRITE ( 14 ) w_m_r |
---|
1232 | ENDIF |
---|
1233 | |
---|
1234 | IF ( ALLOCATED( w_m_s ) ) THEN |
---|
1235 | CALL wrd_write_string( 'w_m_s' ) |
---|
1236 | WRITE ( 14 ) w_m_s |
---|
1237 | ENDIF |
---|
1238 | |
---|
1239 | IF ( ALLOCATED( z0_av ) ) THEN |
---|
1240 | CALL wrd_write_string( 'z0_av' ) |
---|
1241 | WRITE ( 14 ) z0_av |
---|
1242 | ENDIF |
---|
1243 | |
---|
1244 | IF ( ALLOCATED( z0h_av ) ) THEN |
---|
1245 | CALL wrd_write_string( 'z0h_av' ) |
---|
1246 | WRITE ( 14 ) z0h_av |
---|
1247 | ENDIF |
---|
1248 | |
---|
1249 | IF ( ALLOCATED( z0q_av ) ) THEN |
---|
1250 | CALL wrd_write_string( 'z0q_av' ) |
---|
1251 | WRITE ( 14 ) z0q_av |
---|
1252 | ENDIF |
---|
1253 | |
---|
1254 | IF ( land_surface .OR. urban_surface ) THEN |
---|
1255 | |
---|
1256 | IF ( ALLOCATED( ghf_av ) ) THEN |
---|
1257 | CALL wrd_write_string( 'ghf_av' ) |
---|
1258 | WRITE ( 14 ) ghf_av |
---|
1259 | ENDIF |
---|
1260 | |
---|
1261 | IF ( ALLOCATED( r_a_av ) ) THEN |
---|
1262 | CALL wrd_write_string( 'r_a_av' ) |
---|
1263 | WRITE ( 14 ) r_a_av |
---|
1264 | ENDIF |
---|
1265 | |
---|
1266 | ENDIF |
---|
1267 | |
---|
1268 | IF ( ALLOCATED( tsurf_av ) ) THEN |
---|
1269 | CALL wrd_write_string( 'tsurf_av' ) |
---|
1270 | WRITE ( 14 ) tsurf_av |
---|
1271 | ENDIF |
---|
1272 | |
---|
1273 | ! |
---|
1274 | !-- Write restart data of other modules |
---|
1275 | IF ( bulk_cloud_model ) CALL bcm_wrd_local |
---|
1276 | IF ( air_chemistry ) CALL chem_wrd_local |
---|
1277 | IF ( gust_module_enabled ) CALL gust_wrd_local |
---|
1278 | IF ( land_surface ) CALL lsm_wrd_local |
---|
1279 | IF ( ocean_mode ) CALL ocean_wrd_local |
---|
1280 | IF ( radiation ) CALL radiation_wrd_local |
---|
1281 | IF ( salsa ) CALL salsa_wrd_local |
---|
1282 | CALL surface_wrd_local |
---|
1283 | IF ( urban_surface ) CALL usm_wrd_local |
---|
1284 | |
---|
1285 | ! |
---|
1286 | !-- Write user-defined restart data |
---|
1287 | CALL user_wrd_local |
---|
1288 | |
---|
1289 | ! |
---|
1290 | !-- Write end label |
---|
1291 | CALL wrd_write_string( '*** end ***' ) |
---|
1292 | |
---|
1293 | END SUBROUTINE wrd_local |
---|
1294 | |
---|
1295 | |
---|
1296 | END MODULE write_restart_data_mod |
---|