Ignore:
Timestamp:
Jul 2, 2025, 12:00:08 PM (4 days ago)
Author:
dcugnet
Message:
  • Use REAL(KIND=REAL32) and REAL(KIND=REAL64) Iinstead of REAL and DOUBLE PRECISION

to avoid ambiguity problems in generic procedure when reals are promoted to doubles.

  • generic "num2str" replaces "str2int", "str2real", "str2dble" and "str2bool" functions.
Location:
LMDZ6/trunk/libf/phylmd
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/trunk/libf/phylmd/infotrac_phy.F90

    r5487 r5748  
    33MODULE infotrac_phy
    44
    5    USE       strings_mod, ONLY: msg, maxlen, cat, dispTable, int2str, bool2str, strStack, strParse, strCount, strIdx
     5   USE       strings_mod, ONLY: msg, maxlen, cat, dispTable, num2str, strStack, strParse, strCount, strIdx
    66   USE readTracFiles_mod, ONLY: trac_type, readTracersFiles, tracers,  addPhase,  addKey, iH2O,  &
    77       isoSelect,  indexUpdate, isot_type, testTracersFiles, isotope,  delPhase,  getKey, tran0, &
     
    271271   IF( nqtot /= nqtrue ) THEN
    272272      CALL msg('The choice of advection scheme for one or more tracers makes it necessary to add tracers')
    273       CALL msg('The number of true tracers is '//TRIM(int2str(nqtrue)))
    274       CALL msg('The total number of tracers needed is '//TRIM(int2str(nqtot)))
     273      CALL msg('The number of true tracers is '//TRIM(num2str(nqtrue)))
     274      CALL msg('The total number of tracers needed is '//TRIM(num2str(nqtot)))
    275275   END IF
    276276
     
    365365   !=== DISPLAY THE RESULTS
    366366   IF(.NOT.is_master) RETURN
    367    CALL msg('nqo    = '//TRIM(int2str(nqo)),    modname)
    368    CALL msg('nbtr   = '//TRIM(int2str(nbtr)),   modname)
    369    CALL msg('nqtrue = '//TRIM(int2str(nqtrue)), modname)
    370    CALL msg('nqtot  = '//TRIM(int2str(nqtot)),  modname)
    371    CALL msg('niso   = '//TRIM(int2str(niso)),   modname)
    372    CALL msg('ntiso  = '//TRIM(int2str(ntiso)),  modname)
    373    CALL msg('nqCO2  = '//TRIM(int2str(nqCO2)),  modname, CPPKEY_INCA)
    374    CALL msg('nqINCA = '//TRIM(int2str(nqINCA)), modname, CPPKEY_INCA)
     367   CALL msg('nqo    = '//TRIM(num2str(nqo)),    modname)
     368   CALL msg('nbtr   = '//TRIM(num2str(nbtr)),   modname)
     369   CALL msg('nqtrue = '//TRIM(num2str(nqtrue)), modname)
     370   CALL msg('nqtot  = '//TRIM(num2str(nqtot)),  modname)
     371   CALL msg('niso   = '//TRIM(num2str(niso)),   modname)
     372   CALL msg('ntiso  = '//TRIM(num2str(ntiso)),  modname)
     373   CALL msg('nqCO2  = '//TRIM(num2str(nqCO2)),  modname, CPPKEY_INCA)
     374   CALL msg('nqINCA = '//TRIM(num2str(nqINCA)), modname, CPPKEY_INCA)
    375375   t => tracers
    376376   CALL msg('Information stored in '//TRIM(modname)//': ', modname)
    377377   IF(dispTable('issssssssiiiiiiii', ['iq  ', 'name', 'lNam', 'g0Nm', 'prnt', 'type', 'phas', 'comp',      &
    378378                              'isPh', 'iGen', 'iqPr', 'nqDe', 'nqCh', 'iGrp', 'iNam', 'iZon', 'iPha'],     &
    379       cat(t%name, t%longName, t%gen0Name, t%parent, t%type, t%phase, t%component, bool2str(t%isInPhysics)),&
     379      cat(t%name, t%longName, t%gen0Name, t%parent, t%type, t%phase, t%component, num2str(t%isInPhysics)), &
    380380      cat([(iq, iq=1, nqtot)], t%iGeneration, t%iqParent, t%nqDescen, t%nqChildren, t%iso_iGroup,          &
    381381                  t%iso_iName, t%iso_iZone, t%iso_iPhase), nColMax=maxTableWidth, nHead=2, sub=modname))   &
     
    390390
    391391   IF(CPPKEY_STRATAER .AND. type_trac == 'coag') THEN
    392       CALL msg('nbtr_bin       ='//TRIM(int2str(nbtr_bin      )), modname)
    393       CALL msg('nbtr_sulgas    ='//TRIM(int2str(nbtr_sulgas   )), modname)
    394       CALL msg('id_BIN01_strat ='//TRIM(int2str(id_BIN01_strat)), modname)
    395       CALL msg('id_OCS_strat   ='//TRIM(int2str(id_OCS_strat  )), modname)
    396       CALL msg('id_SO2_strat   ='//TRIM(int2str(id_SO2_strat  )), modname)
    397       CALL msg('id_H2SO4_strat ='//TRIM(int2str(id_H2SO4_strat)), modname)
    398       CALL msg('id_TEST_strat  ='//TRIM(int2str(id_TEST_strat )), modname)
     392      CALL msg('nbtr_bin       ='//TRIM(num2str(nbtr_bin      )), modname)
     393      CALL msg('nbtr_sulgas    ='//TRIM(num2str(nbtr_sulgas   )), modname)
     394      CALL msg('id_BIN01_strat ='//TRIM(num2str(id_BIN01_strat)), modname)
     395      CALL msg('id_OCS_strat   ='//TRIM(num2str(id_OCS_strat  )), modname)
     396      CALL msg('id_SO2_strat   ='//TRIM(num2str(id_SO2_strat  )), modname)
     397      CALL msg('id_H2SO4_strat ='//TRIM(num2str(id_H2SO4_strat)), modname)
     398      CALL msg('id_TEST_strat  ='//TRIM(num2str(id_TEST_strat )), modname)
    399399   END IF
    400400
  • LMDZ6/trunk/libf/phylmd/phyetat0_get_mod.f90

    r5268 r5748  
    122122  USE iostart,           ONLY: get_field
    123123  USE print_control_mod, ONLY: lunout
    124   USE strings_mod,       ONLY: int2str, maxlen
     124  USE strings_mod,       ONLY: num2str, maxlen
    125125  IMPLICIT NONE
    126126  REAL,             INTENT(INOUT) :: field(:,:,:)
     
    133133  IF(SIZE(field,3)>99) CALL abort_physic("phyetat0", "Too much sub-cells", 1)
    134134  DO nsrf = 1, SIZE(field,3)
    135     DO i = 1, SIZE(name); nam(i) = TRIM(name(i))//TRIM(int2str(nsrf,2)); END DO
    136     des = TRIM(descr)//" srf:"//int2str(nsrf,2)
     135    DO i = 1, SIZE(name); nam(i) = TRIM(name(i))//TRIM(num2str(nsrf,2)); END DO
     136    des = TRIM(descr)//" srf:"//num2str(nsrf,2)
    137137    lFound = phyetat0_get21(field(:,:,nsrf), nam, TRIM(des), default, tname)
    138138  END DO
  • LMDZ6/trunk/libf/phylmd/phytrac_mod.f90

    r5473 r5748  
    128128    USE dimphy
    129129    USE infotrac_phy, ONLY: nbtr, nqCO2, type_trac, conv_flg, pbl_flg
    130     USE strings_mod,  ONLY: int2str
     130    USE strings_mod,  ONLY: num2str
    131131    USE mod_grid_phy_lmdz
    132132    USE mod_phys_lmdz_para
     
    735735          ENDDO
    736736
    737           CALL minmaxqfi(tr_seri(:,:,it),0.,1.e33,'convection it = '//TRIM(int2str(it)))
     737          CALL minmaxqfi(tr_seri(:,:,it),0.,1.e33,'convection it = '//TRIM(num2str(it)))
    738738
    739739       ENDDO ! nbtr
     
    939939                ENDDO
    940940             ENDDO
    941              CALL minmaxqfi(tr_seri(:,:,it),0.,1.e33,'lsc scav it = '//TRIM(int2str(it)))
     941             CALL minmaxqfi(tr_seri(:,:,it),0.,1.e33,'lsc scav it = '//TRIM(num2str(it)))
    942942             ENDIF
    943943
  • LMDZ6/trunk/libf/phylmd/traclmdz_mod.f90

    r5481 r5748  
    312312    USE dimphy
    313313    USE infotrac_phy, ONLY: nbtr, pbl_flg
    314     USE strings_mod,  ONLY: int2str
     314    USE strings_mod,  ONLY: num2str
    315315    USE regr_pr_comb_coefoz_m, ONLY: regr_pr_comb_coefoz
    316316    USE o3_chem_m, ONLY: o3_chem
     
    558558             END DO
    559559          END DO
    560           CALL minmaxqfi(tr_seri(:,:,it),0.,1.e33,'puits rn it='//TRIM(int2str(it)))
     560          CALL minmaxqfi(tr_seri(:,:,it),0.,1.e33,'puits rn it='//TRIM(num2str(it)))
    561561       END IF
    562562    END DO
Note: See TracChangeset for help on using the changeset viewer.