- Timestamp:
- 2018-10-29T15:20:26+01:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/UKMO/dev_r5518_AMM15_package/NEMOGCM/NEMO/OPA_SRC/ZDF/zdfmxl.F90
r10249 r10251 18 18 USE phycst ! physical constants 19 19 USE iom ! I/O library 20 USE eosbn2 ! for zdf_mxl_zint21 20 USE lib_mpp ! MPP library 22 21 USE wrk_nemo ! work arrays … … 27 26 PRIVATE 28 27 29 PUBLIC zdf_mxl_tref ! called by asminc.F9030 28 PUBLIC zdf_mxl ! called by step.F90 31 29 32 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: hmld_tref !: mixed layer depth at t-points - temperature criterion [m]33 30 INTEGER , PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: nmln !: number of level in the mixed layer (used by TOP) 34 31 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: hmld !: mixing layer depth (turbocline) [m] 35 32 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: hmlp !: mixed layer depth (rho=rho0+zdcrit) [m] 36 33 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: hmlpt !: mixed layer depth at t-points [m] 37 REAL(wp), PUBLIC, ALLOCATABLE, DIMENSION(:,:) :: hmld_zint !: vertically-interpolated mixed layer depth [m]38 REAL(wp), PUBLIC, ALLOCATABLE, DIMENSION(:,:) :: htc_mld ! Heat content of hmld_zint39 LOGICAL, PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: ll_found ! Is T_b to be found by interpolation ?40 LOGICAL, PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:,:) :: ll_belowml ! Flag points below mixed layer when ll_found=F41 34 42 35 REAL(wp), PUBLIC :: rho_c = 0.01_wp !: density criterion for mixed layer depth 43 36 REAL(wp) :: avt_c = 5.e-4_wp ! Kz criterion for the turbocline depth 44 45 TYPE, PUBLIC :: MXL_ZINT !: Structure for MLD defs46 INTEGER :: mld_type ! mixed layer type47 REAL(wp) :: zref ! depth of initial T_ref48 REAL(wp) :: dT_crit ! Critical temp diff49 REAL(wp) :: iso_frac ! Fraction of rn_dT_crit used50 END TYPE MXL_ZINT51 52 !Used for 25h mean53 LOGICAL, PRIVATE :: mld_25h_init = .TRUE. !Logical used to initalise 25h54 !outputs. Necassary, because we need to55 !initalise the mld_25h on the zeroth56 !timestep (i.e in the nemogcm_init call)57 LOGICAL, PRIVATE :: mld_25h_write = .FALSE. !Logical confirm 25h calculating/processing58 59 INTEGER, SAVE :: i_cnt_25h ! Counter for 25 hour means60 61 REAL(wp),SAVE, ALLOCATABLE, DIMENSION(:,:,:) :: hmld_zint_25h62 37 63 38 !! * Substitutions … … 76 51 zdf_mxl_alloc = 0 ! set to zero if no array to be allocated 77 52 IF( .NOT. ALLOCATED( nmln ) ) THEN 78 ALLOCATE( nmln(jpi,jpj), hmld(jpi,jpj), hmlp(jpi,jpj), hmlpt(jpi,jpj), hmld_zint(jpi,jpj), & 79 & htc_mld(jpi,jpj), & 80 & ll_found(jpi,jpj), ll_belowml(jpi,jpj,jpk), STAT= zdf_mxl_alloc ) 53 ALLOCATE( nmln(jpi,jpj), hmld(jpi,jpj), hmlp(jpi,jpj), hmlpt(jpi,jpj), STAT= zdf_mxl_alloc ) 81 54 ! 82 ALLOCATE(hmld_tref(jpi,jpj))83 55 IF( lk_mpp ) CALL mpp_sum ( zdf_mxl_alloc ) 84 56 IF( zdf_mxl_alloc /= 0 ) CALL ctl_warn('zdf_mxl_alloc: failed to allocate arrays.') … … 87 59 END FUNCTION zdf_mxl_alloc 88 60 89 SUBROUTINE zdf_mxl_tref()90 !!----------------------------------------------------------------------91 !! *** ROUTINE zdf_mxl_tref ***92 !!93 !! ** Purpose : Compute the mixed layer depth with temperature criteria.94 !!95 !! ** Method : The temperature-defined mixed layer depth is required96 !! when assimilating SST in a 2D analysis.97 !!98 !! ** Action : hmld_tref99 !!----------------------------------------------------------------------100 !101 INTEGER :: ji, jj, jk ! dummy loop indices102 REAL(wp) :: t_ref ! Reference temperature103 REAL(wp) :: temp_c = 0.2 ! temperature criterion for mixed layer depth104 !!----------------------------------------------------------------------105 !106 ! Initialise array107 IF( zdf_mxl_alloc() /= 0 ) CALL ctl_stop( 'STOP', 'zdf_mxl_tref : unable to allocate arrays' )108 109 !For the AMM model assimiation uses a temperature based mixed layer depth110 !This is defined here111 DO jj = 1, jpj112 DO ji = 1, jpi113 hmld_tref(ji,jj)=fsdept(ji,jj,1 )114 IF(ssmask(ji,jj) > 0.)THEN115 t_ref=tsn(ji,jj,1,jp_tem)116 DO jk=2,jpk117 IF(ssmask(ji,jj)==0.)THEN118 hmld_tref(ji,jj)=fsdept(ji,jj,jk )119 EXIT120 ELSEIF( ABS(tsn(ji,jj,jk,jp_tem)-t_ref) < temp_c)THEN121 hmld_tref(ji,jj)=fsdept(ji,jj,jk )122 ELSE123 EXIT124 ENDIF125 ENDDO126 ENDIF127 ENDDO128 ENDDO129 130 END SUBROUTINE zdf_mxl_tref131 61 132 62 SUBROUTINE zdf_mxl( kt ) … … 207 137 ENDIF 208 138 209 ! Vertically-interpolated mixed-layer depth diagnostic210 CALL zdf_mxl_zint( kt )211 212 139 IF(ln_ctl) CALL prt_ctl( tab2d_1=REAL(nmln,wp), clinfo1=' nmln : ', tab2d_2=hmlp, clinfo2=' hmlp : ', ovlap=1 ) 213 140 ! … … 218 145 END SUBROUTINE zdf_mxl 219 146 220 SUBROUTINE zdf_mxl_zint_mld( sf )221 !!----------------------------------------------------------------------------------222 !! *** ROUTINE zdf_mxl_zint_mld ***223 !224 ! Calculate vertically-interpolated mixed layer depth diagnostic.225 !226 ! This routine can calculate the mixed layer depth diagnostic suggested by227 ! Kara et al, 2000, JGR, 105, 16803, but is more general and can calculate228 ! vertically-interpolated mixed-layer depth diagnostics with other parameter229 ! settings set in the namzdf_mldzint namelist.230 !231 ! If mld_type=1 the mixed layer depth is calculated as the depth at which the232 ! density has increased by an amount equivalent to a temperature difference of233 ! 0.8C at the surface.234 !235 ! For other values of mld_type the mixed layer is calculated as the depth at236 ! which the temperature differs by 0.8C from the surface temperature.237 !238 ! David Acreman, Daley Calvert239 !240 !!-----------------------------------------------------------------------------------241 242 TYPE(MXL_ZINT), INTENT(in) :: sf243 244 ! Diagnostic criteria245 INTEGER :: nn_mld_type ! mixed layer type246 REAL(wp) :: rn_zref ! depth of initial T_ref247 REAL(wp) :: rn_dT_crit ! Critical temp diff248 REAL(wp) :: rn_iso_frac ! Fraction of rn_dT_crit used249 250 ! Local variables251 REAL(wp), PARAMETER :: zepsilon = 1.e-30 ! local small value252 INTEGER, POINTER, DIMENSION(:,:) :: ikmt ! number of active tracer levels253 INTEGER, POINTER, DIMENSION(:,:) :: ik_ref ! index of reference level254 INTEGER, POINTER, DIMENSION(:,:) :: ik_iso ! index of last uniform temp level255 REAL, POINTER, DIMENSION(:,:,:) :: zT ! Temperature or density256 REAL, POINTER, DIMENSION(:,:) :: ppzdep ! depth for use in calculating d(rho)257 REAL, POINTER, DIMENSION(:,:) :: zT_ref ! reference temperature258 REAL :: zT_b ! base temperature259 REAL, POINTER, DIMENSION(:,:,:) :: zdTdz ! gradient of zT260 REAL, POINTER, DIMENSION(:,:,:) :: zmoddT ! Absolute temperature difference261 REAL :: zdz ! depth difference262 REAL :: zdT ! temperature difference263 REAL, POINTER, DIMENSION(:,:) :: zdelta_T ! difference critereon264 REAL, POINTER, DIMENSION(:,:) :: zRHO1, zRHO2 ! Densities265 INTEGER :: ji, jj, jk ! loop counter266 267 !!-------------------------------------------------------------------------------------268 !269 CALL wrk_alloc( jpi, jpj, ikmt, ik_ref, ik_iso)270 CALL wrk_alloc( jpi, jpj, ppzdep, zT_ref, zdelta_T, zRHO1, zRHO2 )271 CALL wrk_alloc( jpi, jpj, jpk, zT, zdTdz, zmoddT )272 273 ! Unpack structure274 nn_mld_type = sf%mld_type275 rn_zref = sf%zref276 rn_dT_crit = sf%dT_crit277 rn_iso_frac = sf%iso_frac278 279 ! Set the mixed layer depth criterion at each grid point280 IF( nn_mld_type == 0 ) THEN281 zdelta_T(:,:) = rn_dT_crit282 zT(:,:,:) = rhop(:,:,:)283 ELSE IF( nn_mld_type == 1 ) THEN284 ppzdep(:,:)=0.0285 call eos ( tsn(:,:,1,:), ppzdep(:,:), zRHO1(:,:) )286 ! Use zT temporarily as a copy of tsn with rn_dT_crit added to SST287 ! [assumes number of tracers less than number of vertical levels]288 zT(:,:,1:jpts)=tsn(:,:,1,1:jpts)289 zT(:,:,jp_tem)=zT(:,:,1)+rn_dT_crit290 CALL eos( zT(:,:,1:jpts), ppzdep(:,:), zRHO2(:,:) )291 zdelta_T(:,:) = abs( zRHO1(:,:) - zRHO2(:,:) ) * rau0292 ! RHO from eos (2d version) doesn't calculate north or east halo:293 CALL lbc_lnk( zdelta_T, 'T', 1. )294 zT(:,:,:) = rhop(:,:,:)295 ELSE296 zdelta_T(:,:) = rn_dT_crit297 zT(:,:,:) = tsn(:,:,:,jp_tem)298 END IF299 300 ! Calculate the gradient of zT and absolute difference for use later301 DO jk = 1 ,jpk-2302 zdTdz(:,:,jk) = ( zT(:,:,jk+1) - zT(:,:,jk) ) / fse3w(:,:,jk+1)303 zmoddT(:,:,jk) = abs( zT(:,:,jk+1) - zT(:,:,jk) )304 END DO305 306 ! Find density/temperature at the reference level (Kara et al use 10m).307 ! ik_ref is the index of the box centre immediately above or at the reference level308 ! Find rn_zref in the array of model level depths and find the ref309 ! density/temperature by linear interpolation.310 DO jk = jpkm1, 2, -1311 WHERE ( fsdept(:,:,jk) > rn_zref )312 ik_ref(:,:) = jk - 1313 zT_ref(:,:) = zT(:,:,jk-1) + zdTdz(:,:,jk-1) * ( rn_zref - fsdept(:,:,jk-1) )314 END WHERE315 END DO316 317 ! If the first grid box centre is below the reference level then use the318 ! top model level to get zT_ref319 WHERE ( fsdept(:,:,1) > rn_zref )320 zT_ref = zT(:,:,1)321 ik_ref = 1322 END WHERE323 324 ! The number of active tracer levels is 1 less than the number of active w levels325 ikmt(:,:) = mbathy(:,:) - 1326 327 ! Initialize / reset328 ll_found(:,:) = .false.329 330 IF ( rn_iso_frac - zepsilon > 0. ) THEN331 ! Search for a uniform density/temperature region where adjacent levels332 ! differ by less than rn_iso_frac * deltaT.333 ! ik_iso is the index of the last level in the uniform layer334 ! ll_found indicates whether the mixed layer depth can be found by interpolation335 ik_iso(:,:) = ik_ref(:,:)336 DO jj = 1, nlcj337 DO ji = 1, nlci338 !CDIR NOVECTOR339 DO jk = ik_ref(ji,jj), ikmt(ji,jj)-1340 IF ( zmoddT(ji,jj,jk) > ( rn_iso_frac * zdelta_T(ji,jj) ) ) THEN341 ik_iso(ji,jj) = jk342 ll_found(ji,jj) = ( zmoddT(ji,jj,jk) > zdelta_T(ji,jj) )343 EXIT344 END IF345 END DO346 END DO347 END DO348 349 ! Use linear interpolation to find depth of mixed layer base where possible350 hmld_zint(:,:) = rn_zref351 DO jj = 1, jpj352 DO ji = 1, jpi353 IF (ll_found(ji,jj) .and. tmask(ji,jj,1) == 1.0) THEN354 zdz = abs( zdelta_T(ji,jj) / zdTdz(ji,jj,ik_iso(ji,jj)) )355 hmld_zint(ji,jj) = fsdept(ji,jj,ik_iso(ji,jj)) + zdz356 END IF357 END DO358 END DO359 END IF360 361 ! If ll_found = .false. then calculate MLD using difference of zdelta_T362 ! from the reference density/temperature363 364 ! Prevent this section from working on land points365 WHERE ( tmask(:,:,1) /= 1.0 )366 ll_found = .true.367 END WHERE368 369 DO jk=1, jpk370 ll_belowml(:,:,jk) = abs( zT(:,:,jk) - zT_ref(:,:) ) >= zdelta_T(:,:)371 END DO372 373 ! Set default value where interpolation cannot be used (ll_found=false)374 DO jj = 1, jpj375 DO ji = 1, jpi376 IF ( .not. ll_found(ji,jj) ) hmld_zint(ji,jj) = fsdept(ji,jj,ikmt(ji,jj))377 END DO378 END DO379 380 DO jj = 1, jpj381 DO ji = 1, jpi382 !CDIR NOVECTOR383 DO jk = ik_ref(ji,jj)+1, ikmt(ji,jj)384 IF ( ll_found(ji,jj) ) EXIT385 IF ( ll_belowml(ji,jj,jk) ) THEN386 zT_b = zT_ref(ji,jj) + zdelta_T(ji,jj) * SIGN(1.0, zdTdz(ji,jj,jk-1) )387 zdT = zT_b - zT(ji,jj,jk-1)388 zdz = zdT / zdTdz(ji,jj,jk-1)389 hmld_zint(ji,jj) = fsdept(ji,jj,jk-1) + zdz390 EXIT391 END IF392 END DO393 END DO394 END DO395 396 hmld_zint(:,:) = hmld_zint(:,:)*tmask(:,:,1)397 !398 CALL wrk_dealloc( jpi, jpj, ikmt, ik_ref, ik_iso)399 CALL wrk_dealloc( jpi, jpj, ppzdep, zT_ref, zdelta_T, zRHO1, zRHO2 )400 CALL wrk_dealloc( jpi,jpj, jpk, zT, zdTdz, zmoddT )401 !402 END SUBROUTINE zdf_mxl_zint_mld403 404 SUBROUTINE zdf_mxl_zint_htc( kt )405 !!----------------------------------------------------------------------406 !! *** ROUTINE zdf_mxl_zint_htc ***407 !!408 !! ** Purpose :409 !!410 !! ** Method :411 !!----------------------------------------------------------------------412 413 INTEGER, INTENT(in) :: kt ! ocean time-step index414 415 INTEGER :: ji, jj, jk416 INTEGER :: ikmax417 REAL(wp) :: zc, zcoef418 !419 INTEGER, ALLOCATABLE, DIMENSION(:,:) :: ilevel420 REAL(wp), ALLOCATABLE, DIMENSION(:,:) :: zthick_0, zthick421 422 !!----------------------------------------------------------------------423 424 IF( .NOT. ALLOCATED(ilevel) ) THEN425 ALLOCATE( ilevel(jpi,jpj), zthick_0(jpi,jpj), &426 & zthick(jpi,jpj), STAT=ji )427 IF( lk_mpp ) CALL mpp_sum(ji)428 IF( ji /= 0 ) CALL ctl_stop( 'STOP', 'zdf_mxl_zint_htc : unable to allocate arrays' )429 ENDIF430 431 ! Find last whole model T level above the MLD432 ilevel(:,:) = 0433 zthick_0(:,:) = 0._wp434 435 DO jk = 1, jpkm1436 DO jj = 1, jpj437 DO ji = 1, jpi438 zthick_0(ji,jj) = zthick_0(ji,jj) + fse3t(ji,jj,jk)439 IF( zthick_0(ji,jj) < hmld_zint(ji,jj) ) ilevel(ji,jj) = jk440 END DO441 END DO442 WRITE(numout,*) 'zthick_0(jk =',jk,') =',zthick_0(2,2)443 WRITE(numout,*) 'fsdepw(jk+1 =',jk+1,') =',fsdepw(2,2,jk+1)444 END DO445 446 ! Surface boundary condition447 IF( lk_vvl ) THEN ; zthick(:,:) = 0._wp ; htc_mld(:,:) = 0._wp448 ELSE ; zthick(:,:) = sshn(:,:) ; htc_mld(:,:) = tsn(:,:,1,jp_tem) * sshn(:,:) * tmask(:,:,1)449 ENDIF450 451 ! Deepest whole T level above the MLD452 ikmax = MIN( MAXVAL( ilevel(:,:) ), jpkm1 )453 454 ! Integration down to last whole model T level455 DO jk = 1, ikmax456 DO jj = 1, jpj457 DO ji = 1, jpi458 zc = fse3t(ji,jj,jk) * REAL( MIN( MAX( 0, ilevel(ji,jj) - jk + 1 ) , 1 ) ) ! 0 below ilevel459 zthick(ji,jj) = zthick(ji,jj) + zc460 htc_mld(ji,jj) = htc_mld(ji,jj) + zc * tsn(ji,jj,jk,jp_tem) * tmask(ji,jj,jk)461 END DO462 END DO463 END DO464 465 ! Subsequent partial T level466 zthick(:,:) = hmld_zint(:,:) - zthick(:,:) ! remaining thickness to reach MLD467 468 DO jj = 1, jpj469 DO ji = 1, jpi470 htc_mld(ji,jj) = htc_mld(ji,jj) + tsn(ji,jj,ilevel(ji,jj)+1,jp_tem) &471 & * MIN( fse3t(ji,jj,ilevel(ji,jj)+1), zthick(ji,jj) ) * tmask(ji,jj,ilevel(ji,jj)+1)472 END DO473 END DO474 475 WRITE(numout,*) 'htc_mld(after) =',htc_mld(2,2)476 477 ! Convert to heat content478 zcoef = rau0 * rcp479 htc_mld(:,:) = zcoef * htc_mld(:,:)480 481 END SUBROUTINE zdf_mxl_zint_htc482 483 SUBROUTINE zdf_mxl_zint( kt )484 !!----------------------------------------------------------------------485 !! *** ROUTINE zdf_mxl_zint ***486 !!487 !! ** Purpose :488 !!489 !! ** Method :490 !!----------------------------------------------------------------------491 492 INTEGER, INTENT(in) :: kt ! ocean time-step index493 494 INTEGER :: ios495 INTEGER :: jn496 497 INTEGER :: nn_mld_diag = 0 ! number of diagnostics498 499 INTEGER :: i_steps ! no of timesteps per hour500 INTEGER :: ierror ! logical error message501 502 REAL(wp) :: zdt ! timestep variable503 504 CHARACTER(len=1) :: cmld505 506 TYPE(MXL_ZINT) :: sn_mld1, sn_mld2, sn_mld3, sn_mld4, sn_mld5507 TYPE(MXL_ZINT), SAVE, DIMENSION(5) :: mld_diags508 509 NAMELIST/namzdf_mldzint/ nn_mld_diag, sn_mld1, sn_mld2, sn_mld3, sn_mld4, sn_mld5510 511 !!----------------------------------------------------------------------512 513 IF( kt == nit000 ) THEN514 REWIND( numnam_ref ) ! Namelist namzdf_mldzint in reference namelist515 READ ( numnam_ref, namzdf_mldzint, IOSTAT = ios, ERR = 901)516 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzdf_mldzint in reference namelist', lwp )517 518 REWIND( numnam_cfg ) ! Namelist namzdf_mldzint in configuration namelist519 READ ( numnam_cfg, namzdf_mldzint, IOSTAT = ios, ERR = 902 )520 902 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzdf_mldzint in configuration namelist', lwp )521 IF(lwm) WRITE ( numond, namzdf_mldzint )522 523 IF( nn_mld_diag > 5 ) CALL ctl_stop( 'STOP', 'zdf_mxl_ini: Specify no more than 5 MLD definitions' )524 525 mld_diags(1) = sn_mld1526 mld_diags(2) = sn_mld2527 mld_diags(3) = sn_mld3528 mld_diags(4) = sn_mld4529 mld_diags(5) = sn_mld5530 531 IF( nn_mld_diag > 0 ) THEN532 WRITE(numout,*) '=============== Vertically-interpolated mixed layer ================'533 WRITE(numout,*) '(Diagnostic number, nn_mld_type, rn_zref, rn_dT_crit, rn_iso_frac)'534 DO jn = 1, nn_mld_diag535 WRITE(numout,*) 'MLD criterion',jn,':'536 WRITE(numout,*) ' nn_mld_type =', mld_diags(jn)%mld_type537 WRITE(numout,*) ' rn_zref =' , mld_diags(jn)%zref538 WRITE(numout,*) ' rn_dT_crit =' , mld_diags(jn)%dT_crit539 WRITE(numout,*) ' rn_iso_frac =', mld_diags(jn)%iso_frac540 END DO541 WRITE(numout,*) '===================================================================='542 ENDIF543 ENDIF544 545 IF( nn_mld_diag > 0 ) THEN546 DO jn = 1, nn_mld_diag547 WRITE(cmld,'(I1)') jn548 IF( iom_use( "mldzint_"//cmld ) .OR. iom_use( "mldhtc_"//cmld ) ) THEN549 CALL zdf_mxl_zint_mld( mld_diags(jn) )550 551 IF( iom_use( "mldzint_"//cmld ) ) THEN552 CALL iom_put( "mldzint_"//cmld, hmld_zint(:,:) )553 ENDIF554 555 IF( iom_use( "mldhtc_"//cmld ) ) THEN556 CALL zdf_mxl_zint_htc( kt )557 CALL iom_put( "mldhtc_"//cmld , htc_mld(:,:) )558 ENDIF559 560 IF( iom_use( "mldzint25h_"//cmld ) ) THEN561 IF( .NOT. mld_25h_write ) mld_25h_write = .TRUE.562 zdt = rdt563 IF( nacc == 1 ) zdt = rdtmin564 IF( MOD( 3600,INT(zdt) ) == 0 ) THEN565 i_steps = 3600/INT(zdt)566 ELSE567 CALL ctl_stop('STOP', 'zdf_mxl_zint 25h: timestep must give MOD(3600,rdt) = 0 otherwise no hourly values are possible')568 ENDIF569 IF( ( mld_25h_init ) .OR. ( kt == nit000 ) ) THEN570 i_cnt_25h = 1571 IF( .NOT. ALLOCATED(hmld_zint_25h) ) THEN572 ALLOCATE( hmld_zint_25h(jpi,jpj,nn_mld_diag), STAT=ierror )573 IF( ierror > 0 ) CALL ctl_stop( 'zdf_mxl_zint 25h: unable to allocate hmld_zint_25h' )574 ENDIF575 hmld_zint_25h(:,:,jn) = hmld_zint(:,:)576 ENDIF577 IF( MOD( kt, i_steps ) == 0 .AND. kt .NE. nn_it000 ) THEN578 hmld_zint_25h(:,:,jn) = hmld_zint_25h(:,:,jn) + hmld_zint(:,:)579 ENDIF580 IF( i_cnt_25h .EQ. 25 .AND. MOD( kt, i_steps*24) == 0 .AND. kt .NE. nn_it000 ) THEN581 CALL iom_put( "mldzint25h_"//cmld , hmld_zint_25h(:,:,jn) / 25._wp )582 ENDIF583 ENDIF584 585 ENDIF586 END DO587 588 IF( mld_25h_write ) THEN589 IF( ( MOD( kt, i_steps ) == 0 ) .OR. mld_25h_init ) THEN590 IF (lwp) THEN591 WRITE(numout,*) 'zdf_mxl_zint (25h) : Summed the following number of hourly values so far',i_cnt_25h592 ENDIF593 i_cnt_25h = i_cnt_25h + 1594 IF( mld_25h_init ) mld_25h_init = .FALSE.595 ENDIF596 IF( i_cnt_25h .EQ. 25 .AND. MOD( kt, i_steps*24) == 0 .AND. kt .NE. nn_it000 ) THEN597 i_cnt_25h = 1598 DO jn = 1, nn_mld_diag599 hmld_zint_25h(:,:,jn) = hmld_zint(:,:)600 ENDDO601 ENDIF602 ENDIF603 604 ENDIF605 606 END SUBROUTINE zdf_mxl_zint607 608 147 !!====================================================================== 609 148 END MODULE zdfmxl
Note: See TracChangeset
for help on using the changeset viewer.