New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 521 for trunk/NEMO/OPA_SRC/TRD/trdmld.F90 – NEMO

Ignore:
Timestamp:
2006-10-11T16:45:09+02:00 (18 years ago)
Author:
opalod
Message:

nemo_v1_update_73 : CT : build Mixed Layer restart files using iom

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEMO/OPA_SRC/TRD/trdmld.F90

    r503 r521  
    3535   USE lbclnk          ! ocean lateral boundary conditions (or mpp link) 
    3636   USE diadimg         ! dimg direct access file format output 
    37    USE trdmld_rst , ONLY : trd_mld_rst_read  ! restart for diagnosing the ML trends 
     37   USE trdmld_rst      ! restart for diagnosing the ML trends 
    3838   USE prtctl          ! Print control 
    3939 
     
    230230      !! 
    231231      INTEGER :: ji, jj, jk, jl, ik, it 
    232       LOGICAL :: lldebug = .TRUE. 
     232      LOGICAL :: lldebug = .FALSE. 
    233233      REAL(wp) :: zavt, zfn, zfn2 
    234234      REAL(wp) ,DIMENSION(jpi,jpj) ::     & 
     
    253253      ! ... These terms can be estimated by flux computation at the lower boundary of the ML  
    254254      !     (we compute (-1/h) * K_z * d_z( T ) and (-1/h) * K_z * d_z( S )) 
    255       DO jj = 1,jpj 
    256          DO ji = 1,jpi 
    257             ik = nmld(ji,jj) 
    258             zavt = avt(ji,jj,ik) 
    259             tmltrd(ji,jj,jpmld_zdf) = - zavt / fse3w(ji,jj,ik) * tmask(ji,jj,ik)  & 
    260                &                      * ( tn(ji,jj,ik-1) - tn(ji,jj,ik) )         & 
    261                &                      / MAX( 1., rmld(ji,jj) ) * tmask(ji,jj,1) 
    262             zavt = fsavs(ji,jj,ik) 
    263             smltrd(ji,jj,jpmld_zdf) = - zavt / fse3w(ji,jj,ik) * tmask(ji,jj,ik)  & 
    264                &                      * ( sn(ji,jj,ik-1) - sn(ji,jj,ik) )         & 
    265                &                      / MAX( 1., rmld(ji,jj) ) * tmask(ji,jj,1) 
    266          END DO 
    267       END DO 
    268  
    269       ! ... Remove this K_z trend from the iso-neutral diffusion term (if any) 
    270255      IF( ln_traldf_iso ) THEN 
     256         DO jj = 1,jpj 
     257            DO ji = 1,jpi 
     258               ik = nmld(ji,jj) 
     259               zavt = avt(ji,jj,ik) 
     260               tmltrd(ji,jj,jpmld_zdf) = - zavt / fse3w(ji,jj,ik) * tmask(ji,jj,ik)  & 
     261                  &                      * ( tn(ji,jj,ik-1) - tn(ji,jj,ik) )         & 
     262                  &                      / MAX( 1., rmld(ji,jj) ) * tmask(ji,jj,1) 
     263               zavt = fsavs(ji,jj,ik) 
     264               smltrd(ji,jj,jpmld_zdf) = - zavt / fse3w(ji,jj,ik) * tmask(ji,jj,ik)  & 
     265                  &                      * ( sn(ji,jj,ik-1) - sn(ji,jj,ik) )         & 
     266                  &                      / MAX( 1., rmld(ji,jj) ) * tmask(ji,jj,1) 
     267            END DO 
     268         END DO 
     269 
     270         ! ... Remove this K_z trend from the iso-neutral diffusion term (if any) 
    271271         tmltrd(:,:,jpmld_ldf) = tmltrd(:,:,jpmld_ldf) - tmltrd(:,:,jpmld_zdf) 
    272272         smltrd(:,:,jpmld_ldf) = smltrd(:,:,jpmld_ldf) - smltrd(:,:,jpmld_zdf) 
     
    698698      END IF 
    699699 
     700      ! ====================================================================== 
     701      ! V. Write restart file 
     702      ! ====================================================================== 
     703 
     704      CALL trd_mld_rst_write( kt )  
     705 
    700706   END SUBROUTINE trd_mld 
    701707 
Note: See TracChangeset for help on using the changeset viewer.