DESCRIPTIONThis module reads in 2D scalar or vector data from an ascii file in a simple format and outputs a 2D uniform lattice. The 2D ascii file format consists of:
nx, ny, veclen, x0, y0, dx, dy, data.
Here nx, x0 and dx are respectively the number of points, the origin and the grid spacing in the x direction (and similarly for the y direction). veclen is the number of data values at each location in the array. Finally, data is the array of values, ordered with the values at each location varying fastest, then x, then y. In this list, nx, ny and veclen are of type short, while the rest of the items are of type float.
The mapping between the file variables and the components of the output lattice is as follows (this can be seen by using DataScribe to view the structure of the module):
nx -> dims; ny -> dims; x0 -> bBox; x0 + (nx-1)*dx -> bBox; y0 -> bBox; y0 + (ny-1)*dy -> bBox; veclen -> nDataVar; data -> values;
Input filename. The name may be entered into the text type-in slot, or via the file browser (obtained using the File item on the menu bar).
Port: Script File
Output data - 2D uniform float lattice.
Read3Db uses a similar format to read in 3D scalar or vector data from binary files.
© The Numerical Algorithms Group Ltd, Oxford UK. 2000