source: trunk/LMDZ.VENUS/libf/phyvenus/infotrac_phy.F90 @ 3094

Last change on this file since 3094 was 1981, checked in by emillour, 6 years ago

Venus physics:
Follow-up of longer tracer names in the dynamics and addition of
init_print_control module variables in conf_phys.
EM

File size: 1.4 KB
Line 
1
2! $Id: $
3
4MODULE infotrac_phy
5
6! Infotrac for physics; contains the same information as infotrac for
7! the dynamics
8  IMPLICIT NONE
9
10! iflag_trac: ==1 if running with tracers
11  INTEGER,SAVE :: iflag_trac
12!$OMP THREADPRIVATE(iflag_trac)
13
14! nqtot : total number of tracers
15  INTEGER,SAVE :: nqtot
16!$OMP THREADPRIVATE(nqtot)
17
18! tracer names
19  CHARACTER(len=30),ALLOCATABLE,DIMENSION(:),SAVE :: tname
20  CHARACTER(len=33),ALLOCATABLE,DIMENSION(:),SAVE :: ttext ! tracer long name for diagnostics
21!$OMP THREADPRIVATE(tname,ttext)
22
23CONTAINS
24
25  SUBROUTINE init_infotrac_phy(iflag_trac_,nqtot_,tname_,ttext_)
26  ! Initialize module variables
27 
28  USE print_control_mod, ONLY: lunout
29  IMPLICIT NONE
30 
31  INTEGER,INTENT(IN) :: iflag_trac_ ! ==1 if running with tracers
32  INTEGER,INTENT(IN) :: nqtot_ ! total number of tracers
33  CHARACTER(LEN=*),INTENT(IN) :: tname_(nqtot_)
34  CHARACTER(LEN=*),INTENT(IN) :: ttext_(nqtot_)
35 
36  INTEGER :: iq
37  CHARACTER(LEN=30) :: modname="init_infotrac_phy"
38  CHARACTER(LEN=50) :: abort_message
39 
40  iflag_trac=iflag_trac_
41  nqtot=nqtot_
42 
43  ALLOCATE(tname(nqtot))
44  ALLOCATE(ttext(nqtot))
45  DO iq=1,nqtot
46    if (len_trim(tname_(iq)).gt.len(tname(iq))) then
47      abort_message="init_infotrac_phy error; tname_() too long!"
48      call abort_physic(modname,abort_message,1)
49    endif
50    tname(iq)=tname_(iq)
51    ttext(iq)=ttext_(iq)
52  ENDDO
53 
54  END SUBROUTINE init_infotrac_phy
55
56END MODULE infotrac_phy
Note: See TracBrowser for help on using the repository browser.