Changeset 10010
- Timestamp:
- 2018-07-29T13:40:45+02:00 (6 years ago)
- Location:
- NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_all_update.F90
r9780 r10010 48 48 CALL Agrif_Update_ssh() ! Update sea level 49 49 ! 50 IF (.NOT.ln_linssh) CALL Agrif_Update_vvl() ! Update scale factors50 IF (.NOT.ln_linssh) CALL Agrif_Update_vvl() ! Update vertical mesh from ssh 51 51 ! 52 52 CALL Agrif_Update_tra() ! Update temperature/salinity -
NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_oce_update.F90
r10009 r10010 249 249 INTEGER :: jk ! dummy loop index 250 250 REAL(wp):: zcoef ! local scalar 251 !!----------------------------------------------------------------------252 ! 253 IF (lwp.AND.lk_agrif_debug) Write(*,*) 'Finalize e3 on grid Number', &254 &Agrif_Fixed(), 'Step', Agrif_Nb_Step()251 REAL(wp), DIMENSION(jpi,jpj) :: zssht_h, zsshu_h, zsshv_h, zsshf_h 252 !!---------------------------------------------------------------------- 253 ! 254 IF (lwp.AND.lk_agrif_debug) Write(*,*) 'Finalize e3 on grid Number', Agrif_Fixed(), 'Step', Agrif_Nb_Step() 255 255 256 256 ! Save "old" scale factor (prior update) for subsequent asselin correction of prognostic variables … … 263 263 hv_a(:,:) = hv_n(:,:) 264 264 265 ! 1) NOW fields 266 !-------------- 267 ! ! Vertical scale factor interpolations 268 CALL dom_vvl_interpol( e3t_n(:,:,:), e3u_n (:,:,:) , 'U' ) 269 CALL dom_vvl_interpol( e3t_n(:,:,:), e3v_n (:,:,:) , 'V' ) 270 CALL dom_vvl_interpol( e3u_n(:,:,:), e3f_n (:,:,:) , 'F' ) 271 CALL dom_vvl_interpol( e3u_n(:,:,:), e3uw_n(:,:,:), 'UW' ) 272 CALL dom_vvl_interpol( e3v_n(:,:,:), e3vw_n(:,:,:), 'VW' ) 273 ! 274 ! ! Update total depths 275 hu_n(:,:) = 0._wp ! Ocean depth at U-points 276 hv_n(:,:) = 0._wp ! Ocean depth at V-points 277 DO jk = 1, jpkm1 278 hu_n(:,:) = hu_n(:,:) + e3u_n(:,:,jk) * umask(:,:,jk) 279 hv_n(:,:) = hv_n(:,:) + e3v_n(:,:,jk) * vmask(:,:,jk) 280 END DO 281 ! ! Inverse of the local depth 282 r1_hu_n(:,:) = ssumask(:,:) / ( hu_n(:,:) + 1._wp - ssumask(:,:) ) 283 r1_hv_n(:,:) = ssvmask(:,:) / ( hv_n(:,:) + 1._wp - ssvmask(:,:) ) 284 285 286 ! 2) BEFORE fields: 287 !------------------ 265 ! !* NOW fields : 266 CALL ssh2e3_now ! set: ht , hu , hv , r1_hu, r1_hv 267 ! ! e3t, e3w, e3u, e3uw, e3v, e3vw, e3f (from 1 to jpkm1) 268 ! ! gdept_n, gdepw_n, gde3w_n 269 270 ! !* BEFORE fields : 288 271 IF (.NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) THEN 289 !!gm IF (.NOT.(lk_agrif_fstep.AND.(neuler==0) )) THEN 290 ! ! Vertical scale factor interpolations 291 CALL dom_vvl_interpol( e3t_b(:,:,:), e3u_b (:,:,:), 'U' ) 292 CALL dom_vvl_interpol( e3t_b(:,:,:), e3v_b (:,:,:), 'V' ) 293 CALL dom_vvl_interpol( e3u_b(:,:,:), e3uw_b(:,:,:), 'UW' ) 294 CALL dom_vvl_interpol( e3v_b(:,:,:), e3vw_b(:,:,:), 'VW' ) 295 ! 296 ! ! Update total depths: 297 hu_b(:,:) = 0._wp ! Ocean depth at U-points 298 hv_b(:,:) = 0._wp ! Ocean depth at V-points 299 DO jk = 1, jpkm1 300 hu_b(:,:) = hu_b(:,:) + e3u_b(:,:,jk) * umask(:,:,jk) 301 hv_b(:,:) = hv_b(:,:) + e3v_b(:,:,jk) * vmask(:,:,jk) 302 END DO 303 ! ! Inverse of the local depth 304 r1_hu_b(:,:) = ssumask(:,:) / ( hu_b(:,:) + 1._wp - ssumask(:,:) ) 305 r1_hv_b(:,:) = ssvmask(:,:) / ( hv_b(:,:) + 1._wp - ssvmask(:,:) ) 272 ! 273 CALL ssh2e3_before ! set: hu , hv , r1_hu, r1_hv 274 ! ! e3t, e3w, e3u, e3uw, e3v, e3vw (from 1 to jpkm1) 275 ! 306 276 ENDIF 307 277 ! … … 457 427 ztnu = tabres(ji,jj,jk,jn) 458 428 ztno = tsn(ji,jj,jk,jn) * e3t_a(ji,jj,jk) 459 tsb(ji,jj,jk,jn) = ( ztb + rn_ rn_atfp * ( ztnu - ztno) ) / e3t_b(ji,jj,jk) * tmask(ji,jj,jk)429 tsb(ji,jj,jk,jn) = ( ztb + rn_atfp * ( ztnu - ztno) ) / e3t_b(ji,jj,jk) * tmask(ji,jj,jk) 460 430 ENDIF 461 431 END DO … … 971 941 ! Update barotropic velocities: 972 942 IF ( .NOT.ln_dynspg_ts .OR. ( ln_dynspg_ts .AND. .NOT.ln_bt_fw ) ) THEN 973 IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) THEN ! Add asselin part943 IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) THEN ! Add asselin part 974 944 !!gm IF (.NOT.(lk_agrif_fstep.AND.(neuler==0))) THEN ! Add asselin part 975 945 zcorr = (tabres(ji,jj) - vn_b(ji,jj) * hv_a(ji,jj)) * r1_hv_b(ji,jj) … … 1212 1182 zcor = rn_Dt * r1_e1e2t(ji,j1 ) * e1v(ji,j1 ) * ( vb2_b(ji,j1)-tabres(ji,j1) ) 1213 1183 ssh(ji,j1 ,Nnn) = ssh(ji,j1 ,Nnn) + zcor 1214 IF ( .NOT.( lk_agrif_fstep .AND. l_ euler ) ) ssh(ji,j1 ,Nbb) = ssh(ji,j1,Nbb) + rn_atfp * zcor1184 IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) ssh(ji,j1 ,Nbb) = ssh(ji,j1,Nbb) + rn_atfp * zcor 1215 1185 !!gm IF (.NOT.(lk_agrif_fstep.AND.(neuler==0))) sshb(ji,j1 ) = sshb(ji,j1) + rn_atfp * zcor 1216 1186 END DO … … 1367 1337 ! hdivn(i1:i2,j1:j2,1:jpkm1) = e3t_b(i1:i2,j1:j2,1:jpkm1) 1368 1338 1369 IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ==0) ) THEN1339 IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) THEN 1370 1340 !!gm IF (.NOT.(lk_agrif_fstep.AND.(neuler==0) )) THEN 1371 1341 DO jk = 1, jpkm1 -
NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/OCE/stpRK3.F90
r10001 r10010 314 314 ! AGRIF 315 315 !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 316 CALL Agrif_Integrate_ChildGrids( stp ) ! allows to finish all the Child Grids before updating316 CALL Agrif_Integrate_ChildGrids( stp_RK3 ) ! allows to finish all the Child Grids before updating 317 317 318 318 IF( Agrif_NbStepint() == 0 ) CALL Agrif_update_all( ) ! Update all components
Note: See TracChangeset
for help on using the changeset viewer.