source: LMDZ6/branches/Ocean_skin/libf/dyn3dmem/caladvtrac_mod.F90 @ 5454

Last change on this file since 5454 was 4368, checked in by lguez, 2 years ago

Sync latest trunk changes to Ocean_skin

  • Property copyright set to
    Name of program: LMDZ
    Creation date: 1984
    Version: LMDZ5
    License: CeCILL version 2
    Holder: Laboratoire de m\'et\'eorologie dynamique, CNRS, UMR 8539
    See the license file in the root directory
File size: 3.2 KB
Line 
1MODULE caladvtrac_mod
2
3  REAL,POINTER,SAVE :: q_adv(:,:,:)
4  REAL,POINTER,SAVE :: massem_adv(:,:)
5  REAL,POINTER,SAVE :: wg_adv(:,:)
6  REAL,POINTER,SAVE :: teta_adv(:,:)
7  REAL,POINTER,SAVE :: p_adv(:,:)
8  REAL,POINTER,SAVE :: pk_adv(:,:)
9  REAL,POINTER,SAVE :: pbarug_adv(:,:)
10  REAL,POINTER,SAVE :: pbarvg_adv(:,:)
11  REAL,POINTER,SAVE :: pbaruc(:,:)
12  REAL,POINTER,SAVE :: pbarvc(:,:)
13  REAL,POINTER,SAVE :: pbarug(:,:)
14  REAL,POINTER,SAVE :: pbarvg(:,:)
15  REAL,POINTER,SAVE :: wg(:,:)
16
17  REAL,POINTER,SAVE :: massem(:,:)
18  !Offline
19  REAL,POINTER,SAVE :: tetac(:,:)
20  REAL,POINTER,SAVE :: massec(:,:)
21  REAL,POINTER,SAVE :: phic(:,:)
22  REAL,POINTER,SAVE :: pbarucc(:,:)
23  REAL,POINTER,SAVE :: pbarvcc(:,:)
24  REAL,POINTER,SAVE :: pbarugg(:,:)
25  REAL,POINTER,SAVE :: pbarvgg(:,:)
26  REAL,POINTER,SAVE :: wgg(:,:)
27CONTAINS
28
29  SUBROUTINE caladvtrac_allocate
30  USE bands
31  USE allocate_field_mod
32  USE parallel_lmdz
33  USE infotrac, ONLY: nqtot
34  USE advtrac_mod, ONLY : advtrac_allocate
35  USE groupe_mod
36  IMPLICIT NONE
37  INCLUDE "dimensions.h"
38  INCLUDE "paramet.h"
39  TYPE(distrib),POINTER :: d
40
41    d=>distrib_vanleer
42    CALL allocate_u(q_adv,llm,nqtot,d)
43    CALL allocate_u(massem_adv,llm,d)
44    CALL allocate_u(wg_adv,llm,d)
45    CALL allocate_u(teta_adv,llm,d)
46    CALL allocate_u(p_adv,llmp1,d)
47    CALL allocate_u(pk_adv,llm,d)
48    CALL allocate_u(pbarug_adv,llm,d)
49    CALL allocate_v(pbarvg_adv,llm,d)
50
51    d=>distrib_caldyn
52    CALL allocate_u(massem,llm,d)
53    CALL allocate_u(pbaruc,llm,d)
54    pbaruc(:,:)=0
55    CALL allocate_v(pbarvc,llm,d)
56    pbarvc(:,:)=0
57    CALL allocate_u(pbarug,llm,d)
58    CALL allocate_v(pbarvg,llm,d)
59    CALL allocate_u(wg,llm,d)
60    ! Offline
61    CALL allocate_u(tetac,llm,d)
62    CALL allocate_u(phic,llm,d)
63    CALL allocate_u(pbarucc,llm,d)
64    CALL allocate_v(pbarvcc,llm,d)
65    CALL allocate_u(massec,llm,d)
66    CALL allocate_u(pbarugg,llm,d)
67    CALL allocate_v(pbarvgg,llm,d)
68    CALL allocate_u(wgg,llm,d)
69
70    CALL groupe_allocate
71    CALL advtrac_allocate
72   
73  END SUBROUTINE caladvtrac_allocate
74 
75  SUBROUTINE caladvtrac_switch_caldyn(dist)
76  USE allocate_field_mod
77  USE bands
78  USE parallel_lmdz
79  USE groupe_mod
80  IMPLICIT NONE
81    TYPE(distrib),INTENT(IN) :: dist
82
83    CALL switch_u(massem,distrib_caldyn,dist)
84    CALL switch_u(pbaruc,distrib_caldyn,dist)
85    CALL switch_v(pbarvc,distrib_caldyn,dist,up=1)
86    CALL switch_u(pbarug,distrib_caldyn,dist)
87    CALL switch_v(pbarvg,distrib_caldyn,dist)
88    CALL switch_u(wg,distrib_caldyn,dist)
89   
90    CALL groupe_switch_caldyn(dist)
91
92  END SUBROUTINE caladvtrac_switch_caldyn
93 
94  SUBROUTINE caladvtrac_switch_vanleer(dist)
95  USE allocate_field_mod
96  USE bands
97  USE parallel_lmdz
98  USE advtrac_mod, ONLY : advtrac_switch_vanleer
99  IMPLICIT NONE
100    TYPE(distrib),INTENT(IN) :: dist
101 
102    CALL switch_u(q_adv,distrib_vanleer,dist)
103    CALL switch_u(massem_adv,distrib_vanleer,dist)
104    CALL switch_u(wg_adv,distrib_vanleer,dist)
105    CALL switch_u(teta_adv,distrib_vanleer,dist)
106    CALL switch_u(p_adv,distrib_vanleer,dist)
107    CALL switch_u(pk_adv,distrib_vanleer,dist)
108    CALL switch_u(pbarug_adv,distrib_vanleer,dist)
109    CALL switch_v(pbarvg_adv,distrib_vanleer,dist)
110
111    CALL advtrac_switch_vanleer(dist)
112   
113  END SUBROUTINE caladvtrac_switch_vanleer 
114 
115END MODULE caladvtrac_mod 
Note: See TracBrowser for help on using the repository browser.