﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
193	Private automatic arrays	arango	arango	"This is a complete update for ROMS private storage arrays that are automatically allocated when entering the '''_tile''' routines.  These array needed to be redisigned to allow the different types of nesting: refining, composite, and mosaics. These arrays where temporarily changed to global dimensions in '''revision 168''' (src:ticket:142).  This is fine in distributed-memory applications but the private storage is much larger than needed in shared-memory and serial with partitions applications.  ''This is not a bug'' but the model required larger memory in such applications. Perhaps, you didn't noticed...

A new variable is not introduce to '''tile.h''' to determine the size of the private storage arrays for each nested grid:
{{{
!
!  Set horizontal starting and ending indices for automatic private storage
!  arrays.
!
      IminS=BOUNDS(ng)%Istr(tile)-3
      ImaxS=BOUNDS(ng)%Iend(tile)+3
      JminS=BOUNDS(ng)%Jstr(tile)-3
      JmaxS=BOUNDS(ng)%Jend(tile)+3
}}}

So now each tile routines have the following additional arguments: '''IminS''', '''ImaxS''',''' JminS''', and '''JmaxS''', for example:
{{{
      CALL xxxxx_tile (ng, tile,                                        &
     &                 LBi, UBi, LBj, UBj,                              &
     &                 IminS, ImaxS, JminS, JmaxS,                      &
     &                 ...)
}}}

The values of '''IminS''', '''ImaxS''',''' JminS''', and '''JmaxS''' will change in the future to allow for the different size of the contact areas.  However, the change will be limited to '''tile.h'''.  Notice that now the numerous additions and substractions per time-step from the CPP tokens in '''globaldefs.h''' are eliminated:
{{{
#define PRIVATE_1D_SCRATCH_ARRAY IminS:ImaxS
#define PRIVATE_2D_SCRATCH_ARRAY IminS:ImaxS,JminS:JmaxS
}}}

These definitions are keept for compatability but not used in the new version.

See the following forum [https://www.myroms.org/forum/viewtopic.php?f=13&t=1001 post] for more information.  Many thanks to John Warner for remind me about this issue. "	upgrade	closed	major	Nesting/Composed Grids	Nonlinear	3.2	Done		
