(3M) Calculator User Manual

Description
The SCOTCH
graphFree function frees the graph data of a SCOTCH Graph struc-
ture previously initialized by SCOTCH graphInit, but preserves its internal
data structures . This call is equivalent to a call to SCOTCH
graphExit im-
mediately followed by a call to SCOTCH graphInit. Consequently, the given
SCOTCH Graph structure remains ready for subsequent calls to any routine of
the libScotch library.
7.5.4 SCOTCH
graphLoad
Synopsis
int SCOTCH graphLoad (SCOTCH Graph * grafptr,
FILE * stream,
SCOTCH
Num baseval,
SCOTCH Num flagval)
scotchfgraphload (doubleprecision (*) grafdat,
integer fildes,
integer*num baseval,
integer*num flagval,
integer ierr)
Description
The SCOTCH graphLoad r outine fills the SCOTCH Graph structure pointed to
by grafptr with the source graph description available from stream stream
in the Scotch graph format (see section 5.1).
To ease the handling of source graph files by programs written in C a s well as
in Fortran, the base value of the graph to read can be set to 0 or 1, by setting
the baseval parameter to the proper value. A value of -1 indicates that the
graph base sho uld be the same as the one provided in the graph description
that is read fro m stream.
The flagval value is a combina tion of the following integer va lues, that may
be added or bitwise -ored:
0 Keep vertex and edge weights if they are present in the stream data.
1 Remove vertex weights. The graph read will have all of its vertex weights
set to one, regardless of what is specified in the stream data.
2 Remove edge weights. The graph read will have all of its edge weights
set to one, regardless of what is specified in the stream data.
Fortra n users must use the PXFFILENO or FNUM functions to obtain the number
of the Unix file descriptor fildes associated with the logical unit of the graph
file.
Return val ues
SCOTCH
graphLoad returns 0 if the gra ph structure has been successfully al-
located and filled with the data read, and 1 else.
78