/[MITgcm]/MITgcm/pkg/diagnostics/diagnostics_set_levels.F
ViewVC logotype

Diff of /MITgcm/pkg/diagnostics/diagnostics_set_levels.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.8 by jmc, Mon May 23 02:22:07 2005 UTC revision 1.12 by jmc, Wed Jan 31 21:47:55 2007 UTC
# Line 69  C     !LOCAL VARIABLES: Line 69  C     !LOCAL VARIABLES:
69    
70  C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|  C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
71    
72          _BEGIN_MASTER( myThid )
73    
74        nlevs   = MAX(Nr,Nrphys)        nlevs   = MAX(Nr,Nrphys)
75        nGroundLev = land_nLev        nGroundLev = land_nLev
76    
# Line 93  C-      others: set 1 level: Line 95  C-      others: set 1 level:
95          ENDIF          ENDIF
96        ENDDO        ENDDO
97    
       _BEGIN_MASTER( myThid )  
98        stdUnit = standardMessageUnit        stdUnit = standardMessageUnit
99        WRITE(msgBuf,'(2A)')        WRITE(msgBuf,'(2A)')
100       &   '------------------------------------------------------------'       &   '------------------------------------------------------------'
# Line 174  C--   Check for multiple definition of t Line 175  C--   Check for multiple definition of t
175    
176  C--   Check that number of levels to write (in data.diagnostics) does not  C--   Check that number of levels to write (in data.diagnostics) does not
177  C     exceeds max size: nlevs=max(Nr,NrPhys)  C     exceeds max size: nlevs=max(Nr,NrPhys)
178  C-  note: a better place would be in DIAGNOSTICS_CHECK but prefer to do it  C   note: max size of array to write has been changed to "numLevels",
179  C         here where nlevs is defined.  C         so that this checking is no longer usefull since nlevels
180        DO n=1,nlists  C         cannot be larger than "numLevels" anyway.
         IF ( nlevels(n).GT.nlevs ) THEN  
           WRITE(msgBuf,'(3A,I3,2A)') 'DIAGNOSTICS_SET_LEVELS: ',  
      &       'Ask for too many levels',  
      &       ' in list n=', n, ', filename: ', fnames(n)  
           CALL PRINT_ERROR( msgBuf , myThid )  
           WRITE(msgBuf,'(2A,I4,A,I4)') 'DIAGNOSTICS_SET_LEVELS: ',  
      &       ' number of lev= ', nlevels(n), ' exceeds Max=',nlevs  
           CALL PRINT_ERROR( msgBuf , myThid )  
           STOP 'ABNORMAL END: S/R DIAGNOSTICS_SET_LEVELS'  
         ENDIF  
       ENDDO  
181    
182        _END_MASTER( myThid )        _END_MASTER( myThid )
183    
184    C--   Everyone else must wait for the levels to be set
185          _BARRIER
186    
187        RETURN        RETURN
188        END        END

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.12

  ViewVC Help
Powered by ViewVC 1.1.22