Ignore:
Timestamp:
Aug 1, 2025, 4:03:00 PM (5 days ago)
Author:
afalco
Message:

check size of z2sig.def when reading it.
AF

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.COMMON/libf/dyn3d_common/disvert_noterre.F

    r1422 r3874  
    2424c
    2525c=======================================================================
    26 c    Discretisation verticale en coordonnée hybride (ou sigma)
     26c    Discretisation verticale en coordonne hybride (ou sigma)
    2727c
    2828c=======================================================================
     
    138138         READ(99,*) scaleheight
    139139         do l=1,llm
    140             read(99,*) zsig(l)
     140            read(99,*,iostat=ierr1) zsig(l)
     141            if (ierr1 .ne. 0) then
     142               write(lunout,*) 'ERROR with line ', l,' of z2sig.def'
     143               call abort_gcm(modname, "z2sig.def too short?", 1)
     144            endif
    141145         end do
     146         ! Check if there are more lines to read in the file
     147         read(99,*,iostat=ierr1)
     148         if (ierr1 .eq. 0) then
     149            write(lunout,*) 'ERROR: Expected nb of levels:', llm
     150            call abort_gcm(modname,
     151     &        'z2sig.def has more lines than expected', 1)
     152         endif
    142153         CLOSE(99)
    143154
     
    208219c     Calcul au milieu des couches :
    209220c     WARNING : le choix de placer le milieu des couches au niveau de
    210 c     pression intermédiaire est arbitraire et pourrait etre modifié.
     221c     pression interm�diaire est arbitraire et pourrait etre modifi�.
    211222c     Le calcul du niveau pour la derniere couche
    212223c     (on met la meme distance (en log pression)  entre P(llm)
    213224c     et P(llm -1) qu'entre P(llm-1) et P(llm-2) ) est
    214 c     Specifique.  Ce choix est spécifié ici ET dans exner_milieu.F
     225c     Specifique.  Ce choix est sp�cifi� ici ET dans exner_milieu.F
    215226
    216227      DO l = 1, llm-1
     
    284295c     L'objectif est de calculer newsig telle que
    285296c       (1 -pa/preff)*exp(1-1./newsig**2)+(pa/preff)*newsig = sig
    286 c     Cela ne se résoud pas analytiquement:
    287 c     => on résoud par iterration bourrine
     297c     Cela ne se rsoud pas analytiquement:
     298c     => on rsoud par iterration bourrine
    288299c     ----------------------------------------------
    289300c     Information  : where exp(1-1./x**2) become << x
     
    320331              newsig=(X2+newsig)*0.5
    321332          end if
    322 c         Test : on arete lorsque on approxime sig à moins de 0.01 m près
     333c         Test : on arete lorsque on approxime sig � moins de 0.01 m pr�s
    323334c         (en pseudo altitude) :
    324335          IF(abs(10.*log(F)).LT.1.E-5) goto 999
Note: See TracChangeset for help on using the changeset viewer.