[MITgcm-support] spatially variable bottom drag

Michael A Spall mspall at whoi.edu
Mon Apr 18 07:30:05 EDT 2022


Hi Jody,
Thanks, yours looks a little more complete than mine, but I did put together something that is working fine.
I only needed it for one calculation though so I will just stick with what I did. 
best regards,
Mike

==================================================================

Michael A. Spall
Senior Scientist
Clark 323A
Department of Physical Oceanography
Woods Hole Oceanographic Institution
360 Woods Hole Road MS #21
Woods Hole, MA 02543

508-289-3342
mspall at whoi.edu
https://www2.whoi.edu/staff/mspall

________________________________________
From: MITgcm-support <mitgcm-support-bounces at mitgcm.org> on behalf of Jody Klymak <jklymak at uvic.ca>
Sent: Sunday, April 17, 2022 12:46 PM
To: mitgcm-support at mitgcm.org
Subject: Re: [MITgcm-support] spatially variable bottom drag

A little late to comment, but I made a variable bottom drag package that still requires some cleanup…

https://nam02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjklymak%2FMITgcm%2Ftree%2Fvariable_bottom_drag%2Fpkg%2Fvar_bot_drag&data=04%7C01%7Cmspall%40whoi.edu%7Cca55467115a7483a346908da2091dd63%7Cd44c5cc6d18c46cc8abd4fdf5b6e5944%7C0%7C0%7C637858108548093951%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=oCWbTEEHnnUlt19Rq03hJ%2Bb8N0mRQSsKynGnFtJ%2BYbY%3D&reserved=0

Cheers,   Jody




> On Apr 12, 2022, at 4:21 PM, Michael A Spall <mspall at whoi.edu> wrote:
>
> I am interested in making my linear bottom drag coefficient a function of space. I tried to do this
> by defining a 2-D array between 0 and 1 and multiplying the rhs of uDragTerms in mom_u_bottomdrag.F
> by this scaling array (same for vDragTerms in mom_v_bottomdrag.F). I added common blocks to those
> subroutines with the array so it is seen there. However, it looks like bi and bj are both 1 for all tiles in those
> subtroutines, so it always takes the values of my scaling array from the first tile.  Also in dynamics.F, which
> calls them. I found some text online that says these are done in dynamics.F by a single loop, but I don't know
> what that means.  Any advice on how to make bottom drag a function of location?
>
> I am using MITgcm_c65l, the SIZE.h file is below.
>
> Thanks,
> Mike
>
> C $Header: /u/gcmpack/MITgcm/model/inc/SIZE.h,v 1.28 2009/05/17 21:15:07 jmc Exp $
> C $Name:  $
> C
> CBOP
> C    !ROUTINE: SIZE.h
> C    !INTERFACE:
> C    include SIZE.h
> C    !DESCRIPTION: \bv
> C     *==========================================================*
> C     | SIZE.h Declare size of underlying computational grid.
> C     *==========================================================*
> C     | The design here support a three-dimensional model grid
> C     | with indices I,J and K. The three-dimensional domain
> C     | is comprised of nPx*nSx blocks of size sNx along one axis
> C     | nPy*nSy blocks of size sNy along another axis and one
> C     | block of size Nz along the final axis.
> C     | Blocks have overlap regions of size OLx and OLy along the
> C     | dimensions that are subdivided.
> C     *==========================================================*
> C     \ev
> CEOP
> C     Voodoo numbers controlling data layout.
> C     sNx :: No. X points in sub-grid.
> C     sNy :: No. Y points in sub-grid.
> C     OLx :: Overlap extent in X.
> C     OLy :: Overlat extent in Y.
> C     nSx :: No. sub-grids in X.
> C     nSy :: No. sub-grids in Y.
> C     nPx :: No. of processes to use in X.
> C     nPy :: No. of processes to use in Y.
> C     Nx  :: No. points in X for the total domain.
> C     Ny  :: No. points in Y for the total domain.
> C     Nr  :: No. points in Z for full process domain.
>      INTEGER sNx
>      INTEGER sNy
>      INTEGER OLx
>      INTEGER OLy
>      INTEGER nSx
>      INTEGER nSy
>      INTEGER nPx
>      INTEGER nPy
>      INTEGER Nx
>      INTEGER Ny
>      INTEGER Nr
>      PARAMETER (
>     &           sNx = 35,
>     &           sNy = 35,
>     &           OLx =   4,
>     &           OLy =   4,
>     &           nSx =   1,
>     &           nSy =   1,
>     &           nPx =  12,
>     &           nPy =  12,
>     &           Nx  = sNx*nSx*nPx,
>     &           Ny  = sNy*nSy*nPy,
>     &           Nr  =  60)
>
> C     MAX_OLX :: Set to the maximum overlap region size of any array
> C     MAX_OLY    that will be exchanged. Controls the sizing of exch
> C                routine buffers.
>      INTEGER MAX_OLX
>      INTEGER MAX_OLY
>      PARAMETER ( MAX_OLX = OLx,
>     &            MAX_OLY = OLy )
>
>
>
> ==================================================================
>
> Michael A. Spall
> Senior Scientist
> Clark 323A
> Department of Physical Oceanography
> Woods Hole Oceanographic Institution
> 360 Woods Hole Road MS #21
> Woods Hole, MA 02543
>
> 508-289-3342
> mspall at whoi.edu
> https://www2.whoi.edu/staff/mspall
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> https://nam02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmailman.mitgcm.org%2Fmailman%2Flistinfo%2Fmitgcm-support&data=04%7C01%7Cmspall%40whoi.edu%7Cca55467115a7483a346908da2091dd63%7Cd44c5cc6d18c46cc8abd4fdf5b6e5944%7C0%7C0%7C637858108548093951%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=YnWLGTS%2BVNDRgbtoxN2UVt2W%2BXM4YEwzjh1OvLFfGpQ%3D&reserved=0

_______________________________________________
MITgcm-support mailing list
MITgcm-support at mitgcm.org
https://nam02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmailman.mitgcm.org%2Fmailman%2Flistinfo%2Fmitgcm-support&data=04%7C01%7Cmspall%40whoi.edu%7Cca55467115a7483a346908da2091dd63%7Cd44c5cc6d18c46cc8abd4fdf5b6e5944%7C0%7C0%7C637858108548093951%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=YnWLGTS%2BVNDRgbtoxN2UVt2W%2BXM4YEwzjh1OvLFfGpQ%3D&reserved=0


More information about the MITgcm-support mailing list