/[MITgcm]/MITgcm/pkg/exf/exf_check_range.F
ViewVC logotype

Diff of /MITgcm/pkg/exf/exf_check_range.F

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

revision 1.17 by dimitri, Sun Feb 6 17:26:23 2005 UTC revision 1.18 by heimbach, Fri Feb 11 17:24:41 2005 UTC
# Line 65  c             Heat flux. Line 65  c             Heat flux.
65                if ( ( hflux(i,j,bi,bj) .GT. 1600. .OR.                if ( ( hflux(i,j,bi,bj) .GT. 1600. .OR.
66       &               hflux(i,j,bi,bj) .LT. -500. ) .AND.       &               hflux(i,j,bi,bj) .LT. -500. ) .AND.
67       &              hFacC(i,j,1,bi,bj) .NE. 0. ) then       &              hFacC(i,j,1,bi,bj) .NE. 0. ) then
68                   print *, 'EXF WARNING: hflux out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
69         &                'EXF WARNING: hflux out of range for i,j= ',
70       &                i, j, hflux(i,j,bi,bj)       &                i, j, hflux(i,j,bi,bj)
71                   exferr = 1                   exferr = 1
72                endif                endif
# Line 73  c Line 74  c
74  c             Salt flux.  c             Salt flux.
75                if ( ABS(sflux(i,j,bi,bj)) .GT. 1.E-6 .AND.                if ( ABS(sflux(i,j,bi,bj)) .GT. 1.E-6 .AND.
76       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then
77                   print *, 'EXF WARNING: sflux out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
78         &                'EXF WARNING: sflux out of range for i,j= ',
79       &                i, j, sflux(i,j,bi,bj)       &                i, j, sflux(i,j,bi,bj)
80                   exferr = 1                   exferr = 1
81                endif                endif
# Line 81  c Line 83  c
83  c             Zonal wind stress.  c             Zonal wind stress.
84                if ( ABS(ustress(i,j,bi,bj)) .GT. 2.5 .AND.                if ( ABS(ustress(i,j,bi,bj)) .GT. 2.5 .AND.
85       &             hFacW(i,j,1,bi,bj) .NE. 0. ) then       &             hFacW(i,j,1,bi,bj) .NE. 0. ) then
86                   print *, 'EXF WARNING: ustress out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
87         &                'EXF WARNING: ustress out of range for i,j= ',
88       &                i, j, ustress(i,j,bi,bj)       &                i, j, ustress(i,j,bi,bj)
89                   exferr = 1                   exferr = 1
90                endif                endif
# Line 89  c Line 92  c
92  c             Meridional wind stress.  c             Meridional wind stress.
93                if ( ABS(vstress(i,j,bi,bj)) .GT. 2.2 .AND.                if ( ABS(vstress(i,j,bi,bj)) .GT. 2.2 .AND.
94       &             hFacS(i,j,1,bi,bj) .NE. 0. ) then       &             hFacS(i,j,1,bi,bj) .NE. 0. ) then
95                   print *, 'EXF WARNING: vstress out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
96         &                'EXF WARNING: vstress out of range for i,j= ',
97       &                i, j, vstress(i,j,bi,bj)       &                i, j, vstress(i,j,bi,bj)
98                   exferr = 1                   exferr = 1
99                endif                endif
# Line 98  c Line 102  c
102  c             zonal wind speed  c             zonal wind speed
103                if ( ABS(uwind(i,j,bi,bj)) .GT. 100. .AND.                if ( ABS(uwind(i,j,bi,bj)) .GT. 100. .AND.
104       &             hFacW(i,j,1,bi,bj) .NE. 0. ) then       &             hFacW(i,j,1,bi,bj) .NE. 0. ) then
105                   print *, 'EXF WARNING: uwind out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
106         &                'EXF WARNING: uwind out of range for i,j= ',
107       &                i, j, uwind(i,j,bi,bj)       &                i, j, uwind(i,j,bi,bj)
108                   exferr = 1                   exferr = 1
109                endif                endif
# Line 106  c Line 111  c
111  c             zonal wind speed  c             zonal wind speed
112                if ( ABS(vwind(i,j,bi,bj)) .GT. 100. .AND.                if ( ABS(vwind(i,j,bi,bj)) .GT. 100. .AND.
113       &             hFacS(i,j,1,bi,bj) .NE. 0. ) then       &             hFacS(i,j,1,bi,bj) .NE. 0. ) then
114                   print *, 'EXF WARNING: vwind out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
115         &                'EXF WARNING: vwind out of range for i,j= ',
116       &                i, j, vwind(i,j,bi,bj)       &                i, j, vwind(i,j,bi,bj)
117                   exferr = 1                   exferr = 1
118                endif                endif
# Line 117  c             2-m air temperature Line 123  c             2-m air temperature
123                if ( (atemp(i,j,bi,bj) .LT. 183 .OR.                if ( (atemp(i,j,bi,bj) .LT. 183 .OR.
124       &             atemp(i,j,bi,bj) .GT. 343 ) .AND.       &             atemp(i,j,bi,bj) .GT. 343 ) .AND.
125       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then
126                   print *, 'EXF WARNING: atemp + exf_offset_atemp ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
127         &                'EXF WARNING: atemp + exf_offset_atemp ',
128       &                'out of range for i,j= ',       &                'out of range for i,j= ',
129       &                i, j, atemp(i,j,bi,bj)       &                i, j, atemp(i,j,bi,bj)
130                   exferr = 1                   exferr = 1
# Line 127  c             2-m specific humidity Line 134  c             2-m specific humidity
134                if ( (aqh(i,j,bi,bj) .LT. 0. .OR.                if ( (aqh(i,j,bi,bj) .LT. 0. .OR.
135       &             aqh(i,j,bi,bj) .GT. 0.1 ) .AND.       &             aqh(i,j,bi,bj) .GT. 0.1 ) .AND.
136       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then
137                   print *, 'EXF WARNING: aqh out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
138         &                'EXF WARNING: aqh out of range for i,j= ',
139       &                i, j, aqh(i,j,bi,bj)       &                i, j, aqh(i,j,bi,bj)
140                   exferr = 1                   exferr = 1
141                endif                endif
# Line 136  c             precipitation rate Line 144  c             precipitation rate
144                if ( (precip(i,j,bi,bj) .LT. 0. .OR.                if ( (precip(i,j,bi,bj) .LT. 0. .OR.
145       &             precip(i,j,bi,bj) .GT. 2.E-6 ) .AND.       &             precip(i,j,bi,bj) .GT. 2.E-6 ) .AND.
146       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then
147                   print *, 'EXF WARNING: precip out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
148         &                'EXF WARNING: precip out of range for i,j= ',
149       &                i, j, precip(i,j,bi,bj)       &                i, j, precip(i,j,bi,bj)
150                   exferr = 1                   exferr = 1
151                endif                endif
# Line 147  c             Short wave radiative flux. Line 156  c             Short wave radiative flux.
156                if ( (swflux(i,j,bi,bj) .GT. 1. .OR.                if ( (swflux(i,j,bi,bj) .GT. 1. .OR.
157       &             swflux(i,j,bi,bj) .LT. -1000. ) .AND.       &             swflux(i,j,bi,bj) .LT. -1000. ) .AND.
158       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then
159                   print *, 'EXF WARNING: swflux out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
160         &                'EXF WARNING: swflux out of range for i,j= ',
161       &                i, j, swflux(i,j,bi,bj)       &                i, j, swflux(i,j,bi,bj)
162                   exferr = 1                   exferr = 1
163                endif                endif
# Line 158  c             Runoff. Line 168  c             Runoff.
168                if ( (runoff(i,j,bi,bj) .LT. 0. .OR.                if ( (runoff(i,j,bi,bj) .LT. 0. .OR.
169       &             runoff(i,j,bi,bj) .GT. 1.E-6 ) .AND.       &             runoff(i,j,bi,bj) .GT. 1.E-6 ) .AND.
170       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then       &             hFacC(i,j,1,bi,bj) .NE. 0. ) then
171                   print *, 'EXF WARNING: runoff out of range for i,j= ',                   write(standardmessageunit,'(A,2(2X,I5),2X,D22.15)')
172         &                'EXF WARNING: runoff out of range for i,j= ',
173       &                i, j, runoff(i,j,bi,bj)       &                i, j, runoff(i,j,bi,bj)
174                   print *, 'Please note that input units for runoff are'                   write(standardmessageunit,'(A)')
175                   print *, 'm/s not m/yr.  If input file is in m/yr, set'       &                'Please note that input units for runoff are'
176                   print *, 'exf_inscal_runoff=3.171e-8'                   write(standardmessageunit,'(A)')
177                   print *, 'in the data.exf input file.'       &                'm/s not m/yr.  If input file is in m/yr, set'
178                     write(standardmessageunit,'(A)')
179         &                'exf_inscal_runoff=3.170979198E-8'
180                     write(standardmessageunit,'(A)')
181         &                'in the data.exf input file.'
182                   exferr = 1                   exferr = 1
183                endif                endif
184  #endif  #endif
185    
186                if ( exferr .NE. 0 ) then                if ( exferr .NE. 0 ) then
187                 print *, 'EXF WARNING: If you think these values are OK '                 write(standardmessageunit,'(A)')
188                 print *, 'EXF WARNING: then set useExfCheckRange=.FALSE.'       &                'EXF WARNING: If you think these values are OK '
189                   write(standardmessageunit,'(A)')
190         &                'EXF WARNING: then set useExfCheckRange=.FALSE.'
191                 STOP 'in S/R exf_check_range'                 STOP 'in S/R exf_check_range'
192                endif                endif
193    

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.18

  ViewVC Help
Powered by ViewVC 1.1.22