/[lmdze]/trunk/dyn3d/groupe.f
ViewVC logotype

Contents of /trunk/dyn3d/groupe.f

Parent Directory Parent Directory | Revision Log Revision Log


Revision 91 - (show annotations)
Wed Mar 26 17:18:58 2014 UTC (10 years, 1 month ago) by guez
File size: 2376 byte(s)
Removed unused variables lock_startdate and time_stamp of module
calendar.

Noticed that physiq does not change the surface pressure. So removed
arguments ps and dpfi of subroutine addfi. dpfi was always 0. The
computation of ps in addfi included some averaging at the poles. In
principle, this does not change ps but in practice it does because of
finite numerical precision. So the results of the simulation are
changed. Removed arguments ps and dpfi of calfis. Removed argument
d_ps of physiq.

du at the poles is not computed by dudv1, so declare only the
corresponding latitudes in dudv1. caldyn passes only a section of the
array dudyn as argument.

Removed variable niadv of module iniadvtrac_m.

Declared arguments of exner_hyb as assumed-shape arrays and made all
other horizontal sizes in exner_hyb dynamic. This allows the external
program test_disvert to use exner_hyb at a single horizontal position.

1 SUBROUTINE groupe(pext, pbaru, pbarv, pbarum, pbarvm, wm)
2
3 ! From dyn3d/groupe.F, v 1.1.1.1 2004/05/19 12:53:06
4
5 ! sous-programme servant a fitlrer les champs de flux de masse aux
6 ! poles en "regroupant" les mailles 2 par 2 puis 4 par 4 etc. au fur
7 ! et a mesure qu'on se rapproche du pole.
8
9 ! en entree: pext, pbaru et pbarv
10 ! en sortie: pbarum, pbarvm et wm.
11
12 ! remarque, le wm est recalcule a partir des pbaru pbarv et on n'a
13 ! donc pas besoin de w en entree.
14
15 USE dimens_m
16 USE paramet_m
17 USE comconst
18 USE disvert_m
19 USE comgeom
20 use vitvert_m, only: vitvert
21
22 IMPLICIT NONE
23
24 INTEGER, PARAMETER:: ngroup = 3
25
26 REAL pbaru(iip1, jjp1, llm), pbarv(iip1, jjm, llm)
27 REAL pext(iip1, jjp1, llm)
28
29 REAL, intent(out):: pbarum(iip1, jjp1, llm)
30 real pbarvm(iip1, jjm, llm)
31 REAL wm(iip1, jjp1, llm)
32
33 REAL zconvm(iip1, jjp1, llm), zconvmm(iip1, jjp1, llm)
34 REAL uu
35 INTEGER i, j, l
36 LOGICAL:: firstcall = .TRUE.
37
38 !------------------------------------------------------
39
40 IF (firstcall) THEN
41 IF (mod(iim, 2**ngroup) /= 0) then
42 print *, 'groupe: bad iim'
43 STOP 1
44 end IF
45 firstcall = .FALSE.
46 END IF
47
48 ! Champs 1D
49
50 CALL convflu(pbaru, pbarv, llm, zconvm)
51
52 CALL scopy(ijp1llm, zconvm, 1, zconvmm, 1)
53 CALL scopy(ijmllm, pbarv, 1, pbarvm, 1)
54
55 CALL groupeun(jjp1, llm, zconvmm)
56 CALL groupeun(jjm, llm, pbarvm)
57
58 ! Champs 3D
59
60 DO l = 1, llm
61 DO j = 2, jjm
62 uu = pbaru(iim, j, l)
63 DO i = 1, iim
64 uu = uu + pbarvm(i, j, l) - pbarvm(i, j-1, l) - zconvmm(i, j, l)
65 pbarum(i, j, l) = uu
66 END DO
67 pbarum(iip1, j, l) = pbarum(1, j, l)
68 END DO
69 END DO
70 pbarum(:, 1, :) = 0
71 pbarum(:, jjm + 1, :) = 0
72
73 ! integration de la convergence de masse de haut en bas
74 DO l = 1, llm
75 DO j = 1, jjp1
76 DO i = 1, iip1
77 zconvmm(i, j, l) = zconvmm(i, j, l)
78 END DO
79 END DO
80 END DO
81 DO l = llm - 1, 1, -1
82 DO j = 1, jjp1
83 DO i = 1, iip1
84 zconvmm(i, j, l) = zconvmm(i, j, l) + zconvmm(i, j, l+1)
85 END DO
86 END DO
87 END DO
88
89 CALL vitvert(zconvmm, wm)
90
91 END SUBROUTINE groupe

  ViewVC Help
Powered by ViewVC 1.1.21