Changeset 3832
- Timestamp:
- 2013-03-06T17:22:01+01:00 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2012/dev_MERGE_2012/NEMOGCM/NEMO/OPA_SRC/SBC/sbcrnf.F90
r3811 r3832 95 95 INTEGER, INTENT(in) :: kt ! ocean time step 96 96 ! 97 INTEGER :: ji, jj ! dummy loop indices 97 INTEGER :: ji, jj ! dummy loop indices 98 INTEGER :: z_err = 0 ! dummy integer for error handling 98 99 !!---------------------------------------------------------------------- 99 100 ! … … 140 141 IF( ln_rnf_sal ) rnf_tsc(:,:,jp_sal) = ( sf_s_rnf(1)%fnow(:,:,1) ) * rnf(:,:) * r1_rau0 141 142 ! ! else use S=0 for runoffs (done one for all in the init) 142 ! 143 IF( ln_rnf_tem .OR. ln_rnf_sal ) THEN ! runoffs as outflow: use ocean SST and SSS 144 WHERE( rnf(:,:) < 0._wp ) ! example baltic model when flow is out of domain 145 rnf_tsc(:,:,jp_tem) = sst_m(:,:) * rnf(:,:) * r1_rau0 146 rnf_tsc(:,:,jp_sal) = sss_m(:,:) * rnf(:,:) * r1_rau0 147 END WHERE 148 ENDIF 143 IF ( ANY( rnf(:,:) < 0._wp ) ) z_err=1 144 IF(lk_mpp) CALL mpp_sum(z_err) 145 IF( z_err > 0 ) CALL ctl_stop( 'sbc_rnf : negative runnoff values exist' ) 149 146 ! 150 147 CALL iom_put( "runoffs", rnf ) ! output runoffs arrays … … 338 335 IF(lwp) WRITE(numout,*) ' runoffs depth read in a file' 339 336 rn_dep_file = TRIM( cn_dir )//TRIM( sn_dep_rnf%clname ) 337 IF( .NOT. sn_dep_rnf%ln_clim ) THEN ; WRITE(rn_dep_file, '(a,"_y",i4)' ) TRIM( rn_dep_file ), nyear ! add year 338 IF( sn_dep_rnf%cltype == 'monthly' ) WRITE(rn_dep_file, '(a,"m",i2)' ) TRIM( rn_dep_file ), nmonth ! add month 339 ENDIF 340 340 CALL iom_open ( rn_dep_file, inum ) ! open file 341 341 CALL iom_get ( inum, jpdom_data, sn_dep_rnf%clvar, h_rnf ) ! read the river mouth array … … 352 352 ELSEIF( h_rnf(ji,jj) == -999._wp ) THEN ; nk_rnf(ji,jj) = mbkt(ji,jj) 353 353 ELSE 354 CALL ctl_stop( ' runoff depth not positive, and not -999 or -1, rnf value in file fort.999' )355 WRITE(999,*) 'ji, jj, rnf(ji,jj) :', ji, jj,rnf(ji,jj)354 CALL ctl_stop( 'sbc_rnf_init: runoff depth not positive, and not -999 or -1, rnf value in file fort.999' ) 355 WRITE(999,*) 'ji, jj, h_rnf(ji,jj) :', ji, jj, h_rnf(ji,jj) 356 356 ENDIF 357 357 END DO
Note: See TracChangeset
for help on using the changeset viewer.