3 geometry files – Scotch Brand 5.1.10 User Manual

Page 21

Advertising
background image

The third line holds three figures: the base index of the first element vertex in

memory (velmbas), the base index of the first node vertex in memory (vnodbas),
and a numeric flag.

The Scotch mesh file format requires that all nodes and all elements be assigned

to contiguous ranges of indices. Therefore, either all element vertices are defined
before all node vertices, or all node vertices are defined before all element vertices.
The node and element base indices indicate at the same time whether elements or
nodes are put in the first place, as well as the value of the starting index used to
describe the graph. Indeed, if velmbas < vnodbas, then elements have the smallest
indices, velmbas is the base value of the underlying graph (that is, baseval =
velmbas

), and velmbas + velmnbr = vnodbas holds. Conversely, if velmbas >

vnodbas

, then nodes have the smallest indices, vnodbas is the base value of the

underlying graph, (that is, baseval = vnodbas), and vnodbas+vnodnbr = velmbas
holds.

The numeric flag, similar to the one used by the Chaco graph format [24], is

made of three decimal digits. A non-zero value in the units indicates that vertex
weights are provided. A non-zero value in the tenths indicates that edge weights
are provided. A non-zero value in the hundredths indicates that vertex labels are
provided; if it is the case, and if velmbas < vnodbas (resp. velmbas > vnodbas),
the velmnbr (resp. vnodnbr) first vertex lines are assumed to be element (resp.
node) vertices, irrespective of their vertex labels, and the vnodnbr (resp. velmnbr)
remaining vertex lines are assumed to be node (resp. element) vertices; else, natural
order is assumed, starting at the underlying graph base index (baseval).

This header data is then followed by as many lines as there are node and element

vertices in the graph. These lines are similar to the ones of the graph format, except
that, in order to save disk space, the numberings of nodes and elements all start
from the same base value, that is, min(velmbas, vnodbas) (also called baseval, like
for regular graphs).

For example, Figure 5 shows the contents of the mesh file modeling three square

elements, with unity vertex and edge weights, elements defined before nodes, and
numbering of the underlying graph starting from 1. In memory, the three elements
are labeled from 1 to 3, and the eight nodes are labeled from 4 to 11. In the file,
the three elements are still labeled from 1 to 3, while the eight nodes are labeled
from 1 to 8.

When labels are used, elements and nodes may have similar labels, but not two

elements, nor two nodes, should have the same labels.

5.3

Geometry files

Geometry files, which usually end in “.xyz”, hold the coordinates of the vertices
of their associated graph or mesh. These files are not used in the mapping process
itself, since only topological properties are taken into account then (mappings are
computed regardless of graph geometry). They are used by visualization programs
to compute graphical representations of mapping results.

The first string to appear in a geometry file codes for its type, or dimensional-

ity. It is “1” if the file contains unidimensional coordinates, “2” for bidimensional
coordinates, and “3” for tridimensional coordinates. It is followed by the number of
coordinate data stored in the file, which should be at least equal to the number of
vertices of the associated graph or mesh, and by that many coordinate lines. Each
coordinate line holds the label of the vertex, plus one, two or three real numbers
which are the (X), (X,Y), or (X,Y,Z), coordinates of the graph vertices, according

21

Advertising