/[lmdze]/trunk/Sources/phylmd/qcheck.f
ViewVC logotype

Annotation of /trunk/Sources/phylmd/qcheck.f

Parent Directory Parent Directory | Revision Log Revision Log


Revision 134 - (hide annotations)
Wed Apr 29 15:47:56 2015 UTC (9 years, 1 month ago) by guez
File size: 897 byte(s)
Sources inside, compilation outside.
1 guez 17 module qcheck_m
2    
3     IMPLICIT none
4    
5     contains
6    
7 guez 98 pure FUNCTION qcheck(paprs, q, ql)
8 guez 17
9     ! From phylmd/physiq.F, v 1.22 2006/02/20 09:38:28
10    
11 guez 98 ! Calculer et imprimer l'eau totale. A utiliser pour vérifier
12     ! la conservation de l'eau.
13 guez 17
14 guez 98 use comgeomphy, only: airephy
15     use dimphy, only: klon, klev
16     use SUPHEC_M, ONLY: rg
17 guez 17
18 guez 98 REAL, intent(in):: paprs(:, :) ! (klon, klev + 1)
19     real, intent(in):: q(:, :), ql(:, :) ! (klon, klev)
20    
21     ! Local:
22 guez 17 REAL qtotal, zx, qcheck
23     INTEGER i, k
24    
25 guez 98 !---------------------------------------------------------
26    
27 guez 17 zx = 0.0
28     DO i = 1, klon
29 guez 98 zx = zx + airephy(i)
30 guez 17 ENDDO
31     qtotal = 0.0
32     DO k = 1, klev
33     DO i = 1, klon
34 guez 98 qtotal = qtotal + (q(i, k)+ql(i, k)) * airephy(i) &
35 guez 17 *(paprs(i, k)-paprs(i, k+1))/RG
36     ENDDO
37     ENDDO
38    
39 guez 98 qcheck = qtotal / zx
40 guez 17
41     END FUNCTION qcheck
42    
43     end module qcheck_m

  ViewVC Help
Powered by ViewVC 1.1.21