source: LMDZ6/branches/LMDZ-tracers/libf/dyn3dmem/vlz_mod.F90 @ 3852

Last change on this file since 3852 was 3852, checked in by dcugnet, 3 years ago

Extension of the tracers management.

The tracers files can be:

1) "traceur.def": old format, with:

  • the number of tracers on the first line
  • one line for each tracer: <tracer name> <hadv> <vadv> [<parent name>]

2) "tracer.def": new format with one section each model component.
3) "tracer_<name>.def": new format with a single section.

The formats 2 and 3 reading is driven by the "type_trac" key, which can be a

coma-separated list of components.

  • Format 2: read the sections from the "tracer.def" file.
  • format 3: read one section each "tracer_<section name>.def" file.
  • the first line of a section is "&<section name>
  • the other lines start with a tracer name followed by <key>=<val> pairs.
  • the "default" tracer name is reserved ; the other tracers of the section inherit its <key>=<val>, except for the keys that are redefined locally.

This format helps keeping the tracers files compact, thanks to the "default"
special tracer and the three levels of factorization:

  • on the tracers names: a tracer name can be a coma-separated list of tracers => all the tracers of the list have the same <key>=<val> properties
  • on the parents names: the value of the "parent" property can be a coma-separated list of tracers => only possible for geographic tagging tracers
  • on the phases: the property "phases" is [g](l][s] (gas/liquid/solid)

Read information is stored in the vector "tracers(:)", of derived type "tra".

"isotopes_params.def" is a similar file, with one section each isotopes family.
It contains a database of isotopes properties ; if there are second generation
tracers (isotopes), the corresponding sections are read.

Read information is stored in the vector "isotopes(:)", of derived type "iso".

The "getKey" function helps to get the values of the parameters stored in
"tracers" or "isotopes".

  • 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: 1.3 KB
Line 
1MODULE vlz_mod
2
3  REAL,POINTER,SAVE :: wq(:,:,:)
4  REAL,POINTER,SAVE :: dzq(:,:)
5  REAL,POINTER,SAVE :: dzqw(:,:)
6  REAL,POINTER,SAVE :: adzqw(:,:)
7  ! CRisi: pour les traceurs: 
8  !REAL,POINTER,SAVE :: masseq(:,:,:)
9  REAL,POINTER,SAVE :: Ratio(:,:,:)
10 
11CONTAINS
12
13  SUBROUTINE vlz_allocate
14  USE bands
15  USE allocate_field_mod
16  USE parallel_lmdz
17  USE infotrac, ONLY: nqtot, tracers
18  USE dimensions_mod
19  IMPLICIT NONE
20  TYPE(distrib),POINTER :: d
21   
22    d=>distrib_vanleer
23    CALL allocate_u(wq,llm+1,nqtot,d)
24    CALL allocate_u(dzq,llm,d)
25    CALL allocate_u(dzqw,llm,d)
26    CALL allocate_u(adzqw,llm,d)
27    IF(ANY(tracers(:)%ndesc > 0) THEN
28      !CALL allocate_u(masseq,llm,nqtot,d)
29      CALL allocate_u(Ratio,llm,nqtot,d)
30    END IF
31
32  END SUBROUTINE vlz_allocate
33 
34  SUBROUTINE vlz_switch_vanleer(dist)
35  USE allocate_field_mod
36  USE bands
37  USE parallel_lmdz
38  USE infotrac
39  IMPLICIT NONE
40    TYPE(distrib),INTENT(IN) :: dist
41 
42    CALL switch_u(wq,distrib_vanleer,dist)
43    CALL switch_u(dzq,distrib_vanleer,dist)
44    CALL switch_u(dzqw,distrib_vanleer,dist)
45    CALL switch_u(adzqw,distrib_vanleer,dist)
46    ! CRisi:
47    if (nqdesc_tot.gt.0) then   
48    !CALL switch_u(masseq,distrib_vanleer,dist)
49    CALL switch_u(Ratio,distrib_vanleer,dist)
50    endif !if (nqdesc_tot.gt.0) then     
51
52  END SUBROUTINE vlz_switch_vanleer 
53 
54END MODULE vlz_mod 
Note: See TracBrowser for help on using the repository browser.