Changeset 11658
- Timestamp:
- 2019-10-07T19:55:50+02:00 (4 years ago)
- Location:
- NEMO/branches/2019/ENHANCE-03_domcfg/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/2019/ENHANCE-03_domcfg/src/domclo.F90
r11628 r11658 156 156 DO jcs = 1,nn_closea 157 157 158 !! 2.2 : print out and sanity check159 !! flag changed in sanity checks160 lskip = .FALSE.161 162 !! define seed to extract the closed sea jcs163 CALL dom_ngb(sn_lake(jcs)%rlonsrc, sn_lake(jcs)%rlatsrc, jiseed, jjseed, zdistseed, 'T')164 165 158 !! how the excess of the closed seas is spread out: 166 IF (lwp) THEN167 WRITE(numout,*)168 WRITE(numout,'(a,a10,a,2f7.2,a)')' processing lake ',TRIM(sn_lake(jcs)%cname) &169 & ,' ( lat/lon : ',sn_lake(jcs)%rlatsrc, sn_lake(jcs)%rlonsrc,' )'170 END IF171 159 cloc = sn_lake(jcs)%cloctrg 172 160 csch = sn_lake(jcs)%cschtrg 173 174 !! set up indexes and mask ! SELECT CASE ...161 162 !! set up indexes and mask 175 163 SELECT CASE (csch) 176 164 CASE('glo') … … 178 166 zmsksrc(:,:) = msk_glo(:,:) 179 167 zmsktrg(:,:) = msk_gloid(:,:) 180 IF (lwp) WRITE(numout,*)' net evap/precip will be spread globally'181 168 CASE('rnf') 182 169 jsch = jrnf 183 170 zmsksrc(:,:) = msk_rnf(:,:) 184 171 zmsktrg(:,:) = msk_rnfid(:,:) 185 IF (lwp) WRITE(numout,*)' net precip will be spread locally and net evap globally'186 172 CASE('emp') 187 173 jsch = jemp 188 174 zmsksrc(:,:) = msk_emp(:,:) 189 175 zmsktrg(:,:) = msk_empid(:,:) 190 IF (lwp) WRITE(numout,*)' net precip will be spread locally'191 176 CASE DEFAULT 192 CALL ctl_stop( 'STOP', 'domclo: unknown target type for lake (should be glo, emp, rnf)' )177 CALL ctl_stop( 'STOP', 'domclo: ',TRIM(csch),' is an unknown target type for lake (should be glo, emp, rnf)' ) 193 178 END SELECT 179 180 !! 2.2 : print out and sanity check 181 !! flag changed in sanity checks 182 lskip = .FALSE. 183 184 !! define seed to extract the closed sea jcs 185 CALL dom_ngb(sn_lake(jcs)%rlonsrc, sn_lake(jcs)%rlatsrc, jiseed, jjseed, zdistseed, 'T') 194 186 195 187 !! sanity check on the msk value (closea mask should be 99 otherwise, lake already processed) … … 209 201 lskip = .TRUE. 210 202 END IF 211 203 212 204 !! 2.3 : compute mask for global, rnf, emp case 213 205 IF (.NOT. lskip) THEN 206 207 IF (lwp) THEN 208 WRITE(numout,*) 209 WRITE(numout,'(a,a10,a,2f7.2,a,2i6,a,f7.2,a)') & 210 & ' processing lake ',TRIM(sn_lake(jcs)%cname) & 211 & ,' ( lat/lon : ',sn_lake(jcs)%rlatsrc, sn_lake(jcs)%rlonsrc & 212 & ,' , i/j : ',jiseed,jjseed & 213 & ,' , distance to seed : ',zdistseed,'m )' 214 END IF 215 214 216 !! fill close sea mask with counter value 215 217 CALL fill_pool( jiseed, jjseed, zmsksrc, REAL(jsch ,8)) … … 248 250 249 251 !! print 250 IF (lwp) WRITE(numout,'(a,f7.0,a,2f7.2,a,2i7,a)')' river mouth area is defined by points within ',zradtrg(1) & 251 & ,' m of lat/lon ', sn_lake(jcs)%rlontrg, sn_lake(jcs)%rlattrg & 252 & ,' (closest point is i/j ',jiseed, jjseed,')' 252 IF (lwp) WRITE(numout,'(a,f7.0,a,2f7.2,a,2i7,a,f7.0,a)') & 253 & ' river mouth area is defined by points within ',zradtrg(1) & 254 & ,' m of lat/lon ', sn_lake(jcs)%rlontrg, sn_lake(jcs)%rlattrg & 255 & ,' (closest wet point is i/j ',jiseed, jjseed,' at ',zdistseed,' m )' 253 256 CASE ('coast') 254 257 !! define coastline mask … … 265 268 266 269 !! print 267 IF (lwp) WRITE(numout,'(a,f7.0,a,2f7.2,a,2i7,a)')' river mouth area is defined by coastal points within ',zradtrg(1) & 268 & ,' m of lat/lon ', sn_lake(jcs)%rlontrg, sn_lake(jcs)%rlattrg & 269 & ,' (closest point is i/j ',jiseed, jjseed,')' 270 IF (lwp) WRITE(numout,'(a,f7.0,a,2f7.2,a,2i7,a,f7.0,a)') & 271 & ' river mouth area is defined by coastal points within ',zradtrg(1) & 272 & ,' m of lat/lon ', sn_lake(jcs)%rlontrg, sn_lake(jcs)%rlattrg & 273 & ,' (closest wet point is i/j ',jiseed, jjseed,' at ',zdistseed,' m )' 270 274 271 275 CASE DEFAULT … … 277 281 zarea = glob_sum('domclo',zmsktrg * msk_opnsea) 278 282 IF (zarea == 0._wp) CALL ctl_stop( 'STOP', 'river mouth area is 0, tune lon/lat trg or radtrg for this lake') 283 ! 284 zarea = glob_sum('domclo',zmsksrc * msk_opnsea) 285 IF (zarea > 0._wp) CALL ctl_stop( 'STOP', 'closed seas and open ocean have common points, ' & 286 & , 'tune lon/lat src or check if your lake is really closed on the model grid') 279 287 280 288 !! set up indexes and mask … … 284 292 msk_glo(:,:) = zmsksrc(:,:) 285 293 msk_gloid(:,:) = zmsktrg(:,:) 294 IF (lwp) WRITE(numout,*)' net evap/precip will be spread globally (glo)' 286 295 CASE ('rnf') 287 296 jrnf = jrnf + 1 288 297 msk_rnf(:,:) = zmsksrc(:,:) 289 298 msk_rnfid(:,:) = zmsktrg(:,:) 299 IF (lwp) WRITE(numout,*)' net precip will be spread locally and net evap globally (rnf)' 290 300 CASE ('emp') 291 301 jemp = jemp + 1 292 302 msk_emp(:,:) = zmsksrc(:,:) 293 303 msk_empid(:,:) = zmsktrg(:,:) 304 IF (lwp) WRITE(numout,*)' net evap/precip will be spread locally (emp)' 294 305 END SELECT 295 306 -
NEMO/branches/2019/ENHANCE-03_domcfg/src/domzgr.F90
r11602 r11658 60 60 REAL(wp), PUBLIC :: e3zps_min !: miminum thickness for partial steps (meters) 61 61 REAL(wp), PUBLIC :: e3zps_rat !: minimum thickness ration for partial steps 62 INTEGER, PUBLIC :: nperio !: type of lateral boundary condition63 62 64 63 ! Song and Haidvogel 1994 stretching parameters … … 702 701 ENDIF 703 702 ENDIF 704 ELSEIF( jperio == 1 .OR. jperio == 4 .OR. jperio == 6) THEN703 ELSEIF( l_Iperio ) THEN 705 704 IF(lwp) WRITE(numout,*)' east-west cyclic boundary conditions on mbathy: jperio = ', jperio 706 705 mbathy( 1 ,:) = mbathy(jpim1,:) … … 1166 1165 mbathy(:,:) = INT( zbathy(:,:) ) 1167 1166 ENDIF 1168 IF( nperio == 1 .OR. nperio == 4 .OR. nperio == 6) THEN1167 IF( l_Iperio ) THEN 1169 1168 misfdep( 1 ,:) = misfdep(jpim1,:) ! local domain is cyclic east-west 1170 1169 misfdep(jpi,:) = misfdep( 2 ,:) -
NEMO/branches/2019/ENHANCE-03_domcfg/src/iom.F90
r11654 r11658 660 660 ! do we read the overlap 661 661 ! ugly patch SM+JMM+RB to overwrite global definition in some cases 662 llnoov = (jpni * jpnj ) == jpnij .AND. .NOT. lk_agrif 662 !llnoov = (jpni * jpnj ) == jpnij .AND. .NOT. lk_agrif 663 ! for domain_cfg, force to read the full domain 664 llnoov = .FALSE. 663 665 ! create the file name by added, if needed, TRIM(Agrif_CFixed()) and TRIM(clsuffix) 664 666 ! ============= … … 1052 1054 ! do we read the overlap 1053 1055 ! ugly patch SM+JMM+RB to overwrite global definition in some cases 1054 llnoov = (jpni * jpnj ) == jpnij .AND. .NOT. lk_agrif 1056 ! 1057 !llnoov = (jpni * jpnj ) == jpnij .AND. .NOT. lk_agrif 1058 ! for domain_cfg tools force to read the full domain 1059 llnoov = .FALSE. 1055 1060 ! check kcount and kstart optionals parameters... 1056 1061 IF( PRESENT(kcount) .AND. (.NOT. PRESENT(kstart)) ) CALL ctl_stop(trim(clinfo), 'kcount present needs kstart present') … … 1233 1238 ENDIF 1234 1239 ENDIF 1235 1240 WRITE(numout,*) 'istart icnt',istart, ' ', icnt 1241 WRITE(numout,*) ' idx i1, i2, j1, j2 ',ix1, ix2, iy1, iy2 1236 1242 CALL iom_nf90_get( kiomid, idvar, inbdim, istart, icnt, ix1, ix2, iy1, iy2, pv_r1d, pv_r2d, pv_r3d ) 1237 1243
Note: See TracChangeset
for help on using the changeset viewer.