source: palm/trunk/SOURCE/package_parin.f90 @ 1367

Last change on this file since 1367 was 1367, checked in by witha, 10 years ago

Bugfix: module kinds must be used in package_parin

  • Property svn:keywords set to Id
File size: 9.1 KB
RevLine 
[1]1 SUBROUTINE package_parin
2
[1036]3!--------------------------------------------------------------------------------!
4! This file is part of PALM.
5!
6! PALM is free software: you can redistribute it and/or modify it under the terms
7! of the GNU General Public License as published by the Free Software Foundation,
8! either version 3 of the License, or (at your option) any later 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!
[1310]17! Copyright 1997-2014 Leibniz Universitaet Hannover
[1036]18!--------------------------------------------------------------------------------!
19!
[484]20! Current revisions:
[1]21! -----------------
[1341]22!
[1360]23!
[1321]24! Former revisions:
25! -----------------
26! $Id: package_parin.f90 1367 2014-04-23 15:18:30Z witha $
27!
[1360]28! 1359 2014-04-11 17:15:14Z hoffmann
29! +alloc_factor, + min_nr_particle
30! -dt_sort_particles, -maximum_number_of_particles
31!
[1341]32! 1340 2014-03-25 19:45:13Z kanani
33! REAL constants defined as wp-kinds
34!
[1325]35! 1324 2014-03-21 09:13:16Z suehring
36! Bugfix: Missing variable dt_data_output output added to ONLY statement
37!
[1321]38! 1320 2014-03-20 08:40:49Z raasch
[1320]39! ONLY-attribute added to USE-statements,
40! kind-parameters added to all INTEGER and REAL declaration statements,
41! kinds are defined in new module kinds,
42! old module precision_kind is removed,
43! revision history before 2012 removed,
44! comment fields (!:) to be used for variable explanations added to
45! all variable declaration statements
[392]46!
[1037]47! 1036 2012-10-22 13:43:42Z raasch
48! code put under GPL (PALM 3.9)
49!
[829]50! 828 2012-02-21 12:00:36Z raasch
51! +dissipation_classes, radius_classes in parpar
52!
[826]53! 825 2012-02-19 03:03:44Z raasch
54! wang_collision_kernel and turbulence_effects_on_collision in particles_par
55! replaced by collision_kernel
56!
[1]57! Revision 1.1  2000/12/28 13:21:57  raasch
58! Initial revision
59!
60!
61! Description:
62! ------------
63! This subroutine reads from the NAMELIST file variables controling model
64! software packages which are used optionally in the run.
65!------------------------------------------------------------------------------!
66
[1320]67    USE control_parameters,                                                    &
[1324]68        ONLY:  averaging_interval_sp, dt_data_output, dt_dopts, dt_dosp,       &
69               dt_dvrp, particle_maximum_age, skip_time_dosp, threshold
[1]70
[1320]71    USE dvrp_variables,                                                        &
72        ONLY:  clip_dvrp_l, clip_dvrp_n, clip_dvrp_r, clip_dvrp_s,             &
73               cluster_size, color_interval, dvrpsize_interval,                &
74               dvrp_directory, dvrp_file, dvrp_host, dvrp_output,              &
75               dvrp_password, dvrp_username, groundplate_color,                &
76               isosurface_color, mode_dvrp, particle_color,                    &
77               particle_dvrpsize, pathlines_fadeintime,                        &
78               pathlines_fadeouttime, pathlines_linecount,                     &
79               pathlines_maxhistory, pathlines_wavecount,                      &
80               pathlines_wavetime, slicer_range_limits_dvrp, superelevation,   &
81               superelevation_x, superelevation_y, topography_color,           &
82               vc_alpha, vc_gradient_normals, vc_mode, vc_size_x, vc_size_y,   &
83               vc_size_z
84
[1367]85    USE kinds
86
[1320]87    USE particle_attributes,                                                   &
[1359]88        ONLY:  alloc_factor, bc_par_b, bc_par_lr, bc_par_ns, bc_par_t,         &
89               collision_kernel, density_ratio, dissipation_classes,           &
90               dt_min_part, dt_prel, dt_write_particle_data, dvrp_psize,       &
[1320]91               end_time_prel, initial_weighting_factor,                        &
[1359]92               maximum_number_of_tailpoints,                                   &
[1320]93               maximum_tailpoint_age, minimum_tailpoint_distance,              &
[1359]94               min_nr_particle, number_of_particle_groups, particles_per_point,&
[1320]95               particle_advection, particle_advection_start, pdx, pdy, pdz,    &
96               psb, psl, psn, psr, pss, pst, radius, radius_classes,           &
97               random_start_position, read_particles_from_restartfile,         &
98               skip_particles_for_tail, use_particle_tails,                    &
99               use_sgs_for_particles, vertical_particle_advection,             &
100               write_particle_statistics
101
102    USE spectrum,                                                              &
103        ONLY:  comp_spectra_level, data_output_sp, plot_spectra_level,         &
104               spectra_direction
105
[1]106    IMPLICIT NONE
107
[1320]108    CHARACTER (LEN=80) ::  line  !:
[1]109
[242]110    NAMELIST /dvrp_graphics_par/  clip_dvrp_l, clip_dvrp_n, clip_dvrp_r,       &
[264]111                                  clip_dvrp_s, cluster_size, color_interval,   &
112                                  dt_dvrp, dvrpsize_interval, dvrp_directory,  &
113                                  dvrp_file, dvrp_host, dvrp_output,           &
[336]114                                  dvrp_password, dvrp_psize, dvrp_username,    &
[284]115                                  groundplate_color, isosurface_color,         &
116                                  mode_dvrp, particle_color, particle_dvrpsize,&
[264]117                                  pathlines_fadeintime, pathlines_fadeouttime, &
118                                  pathlines_linecount, pathlines_maxhistory,   &
119                                  pathlines_wavecount, pathlines_wavetime,     &
120                                  slicer_range_limits_dvrp, superelevation,    &
121                                  superelevation_x, superelevation_y,          &
[284]122                                  threshold, topography_color, vc_alpha,       &
123                                  vc_gradient_normals, vc_mode, vc_size_x,     &
124                                  vc_size_y, vc_size_z
[264]125
[1359]126    NAMELIST /particles_par/      alloc_factor, bc_par_b, bc_par_lr,           &
127                                  bc_par_ns, bc_par_t, collision_kernel,       &
128                                  density_ratio, dissipation_classes, dt_dopts,&
129                                  dt_min_part, dt_prel,                        &
[336]130                                  dt_write_particle_data,                      &
[1]131                                  end_time_prel, initial_weighting_factor,     &
132                                  maximum_number_of_tailpoints,                &
133                                  maximum_tailpoint_age,                       &
134                                  minimum_tailpoint_distance,                  &
[1359]135                                  min_nr_particle,                             &
[1]136                                  number_of_particle_groups,                   &
137                                  particles_per_point,                         &
138                                  particle_advection_start,                    &
139                                  particle_maximum_age, pdx, pdy, pdz, psb,    &
[828]140                                  psl, psn, psr, pss, pst, radius,             &
141                                  radius_classes, random_start_position,       &
[1]142                                  read_particles_from_restartfile,             &
[790]143                                  skip_particles_for_tail,                     &
144                                  use_particle_tails, use_sgs_for_particles,   &
[1]145                                  vertical_particle_advection,                 &
146                                  write_particle_statistics
[1320]147
[1]148    NAMELIST /spectra_par/        averaging_interval_sp, comp_spectra_level,   &
149                                  data_output_sp, dt_dosp, plot_spectra_level, &
150                                  skip_time_dosp, spectra_direction
151
152!
153!-- Position the namelist-file at the beginning (it was already opened in
154!-- parin), search for the namelist-group of the package and position the
155!-- file at this line. Do the same for each optionally used package.
[1320]156    line = ' '
[1]157
158#if defined( __dvrp_graphics )
159    REWIND ( 11 )
[1320]160    line = ' '
161    DO   WHILE ( INDEX( line, '&dvrp_graphics_par' ) == 0 )
162       READ ( 11, '(A)', END=10 )  line
[1]163    ENDDO
164    BACKSPACE ( 11 )
165
166!
167!-- Read user-defined namelist
168    READ ( 11, dvrp_graphics_par )
169
170 10 CONTINUE
171#endif
172
[60]173!
174!-- Try to find particles package
[1]175    REWIND ( 11 )
[1320]176    line = ' '
177    DO   WHILE ( INDEX( line, '&particles_par' ) == 0 )
178       READ ( 11, '(A)', END=20 )  line
[1]179    ENDDO
180    BACKSPACE ( 11 )
181
182!
183!-- Read user-defined namelist
184    READ ( 11, particles_par )
185
186!
187!-- Set flag that indicates that particles are switched on
188    particle_advection = .TRUE.
189
190 20 CONTINUE
191
[60]192
[1]193#if defined( __spectra )
194    REWIND ( 11 )
[1320]195    line = ' '
196    DO   WHILE ( INDEX( line, '&spectra_par' ) == 0 )
197       READ ( 11, '(A)', END=30 )  line
[1]198    ENDDO
199    BACKSPACE ( 11 )
200
201!
202!-- Read user-defined namelist
203    READ ( 11, spectra_par )
204
205!
206!-- Default setting of dt_dosp here (instead of check_parameters), because its
207!-- current value is needed in init_pegrid
[1340]208    IF ( dt_dosp == 9999999.9_wp )  dt_dosp = dt_data_output
[1]209
210 30 CONTINUE
211#endif
212
213 END SUBROUTINE package_parin
Note: See TracBrowser for help on using the repository browser.