source: palm/trunk/SOURCE/compute_vpt.f90 @ 819

Last change on this file since 819 was 804, checked in by franke, 13 years ago

last commit documented / Bugfix for calculation of vpt

  • Property svn:keywords set to Id
File size: 1.4 KB
Line 
1 SUBROUTINE compute_vpt
2
3!-------------------------------------------------------------------------------!
4! Current revisions:
5! -----------------
6!
7!
8! Former revisions:
9! -----------------
10! $Id: compute_vpt.f90 804 2012-01-16 16:12:22Z maronga $
11!
12! 803 2012-01-16 15:48:46Z franke
13! Bugfix: wrong factor in calculation of vpt in case of cloud droplets
14!
15! 799 2011-12-21 17:48:03Z franke
16! Bugfix: ql is now included in calculation of vpt in case of
17!         cloud droplets
18!
19! RCS Log replace by Id keyword, revision history cleaned up
20!
21! Revision 1.5  2001/03/30 06:58:52  raasch
22! Translation of remaining German identifiers (variables, subroutines, etc.)
23!
24! Revision 1.1  2000/04/13 14:40:53  schroeter
25! Initial revision
26!
27!
28! Description:
29! -------------
30! Computation of the virtual potential temperature
31!-------------------------------------------------------------------------------!
32
33    USE arrays_3d
34    USE indices
35    USE cloud_parameters
36    USE control_parameters
37
38    IMPLICIT NONE
39
40    INTEGER :: k
41
42    IF ( .NOT. cloud_physics .AND. .NOT. cloud_droplets ) THEN
43       vpt = pt * ( 1.0 + 0.61 * q )
44    ELSE IF (cloud_physics) THEN
45       DO  k = nzb, nzt+1
46          vpt(k,:,:) = ( pt(k,:,:) + pt_d_t(k) * l_d_cp * ql(k,:,:) ) * &
47                       ( 1.0 + 0.61 * q(k,:,:) - 1.61 * ql(k,:,:) ) 
48       ENDDO
49    ELSE
50       vpt = pt * ( 1.0 + 0.61 * q - ql ) 
51    ENDIF
52
53 END SUBROUTINE compute_vpt
Note: See TracBrowser for help on using the repository browser.