50 |
INTEGER nInterval |
INTEGER nInterval |
51 |
_RL xInterval |
_RL xInterval |
52 |
LOGICAL dBugFlag |
LOGICAL dBugFlag |
53 |
|
INTEGER dBugUnit |
54 |
#ifdef ALLOW_FIZHI |
#ifdef ALLOW_FIZHI |
55 |
LOGICAL alarm2, alarm2next |
LOGICAL alarm2, alarm2next |
56 |
CHARACTER *9 tagname |
CHARACTER *9 tagname |
62 |
C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| |
C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| |
63 |
|
|
64 |
dBugFlag = debugLevel.GT.debLevB .AND. myThid.EQ.1 |
dBugFlag = debugLevel.GT.debLevB .AND. myThid.EQ.1 |
65 |
|
dBugUnit = errorMessageUnit |
66 |
|
|
67 |
c newIter = 1 + myIter |
c newIter = 1 + myIter |
68 |
DO n = 1,nlists |
DO n = 1,nlists |
120 |
|
|
121 |
C- check future value of pdiag: |
C- check future value of pdiag: |
122 |
IF (dBugFlag.AND.pdiag(n,1,1).NE.nInterval) |
IF (dBugFlag.AND.pdiag(n,1,1).NE.nInterval) |
123 |
& WRITE(0,'(A,I8,3(A,I3),F17.6)') 'DIAG_SWITCH_ONOFF: at it=', |
& WRITE(dBugUnit,'(A,I8,3(A,I3),F17.6)') |
124 |
& myIter, ', list:', n, ' switch', |
& 'DIAG_SWITCH_ONOFF: at it=', myIter, ', list:', n, |
125 |
& pdiag(n,1,1),' ->', nInterval, xInterval |
& ' switch', pdiag(n,1,1),' ->', nInterval, xInterval |
126 |
IF ( nInterval.LT.0 .OR. nInterval.GE.averageCycle(n) ) THEN |
IF ( nInterval.LT.0 .OR. nInterval.GE.averageCycle(n) ) THEN |
127 |
WRITE(msgBuf,'(2A,I2,A,I4)') 'DIAGNOSTICS_SWITCH_ONOFF:', |
WRITE(msgBuf,'(2A,I2,A,I4)') 'DIAGNOSTICS_SWITCH_ONOFF:', |
128 |
& ' error setting pdiag(n=',n,') to:', nInterval |
& ' error setting pdiag(n=',n,') to:', nInterval |
174 |
IF (iSp.GT.0) THEN |
IF (iSp.GT.0) THEN |
175 |
nd = jSdiag(m,n) |
nd = jSdiag(m,n) |
176 |
IF (dBugFlag.AND.qSdiag(0,0,iSp,bi,bj).NE. 0.) |
IF (dBugFlag.AND.qSdiag(0,0,iSp,bi,bj).NE. 0.) |
177 |
& WRITE(0,'(I8,I4,3A,1PE10.3,A,I3)') myIter, |
& WRITE(dBugUnit,'(A,I8,A,I4,3A,1PE10.3,A,I3)') |
178 |
& nd,' ',cdiag(nd),' :',qSdiag(0,0,iSp,bi,bj),' ->', 0 |
& 'DIAG_SWITCH_ONOFF: at it=', myIter, ' diag:', nd, |
179 |
|
& ' ',cdiag(nd),' :',qSdiag(0,0,iSp,bi,bj),' ->', 0 |
180 |
qSdiag(0,0,iSp,bi,bj) = 0. |
qSdiag(0,0,iSp,bi,bj) = 0. |
181 |
ENDIF |
ENDIF |
182 |
ENDDO |
ENDDO |
187 |
IF (iSp.GT.0) THEN |
IF (iSp.GT.0) THEN |
188 |
nd = jSdiag(m,n) |
nd = jSdiag(m,n) |
189 |
IF (dBugFlag.AND.qSdiag(0,0,iSp,bi,bj).NE.-1.) |
IF (dBugFlag.AND.qSdiag(0,0,iSp,bi,bj).NE.-1.) |
190 |
& WRITE(0,'(I8,I4,3A,1PE10.3,A,I3)') myIter, |
& WRITE(dBugUnit,'(A,I8,A,I4,3A,1PE10.3,A,I3)') |
191 |
& nd,' ',cdiag(nd),' :',qSdiag(0,0,iSp,bi,bj),' ->',-1 |
& 'DIAG_SWITCH_ONOFF: at it=', myIter, ' diag:', nd, |
192 |
|
& ' ',cdiag(nd),' :',qSdiag(0,0,iSp,bi,bj),' ->', -1 |
193 |
qSdiag(0,0,iSp,bi,bj) = -1. |
qSdiag(0,0,iSp,bi,bj) = -1. |
194 |
ENDIF |
ENDIF |
195 |
ENDDO |
ENDDO |