UG_IO SimSys UGRID 2D Grid File Type

A 2D UGRID file contains a boundary edge grid and/or a tria/quad face planar grid. UGRID files also contain boundary edge connectivity, boundary edge ID, boundary condition, and initial normal spacing data records described below (same as 2D FGRID). Also, for a 2D UGRID file the values of Number_of_Vol_Tets, Number_of_Vol_Pents_5, Number_of_Vol_Pents_6, and Number_of_Vol_Hexs must all be 0. The 2D UGRID file is the same as a UGRID file (for 3D) except that the values of Number_of_Vol_Tets, Number_of_Vol_Pents_5, Number_of_Vol_Pents_6, and Number_of_Vol_Hexs must all be 0 and the optional boundary information records are different.

     { Number_of_Nodes, Number_of_Trias, Number_of_Quads,
       Number_of_Vol_Tets, Number_of_Vol_Pents_5, Number_of_Vol_Pents_6,
       Number_of_Vol_Hexs }

     { [ ( X for node 1,
           Y for node 1,
           Z for node 1 ),
         ( X for node 2,
           Y for node 2,
           Z for node 2 ),
           ...
         ( X for node Number_of_Nodes,
           Y for node Number_of_Nodes,
           Z for node Number_of_Nodes ) ] }

     The Z coordinate value is ignored.

     { [ ( index for node 1 of tria face 1,
           index for node 2 of tria face 1,
           index for node 3 of tria face 1 ),
         ( index for node 1 of tria face 2,
           index for node 2 of tria face 2,
           index for node 3 of tria face 2 ),
         ...
         ( index for node 1 of tria face Number_of_Trias,
           index for node 2 of tria face Number_of_Trias,
           index for node 3 of tria face Number_of_Trias ) ]

       [ ( index for node 1 of quad face 1,
           index for node 2 of quad face 1,
           index for node 3 of quad face 1,
           index for node 4 of quad face 1 ),
         ( index for node 1 of quad face 2,
           index for node 2 of quad face 2,
           index for node 3 of quad face 2,
           index for node 4 of quad face 2 ),
         ...
         ( index for node 1 of quad face Number_of_Quads,
           index for node 2 of quad face Number_of_Quads,
           index for node 3 of quad face Number_of_Quads,
           index for node 4 of quad face Number_of_Quads ) ]

       [ dummy ID for face 1,
         dummy ID for face 2,
         ...
         dummy ID for face Number_of_Trias+Number_of_Quads ] }

     { Number_of_Bnd_Edges }

     { ( index for node 1 of boundary edge 1,
         index for node 2 of boundary edge 1,
         edge ID for boundary edge 1 ),
       ( index for node 1 of boundary edge 2,
         index for node 2 of boundary edge 2,
         edge ID for boundary edge 2 ),
       ...
       ( index for node 1 of boundary edge Number_of_Bnd_Edges,
         index for node 2 of boundary edge Number_of_Bnd_Edges,
         edge ID for boundary edge Number_of_Bnd_Edges ) }

     *{ [ grid boundary condition flag for boundary edge 1,
          grid boundary condition flag for boundary edge 2,
          ...
          grid boundary condition flag for boundary edge Number_of_Bnd_Edges ] }*

     *{ [ initial normal spacing for node 1,
          initial normal spacing for node 2,
          ...
          initial normal spacing for node Number_of_Nodes ] }*

     Number_of_Bnd_Edges		: Number of boundary edges.
     Number_of_Quads		: Number of quadrilateral faces.
     Number_of_Trias		: Number of triangular faces.
     Number_of_Vol_Hexs		: Number of hexahedral volume elements that must
    				  be set equal to 0.
     Number_of_Vol_Pents_5		: Number of pentahedral volume elements with
    				  five nodes (pyramid) that must be set equal
    				  to 0.
     Number_of_Vol_Pents_6		: Number of pentahedral volume elements with
    				  six nodes (prismatic) that must be set equal
    				  to 0.
     Number_of_Vol_Tets		: Number of tetrahedral volume elements that
    				  must be set equal to 0.
     Number_of_Nodes		: Number of grid nodes.

Note that in the above description the loops over all faces (1,2,..., Number_of_Trias+Number_of_Quads) the triangular faces are first, followed by the quadrilateral faces.

For a 2D planar grid the Number_of_Vol_Hexs, Number_of_Vol_Pents_5, Number_of_Vol_Pents_6, and Number_of_Vol_Tets must all be zero. In the above description, the parentheses ( ... ) are for grouping, the brackets [ ... ] enclose items in a loop, and braces { ... } enclose items in a single logical record. The items in starred braces *{ ... }* are optional records for grid files that describe a boundary edge grid. If either Number_of_Quads or Number_of_Trias are greater than zero (the grid is a 2D planar grid and not a 2D boundary edge grid) then this data is not read in or written out. The optional records can be included in whole or in part as long as they are in the correct order. The UG_IO grid file reader will attempt to read the "grid boundary condition". If it is not found then reading of the file will end. Finally, the reader will attempt to read the "initial normal spacing".

In FORTRAN unformatted form, the data must be written out or read in using the specified record format. The floating point data items must all be either real*4 or real*8 data. In C binary form, the data may be written out or read in using records the length of loops or of the individual data items. The floating point data items must all be either float or double data. In ASCII formatted form, the data may be written out or read in using records the length of loops or of the individual data items. Data items may be written out in free format of any specific form.

Up One Level

UG_IO SimSys Files Home