Changeset 4358 for LMDZ6/trunk/libf/misc
- Timestamp:
- Nov 30, 2022, 4:37:30 PM (2 years ago)
- Location:
- LMDZ6/trunk/libf/misc
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/libf/misc/readTracFiles_mod.f90
r4348 r4358 54 54 CHARACTER(LEN=maxlen) :: phase = 'g' !--- Phase ('g'as / 'l'iquid / 's'olid) 55 55 CHARACTER(LEN=maxlen) :: component = '' !--- Coma-separated list of components (Ex: lmdz,inca) 56 INTEGER :: iadv = 10 !--- Advection scheme used57 56 INTEGER :: iGeneration = -1 !--- Generation number (>=0) 58 LOGICAL :: isAdvected = .FALSE. !--- "true" tracers: iadv > 0. COUNT(isAdvected )=nqtrue59 LOGICAL :: isInPhysics = .TRUE. !--- "true" tracers: in tr_seri. COUNT(isInPhysics)=nqtottr60 57 INTEGER :: iqParent = 0 !--- Parent index 61 58 INTEGER, ALLOCATABLE :: iqDescen(:) !--- Descendants index (in growing generation order) 62 59 INTEGER :: nqDescen = 0 !--- Number of descendants (all generations) 63 60 INTEGER :: nqChildren = 0 !--- Number of children (first generation) 61 TYPE(keys_type) :: keys !--- <key>=<val> pairs vector 62 INTEGER :: iadv = 10 !--- Advection scheme used 63 LOGICAL :: isAdvected = .FALSE. !--- "true" tracers: iadv > 0. COUNT(isAdvected )=nqtrue 64 LOGICAL :: isInPhysics = .TRUE. !--- "true" tracers: in tr_seri. COUNT(isInPhysics)=nqtottr 64 65 INTEGER :: iso_iGroup = 0 !--- Isotopes group index in isotopes(:) 65 66 INTEGER :: iso_iName = 0 !--- Isotope name index in isotopes(iso_iGroup)%trac(:) 66 67 INTEGER :: iso_iZone = 0 !--- Isotope zone index in isotopes(iso_iGroup)%zone(:) 67 68 INTEGER :: iso_iPhase = 0 !--- Isotope phase index in isotopes(iso_iGroup)%phase 68 TYPE(keys_type) :: keys !--- <key>=<val> pairs vector69 69 END TYPE trac_type 70 70 !------------------------------------------------------------------------------------------------------------------------------ … … 1895 1895 ip = getiPhase(newName) !--- Phase index 1896 1896 IF(ip /= 0 .AND. PRESENT(iPhase)) iPhase = ip !--- Returning phase index 1897 ix = strIdx(newH2OIso, newName) !--- Index in the known H2O isotopes list 1898 IF(ix /= 0) oldName = 'H2O'//'_'//TRIM(oldH2OIso(ix)) !=== WATER ISOTOPE WITHOUT PHASE 1897 ix = strIdx(newH2OIso, strHead(newName, '_')) !--- Index in the known H2O isotopes list 1898 IF(ix /= 0) THEN 1899 oldName = 'H2O'//'_'//TRIM(oldH2OIso(ix)) !=== WATER ISOTOPE WITHOUT PHASE 1900 IF(newH2OIso(ix)/=newName) oldName=TRIM(oldName)//'_'//strTail(newName,'_')!=== WATER ISOTOPIC TAGGING TRACER WITHOUT PHASE 1901 END IF 1899 1902 IF(ix /= 0 .OR. ip == 0) RETURN 1900 1903 oldName = 'H2O'//old_phases(ip:ip) -
LMDZ6/trunk/libf/misc/strings_mod.F90
r4349 r4358 505 505 !=== Count the number of elements separated by "delimiter" in list "rawList". ================================================= 506 506 !============================================================================================================================== 507 LOGICAL FUNCTION strCount_11(rawList, delimiter, nb, lSc) RESULT( out)507 LOGICAL FUNCTION strCount_11(rawList, delimiter, nb, lSc) RESULT(lerr) 508 508 CHARACTER(LEN=*), INTENT(IN) :: rawList 509 509 CHARACTER(LEN=*), INTENT(IN) :: delimiter … … 513 513 LOGICAL :: ll 514 514 ll = .FALSE.; IF(PRESENT(lSc)) ll = lSc 515 out= strCount_1m(rawList, [delimiter], nb, ll)515 lerr = strCount_1m(rawList, [delimiter], nb, ll) 516 516 END FUNCTION strCount_11 517 517 !============================================================================================================================== 518 LOGICAL FUNCTION strCount_m1(rawList, delimiter, nb, lSc) RESULT( out)518 LOGICAL FUNCTION strCount_m1(rawList, delimiter, nb, lSc) RESULT(lerr) 519 519 CHARACTER(LEN=*), INTENT(IN) :: rawList(:) 520 520 CHARACTER(LEN=*), INTENT(IN) :: delimiter … … 525 525 INTEGER :: id 526 526 ll = .FALSE.; IF(PRESENT(lSc)) ll = lSc .AND. INDEX('+-', delimiter) /= 0 527 out= .TRUE.527 lerr = .TRUE. 528 528 ALLOCATE(nb(SIZE(rawList))) 529 529 DO id = 1, SIZE(rawList) 530 out = out.AND. strCount_1m(rawList(id), [delimiter], nb(id), ll)530 lerr = lerr .AND. strCount_1m(rawList(id), [delimiter], nb(id), ll) 531 531 END DO 532 532 END FUNCTION strCount_m1
Note: See TracChangeset
for help on using the changeset viewer.