Changeset 4180
- Timestamp:
- 2013-11-11T19:10:34+01:00 (11 years ago)
- Location:
- branches/2013/dev_UKMO_2013/NEMOGCM
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2013/dev_UKMO_2013/NEMOGCM/CONFIG/AMM12/EXP00/namelist
r4170 r4180 28 28 nn_it000 = 1 ! first time step 29 29 nn_itend = 2880 ! last time step (std 1 day = 288) 30 nn_date0 = 20 070101 ! date at nit_0000 (format yyyymmdd) used if ln_rstart=F or (ln_rstart=T and nn_rstctl=0 or 1)30 nn_date0 = 20120101 ! date at nit_0000 (format yyyymmdd) used if ln_rstart=F or (ln_rstart=T and nn_rstctl=0 or 1) 31 31 nn_leapy = 1 ! Leap year calendar (1) or not (0) 32 32 ln_rstart = .true. ! start from rest (F) or from a restart file (T) … … 140 140 nn_fsbc = 1 ! frequency of surface boundary condition computation 141 141 ! (also = the frequency of sea-ice model call) 142 ln_ana = .false 142 ln_ana = .false. ! analytical formulation (T => fill namsbc_ana ) 143 143 ln_flx = .true. ! flux formulation (T => fill namsbc_flx ) 144 144 ln_blk_clio = .false. ! CLIO bulk formulation (T => fill namsbc_clio) … … 469 469 ! ! file name ! frequency (hours) ! variable ! time interpol. ! clim ! 'yearly'/ ! weights ! rotation ! 470 470 ! ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! filename ! pairing ! 471 bn_ssh = 'amm12_bdyT_ u2d' , 24 , 'sossheig' , .true. , .false. , 'daily' , '' , ''472 bn_u2d = 'amm12_bdyU_ u2d' , 24 , 'vobtcrtx' , .true. , .false. , 'daily' , '' , ''473 bn_v2d = 'amm12_bdyV_ u2d' , 24 , 'vobtcrty' , .true. , .false. , 'daily' , '' , ''474 bn_u3d = 'amm12_bdyU_ u3d' , 24 , 'vozocrtx' , .true. , .false. , 'daily' , '' , ''475 bn_v3d = 'amm12_bdyV_ u3d' , 24 , 'vomecrty' , .true. , .false. , 'daily' , '' , ''471 bn_ssh = 'amm12_bdyT_dyn2d' , 24 , 'sossheig' , .true. , .false. , 'daily' , '' , '' 472 bn_u2d = 'amm12_bdyU_dyn2d' , 24 , 'vobtcrtx' , .true. , .false. , 'daily' , '' , '' 473 bn_v2d = 'amm12_bdyV_dyn2d' , 24 , 'vobtcrty' , .true. , .false. , 'daily' , '' , '' 474 bn_u3d = 'amm12_bdyU_dyn3d' , 24 , 'vozocrtx' , .true. , .false. , 'daily' , '' , '' 475 bn_v3d = 'amm12_bdyV_dyn3d' , 24 , 'vomecrty' , .true. , .false. , 'daily' , '' , '' 476 476 bn_tem = 'amm12_bdyT_tra' , 24 , 'votemper' , .true. , .false. , 'daily' , '' , '' 477 477 bn_sal = 'amm12_bdyT_tra' , 24 , 'vosaline' , .true. , .false. , 'daily' , '' , '' -
branches/2013/dev_UKMO_2013/NEMOGCM/NEMO/OPA_SRC/DOM/domzgr.F90
r4171 r4180 1102 1102 INTEGER :: iip1, ijp1, iim1, ijm1 ! temporary integers 1103 1103 REAL(wp) :: zrmax, ztaper ! temporary scalars 1104 ! 1105 REAL(wp), POINTER, DIMENSION(:,: ) :: zenv, ztmp, zmsk, zri, zrj, zhbat 1104 REAL(wp) :: zrfact ! temporary scalars 1105 REAL(wp), POINTER, DIMENSION(:,: ) :: ztmpi1, ztmpi2, ztmpj1, ztmpj2 1106 1107 ! 1108 REAL(wp), POINTER, DIMENSION(:,: ) :: zenv, zri, zrj, zhbat 1106 1109 1107 1110 NAMELIST/namzgr_sco/ln_s_sh94, ln_s_sf12, ln_sigcrit, rn_sbot_min, rn_sbot_max, rn_hc, rn_rmax,rn_theta, & … … 1111 1114 IF( nn_timing == 1 ) CALL timing_start('zgr_sco') 1112 1115 ! 1113 CALL wrk_alloc( jpi, jpj, zenv, ztmp, zmsk, zri, zrj, zhbat ) 1114 ! 1116 CALL wrk_alloc( jpi, jpj, ztmpi1, ztmpi2, ztmpj1, ztmpj2 ) 1117 CALL wrk_alloc( jpi, jpj, zenv, zri, zrj, zhbat ) 1118 ! 1115 1119 REWIND( numnam ) ! Read Namelist namzgr_sco : sigma-stretching parameters 1116 1120 READ ( numnam, namzgr_sco ) … … 1159 1163 ! ! ============================= 1160 1164 ! use r-value to create hybrid coordinates 1165 zenv(:,:) = bathy(:,:) 1166 ! 1167 ! set first land point adjacent to a wet cell to sbot_min as this needs to be included in smoothing 1161 1168 DO jj = 1, jpj 1162 1169 DO ji = 1, jpi 1163 zenv(ji,jj) = MAX( bathy(ji,jj), rn_sbot_min ) 1164 END DO 1165 END DO 1170 IF( bathy(ji,jj) == 0._wp ) THEN 1171 iip1 = MIN( ji+1, jpi ) 1172 ijp1 = MIN( jj+1, jpj ) 1173 iim1 = MAX( ji-1, 1 ) 1174 ijm1 = MAX( jj-1, 1 ) 1175 IF( (bathy(iip1,jj) + bathy(iim1,jj) + bathy(ji,ijp1) + bathy(ji,ijm1) + & 1176 & bathy(iip1,ijp1) + bathy(iim1,ijm1) + bathy(iip1,ijp1) + bathy(iim1,ijm1)) > 0._wp ) THEN 1177 zenv(ji,jj) = rn_sbot_min 1178 ENDIF 1179 ENDIF 1180 END DO 1181 END DO 1182 ! apply lateral boundary condition CAUTION: keep the value when the lbc field is zero 1183 CALL lbc_lnk( zenv, 'T', 1._wp, 'no0' ) 1166 1184 ! 1167 ! Smooth the bathymetry (if required)1185 ! smooth the bathymetry (if required) 1168 1186 scosrf(:,:) = 0._wp ! ocean surface depth (here zero: no under ice-shelf sea) 1169 1187 scobot(:,:) = bathy(:,:) ! ocean bottom depth … … 1171 1189 jl = 0 1172 1190 zrmax = 1._wp 1173 ! ! ================ ! 1174 DO WHILE( jl <= 10000 .AND. zrmax > rn_rmax ) ! Iterative loop ! 1175 ! ! ================ ! 1191 ! 1192 ! set scaling factor used in reducing vertical gradients 1193 zrfact = ( 1._wp - rn_rmax ) / ( 1._wp + rn_rmax ) 1194 ! 1195 ! initialise temporary evelope depth arrays 1196 ztmpi1(:,:) = zenv(:,:) 1197 ztmpi2(:,:) = zenv(:,:) 1198 ztmpj1(:,:) = zenv(:,:) 1199 ztmpj2(:,:) = zenv(:,:) 1200 ! 1201 ! initialise temporary r-value arrays 1202 zri(:,:) = 1._wp 1203 zrj(:,:) = 1._wp 1204 ! ! ================ ! 1205 DO WHILE( jl <= 10000 .AND. ( zrmax - rn_rmax ) > 1.e-8_wp ) ! Iterative loop ! 1206 ! ! ================ ! 1176 1207 jl = jl + 1 1177 1208 zrmax = 0._wp 1178 zmsk(:,:) = 0._wp 1209 ! we set zrmax from previous r-values (zri and zrj) first 1210 ! if set after current r-value calculation (as previously) 1211 ! we could exit DO WHILE prematurely before checking r-value 1212 ! of current zenv 1213 DO jj = 1, nlcj 1214 DO ji = 1, nlci 1215 zrmax = MAX( zrmax, ABS(zri(ji,jj)), ABS(zrj(ji,jj)) ) 1216 END DO 1217 END DO 1218 zri(:,:) = 0._wp 1219 zrj(:,:) = 0._wp 1179 1220 DO jj = 1, nlcj 1180 1221 DO ji = 1, nlci 1181 1222 iip1 = MIN( ji+1, nlci ) ! force zri = 0 on last line (ji=ncli+1 to jpi) 1182 1223 ijp1 = MIN( jj+1, nlcj ) ! force zrj = 0 on last raw (jj=nclj+1 to jpj) 1183 zri(ji,jj) = ABS( zenv(iip1,jj ) - zenv(ji,jj) ) / ( zenv(iip1,jj ) + zenv(ji,jj) ) 1184 zrj(ji,jj) = ABS( zenv(ji ,ijp1) - zenv(ji,jj) ) / ( zenv(ji ,ijp1) + zenv(ji,jj) ) 1185 zrmax = MAX( zrmax, zri(ji,jj), zrj(ji,jj) ) 1186 IF( zri(ji,jj) > rn_rmax ) zmsk(ji ,jj ) = 1._wp 1187 IF( zri(ji,jj) > rn_rmax ) zmsk(iip1,jj ) = 1._wp 1188 IF( zrj(ji,jj) > rn_rmax ) zmsk(ji ,jj ) = 1._wp 1189 IF( zrj(ji,jj) > rn_rmax ) zmsk(ji ,ijp1) = 1._wp 1224 IF( (zenv(ji,jj) > 0._wp) .AND. (zenv(iip1,jj) > 0._wp)) THEN 1225 zri(ji,jj) = ( zenv(iip1,jj ) - zenv(ji,jj) ) / ( zenv(iip1,jj ) + zenv(ji,jj) ) 1226 END IF 1227 IF( (zenv(ji,jj) > 0._wp) .AND. (zenv(ji,ijp1) > 0._wp)) THEN 1228 zrj(ji,jj) = ( zenv(ji ,ijp1) - zenv(ji,jj) ) / ( zenv(ji ,ijp1) + zenv(ji,jj) ) 1229 END IF 1230 IF( zri(ji,jj) > rn_rmax ) ztmpi1(ji ,jj ) = zenv(iip1,jj ) * zrfact 1231 IF( zri(ji,jj) < -rn_rmax ) ztmpi2(iip1,jj ) = zenv(ji ,jj ) * zrfact 1232 IF( zrj(ji,jj) > rn_rmax ) ztmpj1(ji ,jj ) = zenv(ji ,ijp1) * zrfact 1233 IF( zrj(ji,jj) < -rn_rmax ) ztmpj2(ji ,ijp1) = zenv(ji ,jj ) * zrfact 1190 1234 END DO 1191 1235 END DO 1192 1236 IF( lk_mpp ) CALL mpp_max( zrmax ) ! max over the global domain 1193 ! lateral boundary condition on zmsk: keep 1 along closed boundary (use of MAX)1194 ztmp(:,:) = zmsk(:,:) ; CALL lbc_lnk( zmsk, 'T', 1._wp )1195 DO jj = 1, nlcj1196 DO ji = 1, nlci1197 zmsk(ji,jj) = MAX( zmsk(ji,jj), ztmp(ji,jj) )1198 END DO1199 END DO1200 1237 ! 1201 IF(lwp)WRITE(numout,*) 'zgr_sco : iter= ',jl, ' rmax= ', zrmax , ' nb of pt= ', INT( SUM(zmsk(:,:) ) )1238 IF(lwp)WRITE(numout,*) 'zgr_sco : iter= ',jl, ' rmax= ', zrmax 1202 1239 ! 1203 1240 DO jj = 1, nlcj 1204 1241 DO ji = 1, nlci 1205 iip1 = MIN( ji+1, nlci ) ! last line (ji=nlci) 1206 ijp1 = MIN( jj+1, nlcj ) ! last raw (jj=nlcj) 1207 iim1 = MAX( ji-1, 1 ) ! first line (ji=nlci) 1208 ijm1 = MAX( jj-1, 1 ) ! first raw (jj=nlcj) 1209 IF( zmsk(ji,jj) == 1._wp ) THEN 1210 ztmp(ji,jj) = ( & 1211 & zenv(iim1,ijp1)*zmsk(iim1,ijp1) + zenv(ji,ijp1)*zmsk(ji,ijp1) + zenv(iip1,ijp1)*zmsk(iip1,ijp1) & 1212 & + zenv(iim1,jj )*zmsk(iim1,jj ) + zenv(ji,jj )* 2._wp + zenv(iip1,jj )*zmsk(iip1,jj ) & 1213 & + zenv(iim1,ijm1)*zmsk(iim1,ijm1) + zenv(ji,ijm1)*zmsk(ji,ijm1) + zenv(iip1,ijm1)*zmsk(iip1,ijm1) & 1214 & ) / ( & 1215 & zmsk(iim1,ijp1) + zmsk(ji,ijp1) + zmsk(iip1,ijp1) & 1216 & + zmsk(iim1,jj ) + 2._wp + zmsk(iip1,jj ) & 1217 & + zmsk(iim1,ijm1) + zmsk(ji,ijm1) + zmsk(iip1,ijm1) & 1218 & ) 1219 ENDIF 1220 END DO 1221 END DO 1222 ! 1223 DO jj = 1, nlcj 1224 DO ji = 1, nlci 1225 IF( zmsk(ji,jj) == 1._wp ) zenv(ji,jj) = MAX( ztmp(ji,jj), bathy(ji,jj) ) 1226 END DO 1227 END DO 1228 ! 1229 ! Apply lateral boundary condition CAUTION: keep the value when the lbc field is zero 1230 ztmp(:,:) = zenv(:,:) ; CALL lbc_lnk( zenv, 'T', 1._wp ) 1231 DO jj = 1, nlcj 1232 DO ji = 1, nlci 1233 IF( zenv(ji,jj) == 0._wp ) zenv(ji,jj) = ztmp(ji,jj) 1234 END DO 1235 END DO 1242 zenv(ji,jj) = MAX(zenv(ji,jj), ztmpi1(ji,jj), ztmpi2(ji,jj), ztmpj1(ji,jj), ztmpj2(ji,jj) ) 1243 END DO 1244 END DO 1245 ! apply lateral boundary condition CAUTION: keep the value when the lbc field is zero 1246 CALL lbc_lnk( zenv, 'T', 1._wp, 'no0' ) 1236 1247 ! ! ================ ! 1237 1248 END DO ! End loop ! 1238 1249 ! ! ================ ! 1239 ! 1240 ! Fill ghost rows with appropriate values to avoid undefined e3 values with some mpp decompositions 1241 DO ji = nlci+1, jpi 1242 zenv(ji,1:nlcj) = zenv(nlci,1:nlcj) 1243 END DO 1244 ! 1245 DO jj = nlcj+1, jpj 1246 zenv(:,jj) = zenv(:,nlcj) 1250 DO jj = 1, jpj 1251 DO ji = 1, jpi 1252 zenv(ji,jj) = MAX( zenv(ji,jj), rn_sbot_min ) ! set all points to avoid undefined scale value warnings 1253 END DO 1247 1254 END DO 1248 1255 ! 1249 1256 ! Envelope bathymetry saved in hbatt 1250 1257 hbatt(:,:) = zenv(:,:) 1258 1251 1259 IF( MINVAL( gphit(:,:) ) * MAXVAL( gphit(:,:) ) <= 0._wp ) THEN 1252 1260 CALL ctl_warn( ' s-coordinates are tapered in vicinity of the Equator' ) … … 1522 1530 END DO 1523 1531 ! 1524 CALL wrk_dealloc( jpi, jpj, zenv, ztmp, zmsk, zri, zrj, zhbat ) 1525 ! 1532 CALL wrk_dealloc( jpi, jpj, zenv, ztmpi1, ztmpi2, ztmpj1, ztmpj2, zri, zrj, zhbat ) ! 1526 1533 IF( nn_timing == 1 ) CALL timing_stop('zgr_sco') 1527 1534 !
Note: See TracChangeset
for help on using the changeset viewer.