One important aspect of incompressible flow models is the location of primary variables: velocity and water level (pressure). On a staggered grid, the water level is located at the center of cells and the velocities are located along the faces or nodes of cells (Harlow and Welsh 1965, Patankar 1980). On a non-staggered grid, all of the primary variables are located at the cell
centers. Since the water level is calculated by the divergence of the velocity field and the velocities are driven by water level gradients, the staggered grid facilitates the use of central difference type schemes without producing the checkerboard instabilities. The non-staggered grid involves a simpler source code and for an implicit scheme can minimize the number of coefficients that must be computed and stored during a simulation because many of the terms in the equations are equal. In particular, staggered grids require defining additional control volumes (e.g. dual meshes) at cell faces or nodes and the interpolation of variables on the faces of the additional control volumes. Therefore, a non-staggered (collocated) grid approach is adopted in this study with a Rhie and Chow (1983) type momentum interpolation technique used to eliminate the checkerboard oscillations.
The developed model supports general polygonal meshes with cells consisting of convex polygons with any number of faces. An example of a general polygonal mesh is shown in Figure 4.1.
Figure 4.1. Polygonal mesh. Shaded area indicates the control volume P. Neighboring cells sharing a cell face are indicated by the letter N. The subscripts indicate the neighbor number.
To improve computational efficiency, memory usage, stability, and simplification of grid generation, grids used in the present model are classified as structured or non-telescoping Cartesian, telescoping Cartesian, structured quadrilateral, unstructured triangular, and hybrid triangular/quadrilateral. Depending on the grid topology, simplifications can be made in the discretization and specialized solution techniques used. For example, structured Cartesian and quadrilateral grids result in a penta-diagonal coefficient matrix which can be solved using specialized solvers such as Stone’s (1968) Strongly Implicit Procedure (SIP). Additional aspects of the model where simplifications are made depending on the grid topology are the calculation of cell-face interpolations, spatial gradients, slope limiters, and advection schemes. Further details are provided in subsequent sections.
Currently, all of the computational grids are generated in the Surface-water Modeling System (Zundel 2006). Hence, although the model supports general polygonal meshes, it has only been tested for grid types which can be generated in SMS. Examples of different types of computational grids which can be generated in the SMS interface and have been tested are shown in Figure 4.2. Cartesian grids are classified as uniform, nonuniform, or telescoping. Telescoping locally refines the mesh by splitting a cell into subcells. The only requirement imposed by the numerical methods is that the cells must have a rectangular shape. Additional requirements imposed by the user interface limit the variety of types of Cartesian grids to help simplify the grid generation and avoid grid quality issues. The following requirements are applied to telescoping Cartesian grids:
2. Cells may have a maximum of 6 neighbors.
3. Only two neighboring cells are allowed in the same direction (i.e. north, south, east, and west).
4. Refinement levels must be spaced by at least one cell apart (i.e. cells that share the same corner must be one refinement level apart).
The first requirement simplifies the grid generation process but may be relaxed in future versions. The last three requirements are for grid quality purposes. Requirement 2 avoids having a cell surrounded by refined cells. The last two requirements avoid having excessive cell refinement which can cause numerical instabilities.
For unstructured meshes the model does not have limitations on the number of cell faces, number of cells connected to a single node, grid orthogonality, or any other type. Although grid orthogonality is not a requirement, highly distorted meshes are not recommended since they can cause divergence issues. The only requirement for unstructured meshes is that the cells be convex polygons. A grid is defined as orthogonal if all of the lines connecting the cell centers intersect the cell-face mid points. A grid does not have to be structured to be orthogonal. For example, an unstructured triangular mesh made of equilateral triangles is orthogonal. In general however, it is difficult to enforce orthogonality on unstructured meshes and most unstructured meshes used in practice are non-orthogonal.
a. Regular Cartesian b. Nonuniform Cartesian
c. Telescoping Cartesian d. Stretched Telescoping Cartesian
e. Triangular Unstructured f. Quadrilateral (un)structured
Different types of grids have their own advantages and disadvantages. Regular (uniformly spaced) Cartesian grids have the advantage of being the simplest to generate. However, regular Cartesian grids require a large number of computational cells in order to properly resolve complex geometries. Nonuniform Cartesian grids maintain the same structure as regular Cartesian grids but allow the grid spacing to vary spatially. Telescoping Cartesian grids offer greater flexibility in resolving complex geometries and are relatively simple to generate and also suffer less from grid quality problems compared to unstructured grids. Telescoping Cartesian grids are more difficult to generate than non-telescoping Cartesian grids, but much less difficult than unstructured grids.
A complication of telescoping Cartesian grids compared to non-telescoping Cartesian grids comes from non-orthogonality corrections which are necessary for second-order accuracy. However, since only relatively small fraction of cells have non-orthogonal faces, the increase in computational cost is relatively minor. Another complication from telescoping grids is that for implicit time marching schemes they lead to systems of equations whose matrix coefficients are unbanded and are more difficult to solve compared to the penta-diagonal coefficient matrix of uniform and nonuniform Cartesian grids. Cartesian grids also suffer from the stair-case representation of boundaries unless a boundary fitting method is implemented such as ‘cut cells’ (e.g. Popinet and Richard 2006) or immersed boundaries (e.g. Wang and Wu 2010). Unstructured grids offer the greatest flexibility for resolving complex geometries, but are the most difficult and time consuming to generate. They are more prone to grid quality issues. Lastly, for problems with wetting and drying the boundary fitting capability of unstructured grids may deteriorate unless the mesh is always aligned with the moving boundary (wetting and drying
front), which is generally difficult to achieve for practical problems.
The data structure for all grid types is treated in an unstructured manner in which all cells are numbered in a one-dimensional array and tables are used to determine the connectivity of neighboring cells. This allows for both structured and unstructured grids to exist under the same framework. For structured grids, this approach also has the disadvantage of having to use the connectivity tables to point to neighboring cells. However, this is a relatively small computational expense. For most practical applications, there are large portions of the grid which are inactive (permanently dry). By using the unstructured data structure, inactive cells can be easily excluded from the computational domain and the efficiencies in memory and computation time far outweigh the cost of having to use tables for the cell connectivity. Lastly it is noted that for convenience in handling boundary conditions, each boundary cell has a neighboring ghost cell outside of the computational domain. Ghost cells are stored at the end of the 1D index array.