Ignore:
Timestamp:
Feb 22, 2021, 5:28:31 PM (4 years ago)
Author:
dcugnet
Message:

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".

File:
1 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/branches/LMDZ-tracers/libf/dyn3d/leapfrog.F

    r3416 r3852  
    1111      use IOIPSL
    1212#endif
    13       USE infotrac, ONLY: nqtot,ok_iso_verif
     13      USE infotrac, ONLY: nqtot
    1414      USE guide_mod, ONLY : guide_main
    1515      USE write_field, ONLY: writefield
     
    237237      jH_cur = jH_cur - int(jH_cur)
    238238
    239         if (ok_iso_verif) then
    240            call check_isotopes_seq(q,ip1jmp1,'leapfrog 321')
    241         endif !if (ok_iso_verif) then
     239      call check_isotopes_seq(q,ip1jmp1,'leapfrog 321')
    242240
    243241#ifdef CPP_IOIPSL
     
    271269!      CALL filtreg ( finvmaold ,jjp1, llm, -2,2, .TRUE., 1 )
    272270
    273         if (ok_iso_verif) then
    274            call check_isotopes_seq(q,ip1jmp1,'leapfrog 400')
    275         endif !if (ok_iso_verif) then
     271      call check_isotopes_seq(q,ip1jmp1,'leapfrog 400')
    276272
    277273   2  CONTINUE ! Matsuno backward or leapfrog step begins here
     
    323319      endif
    324320
    325 
    326         if (ok_iso_verif) then
    327            call check_isotopes_seq(q,ip1jmp1,'leapfrog 589')
    328         endif !if (ok_iso_verif) then
     321      call check_isotopes_seq(q,ip1jmp1,'leapfrog 589')
    329322
    330323c-----------------------------------------------------------------------
     
    345338c   -------------------------------------------------------------
    346339
    347         if (ok_iso_verif) then
    348            call check_isotopes_seq(q,ip1jmp1,
     340      call check_isotopes_seq(q,ip1jmp1,
    349341     &           'leapfrog 686: avant caladvtrac')
    350         endif !if (ok_iso_verif) then
    351342
    352343      IF( forward. OR . leapf )  THEN
     
    376367c   ----------------------------------
    377368
    378         if (ok_iso_verif) then
    379            write(*,*) 'leapfrog 720'
    380            call check_isotopes_seq(q,ip1jmp1,'leapfrog 756')
    381         endif !if (ok_iso_verif) then
     369       call check_isotopes_seq(q,ip1jmp1,'leapfrog 756')
    382370       
    383371       CALL integrd ( nqtot,vcovm1,ucovm1,tetam1,psm1,massem1 ,
     
    385373!     $              finvmaold                                    )
    386374
    387        if (ok_iso_verif) then
    388           write(*,*) 'leapfrog 724'
    389            call check_isotopes_seq(q,ip1jmp1,'leapfrog 762')
    390         endif !if (ok_iso_verif) then
     375       call check_isotopes_seq(q,ip1jmp1,'leapfrog 762')
    391376
    392377c .P.Le Van (26/04/94  ajout de  finvpold dans l'appel d'integrd)
     
    552537        CALL massdair(p,masse)
    553538
    554         if (ok_iso_verif) then
    555            call check_isotopes_seq(q,ip1jmp1,'leapfrog 1196')
    556         endif !if (ok_iso_verif) then
     539        call check_isotopes_seq(q,ip1jmp1,'leapfrog 1196')
    557540
    558541c-----------------------------------------------------------------------
     
    639622c   preparation du pas d'integration suivant  ......
    640623
    641         if (ok_iso_verif) then
    642            call check_isotopes_seq(q,ip1jmp1,'leapfrog 1509')
    643         endif !if (ok_iso_verif) then
     624      call check_isotopes_seq(q,ip1jmp1,'leapfrog 1509')
    644625
    645626      IF ( .NOT.purmats ) THEN
     
    703684            ENDIF ! of IF((MOD(itau,iperiod).EQ.0).OR.(itau.EQ.itaufin))
    704685
    705         if (ok_iso_verif) then
    706            call check_isotopes_seq(q,ip1jmp1,'leapfrog 1584')
    707         endif !if (ok_iso_verif) then
     686            call check_isotopes_seq(q,ip1jmp1,'leapfrog 1584')
    708687
    709688c-----------------------------------------------------------------------
     
    785764      ELSE ! of IF (.not.purmats)
    786765
    787         if (ok_iso_verif) then
    788            call check_isotopes_seq(q,ip1jmp1,'leapfrog 1664')
    789         endif !if (ok_iso_verif) then
     766        call check_isotopes_seq(q,ip1jmp1,'leapfrog 1664')
    790767
    791768c       ........................................................
     
    812789            ELSE ! of IF(forward) i.e. backward step
    813790 
    814         if (ok_iso_verif) then
    815            call check_isotopes_seq(q,ip1jmp1,'leapfrog 1698')
    816         endif !if (ok_iso_verif) then 
     791              call check_isotopes_seq(q,ip1jmp1,'leapfrog 1698')
    817792
    818793              IF(MOD(itau,iperiod).EQ.0 .OR. itau.EQ.itaufin) THEN
Note: See TracChangeset for help on using the changeset viewer.