13 implicit double precision (a-h,o-z)
24 100
format(
' out of nodal space - allowed ',i8,
' grids')
27 101
format(
" level ",i4,
" has ",i7,
' grids')
29 write(*,*)
" Could need twice as many grids as on any given" 30 write(*,*)
" level if regridding/birecting" 56 implicit double precision (a-h,o-z)
66 100
format(
' out of bndry space - allowed ',i5,
' bndry grids')
71 numgridstotal = numgridstotal +
numgrids(lev)
76 avgnbors = float(nbortotal)/numgridstotal
77 write(*,101) numgridstotal,nbortotal,avgnbors
78 101
format(
" There are ",i8,
" total grids", i10,
" bndry nbors",
79 .
" average num/grid ",f10.3)
113 integer lbase, levSt, lev, mptr, n
125 do lev = lbase+1,
lfine 187 integer level, n, levSt, k, nborCount
188 integer nodget_bnd, nextSpot, prevNbor, msrc, mptr
189 integer imin, imax, jmin, jmax
190 integer imlo, imhi, jmlo, jmhi
191 integer ixlo, ixhi, jxlo, jxhi
218 ixlo = max(imlo,imin)
219 ixhi = min(imhi,imax)
220 jxlo = max(jmlo,jmin)
221 jxhi = min(jmhi,jmax)
223 if (ixlo .le. ixhi .and. jxlo .le. jxhi)
then 224 nborcount = nborcount + 1
225 nextspot = nodget_bnd()
251 integer nborCount, mold,nextSpot, i, nextnext
subroutine makebndrylist(level)
Preprocess each grid on level level to have a linked list of other grids at the same level that suppl...
integer, parameter bndlistnum
number of grids (on the same level) that border this grid
subroutine makegridlist(lbase)
Make (modify) array of grid numbers, listOfGrids, (after sorting them in the linked list so they are ...
integer, parameter ndihi
global i index of right border of this grid
subroutine freebndrylist(mold)
Free the linked list of intersecting "boundary" grids for grid 'mold' that is no longer active...
integer, dimension(nsize, maxgr) node
integer, dimension(0:maxlv+1) liststart
integer, dimension(maxlv) numgrids
real(kind=8), dimension(rsize, maxgr) rnode
integer, dimension(maxgr) listofgrids
integer, parameter gridnbor
integer, parameter bndlistsize
integer, parameter bndlistst
pointer (actually it's an index in the bndList array) to the first node of a linked list...
integer, parameter ndilo
global i index of left border of this grid
integer, parameter ndjlo
global j index of lower border of this grid
integer, dimension(maxlv) lstart
integer function nodget()
Get first free node of the linked list kept in node array.
integer, dimension(bndlistsize, 2) bndlist
subroutine putnod_bnd(mcell)
integer, parameter outunit
integer, parameter nextfree
integer, parameter ndjhi
global j index of upper border of this grid
integer, parameter levelptr
node number (index) of next grid on the same level
integer function nodget_bnd()
The module contains the definition of a "node descriptor" as well as other global variables used duri...
subroutine initbndrylist()