source: LMDZ5/branches/LMDZ5-DOFOCO/libf/dyn3dmem/caladvtrac_mod.F90 @ 5452

Last change on this file since 5452 was 1632, checked in by Laurent Fairhead, 13 years ago

Import initial du répertoire dyn3dmem

Attention! ceci n'est qu'une version préliminaire du code "basse mémoire":
le code contenu dans ce répertoire est basé sur la r1320 et a donc besoin
d'être mis à jour par rapport à la dynamique parallèle d'aujourd'hui.
Ce code est toutefois mis à disposition pour circonvenir à des problèmes
de mémoire que certaines configurations du modèle pourraient rencontrer.
Dans l'état, il compile et tourne sur vargas et au CCRT


Initial import of dyn3dmem

Warning! this is just a preliminary version of the memory light code:
it is based on r1320 of the code and thus needs to be updated before
it can replace the present dyn3dpar code. It is nevertheless put at your
disposal to circumvent some memory problems some LMDZ configurations may
encounter. In its present state, it will compile and run on vargas and CCRT

File size: 2.6 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 
19CONTAINS
20
21  SUBROUTINE caladvtrac_allocate
22  USE bands
23  USE allocate_field
24  USE parallel
25  USE infotrac
26  USE advtrac_mod, ONLY : advtrac_allocate
27  USE groupe_mod
28  IMPLICIT NONE
29  INCLUDE "dimensions.h"
30  INCLUDE "paramet.h"
31  TYPE(distrib),POINTER :: d
32
33    d=>distrib_vanleer
34    CALL allocate_u(q_adv,llm,nqtot,d)
35    CALL allocate_u(massem_adv,llm,d)
36    CALL allocate_u(wg_adv,llm,d)
37    CALL allocate_u(teta_adv,llm,d)
38    CALL allocate_u(p_adv,llmp1,d)
39    CALL allocate_u(pk_adv,llm,d)
40    CALL allocate_u(pbarug_adv,llm,d)
41    CALL allocate_v(pbarvg_adv,llm,d)
42
43    d=>distrib_caldyn
44    CALL allocate_u(massem,llm,d)
45    CALL allocate_u(pbaruc,llm,d)
46    CALL allocate_v(pbarvc,llm,d)
47    CALL allocate_u(pbarug,llm,d)
48    CALL allocate_v(pbarvg,llm,d)
49    CALL allocate_u(wg,llm,d)
50
51    CALL groupe_allocate
52    CALL advtrac_allocate
53   
54  END SUBROUTINE caladvtrac_allocate
55 
56  SUBROUTINE caladvtrac_switch_caldyn(dist)
57  USE allocate_field
58  USE bands
59  USE parallel
60  USE groupe_mod
61  IMPLICIT NONE
62    TYPE(distrib),INTENT(IN) :: dist
63
64    CALL switch_u(massem,distrib_caldyn,dist)
65    CALL switch_u(pbaruc,distrib_caldyn,dist)
66    CALL switch_v(pbarvc,distrib_caldyn,dist,up=1)
67    CALL switch_u(pbarug,distrib_caldyn,dist)
68    CALL switch_v(pbarvg,distrib_caldyn,dist)
69    CALL switch_u(wg,distrib_caldyn,dist)
70   
71    CALL groupe_switch_caldyn(dist)
72
73  END SUBROUTINE caladvtrac_switch_caldyn
74 
75  SUBROUTINE caladvtrac_switch_vanleer(dist)
76  USE allocate_field
77  USE bands
78  USE parallel
79  USE advtrac_mod, ONLY : advtrac_switch_vanleer
80  IMPLICIT NONE
81    TYPE(distrib),INTENT(IN) :: dist
82 
83    CALL switch_u(q_adv,distrib_vanleer,dist)
84    CALL switch_u(massem_adv,distrib_vanleer,dist)
85    CALL switch_u(wg_adv,distrib_vanleer,dist)
86    CALL switch_u(teta_adv,distrib_vanleer,dist)
87    CALL switch_u(p_adv,distrib_vanleer,dist)
88    CALL switch_u(pk_adv,distrib_vanleer,dist)
89    CALL switch_u(pbarug_adv,distrib_vanleer,dist)
90    CALL switch_v(pbarvg_adv,distrib_vanleer,dist)
91
92    CALL advtrac_switch_vanleer(dist)
93   
94  END SUBROUTINE caladvtrac_switch_vanleer 
95 
96END MODULE caladvtrac_mod 
Note: See TracBrowser for help on using the repository browser.