source: palm/trunk/SOURCE/interaction_droplets_ptq.f90 @ 1834

Last change on this file since 1834 was 1823, checked in by hoffmann, 8 years ago

last commit documented

  • Property svn:keywords set to Id
File size: 4.6 KB
Line 
1!> @file interaction_droplets_ptq.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-2016 Leibniz Universitaet Hannover
17!--------------------------------------------------------------------------------!
18!
19! Current revisions:
20! -----------------
21!
22!
23! Former revisions:
24! -----------------
25! $Id: interaction_droplets_ptq.f90 1823 2016-04-07 08:57:52Z raasch $
26!
27! 1822 2016-04-07 07:49:42Z hoffmann
28! Unused variables removed.
29!
30! 1779 2016-03-03 08:01:28Z raasch
31! bugfix: module procedure names shortened to avoid Intel compiler warnings
32! about too long names
33!
34! 1682 2015-10-07 23:56:08Z knoop
35! Code annotations made doxygen readable
36!
37! 1320 2014-03-20 08:40:49Z raasch
38! ONLY-attribute added to USE-statements,
39! kind-parameters added to all INTEGER and REAL declaration statements,
40! kinds are defined in new module kinds,
41! revision history before 2012 removed,
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! 799 2011-12-21 17:48:03Z franke
49! Bugfix: pt_d_t(k) was missing in calculation of pt_p
50!
51! RCS Log replace by Id keyword, revision history cleaned up
52!
53! Revision 1.1  2005/06/26 19:57:47  raasch
54! Initial revision
55!
56!
57! Description:
58! ------------
59!> Release of latent heat and change of specific humidity due to condensation /
60!> evaporation of droplets.
61!------------------------------------------------------------------------------!
62 MODULE interaction_droplets_ptq_mod
63 
64
65    PRIVATE
66    PUBLIC interaction_droplets_ptq
67
68    INTERFACE interaction_droplets_ptq
69!
70!--    Internal names shortened in order ro avoid Intel compiler messages
71!--    about too long names
72       MODULE PROCEDURE i_droplets_ptq
73       MODULE PROCEDURE i_droplets_ptq_ij
74    END INTERFACE interaction_droplets_ptq
75 
76 CONTAINS
77
78
79!------------------------------------------------------------------------------!
80! Description:
81! ------------
82!> Call for all grid points
83!------------------------------------------------------------------------------!
84    SUBROUTINE i_droplets_ptq
85
86       USE arrays_3d,                                                          &
87           ONLY:  pt_p, ql_c, q_p
88           
89       USE cloud_parameters,                                                   &
90           ONLY:  l_d_cp, pt_d_t
91           
92       USE indices,                                                            &
93           ONLY:  nxl, nxr, nyn, nys, nzb_2d, nzt
94           
95       USE kinds
96
97       USE pegrid
98
99       IMPLICIT NONE
100
101       INTEGER(iwp) ::  i !<
102       INTEGER(iwp) ::  j !<
103       INTEGER(iwp) ::  k !<
104
105 
106       DO  i = nxl, nxr
107          DO  j = nys, nyn
108             DO  k = nzb_2d(j,i)+1, nzt
109                q_p(k,j,i)  = q_p(k,j,i)  - ql_c(k,j,i)
110                pt_p(k,j,i) = pt_p(k,j,i) + l_d_cp * ql_c(k,j,i) * pt_d_t(k)
111             ENDDO
112          ENDDO
113       ENDDO
114
115    END SUBROUTINE i_droplets_ptq
116
117
118!------------------------------------------------------------------------------!
119! Description:
120! ------------
121!> Call for grid point i,j
122!------------------------------------------------------------------------------!
123    SUBROUTINE i_droplets_ptq_ij( i, j )
124
125       USE arrays_3d,                                                          &
126           ONLY:  pt_p, ql_c, q_p
127
128       USE cloud_parameters,                                                   &
129           ONLY:  l_d_cp, pt_d_t
130
131       USE indices,                                                            &
132           ONLY:  nzb_2d, nzt
133
134       USE kinds,                                                              &
135           ONLY:  iwp, wp
136
137       USE pegrid
138
139       IMPLICIT NONE
140
141       INTEGER(iwp) ::  i !<
142       INTEGER(iwp) ::  j !<
143       INTEGER(iwp) ::  k !<
144
145
146       DO  k = nzb_2d(j,i)+1, nzt
147          q_p(k,j,i)  = q_p(k,j,i)  - ql_c(k,j,i)
148          pt_p(k,j,i) = pt_p(k,j,i) + l_d_cp * ql_c(k,j,i) * pt_d_t(k)
149       ENDDO
150
151    END SUBROUTINE i_droplets_ptq_ij
152
153 END MODULE interaction_droplets_ptq_mod
Note: See TracBrowser for help on using the repository browser.