[1682] | 1 | !> @file package_parin.f90 |
---|
[1036] | 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 | ! |
---|
[1818] | 16 | ! Copyright 1997-2016 Leibniz Universitaet Hannover |
---|
[1036] | 17 | !--------------------------------------------------------------------------------! |
---|
| 18 | ! |
---|
[484] | 19 | ! Current revisions: |
---|
[1] | 20 | ! ----------------- |
---|
[1832] | 21 | ! |
---|
[1789] | 22 | ! |
---|
[1485] | 23 | ! Former revisions: |
---|
| 24 | ! ----------------- |
---|
| 25 | ! $Id: package_parin.f90 1832 2016-04-07 13:28:15Z hoffmann $ |
---|
| 26 | ! |
---|
[1832] | 27 | ! 1831 2016-04-07 13:15:51Z hoffmann |
---|
| 28 | ! curvature_solution_effects added |
---|
| 29 | ! |
---|
[1827] | 30 | ! 1826 2016-04-07 12:01:39Z maronga |
---|
| 31 | ! Reading of &radiation_par moved to radiation_model_mod. |
---|
| 32 | ! Reading of &canopy_par moved to plant_canopy_model_mod. |
---|
| 33 | ! |
---|
[1823] | 34 | ! 822 2016-04-07 07:49:42Z hoffmann |
---|
| 35 | ! +collision_algorithm |
---|
| 36 | ! Tails removed. |
---|
| 37 | ! |
---|
[1818] | 38 | ! 1817 2016-04-06 15:44:20Z maronga |
---|
[1826] | 39 | ! Reading of &lsm_par moved to land_surface_model_mod. |
---|
[1818] | 40 | ! |
---|
[1789] | 41 | ! 1788 2016-03-10 11:01:04Z maronga |
---|
| 42 | ! Parameter dewfall removed. |
---|
| 43 | ! |
---|
[1787] | 44 | ! 1786 2016-03-08 05:49:27Z raasch |
---|
| 45 | ! cpp-direktives for spectra removed |
---|
| 46 | ! |
---|
[1758] | 47 | ! 1757 2016-02-22 15:49:32Z maronga |
---|
| 48 | ! Added parameter unscheduled_radiation_calls |
---|
| 49 | ! |
---|
[1692] | 50 | ! 1691 2015-10-26 16:17:44Z maronga |
---|
| 51 | ! Added skip_time_do_lsm, skip_time_do_radiation, and emissivity |
---|
| 52 | ! |
---|
[1683] | 53 | ! 1682 2015-10-07 23:56:08Z knoop |
---|
| 54 | ! Code annotations made doxygen readable |
---|
| 55 | ! |
---|
[1586] | 56 | ! 1585 2015-04-30 07:05:52Z maronga |
---|
| 57 | ! Added several radiation_par parameters |
---|
| 58 | ! |
---|
[1576] | 59 | ! 1575 2015-03-27 09:56:27Z raasch |
---|
| 60 | ! +seed_follows_topography in particles_par |
---|
| 61 | ! |
---|
[1554] | 62 | ! 1553 2015-03-03 17:33:54Z maronga |
---|
| 63 | ! Resorting of lsm_par |
---|
| 64 | ! |
---|
[1552] | 65 | ! 1551 2015-03-03 14:18:16Z maronga |
---|
| 66 | ! Several changes in the liste for land surface model and radiation model |
---|
| 67 | ! |
---|
[1497] | 68 | ! 1496 2014-12-02 17:25:50Z maronga |
---|
| 69 | ! Added support for the land surface model and radiation scheme |
---|
| 70 | ! |
---|
[1485] | 71 | ! 1484 2014-10-21 10:53:05Z kanani |
---|
[1484] | 72 | ! Changes due to new module structure of the plant canopy model: |
---|
| 73 | ! module plant_canopy_model_mod added, |
---|
| 74 | ! new package/namelist canopy_par added, i.e. the canopy model is no longer |
---|
| 75 | ! steered over the inipar-namelist, |
---|
| 76 | ! drag_coefficient, leaf_surface_concentration and scalar_exchange_coefficient |
---|
| 77 | ! renamed to canopy_drag_coeff, leaf_surface_conc and leaf_scalar_exch_coeff. |
---|
| 78 | ! Changed statement tags in CONTINUE-statement |
---|
[1341] | 79 | ! |
---|
[1368] | 80 | ! 1367 2014-04-23 15:18:30Z witha |
---|
| 81 | ! Bugfix: module kinds must be used |
---|
| 82 | ! |
---|
[1360] | 83 | ! 1359 2014-04-11 17:15:14Z hoffmann |
---|
| 84 | ! +alloc_factor, + min_nr_particle |
---|
| 85 | ! -dt_sort_particles, -maximum_number_of_particles |
---|
| 86 | ! |
---|
[1341] | 87 | ! 1340 2014-03-25 19:45:13Z kanani |
---|
| 88 | ! REAL constants defined as wp-kinds |
---|
| 89 | ! |
---|
[1325] | 90 | ! 1324 2014-03-21 09:13:16Z suehring |
---|
| 91 | ! Bugfix: Missing variable dt_data_output output added to ONLY statement |
---|
| 92 | ! |
---|
[1321] | 93 | ! 1320 2014-03-20 08:40:49Z raasch |
---|
[1320] | 94 | ! ONLY-attribute added to USE-statements, |
---|
| 95 | ! kind-parameters added to all INTEGER and REAL declaration statements, |
---|
| 96 | ! kinds are defined in new module kinds, |
---|
| 97 | ! old module precision_kind is removed, |
---|
| 98 | ! revision history before 2012 removed, |
---|
| 99 | ! comment fields (!:) to be used for variable explanations added to |
---|
| 100 | ! all variable declaration statements |
---|
[392] | 101 | ! |
---|
[1037] | 102 | ! 1036 2012-10-22 13:43:42Z raasch |
---|
| 103 | ! code put under GPL (PALM 3.9) |
---|
| 104 | ! |
---|
[829] | 105 | ! 828 2012-02-21 12:00:36Z raasch |
---|
| 106 | ! +dissipation_classes, radius_classes in parpar |
---|
| 107 | ! |
---|
[826] | 108 | ! 825 2012-02-19 03:03:44Z raasch |
---|
| 109 | ! wang_collision_kernel and turbulence_effects_on_collision in particles_par |
---|
| 110 | ! replaced by collision_kernel |
---|
| 111 | ! |
---|
[1] | 112 | ! Revision 1.1 2000/12/28 13:21:57 raasch |
---|
| 113 | ! Initial revision |
---|
| 114 | ! |
---|
| 115 | ! |
---|
| 116 | ! Description: |
---|
| 117 | ! ------------ |
---|
[1682] | 118 | !> This subroutine reads from the NAMELIST file variables controling model |
---|
| 119 | !> software packages which are used optionally in the run. |
---|
[1691] | 120 | !> |
---|
| 121 | !> @todo Perform all actions in the respective submodules and remove |
---|
| 122 | !> package_parin |
---|
[1] | 123 | !------------------------------------------------------------------------------! |
---|
[1682] | 124 | SUBROUTINE package_parin |
---|
| 125 | |
---|
[1] | 126 | |
---|
[1320] | 127 | USE control_parameters, & |
---|
[1324] | 128 | ONLY: averaging_interval_sp, dt_data_output, dt_dopts, dt_dosp, & |
---|
[1496] | 129 | dt_dvrp, particle_maximum_age, skip_time_dosp, & |
---|
| 130 | threshold |
---|
[1] | 131 | |
---|
[1320] | 132 | USE dvrp_variables, & |
---|
| 133 | ONLY: clip_dvrp_l, clip_dvrp_n, clip_dvrp_r, clip_dvrp_s, & |
---|
| 134 | cluster_size, color_interval, dvrpsize_interval, & |
---|
| 135 | dvrp_directory, dvrp_file, dvrp_host, dvrp_output, & |
---|
| 136 | dvrp_password, dvrp_username, groundplate_color, & |
---|
| 137 | isosurface_color, mode_dvrp, particle_color, & |
---|
| 138 | particle_dvrpsize, pathlines_fadeintime, & |
---|
| 139 | pathlines_fadeouttime, pathlines_linecount, & |
---|
| 140 | pathlines_maxhistory, pathlines_wavecount, & |
---|
| 141 | pathlines_wavetime, slicer_range_limits_dvrp, superelevation, & |
---|
| 142 | superelevation_x, superelevation_y, topography_color, & |
---|
| 143 | vc_alpha, vc_gradient_normals, vc_mode, vc_size_x, vc_size_y, & |
---|
| 144 | vc_size_z |
---|
| 145 | |
---|
[1367] | 146 | USE kinds |
---|
| 147 | |
---|
[1320] | 148 | USE particle_attributes, & |
---|
[1359] | 149 | ONLY: alloc_factor, bc_par_b, bc_par_lr, bc_par_ns, bc_par_t, & |
---|
[1831] | 150 | collision_algorithm, collision_kernel, & |
---|
| 151 | curvature_solution_effects, density_ratio, & |
---|
[1822] | 152 | dissipation_classes, dt_min_part, dt_prel, & |
---|
| 153 | dt_write_particle_data, & |
---|
[1320] | 154 | end_time_prel, initial_weighting_factor, & |
---|
[1359] | 155 | min_nr_particle, number_of_particle_groups, particles_per_point,& |
---|
[1320] | 156 | particle_advection, particle_advection_start, pdx, pdy, pdz, & |
---|
| 157 | psb, psl, psn, psr, pss, pst, radius, radius_classes, & |
---|
| 158 | random_start_position, read_particles_from_restartfile, & |
---|
[1822] | 159 | seed_follows_topography, use_sgs_for_particles, & |
---|
[1575] | 160 | vertical_particle_advection, write_particle_statistics |
---|
[1320] | 161 | |
---|
| 162 | USE spectrum, & |
---|
| 163 | ONLY: comp_spectra_level, data_output_sp, plot_spectra_level, & |
---|
| 164 | spectra_direction |
---|
| 165 | |
---|
[1] | 166 | IMPLICIT NONE |
---|
| 167 | |
---|
[1682] | 168 | CHARACTER (LEN=80) :: line !< |
---|
[1] | 169 | |
---|
[1484] | 170 | |
---|
[1826] | 171 | |
---|
[242] | 172 | NAMELIST /dvrp_graphics_par/ clip_dvrp_l, clip_dvrp_n, clip_dvrp_r, & |
---|
[264] | 173 | clip_dvrp_s, cluster_size, color_interval, & |
---|
| 174 | dt_dvrp, dvrpsize_interval, dvrp_directory, & |
---|
| 175 | dvrp_file, dvrp_host, dvrp_output, & |
---|
[1822] | 176 | dvrp_password, dvrp_username, & |
---|
[284] | 177 | groundplate_color, isosurface_color, & |
---|
| 178 | mode_dvrp, particle_color, particle_dvrpsize,& |
---|
[264] | 179 | pathlines_fadeintime, pathlines_fadeouttime, & |
---|
| 180 | pathlines_linecount, pathlines_maxhistory, & |
---|
| 181 | pathlines_wavecount, pathlines_wavetime, & |
---|
| 182 | slicer_range_limits_dvrp, superelevation, & |
---|
| 183 | superelevation_x, superelevation_y, & |
---|
[284] | 184 | threshold, topography_color, vc_alpha, & |
---|
| 185 | vc_gradient_normals, vc_mode, vc_size_x, & |
---|
| 186 | vc_size_y, vc_size_z |
---|
[264] | 187 | |
---|
[1359] | 188 | NAMELIST /particles_par/ alloc_factor, bc_par_b, bc_par_lr, & |
---|
[1822] | 189 | bc_par_ns, bc_par_t, collision_algorithm, & |
---|
[1831] | 190 | collision_kernel, curvature_solution_effects,& |
---|
[1359] | 191 | density_ratio, dissipation_classes, dt_dopts,& |
---|
| 192 | dt_min_part, dt_prel, & |
---|
[336] | 193 | dt_write_particle_data, & |
---|
[1] | 194 | end_time_prel, initial_weighting_factor, & |
---|
[1359] | 195 | min_nr_particle, & |
---|
[1] | 196 | number_of_particle_groups, & |
---|
| 197 | particles_per_point, & |
---|
| 198 | particle_advection_start, & |
---|
| 199 | particle_maximum_age, pdx, pdy, pdz, psb, & |
---|
[828] | 200 | psl, psn, psr, pss, pst, radius, & |
---|
| 201 | radius_classes, random_start_position, & |
---|
[1] | 202 | read_particles_from_restartfile, & |
---|
[1575] | 203 | seed_follows_topography, & |
---|
[1822] | 204 | use_sgs_for_particles, & |
---|
[1] | 205 | vertical_particle_advection, & |
---|
| 206 | write_particle_statistics |
---|
[1320] | 207 | |
---|
[1] | 208 | NAMELIST /spectra_par/ averaging_interval_sp, comp_spectra_level, & |
---|
| 209 | data_output_sp, dt_dosp, plot_spectra_level, & |
---|
| 210 | skip_time_dosp, spectra_direction |
---|
| 211 | |
---|
| 212 | ! |
---|
| 213 | !-- Position the namelist-file at the beginning (it was already opened in |
---|
| 214 | !-- parin), search for the namelist-group of the package and position the |
---|
| 215 | !-- file at this line. Do the same for each optionally used package. |
---|
[1320] | 216 | line = ' ' |
---|
[1] | 217 | |
---|
[1484] | 218 | |
---|
[1] | 219 | #if defined( __dvrp_graphics ) |
---|
| 220 | REWIND ( 11 ) |
---|
[1320] | 221 | line = ' ' |
---|
| 222 | DO WHILE ( INDEX( line, '&dvrp_graphics_par' ) == 0 ) |
---|
[1484] | 223 | READ ( 11, '(A)', END=20 ) line |
---|
[1] | 224 | ENDDO |
---|
| 225 | BACKSPACE ( 11 ) |
---|
| 226 | |
---|
| 227 | ! |
---|
| 228 | !-- Read user-defined namelist |
---|
| 229 | READ ( 11, dvrp_graphics_par ) |
---|
| 230 | |
---|
[1484] | 231 | 20 CONTINUE |
---|
[1] | 232 | #endif |
---|
| 233 | |
---|
[60] | 234 | ! |
---|
| 235 | !-- Try to find particles package |
---|
[1] | 236 | REWIND ( 11 ) |
---|
[1320] | 237 | line = ' ' |
---|
| 238 | DO WHILE ( INDEX( line, '&particles_par' ) == 0 ) |
---|
[1484] | 239 | READ ( 11, '(A)', END=30 ) line |
---|
[1] | 240 | ENDDO |
---|
| 241 | BACKSPACE ( 11 ) |
---|
| 242 | |
---|
| 243 | ! |
---|
| 244 | !-- Read user-defined namelist |
---|
| 245 | READ ( 11, particles_par ) |
---|
| 246 | |
---|
| 247 | ! |
---|
| 248 | !-- Set flag that indicates that particles are switched on |
---|
| 249 | particle_advection = .TRUE. |
---|
| 250 | |
---|
[1484] | 251 | 30 CONTINUE |
---|
[1] | 252 | |
---|
| 253 | REWIND ( 11 ) |
---|
[1320] | 254 | line = ' ' |
---|
| 255 | DO WHILE ( INDEX( line, '&spectra_par' ) == 0 ) |
---|
[1484] | 256 | READ ( 11, '(A)', END=40 ) line |
---|
[1] | 257 | ENDDO |
---|
| 258 | BACKSPACE ( 11 ) |
---|
| 259 | |
---|
| 260 | ! |
---|
| 261 | !-- Read user-defined namelist |
---|
| 262 | READ ( 11, spectra_par ) |
---|
| 263 | |
---|
| 264 | ! |
---|
| 265 | !-- Default setting of dt_dosp here (instead of check_parameters), because its |
---|
| 266 | !-- current value is needed in init_pegrid |
---|
[1340] | 267 | IF ( dt_dosp == 9999999.9_wp ) dt_dosp = dt_data_output |
---|
[1] | 268 | |
---|
[1484] | 269 | 40 CONTINUE |
---|
[1] | 270 | |
---|
[1496] | 271 | |
---|
| 272 | |
---|
| 273 | |
---|
[1] | 274 | END SUBROUTINE package_parin |
---|