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.
#2237 (no/partial/strong slip condition is actually free slip in one-point straits) – NEMO

Opened 6 years ago

Closed 4 years ago

#2237 closed Bug (fixed)

no/partial/strong slip condition is actually free slip in one-point straits

Reported by: davestorkey Owned by: davestorkey
Priority: low Milestone: Unscheduled
Component: LBC Version:
Severity: minor Keywords: momentum boundary slip
Cc:

Description (last modified by nicolasmartin)

BE CAREFUL !!! Due to dynamic behaviour of this ticket creation page, it is highly recommend to set first all other fields before writing the ticket description below.
If you have lost your draft after an unwanted reload, you can click on the link 'Restore Form' in the contextual menu upper right to recover it.
Remove these lines after reading.

Context

Analysis

The boundary condition on velocities tangential to topography is set via the value of fmask initialised in dom_msk as follows (NEMO 4 code):

Calculate from tmask:

               fmask(ji,jj,jk) = tmask(ji,jj  ,jk) * tmask(ji+1,jj  ,jk)   &
                  &            * tmask(ji,jj+1,jk) * tmask(ji+1,jj+1,jk)

Apply slip condition:

      IF( rn_shlat /= 0 ) THEN      ! Not free-slip lateral boundary condition
         !
         ALLOCATE( zwf(jpi,jpj) )
         !
         DO jk = 1, jpk
            zwf( : , : ) = fmask(:,:,jk)         
            DO jj = 2, jpjm1
               DO ji = fs_2, fs_jpim1   ! vector opt.
                  IF( fmask(ji,jj,jk) == 0._wp ) THEN
                     fmask(ji,jj,jk) = rn_shlat * MIN( 1._wp , MAX( zwf(ji+1,jj), zwf(ji,jj+1),   &
                        &                                           zwf(ji-1,jj), zwf(ji,jj-1)  )  )
                  ENDIF
               END DO
            END DO

This selects fmask points at the topography-sea boundary by looking for points where fmask is zero but has a neighbouring fmask which is one. But this criterion doesn't work for single-point channels. A better criterion would be to check the neighbouring umask and vmask values:

Instead of:

MAX( zwf(ji+1,jj), zwf(ji,jj+1),zwf(ji-1,jj), zwf(ji,jj-1) )

this would be better:

MAX( umask(ji,jj,jk), umask(ji,jj+1,jk), vmask(ji,jj,jk), vmask(ji+1,jj,jk) )

Maybe this was deliberate? But if you want no-slip with free-slip in channels it is probably better to do that explicitly via a spatially varying shlat parameter.

Fix

...

Commit History (3)

ChangesetAuthorTimeChangeLog
13271clem2020-07-08T16:53:09+02:00

counterpart of ticket #2237 for sea-ice

13270clem2020-07-08T16:41:20+02:00

should solve ticket #2237

10648davestorkey2019-02-07T16:57:16+01:00

UKMO dev_r10037_shlat2d branch: bug fix - make sure modified shlat values are applied to single-point channels. (This fix relates to ticket #2237).

Change History (8)

comment:1 Changed 6 years ago by nicolasmartin

  • Description modified (diff)

comment:2 Changed 6 years ago by davestorkey

In 10648:

Error: Failed to load processor CommitTicketReference
No macro or processor named 'CommitTicketReference' found

comment:3 Changed 6 years ago by nicolasmartin

  • Version set to v4.0

comment:4 Changed 5 years ago by clevy

  • Version changed from v4.0 to v4.0.*

comment:5 Changed 4 years ago by gm

Yes Dave, I agree. I never though of having a at least 2 ocean grid point channel since I don't think its a good idea to have such a channel.
Nevertheless, it may occur in a user configuration. Your solution is the one to be implemented.

Gurvan

Note that using usrdef_fmask you can always set the boundary condition you want.

comment:6 Changed 4 years ago by clem

In 13270:

Error: Failed to load processor CommitTicketReference
No macro or processor named 'CommitTicketReference' found

comment:7 Changed 4 years ago by clem

In 13271:

Error: Failed to load processor CommitTicketReference
No macro or processor named 'CommitTicketReference' found

comment:8 Changed 4 years ago by clem

  • Resolution set to fixed
  • Status changed from new to closed
  • Version v4.0.* deleted

fixed also in the trunk from r13472

Note: See TracTickets for help on using tickets.