source: palm/trunk/SOURCE/lpm_release_set.f90 @ 1721

Last change on this file since 1721 was 1683, checked in by knoop, 9 years ago

last commit documented

  • Property svn:keywords set to Id
File size: 4.3 KB
Line 
1!> @file lpm_release_set.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-2014 Leibniz Universitaet Hannover
17!--------------------------------------------------------------------------------!
18!
19! Current revisions:
20! ------------------
21!
22!
23! Former revisions:
24! -----------------
25! $Id: lpm_release_set.f90 1683 2015-10-07 23:57:51Z raasch $
26!
27! 1682 2015-10-07 23:56:08Z knoop
28! Code annotations made doxygen readable
29!
30! 1359 2014-04-11 17:15:14Z hoffmann
31! New particle structure integrated.
32! Kind definition added to all floating point numbers.
33! lpm_init changed form a subroutine to a module.
34!
35! 1327 2014-03-21 11:00:16Z raasch
36! -netcdf output queries
37!
38! 1320 2014-03-20 08:40:49Z raasch
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! comment fields (!:) to be used for variable explanations added to
43! all variable declaration statements
44!
45! 1036 2012-10-22 13:43:42Z raasch
46! code put under GPL (PALM 3.9)
47!
48! 849 2012-03-15 10:35:09Z raasch
49! initial revision (former part of advec_particles)
50!
51!
52! Description:
53! ------------
54!> Release a new set of particles and, if required, particle tails. These
55!> particles/tails are added at the end of the existing arrays. Extend the
56!> respective particle and tail arrays, if neccessary.
57!------------------------------------------------------------------------------!
58 SUBROUTINE lpm_release_set
59 
60
61    USE control_parameters,                                                    &
62        ONLY:  iran, message_string, netcdf_data_format
63
64    USE lpm_init_mod,                                                          &
65        ONLY: lpm_create_particle, PHASE_RELEASE
66
67    USE grid_variables,                                                        &
68        ONLY:  dx, dy
69
70    USE indices,                                                               &
71        ONLY:  nxl, nxr, nyn, nys
72
73    USE kinds
74
75    USE particle_attributes,                                                   &
76        ONLY:  minimum_tailpoint_distance, number_of_tails, particles,         &
77               particle_tail_coordinates, use_particle_tails
78
79    IMPLICIT NONE
80
81    INTEGER(iwp) ::  ie     !<
82    INTEGER(iwp) ::  is     !<
83    INTEGER(iwp) ::  n      !<
84    INTEGER(iwp) ::  nn     !<
85
86
87    CALL lpm_create_particle(PHASE_RELEASE)
88!
89!-- particle tails currently not available
90! !
91! !-- Set the beginning of the new particle tails and their age
92!     IF ( use_particle_tails )  THEN
93!
94!        DO  n = is, ie
95! !
96! !--       New particles which should have a tail, already have got a
97! !--       provisional tail id unequal zero (see lpm_init)
98!           IF ( particles(n)%tail_id /= 0 )  THEN
99!
100!              number_of_tails = number_of_tails + 1
101!              nn = number_of_tails
102!              particles(n)%tail_id = nn   ! set the final tail id
103!              particle_tail_coordinates(1,1,nn) = particles(n)%x
104!              particle_tail_coordinates(1,2,nn) = particles(n)%y
105!              particle_tail_coordinates(1,3,nn) = particles(n)%z
106!              particle_tail_coordinates(1,4,nn) = particles(n)%class
107!              particles(n)%tailpoints = 1
108!
109!              IF ( minimum_tailpoint_distance /= 0.0 )  THEN
110!                 particle_tail_coordinates(2,1,nn) = particles(n)%x
111!                 particle_tail_coordinates(2,2,nn) = particles(n)%y
112!                 particle_tail_coordinates(2,3,nn) = particles(n)%z
113!                 particle_tail_coordinates(2,4,nn) = particles(n)%class
114!                 particle_tail_coordinates(1:2,5,nn) = 0.0_wp
115!                 particles(n)%tailpoints = 2
116!              ENDIF
117!
118!           ENDIF
119!
120!        ENDDO
121!
122!     ENDIF
123
124
125 END SUBROUTINE lpm_release_set
Note: See TracBrowser for help on using the repository browser.