Changeset 4046
- Timestamp:
- Dec 15, 2021, 11:18:49 PM (3 years ago)
- Location:
- LMDZ6/trunk/libf
- Files:
-
- 3 added
- 39 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/libf/dyn3d/dynetat0.f90
r2859 r4046 10 10 NF90_CLOSE, NF90_GET_VAR 11 11 USE control_mod, ONLY: planet_type 12 USE strings_mod, ONLY: maxlen 12 13 USE assert_eq_m, ONLY: assert_eq 13 14 USE comvert_mod, ONLY: pa,preff … … 36 37 !=============================================================================== 37 38 ! Local variables: 38 CHARACTER(LEN= 256) :: msg, var, modname39 CHARACTER(LEN=maxlen) :: msg, var, modname 39 40 INTEGER, PARAMETER :: length=100 40 41 INTEGER :: iq, fID, vID, idecal!, iml, jml, lml, nqt … … 126 127 !--- Tracers 127 128 DO iq=1,nqtot 128 var= tname(iq)129 var=TRIM(tracers(iq)%name) 129 130 IF(NF90_INQ_VARID(fID,var,vID)==NF90_NoErr) THEN 130 131 CALL err(NF90_GET_VAR(fID,vID,q(:,:,:,iq)),"get",var); CYCLE … … 153 154 INTEGER, INTENT(IN) :: n1, n2 154 155 CHARACTER(LEN=*), INTENT(IN) :: str1, str2 155 CHARACTER(LEN= 100) :: s1, s2156 CHARACTER(LEN=maxlen) :: s1, s2 156 157 IF(n1/=n2) THEN 157 158 s1='value of '//TRIM(str1)//' =' -
LMDZ6/trunk/libf/dyn3d/dynredem.F90
r3865 r4046 12 12 NF90_64BIT_OFFSET 13 13 USE dynredem_mod, ONLY: cre_var, put_var1, put_var2, err, modname, fil 14 USE strings_mod, ONLY: maxlen 14 15 USE comvert_mod, ONLY: ap,bp,aps,bps,presnivs,pseudoalt,pa,preff, & 15 16 nivsig,nivsigs … … 38 39 REAL :: tab_cntrl(length) !--- RUN PARAMETERS TABLE 39 40 ! For NetCDF: 40 CHARACTER(LEN= 30) :: unites41 CHARACTER(LEN=maxlen) :: unites 41 42 INTEGER :: indexID 42 43 INTEGER :: rlonuID, rlonvID, rlatuID, rlatvID … … 145 146 CALL cre_var(nid,"teta" ,"Temperature",[rlonvID,rlatuID,sID,timID]) 146 147 DO iq=1,nqtot 147 CALL cre_var(nid,t name(iq),ttext(iq),[rlonvID,rlatuID,sID,timID])148 CALL cre_var(nid,tracers(iq)%name,tracers(iq)%longName,[rlonvID,rlatuID,sID,timID]) 148 149 END DO 149 150 CALL cre_var(nid,"masse","Masse d air" ,[rlonvID,rlatuID,sID,timID]) … … 196 197 INTEGER, PARAMETER :: length=100 197 198 REAL :: tab_cntrl(length) ! tableau des parametres du run 198 CHARACTER(LEN= 256) :: var, dum199 CHARACTER(LEN=maxlen) :: var, dum 199 200 LOGICAL :: lread_inca 200 201 !=============================================================================== … … 231 232 232 233 !--- Save tracers 233 DO iq=1,nqtot; var= tname(iq); ierr=-1234 DO iq=1,nqtot; var=TRIM(tracers(iq)%name); ierr=-1 234 235 IF(lread_inca) THEN !--- Possibly read from "start_trac.nc" 235 236 fil="start_trac.nc" -
LMDZ6/trunk/libf/dyn3d_common/infotrac.F90
r4039 r4046 2 2 ! 3 3 MODULE infotrac 4 5 USE readTracFiles_mod, ONLY: trac_type, isot_type, maxlen, ancestor, delPhase 4 6 5 7 ! nqtot : total number of tracers and higher order of moment, water vapor and liquid included … … 26 28 INTEGER, SAVE :: nqCO2 27 29 28 ! Name variables 29 INTEGER,PARAMETER :: tname_lenmax=128 30 CHARACTER(len=tname_lenmax), ALLOCATABLE, DIMENSION(:), SAVE :: tname ! tracer short name for restart and diagnostics 31 CHARACTER(len=tname_lenmax+3), ALLOCATABLE, DIMENSION(:), SAVE :: ttext ! tracer long name for diagnostics 30 ! DC: derived types containing informations about tracers and isotopes 31 TYPE(trac_type), TARGET, SAVE, ALLOCATABLE :: tracers(:) !=== TRACERS DESCRIPTORS VECTOR 32 TYPE(isot_type), TARGET, SAVE, ALLOCATABLE :: isotopes(:) !=== ISOTOPES PARAMETERS VECTOR 32 33 33 34 ! iadv : index of trasport schema for each tracer … … 119 120 CHARACTER(len=8), ALLOCATABLE, DIMENSION(:) :: solsym_inca 120 121 121 CHARACTER(len= tname_lenmax), ALLOCATABLE, DIMENSION(:) :: tnom_0 ! tracer short name122 CHARACTER(len= tname_lenmax), ALLOCATABLE, DIMENSION(:) :: tnom_transp ! transporting fluid short name: CRisi122 CHARACTER(len=maxlen), ALLOCATABLE, DIMENSION(:) :: tnom_0 ! tracer short name 123 CHARACTER(len=maxlen), ALLOCATABLE, DIMENSION(:) :: tnom_transp ! transporting fluid short name: CRisi 123 124 CHARACTER(len=3), DIMENSION(30) :: descrq 124 125 CHARACTER(len=1), DIMENSION(3) :: txts 125 126 CHARACTER(len=2), DIMENSION(9) :: txtp 126 CHARACTER(len= tname_lenmax):: str1,str2127 CHARACTER(len=maxlen) :: str1,str2 127 128 128 129 INTEGER :: nqtrue ! number of tracers read from tracer.def, without higer order of moment … … 131 132 LOGICAL :: continu,nouveau_traceurdef 132 133 INTEGER :: IOstatus ! gestion de la retrocompatibilite de traceur.def 133 CHARACTER(len= 2*tname_lenmax+1) :: tchaine134 CHARACTER(len=maxlen) :: tchaine 134 135 135 136 character(len=*),parameter :: modname="infotrac_init" … … 349 350 if (nouveau_traceurdef) then 350 351 write(lunout,*) 'C''est la nouvelle version de traceur.def' 351 tnom_0(iq)= tchaine(1:iiq-1)352 tnom_transp(iq)= tchaine(iiq+1:)352 tnom_0(iq)=TRIM(tchaine(1:iiq-1)) 353 tnom_transp(iq)=TRIM(tchaine(iiq+1:)) 353 354 else 354 355 write(lunout,*) 'C''est l''ancienne version de traceur.def' … … 563 564 ! Allocate variables with total number of tracers, nqtot 564 565 ! 565 ALLOCATE(t name(nqtot), ttext(nqtot))566 ALLOCATE(tracers(nqtot)) 566 567 ALLOCATE(iadv(nqtot), niadv(nqtot)) 567 568 … … 587 588 588 589 str1=tnom_0(iq) 589 t name(new_iq)= tnom_0(iq)590 tracers(new_iq)%name=TRIM(tnom_0(iq)) 590 591 IF (iadv(new_iq)==0) THEN 591 t text(new_iq)=trim(str1)592 tracers(new_iq)%longName=trim(str1) 592 593 ELSE 593 t text(new_iq)=trim(tnom_0(iq))//descrq(iadv(new_iq))594 tracers(new_iq)%longName=trim(tnom_0(iq))//descrq(iadv(new_iq)) 594 595 ENDIF 595 596 596 597 ! schemas tenant compte des moments d'ordre superieur 597 str2= ttext(new_iq)598 str2=TRIM(tracers(new_iq)%longName) 598 599 IF (iadv(new_iq)==20) THEN 599 600 DO jq=1,3 600 601 new_iq=new_iq+1 601 602 iadv(new_iq)=-20 602 t text(new_iq)=trim(str2)//txts(jq)603 t name(new_iq)=trim(str1)//txts(jq)603 tracers(new_iq)%longName=trim(str2)//txts(jq) 604 tracers(new_iq)%name=trim(str1)//txts(jq) 604 605 END DO 605 606 ELSE IF (iadv(new_iq)==30) THEN … … 607 608 new_iq=new_iq+1 608 609 iadv(new_iq)=-30 609 t text(new_iq)=trim(str2)//txtp(jq)610 t name(new_iq)=trim(str1)//txtp(jq)610 tracers(new_iq)%longName=trim(str2)//txtp(jq) 611 tracers(new_iq)%name=trim(str1)//txtp(jq) 611 612 END DO 612 613 ENDIF … … 628 629 629 630 WRITE(lunout,*) trim(modname),': Information stored in infotrac :' 630 WRITE(lunout,*) trim(modname),': iadv niadv tname ttext:'631 WRITE(lunout,*) trim(modname),': iadv niadv name long_name :' 631 632 632 633 DO iq=1,nqtot 633 WRITE(lunout,*) iadv(iq),niadv(iq), ' ',trim(t name(iq)),' ',trim(ttext(iq))634 WRITE(lunout,*) iadv(iq),niadv(iq), ' ',trim(tracers(iq)%name),' ',trim(tracers(iq)%longName) 634 635 END DO 635 636 … … 802 803 INTEGER, ALLOCATABLE,DIMENSION(:) :: nb_isoind 803 804 INTEGER :: ntraceurs_zone_prec,iq,phase,ixt,iiso,izone 804 CHARACTER(len= tname_lenmax) :: tnom_trac805 CHARACTER(len=maxlen) :: tnom_trac 805 806 INCLUDE "iniprint.h" 806 807 -
LMDZ6/trunk/libf/dyn3d_common/initdynav.F90
r2622 r4046 6 6 USE IOIPSL 7 7 #endif 8 USE infotrac, ONLY : nqtot , ttext8 USE infotrac, ONLY : nqtot 9 9 use com_io_dyn_mod, only : histaveid,histvaveid,histuaveid, & 10 10 dynhistave_file,dynhistvave_file,dynhistuave_file … … 158 158 159 159 ! DO iq=1,nqtot 160 ! call histdef(histaveid, ttext(iq), ttext(iq), '-', & 160 ! call histdef(histaveid, tracers(iq)%name, & 161 ! tracers(iq)%longName, '-', & 161 162 ! iip1, jjp1, thoriid, llm, 1, llm, zvertiid, & 162 163 ! 32, 'ave(X)', t_ops, t_wrt) -
LMDZ6/trunk/libf/dyn3d_common/inithist.F
r2622 r4046 7 7 USE IOIPSL 8 8 #endif 9 USE infotrac, ONLY : nqtot , ttext9 USE infotrac, ONLY : nqtot 10 10 use com_io_dyn_mod, only : histid,histvid,histuid, & 11 11 & dynhist_file,dynhistv_file,dynhistu_file … … 157 157 ! 158 158 ! DO iq=1,nqtot 159 ! call histdef(histid, ttext(iq), ttext(iq), '-', 159 ! call histdef(histid, tracers(iq)%name, 160 ! tracers(iq)%longName, '-', 160 161 ! . iip1, jjp1, thoriid, llm, 1, llm, zvertiid, 161 162 ! . 32, 'inst(X)', t_ops, t_wrt) -
LMDZ6/trunk/libf/dyn3d_common/writedynav.F90
r2622 r4046 6 6 USE ioipsl 7 7 #endif 8 USE infotrac, ONLY : nqtot , ttext8 USE infotrac, ONLY : nqtot 9 9 use com_io_dyn_mod, only : histaveid, histvaveid, histuaveid 10 10 USE comconst_mod, ONLY: cpp … … 106 106 107 107 ! DO iq=1, nqtot 108 ! call histwrite(histaveid, t text(iq), itau_w, q(:, :, iq), &109 ! iip1*jjp1*llm, ndexu)108 ! call histwrite(histaveid, tracers(iq)%longName, itau_w, & 109 ! q(:, :, iq), iip1*jjp1*llm, ndexu) 110 110 ! enddo 111 111 -
LMDZ6/trunk/libf/dyn3d_common/writehist.F
r2622 r4046 7 7 USE ioipsl 8 8 #endif 9 USE infotrac, ONLY : nqtot , ttext9 USE infotrac, ONLY : nqtot 10 10 use com_io_dyn_mod, only : histid,histvid,histuid 11 11 USE temps_mod, ONLY: itau_dyn … … 100 100 C 101 101 ! DO iq=1,nqtot 102 ! call histwrite(histid, t text(iq), itau_w, q(:,:,iq),103 ! . iip1*jjp1*llm, ndexu)102 ! call histwrite(histid, tracers(iq)%longName, itau_w, 103 ! . q(:,:,iq), iip1*jjp1*llm, ndexu) 104 104 ! enddo 105 105 !C -
LMDZ6/trunk/libf/dyn3dmem/dynetat0_loc.F90
r3967 r4046 11 11 NF90_NOWRITE, NF90_CLOSE, NF90_INQUIRE_VARIABLE, NF90_GET_VAR, NF90_NoErr 12 12 USE control_mod, ONLY: planet_type 13 USE strings_mod, ONLY: maxlen 13 14 USE assert_eq_m, ONLY: assert_eq 14 15 USE comvert_mod, ONLY: pa,preff … … 39 40 !=============================================================================== 40 41 ! Local variables: 41 CHARACTER(LEN= 256) :: msg, var, modname42 CHARACTER(LEN=maxlen) :: msg, var, modname 42 43 INTEGER, PARAMETER :: length=100 43 44 INTEGER :: iq, fID, vID, idecal, ierr … … 152 153 ALLOCATE(q_glo(ip1jmp1,llm)) 153 154 DO iq=1,nqtot 154 var= tname(iq)155 var=TRIM(tracers(iq)%name) 155 156 #ifdef INCA 156 157 IF (var .eq. "O3" ) THEN … … 191 192 INTEGER, INTENT(IN) :: n1, n2 192 193 CHARACTER(LEN=*), INTENT(IN) :: str1, str2 193 CHARACTER(LEN= 256) :: s1, s2194 CHARACTER(LEN=maxlen) :: s1, s2 194 195 IF(n1/=n2) THEN 195 196 s1='value of '//TRIM(str1)//' =' -
LMDZ6/trunk/libf/dyn3dmem/dynredem_loc.F90
r3865 r4046 14 14 NF90_64BIT_OFFSET 15 15 USE dynredem_mod, ONLY: cre_var, put_var, err, modname, fil 16 USE strings_mod, ONLY: maxlen 16 17 USE comvert_mod, ONLY: ap,bp,aps,bps,presnivs,pseudoalt,pa,preff, & 17 18 nivsig,nivsigs … … 41 42 REAL :: phis_glo(ip1jmp1) 42 43 ! For NetCDF: 43 CHARACTER(LEN= 30) :: unites44 CHARACTER(LEN=maxlen) :: unites 44 45 INTEGER :: indexID 45 46 INTEGER :: rlonuID, rlonvID, rlatuID, rlatvID … … 151 152 CALL cre_var(nid,"teta" ,"Temperature",[rlonvID,rlatuID,sID,timID]) 152 153 DO iq=1,nqtot 153 CALL cre_var(nid,t name(iq),ttext(iq),[rlonvID,rlatuID,sID,timID])154 CALL cre_var(nid,tracers(iq)%name,tracers(iq)%longName,[rlonvID,rlatuID,sID,timID]) 154 155 END DO 155 156 CALL cre_var(nid,"masse","Masse d air" ,[rlonvID,rlatuID,sID,timID]) … … 204 205 INTEGER, PARAMETER :: length=100 205 206 REAL :: tab_cntrl(length) ! tableau des parametres du run 206 CHARACTER(LEN= 256) :: var, dum207 CHARACTER(LEN=maxlen) :: var, dum 207 208 LOGICAL :: lread_inca 208 209 !=============================================================================== … … 248 249 249 250 !--- Save tracers 250 DO iq=1,nqtot; var= tname(iq); ierr=-1251 DO iq=1,nqtot; var=TRIM(tracers(iq)%name); ierr=-1 251 252 IF(lread_inca) THEN !--- Possibly read from "start_trac.nc" 252 253 !$OMP MASTER -
LMDZ6/trunk/libf/dyn3dmem/initdynav_loc.F
r2622 r4046 252 252 C 253 253 ! DO iq=1,nqtot 254 ! call histdef(histaveid, ttext(iq), ttext(iq), '-', 254 ! call histdef(histaveid, tracers(iq)%name, 255 ! . tracers(iq)%longName, '-', 255 256 ! . iip1, jjn, thoriid, llm, 1, llm, zvertiid, 256 257 ! . 32, 'ave(X)', t_ops, t_wrt) -
LMDZ6/trunk/libf/dyn3dmem/inithist_loc.F
r2622 r4046 253 253 C 254 254 ! DO iq=1,nqtot 255 ! call histdef(histid, ttext(iq), ttext(iq), '-', 255 ! call histdef(histid, tracers(iq)%name, 256 ! . tracers(iq)%longName, '-', 256 257 ! . iip1, jjn, thoriid, llm, 1, llm, zvertiid, 257 258 ! . 32, 'inst(X)', t_ops, t_wrt) -
LMDZ6/trunk/libf/dyn3dmem/writedynav_loc.F
r2622 r4046 11 11 USE parallel_lmdz 12 12 USE misc_mod 13 USE infotrac, ONLY : nqtot , ttext13 USE infotrac, ONLY : nqtot 14 14 use com_io_dyn_mod, only : histaveid,histvaveid,histuaveid 15 15 USE comconst_mod, ONLY: cpp … … 177 177 !!$OMP MASTER 178 178 ! DO iq=1,nqtot 179 ! call histwrite(histaveid, t text(iq), itau_w, q(ijb:ije,:,iq),180 ! . iip1*jjn*llm, ndexu)179 ! call histwrite(histaveid, tracers(iq)%longName, itau_w, & 180 ! . q(ijb:ije,:,iq), iip1*jjn*llm, ndexu) 181 181 ! enddo 182 182 !!$OMP END MASTER -
LMDZ6/trunk/libf/dyn3dmem/writehist_loc.F
r2622 r4046 11 11 USE parallel_lmdz 12 12 USE misc_mod 13 USE infotrac, ONLY : nqtot , ttext13 USE infotrac, ONLY : nqtot 14 14 use com_io_dyn_mod, only : histid,histvid,histuid 15 15 USE comconst_mod, ONLY: cpp … … 177 177 !!$OMP MASTER 178 178 ! DO iq=1,nqtot 179 ! call histwrite(histid, t text(iq), itau_w, q(ijb:ije,:,iq),180 ! . iip1*jjn*llm, ndexu)179 ! call histwrite(histid, tracers(iq)%longName, itau_w, 180 ! . q(ijb:ije,:,iq), iip1*jjn*llm, ndexu) 181 181 ! enddo 182 182 !!$OMP END MASTER -
LMDZ6/trunk/libf/dynphy_lonlat/calfis.F
r2604 r4046 29 29 c Auteur : P. Le Van, F. Hourdin 30 30 c ......... 31 USE infotrac, ONLY: nqtot, niadv, t name31 USE infotrac, ONLY: nqtot, niadv, tracers 32 32 USE control_mod, ONLY: planet_type, nsplit_phys 33 33 #ifdef CPP_PHYS … … 481 481 lafin_split=lafin.and.isplit==nsplit_phys 482 482 483 CALL call_physiq(ngridmx,llm,nqtot,t name,483 CALL call_physiq(ngridmx,llm,nqtot,tracers(:)%name, 484 484 & debut_split,lafin_split, 485 485 & jD_cur,jH_cur_split,zdt_split, … … 522 522 ! . llm, !! nlayer 523 523 ! . nqtot, !! nq 524 ! . t name,!! tracer names from dynamical core (given in infotrac)524 ! . tracers(:)%name,!! tracer names from dynamical core (given in infotrac) 525 525 ! . debut_split, !! firstcall 526 526 ! . lafin_split, !! lastcall -
LMDZ6/trunk/libf/dynphy_lonlat/calfis_loc.F
r2604 r4046 45 45 USE Times 46 46 #endif 47 USE infotrac, ONLY: nqtot, niadv, t name47 USE infotrac, ONLY: nqtot, niadv, tracers 48 48 USE control_mod, ONLY: planet_type, nsplit_phys 49 49 #ifdef CPP_PHYS … … 731 731 lafin_split=lafin.and.isplit==nsplit_phys 732 732 733 CALL call_physiq(klon,llm,nqtot,t name,733 CALL call_physiq(klon,llm,nqtot,tracers(:)%name, 734 734 & debut_split,lafin_split, 735 735 & jD_cur,jH_cur_split,zdt_split, -
LMDZ6/trunk/libf/dynphy_lonlat/phylmd/etat0dyn_netcdf.F90
r3435 r4046 39 39 USE comvert_mod, ONLY: ap, bp, preff, pressure_exner 40 40 USE temps_mod, ONLY: annee_ref, day_ref, itau_dyn, itau_phy, start_time 41 USE strings_mod, ONLY: strLower 41 42 42 43 IMPLICIT NONE … … 74 75 USE exner_hyb_m, ONLY: exner_hyb 75 76 USE exner_milieu_m, ONLY: exner_milieu 76 USE infotrac, ONLY: nqtot, t name77 USE infotrac, ONLY: nqtot, tracers 77 78 USE filtreg_mod 78 79 IMPLICIT NONE … … 84 85 ! Local variables: 85 86 CHARACTER(LEN=256) :: modname, fmt 86 INTEGER :: i, j, l, ji, itau, iday 87 INTEGER :: i, j, l, ji, itau, iday, iq 87 88 REAL :: xpn, xps, time, phystep 88 89 REAL, DIMENSION(iip1,jjp1) :: psol … … 145 146 ! Look for ozone tracer: 146 147 #ifndef INCA 147 DO i =1,nqtot; IF(ANY(["O3","o3"]==tname(i))) EXIT; END DO148 DO iq=1,nqtot; IF(strLower(tracers(iq)%name)=="o3") EXIT; END DO 148 149 IF(i/=nqtot+1) THEN 149 150 CALL regr_lat_time_coefoz -
LMDZ6/trunk/libf/dynphy_lonlat/phylmd/iniphysiq_mod.F90
r3924 r4046 16 16 USE mod_phys_lmdz_para, ONLY: klon_omp ! number of columns (on local omp grid) 17 17 USE vertical_layers_mod, ONLY : init_vertical_layers 18 USE infotrac, ONLY: nqtot,nqo,nbtr,nqCO2,t name,ttext,type_trac,&18 USE infotrac, ONLY: nqtot,nqo,nbtr,nqCO2,tracers,type_trac,& 19 19 niadv,conv_flg,pbl_flg,solsym,& 20 20 nqfils,nqdesc,nqdesc_tot,iqfils,iqpere,& … … 146 146 147 147 ! Initialize tracer names, numbers, etc. for physics 148 CALL init_infotrac_phy(nqtot,nqo,nbtr,nqtottr,nqCO2,t name,ttext,type_trac,&148 CALL init_infotrac_phy(nqtot,nqo,nbtr,nqtottr,nqCO2,tracers,type_trac,& 149 149 niadv,conv_flg,pbl_flg,solsym,& 150 150 nqfils,nqdesc,nqdesc_tot,iqfils,iqpere,& … … 203 203 rlonudyn,rlatudyn,rlonvdyn,rlatvdyn) 204 204 #endif 205 IF (type_trac == 'repr') THEN206 #ifdef REPROBUS 207 CALL Init_chem_rep_phys(klon_omp,nbp_lev) 208 #endif 209 END IF 205 END IF 206 IF (type_trac == 'repr') THEN 207 #ifdef REPROBUS 208 CALL Init_chem_rep_phys(klon_omp,nbp_lev) 209 #endif 210 210 END IF 211 211 -
LMDZ6/trunk/libf/phylmd/Dust/phytracr_spl_mod.F90
r3977 r4046 1416 1416 !print *,nbtr 1417 1417 do it=1,nbtr 1418 print *, it, tname(it+nqo) 1419 if (tname(it+nqo) == 'PREC' ) then 1420 id_prec=it 1421 endif 1422 if (tname(it+nqo) == 'FINE' ) then 1423 id_fine=it 1424 endif 1425 if (tname(it+nqo) == 'COSS' ) then 1426 id_coss=it 1427 endif 1428 if (tname(it+nqo) == 'CODU' ) then 1429 id_codu=it 1430 endif 1431 if (tname(it+nqo) == 'SCDU' ) then 1432 id_scdu=it 1433 endif 1418 print *, it, tracers(it+nqo)%name 1419 SELECT CASE(tracers(it+nqo)%name) 1420 CASE('PREC'); id_prec=it 1421 CASE('FINE'); id_fine=it 1422 CASE('COSS'); id_coss=it 1423 CASE('CODU'); id_codu=it 1424 CASE('SCDU'); id_scdu=it 1425 END SELECT 1434 1426 enddo 1435 1427 ! check consistency with dust emission scheme: -
LMDZ6/trunk/libf/phylmd/Dust/splaeropt_5wv_rrtm.F90
r2753 r4046 113 113 114 114 DO itr=1,nbtr !--loop over tracers 115 116 IF (tname(itr+nqo)=='PREC') THEN !--fine mode accumulation mode 117 CYCLE 118 ELSE IF (tname(itr+nqo)=='FINE') THEN !--fine mode accumulation mode 119 soluble=.TRUE. 120 spsol=1 121 aerindex=1 122 ELSE IF (tname(itr+nqo)=='COSS') THEN !--coarse mode sea salt 123 soluble=.TRUE. 124 spsol=2 125 aerindex=2 126 ELSE IF (tname(itr+nqo)=='CODU') THEN !--coarse mode dust 127 soluble=.FALSE. 128 spinsol=1 129 aerindex=3 130 ELSE IF (tname(itr+nqo)=='SCDU') THEN !--super coarse mode dust 131 soluble=.FALSE. 132 spinsol=2 133 aerindex=4 134 ELSE 135 CALL abort_physic(modname,'I cannot do aerosol optics for '//tname(itr+nqo),1) 136 ENDIF 115 SELECT CASE(tracers(itr+nqo)%name) 116 CASE('PREC'); CYCLE !--precursor 117 CASE('FINE'); soluble=.TRUE.; spsol=1; aerindex=1 !--fine mode accumulation mode 118 CASE('COSS'); soluble=.TRUE.; spsol=2; aerindex=2 !--coarse mode sea salt 119 CASE('CODU'); soluble=.FALSE.; spsol=1; aerindex=3 !--coarse mode dust 120 CASE('SCDU'); soluble=.FALSE.; spsol=2; aerindex=4 !--super coarse mode dust 121 CASE DEFAULT; CALL abort_physic(modname,'I cannot do aerosol optics for '//tracers(itr+nqo)%name,1) 122 END SELECT 137 123 138 124 DO la=1,las -
LMDZ6/trunk/libf/phylmd/Dust/splaeropt_6bands_rrtm.F90
r3770 r4046 165 165 cg_ae(:,:,:,:)=0. 166 166 167 DO itr=1, nbtr 168 169 IF (tname(itr+nqo)=='PREC') THEN !--precursor 170 CYCLE 171 ELSE IF (tname(itr+nqo)=='FINE') THEN !--fine mode accumulation mode 172 soluble=.TRUE. 173 spsol=1 174 aerindex=1 175 ELSE IF (tname(itr+nqo)=='COSS') THEN !--coarse mode sea salt 176 soluble=.TRUE. 177 spsol=2 178 aerindex=2 179 ELSE IF (tname(itr+nqo)=='CODU') THEN !--coarse mode dust 180 soluble=.FALSE. 181 spinsol=1 182 aerindex=3 183 ELSE IF (tname(itr+nqo)=='SCDU') THEN !--super coarse mode dust 184 soluble=.FALSE. 185 spinsol=2 186 aerindex=4 187 ELSE 188 CALL abort_physic(modname,'I cannot do aerosol optics for '//tname(itr+nqo),1) 189 ENDIF 167 DO itr=1,nbtr !--loop over tracers 168 SELECT CASE(tracers(itr+nqo)%name) 169 CASE('PREC'); CYCLE !--precursor 170 CASE('FINE'); soluble=.TRUE.; spsol=1; aerindex=1 !--fine mode accumulation mode 171 CASE('COSS'); soluble=.TRUE.; spsol=2; aerindex=2 !--coarse mode sea salt 172 CASE('CODU'); soluble=.FALSE.; spsol=1; aerindex=3 !--coarse mode dust 173 CASE('SCDU'); soluble=.FALSE.; spsol=2; aerindex=4 !--super coarse mode dust 174 CASE DEFAULT; CALL abort_physic(modname,'I cannot do aerosol optics for '//tracers(itr+nqo)%name,1) 175 END SELECT 190 176 191 177 IF (soluble) THEN ! For aerosol soluble components -
LMDZ6/trunk/libf/phylmd/Dust/splaeropt_lw_rrtm.F90
r2753 r4046 55 55 ! 56 56 DO itr=1,nbtr 57 ! 58 IF (tname(itr+nqo)=='PREC') THEN !--precursor 59 CYCLE 60 ELSE IF (tname(itr+nqo)=='FINE') THEN !--fine mode accumulation mode 61 CYCLE 62 ELSE IF (tname(itr+nqo)=='COSS') THEN !--coarse mode sea salt 63 CYCLE 64 ELSE IF (tname(itr+nqo)=='CODU') THEN !--coarse mode dust 65 spinsol=1 66 ELSE IF (tname(itr+nqo)=='SCDU') THEN !--super coarse mode dust 67 spinsol=2 68 ELSE 69 CALL abort_physic(modname,'I cannot do aerosol optics for '//tname(itr+nqo),1) 70 ENDIF 57 SELECT CASE(tracers(itr+nqo)%name) 58 CASE('PREC','FINE''COSS'); CYCLE !--precursor or fine/coarde accumulation mode 59 CASE('CODU'); spinsol=1 !--coarse mode dust 60 CASE('SCDU'); spinsol=2 !--super coarse mode dust 61 CASE DEFAULT; CALL abort_physic(modname,'I cannot do aerosol optics for '//tracers(itr+nqo)%name,1) 62 END SELECT 71 63 ! 72 64 DO inu=1,NLW -
LMDZ6/trunk/libf/phylmd/Dust/splaerosol_optic_rrtm.F90
r2753 r4046 51 51 ! 52 52 DO itr=1,nbtr 53 IF (t name(itr+nqo)=='FINE') THEN53 IF (tracers(itr+nqo)%name=='FINE') THEN 54 54 mass_solu_aero(:,:) = tr_seri(:,:,itr) 55 55 mass_solu_aero_pi(:,:) = tr_seri(:,:,itr) -
LMDZ6/trunk/libf/phylmd/cvltr.F90
r2320 r4046 12 12 USE IOIPSL 13 13 USE dimphy 14 USE infotrac_phy, ONLY : nbtr ,tname14 USE infotrac_phy, ONLY : nbtr 15 15 IMPLICIT NONE 16 16 !===================================================================== -
LMDZ6/trunk/libf/phylmd/cvltr_scav.F90
r2320 r4046 13 13 USE IOIPSL 14 14 USE dimphy 15 USE infotrac_phy, ONLY : nbtr ,tname15 USE infotrac_phy, ONLY : nbtr 16 16 IMPLICIT NONE 17 17 !===================================================================== -
LMDZ6/trunk/libf/phylmd/cvltr_spl.F90
r2320 r4046 13 13 USE IOIPSL 14 14 USE dimphy 15 USE infotrac_phy, ONLY : nbtr ,tname15 USE infotrac_phy, ONLY : nbtr 16 16 IMPLICIT NONE 17 17 !===================================================================== -
LMDZ6/trunk/libf/phylmd/dyn1d/1DUTILS.h
r3780 r4046 713 713 !! enddo 714 714 DO iq = 1,nqtot 715 nmq(iq) = trim(t name(iq))715 nmq(iq) = trim(tracers(iq)%name) 716 716 ENDDO 717 717 print*,'in dyn1deta0 ',fichnom,klon,klev,nqtot … … 864 864 !! nmq(4)="tra2" 865 865 DO iq = 1,nqtot 866 nmq(iq) = trim(t name(iq))866 nmq(iq) = trim(tracers(iq)%name) 867 867 ENDDO 868 868 -
LMDZ6/trunk/libf/phylmd/infotrac_phy.F90
r4005 r4046 7 7 ! the dynamics (could be further cleaned) and is initialized using values 8 8 ! provided by the dynamics 9 10 USE readTracFiles_mod, ONLY: trac_type, maxlen, delPhase 9 11 10 12 ! nqtot : total number of tracers and higher order of moment, water vapor and liquid included … … 41 43 !$OMP THREADPRIVATE(nqperes) 42 44 43 ! Name variables 44 INTEGER,PARAMETER :: tname_lenmax=128 45 CHARACTER(len=tname_lenmax), ALLOCATABLE, DIMENSION(:), SAVE :: tname ! tracer short name for restart and diagnostics 46 CHARACTER(len=tname_lenmax+3), ALLOCATABLE, DIMENSION(:), SAVE :: ttext ! tracer long name for diagnostics 47 !$OMP THREADPRIVATE(tname,ttext) 48 49 !! iadv : index of trasport schema for each tracer 50 ! INTEGER, ALLOCATABLE, DIMENSION(:), SAVE :: iadv 45 ! Tracers parameters 46 TYPE(trac_type), TARGET, ALLOCATABLE, SAVE :: tracers(:) 47 !$OMP THREADPRIVATE(tracers) 51 48 52 49 ! niadv : vector keeping the coorspondance between all tracers(nqtot) treated in the … … 107 104 CONTAINS 108 105 109 SUBROUTINE init_infotrac_phy(nqtot_,nqo_,nbtr_,nqtottr_,nqCO2_,t name_,ttext_,type_trac_,&106 SUBROUTINE init_infotrac_phy(nqtot_,nqo_,nbtr_,nqtottr_,nqCO2_,tracers_,type_trac_,& 110 107 niadv_,conv_flg_,pbl_flg_,solsym_,& 111 108 nqfils_,nqdesc_,nqdesc_tot_,iqfils_,iqpere_,& … … 139 136 INTEGER,INTENT(IN) :: id_BIN01_strat_ 140 137 #endif 141 CHARACTER(len=*),INTENT(IN) :: tname_(nqtot_) ! tracer short name for restart and diagnostics 142 CHARACTER(len=*),INTENT(IN) :: ttext_(nqtot_) ! tracer long name for diagnostics 138 TYPE(trac_type), INTENT(IN) :: tracers_(nqtot_) ! tracers descriptors 143 139 CHARACTER(len=*),INTENT(IN) :: type_trac_ 144 140 INTEGER,INTENT(IN) :: niadv_ (nqtot_) ! equivalent dyn / physique … … 179 175 nqCO2=nqCO2_ 180 176 nqtottr=nqtottr_ 177 ALLOCATE(tracers(nqtot)); tracers(:) = tracers_(:) 181 178 #ifdef CPP_StratAer 182 179 nbtr_bin=nbtr_bin_ … … 187 184 id_BIN01_strat=id_BIN01_strat_ 188 185 #endif 189 ALLOCATE(tname(nqtot))190 tname(:) = tname_(:)191 ALLOCATE(ttext(nqtot))192 ttext(:) = ttext_(:)193 186 type_trac = type_trac_ 194 187 ALLOCATE(niadv(nqtot)) -
LMDZ6/trunk/libf/phylmd/iophy.F90
r3488 r4046 811 811 IMPLICIT NONE 812 812 813 CHARACTER(LEN= 20):: nam_var814 INTEGER, DIMENSION(nfiles) :: flag_var813 CHARACTER(LEN=*), INTENT(INOUT) :: nam_var 814 INTEGER, INTENT(INOUT) :: flag_var(nfiles) 815 815 816 816 IF(prt_level>10) WRITE(lunout,*)'Avant getin: nam_var flag_var ',nam_var,flag_var(:) -
LMDZ6/trunk/libf/phylmd/phyetat0.F90
r3956 r4046 23 23 USE geometry_mod, ONLY : longitude_deg, latitude_deg 24 24 USE iostart, ONLY : close_startphy, get_field, get_var, open_startphy 25 USE infotrac_phy, only: nbtr, nqo, type_trac, t name, niadv25 USE infotrac_phy, only: nbtr, nqo, type_trac, tracers, niadv 26 26 USE traclmdz_mod, ONLY : traclmdz_from_restart 27 27 USE carbon_cycle_mod, ONLY : carbon_cycle_tr, carbon_cycle_cpl, co2_send … … 451 451 !! iiq=niadv(it+2) ! jyg 452 452 iiq=niadv(it+nqo) ! jyg 453 found=phyetat0_get(1,trs(:,it),"trs_"// tname(iiq), &454 "Surf trac"//tname(iiq),0.)453 found=phyetat0_get(1,trs(:,it),"trs_"//TRIM(tracers(iiq)%name), & 454 "Surf trac"//TRIM(tracers(iiq)%name),0.) 455 455 ENDDO 456 456 CALL traclmdz_from_restart(trs) -
LMDZ6/trunk/libf/phylmd/phyredem.F90
r4035 r4046 35 35 USE iostart, ONLY: open_restartphy, close_restartphy, enddef_restartphy, put_field, put_var 36 36 USE traclmdz_mod, ONLY : traclmdz_to_restart 37 USE infotrac_phy, ONLY: type_trac, niadv, t name, nbtr, nqo37 USE infotrac_phy, ONLY: type_trac, niadv, tracers, nbtr, nqo 38 38 USE carbon_cycle_mod, ONLY : carbon_cycle_cpl, co2_send 39 39 USE indice_sol_mod, ONLY: nbsrf, is_oce, is_sic, is_ter, is_lic, epsfra … … 329 329 !! iiq=niadv(it+2) ! jyg 330 330 iiq=niadv(it+nqo) ! jyg 331 CALL put_field(pass,"trs_"//t name(iiq), "", trs(:, it))331 CALL put_field(pass,"trs_"//tracers(iiq)%name, "", trs(:, it)) 332 332 END DO 333 333 END IF … … 380 380 IF (pass==1) CALL enddef_restartphy 381 381 IF (pass==2) CALL close_restartphy 382 ENDDO382 ENDDO ! DO pass=1,2 ! pass=1 netcdf definition ; pass=2 netcdf write 383 383 384 384 !$OMP BARRIER -
LMDZ6/trunk/libf/phylmd/phys_output_mod.F90
r3792 r4046 35 35 USE iophy 36 36 USE dimphy 37 USE infotrac_phy, ONLY: nqtot, nqo, niadv, tname, ttext, type_trac 37 USE infotrac_phy, ONLY: nqtot, nqo, niadv, tracers, type_trac 38 USE strings_mod, ONLY: maxlen 38 39 USE ioipsl 39 40 USE phys_cal_mod, only : hour, calend … … 95 96 CHARACTER(LEN=4), DIMENSION(nlevSTD) :: clevSTD 96 97 REAL, DIMENSION(nlevSTD) :: rlevSTD 97 INTEGER :: nsrf, k, iq, iiq, iff, i, j, ilev 98 INTEGER :: nsrf, k, iq, iiq, iff, i, j, ilev, jq 98 99 INTEGER :: naero 99 100 LOGICAL :: ok_veget … … 113 114 LOGICAL, DIMENSION(nfiles) :: phys_out_filekeys 114 115 LOGICAL, DIMENSION(nfiles) :: phys_out_filestations 116 117 CHARACTER(LEN=50) :: outiso 118 CHARACTER(LEN=20) :: unit 119 CHARACTER(LEN=maxlen) :: tnam, lnam, dn 120 INTEGER :: flag(nfiles) 115 121 116 122 !!!!!!!!!! stockage dans une region limitee pour chaque fichier !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! … … 494 500 IF (nqtot>=nqo+1) THEN 495 501 ! 496 DO iq=nqo+1,nqtot 497 iiq=niadv(iq) 498 o_trac(iq-nqo) = ctrl_out((/ 1, 5, 5, 5, 10, 10, 11, 11, 11, 11 /), & 499 tname(iiq),'Tracer '//ttext(iiq), "-", & 500 (/ '', '', '', '', '', '', '', '', '', '' /)) 501 o_dtr_vdf(iq-nqo) = ctrl_out((/ 4, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 502 'd'//trim(tname(iq))//'_vdf', & 503 'Tendance tracer '//ttext(iiq), "-" , & 504 (/ '', '', '', '', '', '', '', '', '', '' /)) 505 506 o_dtr_the(iq-nqo) = ctrl_out((/ 5, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 507 'd'//trim(tname(iq))//'_the', & 508 'Tendance tracer '//ttext(iiq), "-", & 509 (/ '', '', '', '', '', '', '', '', '', '' /)) 510 511 o_dtr_con(iq-nqo) = ctrl_out((/ 5, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 512 'd'//trim(tname(iq))//'_con', & 513 'Tendance tracer '//ttext(iiq), "-", & 514 (/ '', '', '', '', '', '', '', '', '', '' /)) 515 516 o_dtr_lessi_impa(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 517 'd'//trim(tname(iq))//'_lessi_impa', & 518 'Tendance tracer '//ttext(iiq), "-", & 519 (/ '', '', '', '', '', '', '', '', '', '' /)) 520 521 o_dtr_lessi_nucl(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 522 'd'//trim(tname(iq))//'_lessi_nucl', & 523 'Tendance tracer '//ttext(iiq), "-", & 524 (/ '', '', '', '', '', '', '', '', '', '' /)) 525 526 o_dtr_insc(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 527 'd'//trim(tname(iq))//'_insc', & 528 'Tendance tracer '//ttext(iiq), "-", & 529 (/ '', '', '', '', '', '', '', '', '', '' /)) 530 531 o_dtr_bcscav(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 532 'd'//trim(tname(iq))//'_bcscav', & 533 'Tendance tracer '//ttext(iiq), "-", & 534 (/ '', '', '', '', '', '', '', '', '', '' /)) 535 536 o_dtr_evapls(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 537 'd'//trim(tname(iq))//'_evapls', & 538 'Tendance tracer '//ttext(iiq), "-", & 539 (/ '', '', '', '', '', '', '', '', '', '' /)) 540 541 o_dtr_ls(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 542 'd'//trim(tname(iq))//'_ls', & 543 'Tendance tracer '//ttext(iiq), "-", & 544 (/ '', '', '', '', '', '', '', '', '', '' /)) 545 546 o_dtr_trsp(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 547 'd'//trim(tname(iq))//'_trsp', & 548 'Tendance tracer '//ttext(iiq), "-", & 549 (/ '', '', '', '', '', '', '', '', '', '' /)) 550 551 o_dtr_sscav(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 552 'd'//trim(tname(iq))//'_sscav', & 553 'Tendance tracer '//ttext(iiq), "-", & 554 (/ '', '', '', '', '', '', '', '', '', '' /)) 555 556 o_dtr_sat(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 557 'd'//trim(tname(iq))//'_sat', & 558 'Tendance tracer '//ttext(iiq), "-", & 559 (/ '', '', '', '', '', '', '', '', '', '' /)) 560 561 o_dtr_uscav(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 562 'd'//trim(tname(iq))//'_uscav', & 563 'Tendance tracer '//ttext(iiq), "-", & 564 (/ '', '', '', '', '', '', '', '', '', '' /)) 565 566 o_dtr_dry(iq-nqo) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 567 'cum'//'d'//trim(tname(iq))//'_dry', & 568 'tracer tendency dry deposition'//ttext(iiq), "-", & 569 (/ '', '', '', '', '', '', '', '', '', '' /)) 570 571 o_trac_cum(iq-nqo) = ctrl_out((/ 1, 4, 10, 10, 10, 10, 11, 11, 11, 11 /), & 572 'cum'//tname(iiq),& 573 'Cumulated tracer '//ttext(iiq), "-", & 574 (/ '', '', '', '', '', '', '', '', '', '' /)) 575 ENDDO 576 ENDIF 502 DO iq=nqo+1,nqtot 503 iiq=niadv(iq); jq = iq-nqo 504 dn = 'd'//TRIM(tracers(iiq)%name)//'_' 505 506 flag = [1, 5, 5, 5, 10, 10, 11, 11, 11, 11] 507 lnam = 'Tracer '//TRIM(tracers(iiq)%longName) 508 tnam = TRIM(tracers(iiq)%name); o_trac (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 509 flag = [4, 7, 7, 7, 10, 10, 11, 11, 11, 11] 510 lnam = 'Tendance tracer '//TRIM(tracers(iiq)%longName) 511 tnam = TRIM(dn)//'vdf'; o_dtr_vdf (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 512 513 flag = [5, 7, 7, 7, 10, 10, 11, 11, 11, 11] 514 tnam = TRIM(dn)//'the'; o_dtr_the (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 515 tnam = TRIM(dn)//'con'; o_dtr_con (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 516 517 flag = [7, 7, 7, 7, 10, 10, 11, 11, 11, 11] 518 tnam = TRIM(dn)//'lessi_impa'; o_dtr_lessi_impa(jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 519 tnam = TRIM(dn)//'lessi_nucl'; o_dtr_lessi_nucl(jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 520 tnam = TRIM(dn)//'insc'; o_dtr_insc (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 521 tnam = TRIM(dn)//'bcscav'; o_dtr_bcscav (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 522 tnam = TRIM(dn)//'evapls'; o_dtr_evapls (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 523 tnam = TRIM(dn)//'ls'; o_dtr_ls (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 524 tnam = TRIM(dn)//'trsp'; o_dtr_trsp (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 525 tnam = TRIM(dn)//'sscav'; o_dtr_sscav (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 526 tnam = TRIM(dn)//'sat'; o_dtr_sat (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 527 tnam = TRIM(dn)//'uscav'; o_dtr_uscav (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 528 529 lnam = 'tracer tendency dry deposition'//TRIM(tracers(iiq)%longName) 530 tnam = 'cum'//TRIM(dn)//'dry'; o_dtr_dry (jq) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 531 532 flag = [1, 4, 10, 10, 10, 10, 11, 11, 11, 11] 533 lnam = 'Cumulated tracer '//TRIM(tracers(iiq)%longName) 534 tnam = 'cum'//TRIM(tracers(iiq)%name); o_trac_cum(jq)= ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 535 ENDDO 536 ENDIF 577 537 578 538 ENDDO ! iff … … 594 554 WRITE(lunout,*)'phys_output_open: ends here' 595 555 ENDIF 556 557 ! DO iq=nqo+1,nqtot 558 ! iiq=niadv(iq) 559 ! dn = 'd'//TRIM(tracers(iiq)%name)//'_' 560 ! WRITE(*,'(a,i1,a,10i3)')'trac(',iiq,')%flag = ',o_trac(iiq)%flag 561 ! WRITE(*,'(a,i1,a)')'trac(',iiq,')%tnam = '//TRIM(o_trac(iiq)%name) 562 ! WRITE(*,'(a,i1,a)')'trac(',iiq,')%lnam = '//TRIM(o_trac(iiq)%description) 563 ! END DO 596 564 597 565 END SUBROUTINE phys_output_open -
LMDZ6/trunk/libf/phylmd/phys_output_var_mod.F90
r3987 r4046 5 5 6 6 USE dimphy 7 USE strings_mod, ONLY: maxlen 7 8 ! Variables outputs pour les ecritures des sorties 8 9 !====================================================================== … … 121 122 122 123 TYPE ctrl_out 123 INTEGER ,DIMENSION(nfiles) :: flag124 CHARACTER(len= 20):: name125 CHARACTER(len= 150):: description126 CHARACTER(len= 20):: unit127 CHARACTER(len= 20),DIMENSION(nfiles) :: type_ecrit124 INTEGER :: flag(nfiles) 125 CHARACTER(len=maxlen) :: name 126 CHARACTER(len=maxlen) :: description 127 CHARACTER(len=maxlen) :: unit 128 CHARACTER(len=maxlen) :: type_ecrit(nfiles) 128 129 END TYPE ctrl_out 129 130 -
LMDZ6/trunk/libf/phylmd/phys_output_write_mod.F90
r3956 r4046 25 25 26 26 USE dimphy, ONLY: klon, klev, klevp1 27 USE infotrac_phy, ONLY: nbtr 27 USE infotrac_phy, ONLY: nbtr, nqtot, nqo, type_trac, tracers, niadv 28 USE strings_mod, ONLY: maxlen 28 29 USE mod_phys_lmdz_para, ONLY: is_north_pole_phy,is_south_pole_phy 29 30 USE mod_grid_phy_lmdz, ONLY : nbp_lon, nbp_lat … … 366 367 USE pbl_surface_mod, ONLY: snow 367 368 USE indice_sol_mod, ONLY: nbsrf 368 USE infotrac_phy, ONLY: nqtot, nqo, type_trac, tname, niadv369 369 USE geometry_mod, ONLY: cell_area, latitude_deg, longitude_deg 370 370 USE surface_data, ONLY: type_ocean, version_ocean, ok_veget, landice_opt … … 441 441 INTEGER ISW 442 442 CHARACTER*1 ch1 443 CHARACTER *20 varname443 CHARACTER(LEN=maxlen) :: varname, dn 444 444 445 445 #ifdef CPP_XIOS … … 454 454 455 455 INTEGER :: nqup 456 456 457 457 458 ! On calcul le nouveau tau: … … 512 513 DO iq=nqo+1, nqtot 513 514 iiq=niadv(iq) 514 varname=trim(tname(iiq)) 515 WRITE (lunout,*) 'XIOS var=', nqo, iq, nqtot, varname 515 dn = 'd'//TRIM(tracers(iiq)%name)//'_' 516 WRITE (lunout,*) 'XIOS var=', nqo, iq, nqtot, tracers(iiq)%name 517 518 unt = "kg kg-1" 519 varname=trim(tracers(iiq)%name) 516 520 CALL xios_add_child(group_handle, child, varname) 517 CALL xios_set_attr(child, name=varname, unit="kg kg-1") 518 varname='d'//trim(tname(iiq))//'_vdf' 521 CALL xios_set_attr(child, name=varname, unit=unt) 522 523 unt = "kg kg-1 s-1" 524 varname=TRIM(dn)//'vdf' 519 525 CALL xios_add_child(group_handle, child, varname) 520 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")521 varname= 'd'//trim(tname(iiq))//'_the'526 CALL xios_set_attr(child, name=varname, unit=unt) 527 varname=TRIM(dn)//'the' 522 528 CALL xios_add_child(group_handle, child, varname) 523 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")524 varname= 'd'//trim(tname(iiq))//'_con'529 CALL xios_set_attr(child, name=varname, unit=unt) 530 varname=TRIM(dn)//'con' 525 531 CALL xios_add_child(group_handle, child, varname) 526 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")527 varname= 'd'//trim(tname(iiq))//'_lessi_impa'532 CALL xios_set_attr(child, name=varname, unit=unt) 533 varname=TRIM(dn)//'lessi_impa' 528 534 CALL xios_add_child(group_handle, child, varname) 529 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")530 varname= 'd'//trim(tname(iiq))//'_lessi_nucl'535 CALL xios_set_attr(child, name=varname, unit=unt) 536 varname=TRIM(dn)//'lessi_nucl' 531 537 CALL xios_add_child(group_handle, child, varname) 532 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")533 varname= 'd'//trim(tname(iiq))//'_insc'538 CALL xios_set_attr(child, name=varname, unit=unt) 539 varname=TRIM(dn)//'insc' 534 540 CALL xios_add_child(group_handle, child, varname) 535 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")536 varname= 'd'//trim(tname(iiq))//'_bcscav'541 CALL xios_set_attr(child, name=varname, unit=unt) 542 varname=TRIM(dn)//'bcscav' 537 543 CALL xios_add_child(group_handle, child, varname) 538 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")539 varname= 'd'//trim(tname(iiq))//'_evapls'544 CALL xios_set_attr(child, name=varname, unit=unt) 545 varname=TRIM(dn)//'evapls' 540 546 CALL xios_add_child(group_handle, child, varname) 541 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")542 varname= 'd'//trim(tname(iiq))//'_ls'547 CALL xios_set_attr(child, name=varname, unit=unt) 548 varname=TRIM(dn)//'ls' 543 549 CALL xios_add_child(group_handle, child, varname) 544 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")545 varname= 'd'//trim(tname(iiq))//'_trsp'550 CALL xios_set_attr(child, name=varname, unit=unt) 551 varname=TRIM(dn)//'trsp' 546 552 CALL xios_add_child(group_handle, child, varname) 547 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")548 varname= 'd'//trim(tname(iiq))//'_sscav'553 CALL xios_set_attr(child, name=varname, unit=unt) 554 varname=TRIM(dn)//'sscav' 549 555 CALL xios_add_child(group_handle, child, varname) 550 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")551 varname= 'd'//trim(tname(iiq))//'_sat'556 CALL xios_set_attr(child, name=varname, unit=unt) 557 varname=TRIM(dn)//'sat' 552 558 CALL xios_add_child(group_handle, child, varname) 553 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")554 varname= 'd'//trim(tname(iiq))//'_uscav'559 CALL xios_set_attr(child, name=varname, unit=unt) 560 varname=TRIM(dn)//'uscav' 555 561 CALL xios_add_child(group_handle, child, varname) 556 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")562 CALL xios_set_attr(child, name=varname, unit=unt) 557 563 ENDDO 558 564 !On ajoute les variables 2D traceurs par l interface fortran … … 561 567 DO iq=nqo+1, nqtot 562 568 iiq=niadv(iq) 563 varname='cum'//trim(tname(iiq)) 569 570 unt = "kg m-2" 571 varname='cum'//trim(tracers(iiq)%name) 564 572 WRITE (lunout,*) 'XIOS var=', iq, nqtot, varname 565 573 CALL xios_add_child(group_handle, child, varname) 566 CALL xios_set_attr(child, name=varname, unit="kg m-2") 567 varname='cumd'//trim(tname(iiq))//'_dry' 574 CALL xios_set_attr(child, name=varname, unit=unt) 575 576 unt = "kg m-2 s-1" 577 varname='cumd'//trim(tracers(iiq)%name)//'_dry' 568 578 CALL xios_add_child(group_handle, child, varname) 569 CALL xios_set_attr(child, name=varname, unit= "kg m-2 s-1")579 CALL xios_set_attr(child, name=varname, unit=unt) 570 580 ENDDO 571 581 ENDIF … … 573 583 #endif 574 584 #endif 585 575 586 ! ug la boucle qui suit ne sert qu'une fois, pour l'initialisation, sinon il n'y a toujours qu'un seul passage: 576 587 DO iinit=1, iinitend … … 600 611 ENDIf 601 612 CALL histwrite_phy(o_aire, zx_tmp_fi2d) 602 603 613 IF (vars_defined) THEN 604 614 DO i=1, klon -
LMDZ6/trunk/libf/phylmd/traclmdz_mod.F90
r3581 r4046 96 96 USE indice_sol_mod 97 97 USE print_control_mod, ONLY: lunout 98 USE strings_mod, ONLY: strLower 98 99 99 100 ! Input variables … … 175 176 !! iiq=niadv(it+2) ! jyg 176 177 iiq=niadv(it+nqo) ! jyg 177 IF ( tname(iiq) == "RN" ) THEN 178 id_rn=it ! radon 179 ELSE IF ( tname(iiq) == "PB") THEN 180 id_pb=it ! plomb 181 ! RomP >>> profil initial de PB210 182 open (ilesfil2,file='prof.pb210',status='old',iostat=irr2) 183 IF (irr2 == 0) THEN 184 read(ilesfil2,*) kradio2 185 print*,'number of levels for pb210 profile ',kradio2 186 do k=kradio2,1,-1 187 read (ilesfil2,*) plomb(:,k) 188 enddo 189 close(ilesfil2) 190 do k=1,klev 191 do i=1,klon 192 tr_seri(i,k,id_pb)=plomb(i,k) 193 !! print*, 'tr_seri',i,k,tr_seri(i,k,id_pb) 194 enddo 195 enddo 196 ELSE 197 print *, 'Prof.pb210 does not exist: use restart values' 198 ENDIF 199 ! RomP <<< 200 ELSE IF ( tname(iiq) == "Aga" .OR. tname(iiq) == "AGA" ) THEN 201 ! Age of stratospheric air 202 id_aga=it 203 radio(id_aga) = .FALSE. 204 aerosol(id_aga) = .FALSE. 205 pbl_flg(id_aga) = 0 206 207 ! Find the first model layer above 1.5km from the surface 208 IF (klev>=30) THEN 209 lev_1p5km=6 ! NB! This value is for klev=39 210 ELSE IF (klev>=10) THEN 211 lev_1p5km=5 ! NB! This value is for klev=19 212 ELSE 213 lev_1p5km=klev/2 214 END IF 215 ELSE IF ( tname(iiq) == "BE" .OR. tname(iiq) == "Be" .OR. & 216 tname(iiq) == "BE7" .OR. tname(iiq) == "Be7" ) THEN 217 ! Recherche du Beryllium 7 218 id_be=it 219 ALLOCATE( srcbe(klon,klev) ) 220 radio(id_be) = .TRUE. 221 aerosol(id_be) = .TRUE. ! le Be est un aerosol 222 !jyg le 13/03/2013 ; ajout de pplay en argument de init_be 223 !!! CALL init_be(pctsrf,masktr(:,id_be),tautr(id_be),vdeptr(id_be),scavtr(id_be),srcbe) 224 CALL init_be(pctsrf,pplay,masktr(:,id_be),tautr(id_be),vdeptr(id_be),scavtr(id_be),srcbe) 225 WRITE(lunout,*) 'Initialisation srcBe: OK' 226 ! RomP >>> profil initial de Be7 227 open (ilesfil,file='prof.be7',status='old',iostat=irr) 228 IF (irr == 0) THEN 229 read(ilesfil,*) kradio 230 print*,'number of levels for Be7 profile ',kradio 231 do k=kradio,1,-1 232 read (ilesfil,*) beryllium(:,k) 233 enddo 234 close(ilesfil) 235 do k=1,klev 236 do i=1,klon 237 tr_seri(i,k,id_be)=beryllium(i,k) 238 !! print*, 'tr_seri',i,k,tr_seri(i,k,id_be) 239 enddo 240 enddo 241 ELSE 242 print *, 'Prof.Be7 does not exist: use restart values' 243 ENDIF 244 ! RomP <<< 245 ELSE IF (tname(iiq)=="O3" .OR. tname(iiq)=="o3") THEN 246 ! Recherche de l'ozone : parametrization de la chimie par Cariolle 247 id_o3=it 248 CALL alloc_coefoz ! allocate ozone coefficients 249 CALL press_coefoz ! read input pressure levels 250 ELSE IF ( tname(iiq) == "pcsat" .OR. tname(iiq) == "Pcsat" ) THEN 251 id_pcsat=it 252 ELSE IF ( tname(iiq) == "pcocsat" .OR. tname(iiq) == "Pcocsat" ) THEN 253 id_pcocsat=it 254 ELSE IF ( tname(iiq) == "pcq" .OR. tname(iiq) == "Pcq" ) THEN 255 id_pcq=it 256 ELSE IF ( tname(iiq) == "pcs0" .OR. tname(iiq) == "Pcs0" ) THEN 257 id_pcs0=it 258 conv_flg(it)=0 ! No transport by convection for this tracer 259 ELSE IF ( tname(iiq) == "pcos0" .OR. tname(iiq) == "Pcos0" ) THEN 260 id_pcos0=it 261 conv_flg(it)=0 ! No transport by convection for this tracer 262 ELSE IF ( tname(iiq) == "pcq0" .OR. tname(iiq) == "Pcq0" ) THEN 263 id_pcq0=it 264 conv_flg(it)=0 ! No transport by convection for this tracer 265 ELSE 266 WRITE(lunout,*) 'This is an unknown tracer in LMDZ : ', trim(tname(iiq)) 267 END IF 178 print*,'###'//TRIM(tracers(iiq)%name)//'###' 179 print*,'###'//TRIM(strLower(tracers(iiq)%name))//'###' 180 SELECT CASE(strLower(tracers(iiq)%name)) 181 CASE("rn"); id_rn = it ! radon 182 CASE("pb"); id_pb = it ! plomb 183 CASE("aga"); id_aga = it ! Age of stratospheric air 184 CASE("be","be7");id_be = it ! Recherche du Beryllium 7 185 CASE("o3"); id_o3 = it ! Recherche de l'ozone 186 CASE("pcsat"); id_pcsat = it 187 CASE("pcocsat"); id_pcocsat= it 188 CASE("pcq"); id_pcq = it 189 CASE("pcs0"); id_pcs0 = it 190 CASE("pcos0"); id_pcos0 = it 191 CASE("pcq0"); id_pcq0 = it 192 CASE DEFAULT 193 WRITE(lunout,*) 'This is an unknown tracer in LMDZ : ', trim(tracers(iiq)%name) 194 END SELECT 195 196 SELECT CASE(strLower(tracers(iiq)%name)) 197 CASE("pb") !--- RomP >>> profil initial de PB210 198 OPEN(ilesfil2,file='prof.pb210',status='old',iostat=irr2) 199 IF(irr2 == 0) THEN 200 READ(ilesfil2,*) kradio2 201 WRITE(lunout,*)'number of levels for pb210 profile ',kradio2 202 DO k=kradio2,1,-1; READ (ilesfil2,*) plomb(:,k); END DO 203 CLOSE(ilesfil2) 204 tr_seri(:,:,id_pb) = plomb(:,:) 205 ELSE 206 WRITE(lunout,*)'Prof. Pb210 does not exist: use restart values' 207 END IF 208 CASE("aga") 209 radio(id_aga) = .FALSE. 210 aerosol(id_aga) = .FALSE. 211 pbl_flg(id_aga) = 0 212 ! Find the first model layer above 1.5km from the surface 213 IF (klev>=30) THEN 214 lev_1p5km=6 !--- NB: This value is for klev=39 215 ELSE IF (klev>=10) THEN 216 lev_1p5km=5 !--- NB: This value is for klev=19 217 ELSE 218 lev_1p5km=klev/2 219 END IF 220 CASE("be","be7") 221 ALLOCATE( srcbe(klon,klev) ) 222 radio(id_be) = .TRUE. 223 aerosol(id_be) = .TRUE. !--- Le Be est un aerosol 224 CALL init_be(pctsrf,pplay,masktr(:,id_be),tautr(id_be),vdeptr(id_be),scavtr(id_be),srcbe) 225 WRITE(lunout,*) 'Initialisation srcBe: OK' 226 !--- RomP >>> profil initial de Be7 227 OPEN(ilesfil,file='prof.be7',status='old',iostat=irr) 228 IF(irr == 0) THEN 229 READ(ilesfil,*) kradio 230 WRITE(lunout,*)'number of levels for Be7 profile ',kradio 231 DO k=kradio,1,-1; READ(ilesfil,*) beryllium(:,k); END DO 232 CLOSE(ilesfil) 233 tr_seri(:,:,id_be)=beryllium(:,:) 234 ELSE 235 WRITE(lunout,*)'Prof. Be7 does not exist: use restart values' 236 END IF 237 CASE("o3") !--- Parametrisation par la chimie de Cariolle 238 CALL alloc_coefoz !--- Allocate ozone coefficients 239 CALL press_coefoz !--- Read input pressure levels 240 CASE("pcs0","pcos0","pcq0") 241 conv_flg(it)=0 !--- No transport by convection for this tracer 242 END SELECT 268 243 END DO 269 244 … … 309 284 IF (zero) THEN 310 285 ! The tracer was not found in restart file or it was equal zero everywhere. 311 WRITE(lunout,*) "The tracer ",trim(t name(iiq))," will be initialized"286 WRITE(lunout,*) "The tracer ",trim(tracers(iiq)%name)," will be initialized" 312 287 IF (it==id_pcsat .OR. it==id_pcq .OR. & 313 288 it==id_pcs0 .OR. it==id_pcq0) THEN -
LMDZ6/trunk/libf/phylmdiso/infotrac_phy.F90
r4026 r4046 7 7 ! the dynamics (could be further cleaned) and is initialized using values 8 8 ! provided by the dynamics 9 10 USE readTracFiles_mod, ONLY: trac_type, maxlen, delPhase 9 11 10 12 ! nqtot : total number of tracers and higher order of moment, water vapor and liquid included … … 41 43 !$OMP THREADPRIVATE(nqperes) 42 44 43 ! Name variables 44 INTEGER,PARAMETER :: tname_lenmax=128 45 CHARACTER(len=tname_lenmax), ALLOCATABLE, DIMENSION(:), SAVE :: tname ! tracer short name for restart and diagnostics 46 CHARACTER(len=tname_lenmax+3), ALLOCATABLE, DIMENSION(:), SAVE :: ttext ! tracer long name for diagnostics 47 !$OMP THREADPRIVATE(tname,ttext) 48 49 !! iadv : index of trasport schema for each tracer 50 ! INTEGER, ALLOCATABLE, DIMENSION(:), SAVE :: iadv 45 ! Tracers parameters 46 TYPE(trac_type), TARGET, ALLOCATABLE, SAVE :: tracers(:) 47 !$OMP THREADPRIVATE(tracers) 51 48 52 49 ! niadv : vector keeping the coorspondance between all tracers(nqtot) treated in the … … 107 104 CONTAINS 108 105 109 SUBROUTINE init_infotrac_phy(nqtot_,nqo_,nbtr_,nqtottr_,nqCO2_,t name_,ttext_,type_trac_,&106 SUBROUTINE init_infotrac_phy(nqtot_,nqo_,nbtr_,nqtottr_,nqCO2_,tracers_,type_trac_,& 110 107 niadv_,conv_flg_,pbl_flg_,solsym_,& 111 108 nqfils_,nqdesc_,nqdesc_tot_,iqfils_,iqpere_,& … … 139 136 INTEGER,INTENT(IN) :: id_BIN01_strat_ 140 137 #endif 141 CHARACTER(len=*),INTENT(IN) :: tname_(nqtot_) ! tracer short name for restart and diagnostics 142 CHARACTER(len=*),INTENT(IN) :: ttext_(nqtot_) ! tracer long name for diagnostics 138 CHARACTER(len=*),INTENT(IN) :: tracers_(nqtot_) ! tracers descriptors 143 139 CHARACTER(len=*),INTENT(IN) :: type_trac_ 144 140 INTEGER,INTENT(IN) :: niadv_ (nqtot_) ! equivalent dyn / physique … … 179 175 nqCO2=nqCO2_ 180 176 nqtottr=nqtottr_ 177 ALLOCATE(tracers(nqtot)); tracers(:) = tracers_(:) 181 178 #ifdef CPP_StratAer 182 179 nbtr_bin=nbtr_bin_ … … 187 184 id_BIN01_strat=id_BIN01_strat_ 188 185 #endif 189 ALLOCATE(tname(nqtot))190 tname(:) = tname_(:)191 ALLOCATE(ttext(nqtot))192 ttext(:) = ttext_(:)193 186 type_trac = type_trac_ 194 187 ALLOCATE(niadv(nqtot)) -
LMDZ6/trunk/libf/phylmdiso/phyetat0.F90
r4040 r4046 31 31 USE geometry_mod, ONLY : longitude_deg, latitude_deg 32 32 USE iostart, ONLY : close_startphy, get_field, get_var, open_startphy 33 USE infotrac_phy, only: nbtr, nqo, type_trac, t name, niadv, &33 USE infotrac_phy, only: nbtr, nqo, type_trac, tracers, niadv, & 34 34 itr_indice ! C Risi 35 35 USE traclmdz_mod, ONLY : traclmdz_from_restart … … 476 476 iq=itr_indice(it) 477 477 iiq=niadv(iq) ! jyg 478 found=phyetat0_get(1,trs(:,it),"trs_"// tname(iiq), &479 "Surf trac"//tname(iiq),0.)478 found=phyetat0_get(1,trs(:,it),"trs_"//TRIM(tracers(iiq)%name), & 479 "Surf trac"//TRIM(tracers(iiq)%name),0.) 480 480 ENDDO 481 481 CALL traclmdz_from_restart(trs) … … 489 489 found=phyetat0_get(1,co2_send,"co2_send","co2 send",co2_ppm) 490 490 ENDIF 491 ENDIF !IF (type_trac == 'lmdz') THEN491 ENDIF 492 492 493 493 #ifdef ISO -
LMDZ6/trunk/libf/phylmdiso/phyredem.F90
r3940 r4046 38 38 USE iostart, ONLY: open_restartphy, close_restartphy, enddef_restartphy, put_field, put_var 39 39 USE traclmdz_mod, ONLY : traclmdz_to_restart 40 USE infotrac_phy, ONLY: type_trac, niadv, t name, nbtr, nqo,itr_indice40 USE infotrac_phy, ONLY: type_trac, niadv, tracers, nbtr, nqo,itr_indice 41 41 #ifdef ISO 42 42 USE infotrac_phy, ONLY: itr_indice,niso,ntraciso … … 350 350 iq=itr_indice(it) ! jyg 351 351 iiq=niadv(iq) ! jyg 352 CALL put_field(pass,"trs_"//t name(iiq), "", trs(:, it))352 CALL put_field(pass,"trs_"//tracers(iiq)%name, "", trs(:, it)) 353 353 END DO 354 354 IF (carbon_cycle_cpl) THEN … … 407 407 IF (pass==2) CALL close_restartphy 408 408 ENDDO ! DO pass=1,2 ! pass=1 netcdf definition ; pass=2 netcdf write 409 410 411 409 412 410 !$OMP BARRIER -
LMDZ6/trunk/libf/phylmdiso/phys_output_mod.F90
r3940 r4046 35 35 USE iophy 36 36 USE dimphy 37 USE infotrac_phy, ONLY: nqtot, nqo, niadv, t name, ttext, type_trac, &37 USE infotrac_phy, ONLY: nqtot, nqo, niadv, tracers, type_trac, & 38 38 nqtottr,itr_indice ! C Risi 39 USE strings_mod, ONLY: maxlen 39 40 USE ioipsl 40 41 USE phys_cal_mod, only : hour, calend … … 124 125 125 126 #ifdef ISO 126 INTEGER :: ixt,iiso,izone 127 CHARACTER*50 :: striso_sortie 128 integer :: lnblnk 129 #endif 127 INTEGER :: ixt,iiso,izone 128 CHARACTER(LEN=50) :: outiso 129 CHARACTER(LEN=20) :: unit 130 #endif 131 CHARACTER(LEN=maxlen) :: tnam, lnam, dn 132 INTEGER :: flag(nfiles) 130 133 131 134 !!!!!!!!!! stockage dans une region limitee pour chaque fichier !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! … … 534 537 write(lunout,*) 'itr_indice=',itr_indice 535 538 ! IF (nqtot>=nqo+1) THEN 536 IF (nqtottr>=1) THEN539 IF (nqtottr>=1) THEN 537 540 ! 538 541 !DO iq=nqo+1,nqtot 539 542 ! C Risi: on modifie la boucle 540 doitr=1,nqtottr ! C Risi543 DO itr=1,nqtottr ! C Risi 541 544 iq=itr_indice(itr) ! C Risi 542 545 write(*,*) 'phys_output_mid 503: itr=',itr 543 546 544 547 iiq=niadv(iq) 545 o_trac(itr) = ctrl_out((/ 1, 5, 5, 5, 10, 10, 11, 11, 11, 11 /), & 546 tname(iiq),'Tracer '//ttext(iiq), "-", & 547 (/ '', '', '', '', '', '', '', '', '', '' /)) 548 o_dtr_vdf(itr) = ctrl_out((/ 4, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 549 'd'//trim(tname(iq))//'_vdf', & 550 'Tendance tracer '//ttext(iiq), "-" , & 551 (/ '', '', '', '', '', '', '', '', '', '' /)) 552 553 o_dtr_the(itr) = ctrl_out((/ 5, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 554 'd'//trim(tname(iq))//'_the', & 555 'Tendance tracer '//ttext(iiq), "-", & 556 (/ '', '', '', '', '', '', '', '', '', '' /)) 557 558 o_dtr_con(itr) = ctrl_out((/ 5, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 559 'd'//trim(tname(iq))//'_con', & 560 'Tendance tracer '//ttext(iiq), "-", & 561 (/ '', '', '', '', '', '', '', '', '', '' /)) 562 563 o_dtr_lessi_impa(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 564 'd'//trim(tname(iq))//'_lessi_impa', & 565 'Tendance tracer '//ttext(iiq), "-", & 566 (/ '', '', '', '', '', '', '', '', '', '' /)) 567 568 o_dtr_lessi_nucl(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 569 'd'//trim(tname(iq))//'_lessi_nucl', & 570 'Tendance tracer '//ttext(iiq), "-", & 571 (/ '', '', '', '', '', '', '', '', '', '' /)) 572 573 o_dtr_insc(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 574 'd'//trim(tname(iq))//'_insc', & 575 'Tendance tracer '//ttext(iiq), "-", & 576 (/ '', '', '', '', '', '', '', '', '', '' /)) 577 578 o_dtr_bcscav(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 579 'd'//trim(tname(iq))//'_bcscav', & 580 'Tendance tracer '//ttext(iiq), "-", & 581 (/ '', '', '', '', '', '', '', '', '', '' /)) 582 583 o_dtr_evapls(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 584 'd'//trim(tname(iq))//'_evapls', & 585 'Tendance tracer '//ttext(iiq), "-", & 586 (/ '', '', '', '', '', '', '', '', '', '' /)) 587 588 o_dtr_ls(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 589 'd'//trim(tname(iq))//'_ls', & 590 'Tendance tracer '//ttext(iiq), "-", & 591 (/ '', '', '', '', '', '', '', '', '', '' /)) 592 593 o_dtr_trsp(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 594 'd'//trim(tname(iq))//'_trsp', & 595 'Tendance tracer '//ttext(iiq), "-", & 596 (/ '', '', '', '', '', '', '', '', '', '' /)) 597 598 o_dtr_sscav(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 599 'd'//trim(tname(iq))//'_sscav', & 600 'Tendance tracer '//ttext(iiq), "-", & 601 (/ '', '', '', '', '', '', '', '', '', '' /)) 602 603 o_dtr_sat(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 604 'd'//trim(tname(iq))//'_sat', & 605 'Tendance tracer '//ttext(iiq), "-", & 606 (/ '', '', '', '', '', '', '', '', '', '' /)) 607 608 o_dtr_uscav(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 609 'd'//trim(tname(iq))//'_uscav', & 610 'Tendance tracer '//ttext(iiq), "-", & 611 (/ '', '', '', '', '', '', '', '', '', '' /)) 612 613 o_dtr_dry(itr) = ctrl_out((/ 7, 7, 7, 7, 10, 10, 11, 11, 11, 11 /), & 614 'cum'//'d'//trim(tname(iq))//'_dry', & 615 'tracer tendency dry deposition'//ttext(iiq), "-", & 616 (/ '', '', '', '', '', '', '', '', '', '' /)) 617 618 o_trac_cum(itr) = ctrl_out((/ 1, 4, 10, 10, 10, 10, 11, 11, 11, 11 /), & 619 'cum'//tname(iiq),& 620 'Cumulated tracer '//ttext(iiq), "-", & 621 (/ '', '', '', '', '', '', '', '', '', '' /)) 622 ENDDO 623 ENDIF 548 dn = 'd'//TRIM(tracers(iiq)%name)//'_' 549 550 flag = [1, 5, 5, 5, 10, 10, 11, 11, 11, 11] 551 lnam = 'Tracer '//TRIM(tracers(iiq)%longName) 552 tnam = TRIM(tracers(iiq)%name); o_trac (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 553 554 flag = [4, 7, 7, 7, 10, 10, 11, 11, 11, 11] 555 lnam = 'Tendance tracer '//TRIM(tracers(iiq)%longName) 556 tnam = TRIM(dn)//'vdf'; o_dtr_vdf (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 557 558 flag = [5, 7, 7, 7, 10, 10, 11, 11, 11, 11] 559 tnam = TRIM(dn)//'the'; o_dtr_the (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 560 tnam = TRIM(dn)//'con'; o_dtr_con (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 561 562 flag = [7, 7, 7, 7, 10, 10, 11, 11, 11, 11] 563 tnam = TRIM(dn)//'lessi_impa'; o_dtr_lessi_impa(itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 564 tnam = TRIM(dn)//'lessi_nucl'; o_dtr_lessi_nucl(itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 565 tnam = TRIM(dn)//'insc'; o_dtr_insc (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 566 tnam = TRIM(dn)//'bcscav'; o_dtr_bcscav (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 567 tnam = TRIM(dn)//'evapls'; o_dtr_evapls (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 568 tnam = TRIM(dn)//'ls'; o_dtr_ls (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 569 tnam = TRIM(dn)//'trsp'; o_dtr_trsp (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 570 tnam = TRIM(dn)//'sscav'; o_dtr_sscav (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 571 tnam = TRIM(dn)//'sat'; o_dtr_sat (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 572 tnam = TRIM(dn)//'uscav'; o_dtr_uscav (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 573 574 lnam = 'tracer tendency dry deposition'//TRIM(tracers(iiq)%longName) 575 tnam = 'cum'//TRIM(dn)//'dry'; o_dtr_dry (itr) = ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 576 577 flag = [1, 4, 10, 10, 10, 10, 11, 11, 11, 11] 578 lnam = 'Cumulated tracer '//TRIM(tracers(iiq)%longName) 579 tnam = 'cum'//TRIM(tracers(iiq)%name); o_trac_cum(itr)= ctrl_out(flag, tnam, lnam, "-", [('',i=1,nfiles)]) 580 ENDDO 581 ENDIF 624 582 625 583 ENDDO ! iff … … 627 585 write(*,*) 'phys_output_mid 589' 628 586 #ifdef ISO 629 do ixt=1,ntraciso630 if (ixt.le.niso) then587 do ixt=1,ntraciso 588 if (ixt.le.niso) then 631 589 striso_sortie=striso(ixt) 632 else590 else 633 591 #ifdef ISOTRAC 634 592 iiso=index_iso(ixt) … … 639 597 stop 640 598 #endif 641 endif 642 643 o_xtprecip(ixt)=ctrl_out((/ 1, 1, 1, 10, 5, 10, 11, 11, 11, 11/), & 644 'precip'//striso_sortie(1:lnblnk(striso_sortie)), & 645 'Precip Totale liq+sol', 'kg/(s*m2)', (/ ('', i=1, 10) /)) 646 o_xtplul(ixt) = ctrl_out((/ 1, 1, 1, 10, 10, 10, 11, 11, 11, 11/), & 647 'plul'//striso_sortie(1:lnblnk(striso_sortie)), & 648 'Large-scale Precip.', 'kg/(s*m2)', (/ ('', i=1, 10) /)) 649 o_xtpluc(ixt) = ctrl_out((/ 1, 1, 1, 10, 5, 10, 11, 11, 11, 11/), & 650 'pluc'//striso_sortie(1:lnblnk(striso_sortie)), & 651 'Convective Precip.', 'kg/(s*m2)', (/ ('', i=1, 10) /)) 652 o_xtevap(ixt) = ctrl_out((/ 1, 1, 10, 10, 10, 10, 11, 11, 11, 11/), & 653 'evap'//striso_sortie(1:lnblnk(striso_sortie)), & 654 'Evaporat', 'kg/(s*m2)', (/ ('', i=1, 10) /)) 655 o_xtovap(ixt) = ctrl_out((/ 2, 3, 4, 10, 10, 10, 11, 11, 11, 11/), & 656 'ovap'//striso_sortie(1:lnblnk(striso_sortie)), & 657 'Specific humidity', 'kg/kg', (/ ('', i=1, 10) /)) 658 o_xtoliq(ixt) = ctrl_out((/ 2, 3, 4, 10, 10, 10, 11, 11, 11, 11/), & 659 'oliq'//striso_sortie(1:lnblnk(striso_sortie)), & 660 'Liquid water', 'kg/kg', (/ ('', i=1, 10) /)) 661 o_xtcond(ixt) = ctrl_out((/ 2, 3, 4, 10, 10, 10, 11, 11, 11, 11/), & 662 'ocond'//striso_sortie(1:lnblnk(striso_sortie)), & 663 'Condensed water', 'kg/kg', (/ ('', i=1, 10) /)) 664 o_dxtdyn(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 665 'dqdyn'//striso_sortie(1:lnblnk(striso_sortie)), & 666 'Dynamics dQ', '(kg/kg)/s', (/ ('', i=1, 10) /)) 667 o_dxtldyn(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 668 'dqldyn'//striso_sortie(1:lnblnk(striso_sortie)), & 669 'Dynamics dQL', '(kg/kg)/s', (/ ('', i=1, 10) /)) 670 o_dxtcon(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 671 'dqcon'//striso_sortie(1:lnblnk(striso_sortie)), & 672 'Convection dQ', '(kg/kg)/s', (/ ('', i=1, 10) /)) 673 o_dxteva(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 674 'dqeva'//striso_sortie(1:lnblnk(striso_sortie)), & 675 'Reevaporation dQ', '(kg/kg)/s', (/ ('', i=1, 10) /)) 676 o_dxtlsc(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 677 'dqlsc'//striso_sortie(1:lnblnk(striso_sortie)), & 678 'Condensation dQ', '(kg/kg)/s', (/ ('', i=1, 10) /)) 679 o_dxtajs(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 680 'dqajs'//striso_sortie(1:lnblnk(striso_sortie)), & 681 'Dry adjust. dQ', '(kg/kg)/s', (/ ('', i=1, 10) /)) 682 o_dxtvdf(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 683 'dqvdf'//striso_sortie(1:lnblnk(striso_sortie)), & 684 'Boundary-layer dQ', '(kg/kg)/s', (/ ('', i=1, 10) /)) 685 o_dxtthe(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 686 'dqthe'//striso_sortie(1:lnblnk(striso_sortie)), & 687 'Thermal dQ', '(kg/kg)/s', (/ ('', i=1, 10) /)) 688 689 IF (ok_qch4) then 690 o_dxtch4(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 691 'dqch4'//striso_sortie(1:lnblnk(striso_sortie)), & 692 'H2O due to CH4 oxidation & photolysis', '(kg/kg)/s', (/ ('', i=1, 10) /)) 693 endif ! IF (ok_qch4) then 694 695 if (ixt.eq.iso_HTO) then 696 o_dxtprod_nucl(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 697 'dqprodnucl'//striso_sortie(1:lnblnk(striso_sortie)), & 698 'dHTO/dt due to nuclear production', '(kg/kg)/s', (/ ('', i=1, 10) /)) 699 o_dxtcosmo(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 700 'dqcosmo'//striso_sortie(1:lnblnk(striso_sortie)), & 701 'dHTO/dt due to cosmogenic production', '(kg/kg)/s', (/ ('', i=1, 10) /)) 702 o_dxtdecroiss(ixt) = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 703 'dqdecroiss'//striso_sortie(1:lnblnk(striso_sortie)), & 704 'dHTO/dt due to radiative destruction', '(kg/kg)/s', (/ ('', i=1, 10) /)) 705 endif !if (ixt.eq.iso_HTO) then 706 enddo !do ixt=1,niso 599 endif 600 601 flag = [1, 1, 1, 10, 5, 10, 11, 11, 11, 11]; unit = 'kg/(s*m2)' 602 o_xtprecip(ixt)=ctrl_out(flag, 'precip'//TRIM(outiso), 'Precip Totale liq+sol', unit, [('',i=1,nfiles)]) 603 o_xtpluc (ixt)=ctrl_out(flag, 'pluc'//TRIM(outiso), 'Convective Precip.', unit, [('',i=1,nfiles)]) 604 605 flag = [1, 1, 1, 10, 10, 10, 11, 11, 11, 11] 606 o_xtplul (ixt)=ctrl_out(flag, 'plul'//TRIM(outiso), 'Large-scale Precip.', unit, [('',i=1,nfiles)]) 607 o_xtevap (ixt)=ctrl_out(flag, 'evap'//TRIM(outiso), 'Evaporat.', unit, [('',i=1,nfiles)]) 608 609 flag = [2, 3, 4, 10, 10, 10, 11, 11, 11, 11]; unit = 'kg/kg' 610 o_xtovap (ixt)=ctrl_out(flag, 'ovap'//TRIM(outiso), 'Specific humidity', unit, [('',i=1,nfiles)]) 611 o_xtoliq (ixt)=ctrl_out(flag, 'oliq'//TRIM(outiso), 'Liquid water', unit, [('',i=1,nfiles)]) 612 o_xtcond (ixt)=ctrl_out(flag, 'ocond'//TRIM(outiso), 'Condensed water', unit, [('',i=1,nfiles)]) 613 614 flag = [4, 10, 10, 10, 10, 10, 11, 11, 11, 11]; unit = '(kg/kg)/s' 615 o_dxtdyn (ixt)=ctrl_out(flag, 'dqdyn'//TRIM(outiso), 'Dynamics dQ', unit, [('',i=1,nfiles)]) 616 o_dxtldyn (ixt)=ctrl_out(flag, 'dqldyn'//TRIM(outiso), 'Dynamics dQL', unit, [('',i=1,nfiles)]) 617 o_dxtcon (ixt)=ctrl_out(flag, 'dqcon'//TRIM(outiso), 'Convection dQ', unit, [('',i=1,nfiles)]) 618 o_dxteva (ixt)=ctrl_out(flag, 'dqeva'//TRIM(outiso), 'Reevaporation dQ', unit, [('',i=1,nfiles)]) 619 o_dxtlsc (ixt)=ctrl_out(flag, 'dqlsc'//TRIM(outiso), 'Condensation dQ', unit, [('',i=1,nfiles)]) 620 o_dxtajs (ixt)=ctrl_out(flag, 'dqajs'//TRIM(outiso), 'Dry adjust. dQ', unit, [('',i=1,nfiles)]) 621 o_dxtvdf (ixt)=ctrl_out(flag, 'dqvdf'//TRIM(outiso), 'Boundary-layer dQ', unit, [('',i=1,nfiles)]) 622 o_dxtthe (ixt)=ctrl_out(flag, 'dqthe'//TRIM(outiso), 'Thermal dQ', unit, [('',i=1,nfiles)]) 623 624 IF(ok_qch4) o_dxtch4(ixt)=ctrl_out(flag, 'dqch4'//TRIM(outiso), 'H2O due to CH4 oxidation & photolysis', & 625 unit, [('',i=1,nfiles)]) 626 IF(ixt == iso_HTO) THEN 627 o_dxtprod_nucl(ixt)=ctrl_out(flag, 'dqprodnucl'//TRIM(outiso), 'dHTO/dt due to nuclear production', & 628 unit, [('',i=1,nfiles)]) 629 o_dxtcosmo (ixt)=ctrl_out(flag, 'dqcosmo'//TRIM(outiso), 'dHTO/dt due to cosmogenic production', & 630 unit, [('',i=1,nfiles)]) 631 o_dxtdecroiss (ixt)=ctrl_out(flag, 'dqdecroiss'//TRIM(outiso), 'dHTO/dt due to radiative destruction', & 632 END IF 633 enddo !do ixt=1,niso 707 634 #endif 708 635 write(*,*) 'phys_output_mid 596' -
LMDZ6/trunk/libf/phylmdiso/phys_output_write_mod.F90
r4040 r4046 25 25 26 26 USE dimphy, ONLY: klon, klev, klevp1 27 USE infotrac_phy, ONLY: nbtr 27 USE infotrac_phy, ONLY: nbtr, nqtot, nqo, type_trac, tracers, niadv, & 28 nqtottr,itr_indice 29 USE strings_mod, ONLY: maxlen 28 30 USE mod_phys_lmdz_para, ONLY: is_north_pole_phy,is_south_pole_phy 29 31 USE mod_grid_phy_lmdz, ONLY : nbp_lon, nbp_lat … … 383 385 USE pbl_surface_mod, ONLY: snow 384 386 USE indice_sol_mod, ONLY: nbsrf 385 USE infotrac_phy, ONLY: nqtot, nqo, type_trac, tname, niadv, &386 nqtottr,itr_indice ! C Risi: ajout nqtottr387 387 #ifdef ISO 388 388 USE infotrac_phy, only: ntraciso,niso,nqtottr … … 467 467 INTEGER ISW 468 468 CHARACTER*1 ch1 469 CHARACTER *20 varname469 CHARACTER(LEN=maxlen) :: varname, dn 470 470 471 471 #ifdef CPP_XIOS … … 538 538 DO iq=nqo+1, nqtot 539 539 iiq=niadv(iq) 540 varname=trim(tname(iiq)) 541 WRITE (lunout,*) 'XIOS var=', nqo, iq, nqtot, varname 540 dn = 'd'//TRIM(tracers(iiq)%name)//'_' 541 WRITE (lunout,*) 'XIOS var=', nqo, iq, nqtot, tracers(iiq)%name 542 543 unt = "kg kg-1" 544 varname=trim(tracers(iiq)%name) 542 545 CALL xios_add_child(group_handle, child, varname) 543 CALL xios_set_attr(child, name=varname, unit="kg kg-1") 544 varname='d'//trim(tname(iiq))//'_vdf' 546 CALL xios_set_attr(child, name=varname, unit=unt) 547 548 unt = "kg kg-1 s-1" 549 varname=TRIM(dn)//'vdf' 545 550 CALL xios_add_child(group_handle, child, varname) 546 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")547 varname= 'd'//trim(tname(iiq))//'_the'551 CALL xios_set_attr(child, name=varname, unit=unt) 552 varname=TRIM(dn)//'the' 548 553 CALL xios_add_child(group_handle, child, varname) 549 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")550 varname= 'd'//trim(tname(iiq))//'_con'554 CALL xios_set_attr(child, name=varname, unit=unt) 555 varname=TRIM(dn)//'con' 551 556 CALL xios_add_child(group_handle, child, varname) 552 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")553 varname= 'd'//trim(tname(iiq))//'_lessi_impa'557 CALL xios_set_attr(child, name=varname, unit=unt) 558 varname=TRIM(dn)//'lessi_impa' 554 559 CALL xios_add_child(group_handle, child, varname) 555 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")556 varname= 'd'//trim(tname(iiq))//'_lessi_nucl'560 CALL xios_set_attr(child, name=varname, unit=unt) 561 varname=TRIM(dn)//'lessi_nucl' 557 562 CALL xios_add_child(group_handle, child, varname) 558 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")559 varname= 'd'//trim(tname(iiq))//'_insc'563 CALL xios_set_attr(child, name=varname, unit=unt) 564 varname=TRIM(dn)//'insc' 560 565 CALL xios_add_child(group_handle, child, varname) 561 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")562 varname= 'd'//trim(tname(iiq))//'_bcscav'566 CALL xios_set_attr(child, name=varname, unit=unt) 567 varname=TRIM(dn)//'bcscav' 563 568 CALL xios_add_child(group_handle, child, varname) 564 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")565 varname= 'd'//trim(tname(iiq))//'_evapls'569 CALL xios_set_attr(child, name=varname, unit=unt) 570 varname=TRIM(dn)//'evapls' 566 571 CALL xios_add_child(group_handle, child, varname) 567 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")568 varname= 'd'//trim(tname(iiq))//'_ls'572 CALL xios_set_attr(child, name=varname, unit=unt) 573 varname=TRIM(dn)//'ls' 569 574 CALL xios_add_child(group_handle, child, varname) 570 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")571 varname= 'd'//trim(tname(iiq))//'_trsp'575 CALL xios_set_attr(child, name=varname, unit=unt) 576 varname=TRIM(dn)//'trsp' 572 577 CALL xios_add_child(group_handle, child, varname) 573 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")574 varname= 'd'//trim(tname(iiq))//'_sscav'578 CALL xios_set_attr(child, name=varname, unit=unt) 579 varname=TRIM(dn)//'sscav' 575 580 CALL xios_add_child(group_handle, child, varname) 576 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")577 varname= 'd'//trim(tname(iiq))//'_sat'581 CALL xios_set_attr(child, name=varname, unit=unt) 582 varname=TRIM(dn)//'sat' 578 583 CALL xios_add_child(group_handle, child, varname) 579 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")580 varname= 'd'//trim(tname(iiq))//'_uscav'584 CALL xios_set_attr(child, name=varname, unit=unt) 585 varname=TRIM(dn)//'uscav' 581 586 CALL xios_add_child(group_handle, child, varname) 582 CALL xios_set_attr(child, name=varname, unit= "kg kg-1 s-1")587 CALL xios_set_attr(child, name=varname, unit=unt) 583 588 ENDDO 584 589 !On ajoute les variables 2D traceurs par l interface fortran … … 587 592 DO iq=nqo+1, nqtot 588 593 iiq=niadv(iq) 589 varname='cum'//trim(tname(iiq)) 594 595 unt = "kg m-2" 596 varname='cum'//trim(tracers(iiq)%name) 590 597 WRITE (lunout,*) 'XIOS var=', iq, nqtot, varname 591 598 CALL xios_add_child(group_handle, child, varname) 592 CALL xios_set_attr(child, name=varname, unit="kg m-2") 593 varname='cumd'//trim(tname(iiq))//'_dry' 599 CALL xios_set_attr(child, name=varname, unit=unt) 600 601 unt = "kg m-2 s-1" 602 varname='cumd'//trim(tracers(iiq)%name)//'_dry' 594 603 CALL xios_add_child(group_handle, child, varname) 595 CALL xios_set_attr(child, name=varname, unit= "kg m-2 s-1")604 CALL xios_set_attr(child, name=varname, unit=unt) 596 605 ENDDO 597 606 ENDIF
Note: See TracChangeset
for help on using the changeset viewer.