New URL for NEMO forge!

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.
#2252 (Question/remark about the zcoef variable (dtadyn.F90)) – NEMO

Opened 5 years ago

Closed 4 years ago

#2252 closed Defect (invalid)

Question/remark about the zcoef variable (dtadyn.F90)

Reported by: barrier.n Owned by: systeam
Priority: low Milestone:
Component: OFF Version:
Severity: minor Keywords: zcoef, scale factors


Dear NEMO community

I am currently trying to run a biological model by using outputs of a NEMO-Pisces ORCA1 configuration. This configuration has been run by using the "key_vvl" flag and has the "e3t" and "e3w" variables stored. Since I need to reconstruct the depth of T points, I have looked at the dtadyn.F90 module, and the lines of interest are (lines 365-381)

     ! t- and w- points depth
     ! ----------------------
     fsdept_n(:,:,1) = 0.5_wp * fse3w_n(:,:,1)
     fsdepw_n(:,:,1) = 0.0_wp

     DO jk = 2, jpk
        DO jj = 1,jpj
           DO ji = 1,jpi
             !    zcoef = (tmask(ji,jj,jk) - wmask(ji,jj,jk))   ! 0 everywhere
             !    tmask = wmask, ie everywhere expect at jk = mikt
                                                                ! 1 for jk =
                                                                ! mikt
              zcoef = (tmask(ji,jj,jk) - wmask(ji,jj,jk))
              fsdepw_n(ji,jj,jk) = fsdepw_n(ji,jj,jk-1) + fse3t_n(ji,jj,jk-1)
              fsdept_n(ji,jj,jk) =      zcoef  * ( fsdepw_n(ji,jj,jk  ) + 0.5 * fse3w_n(ji,jj,jk))  &
                  &                + (1-zcoef) * ( fsdept_n(ji,jj,jk-1) + fse3w_n(ji,jj,jk))
           END DO
        END DO
     END DO

My concers are regarding the zcoef variable, since to me it is always equal to 0. Indeed, since wmask is computed as follows (domrea.F90, lines 425-432):

  wmask (:,:,1) = tmask(:,:,1) ! ????????
   wumask(:,:,1) = umask(:,:,1) ! ????????
   wvmask(:,:,1) = vmask(:,:,1) ! ????????
   DO jk = 2, jpk
      wmask (:,:,jk) = tmask(:,:,jk) * tmask(:,:,jk-1)
      wumask(:,:,jk) = umask(:,:,jk) * umask(:,:,jk-1)
      wvmask(:,:,jk) = vmask(:,:,jk) * vmask(:,:,jk-1)

The coef variable is equal to

zcoef = tmask(ji,jj,jk) * (1 - tmask(ji,jj,jk-1))

As a consequence, there is no way for zcoef to be different from 0, since when tmask(jk - 1) is 0, tmask(jk) is 0 as well.

Can you please tell me if I am missing something?

Thanks a lot.

Regards, Nicolas Barrier

Commit History (0)

(No commits)

Change History (1)

comment:1 Changed 4 years ago by smasson

  • Resolution set to invalid
  • Status changed from new to closed

you are right... except when there is ice shelves and that the upper level of the ocean is no more 1 but mikt.

Note: See TracTickets for help on using tickets.