The IRIS Explorer Lattice data type is a generalised multi-dimensional array. It differs from arrays in other languages by being able to store both node-based values and coordinate information for each of the nodes. Being extremely flexible, it is the most commonly used data type in IRIS Explorer, used almost exclusively to store data and pass it between modules.
The Data part of a lattice can be multi-dimensional. If required, multiple data values can be stored at each node.
The Coordinate part of a lattice can have a varying number of dimensions, dependent on the number of dimensions that the data space occupies. There are three different types of coordinate information:
The uniform lattice type has the most simple coordinate specification. The coordinates part is specified as a pair of limits for each spatial dimension. The nodes will be evenly spaced between these limits, so the data must reside on an orthogonal grid with constant spacing in each direction (e.g. a 2D image).
Figure 10.1: An Example Uniform Lattice
The perimeter lattice type is used when the coordinates use an orthogonal grid but the spacing is variable (e.g. a logarithmic grid), so each dimension requires a vector of locations for the nodes.
Figure 10.2: An Example Perimeter Lattice
The curvilinear lattice is used for more complex coordinate requirements. In it, the coordinates for each individual node are specified. Although the data must reside on a grid, it does not have to be orthogonal or regularly spaced (e.g. the output from a computational fluid dynamics calculation). Also, the dimensionality of the coordinate space and physical space can be different.
Figure 10.3: An Example Curvilinear Lattice
Internally, lattices are stored as structures containing all the information IRIS Explorer needs. It is normal to use the parts of the structure to describe the format of the lattice, so it is worth understanding what the structure contains
Lattices can be written to file using the WriteLat module and read using the ReadLat module. These use ASCII text file format, enabling users familiar with the structure of lattices to examine a data file using a standard text editor. The format is as follows.