[Nauty-list] malfunction of catg

William Rummler w.a.rummler at gmail.com
Mon Mar 14 15:28:30 EST 2011

> It seems that catg omits the first char of each file when concatenating
> files. What's wrong?

I checked this out and it appears to happen when catg is processing
graph files without headers. Specifically, at the end of the
openfile_head() function in catg.c, inside the else-clause located on
line 82-83, the statement "ungetc(c,f);" should be added to avoid
losing the first character of the first graph in a header-less graph
file when it is checked for a header.

You could add the "-h" flag to all your geng commands, or you could
edit catg.c --- Basically, replace line 83:


with the following (including the brackets, since ungetc() will not be
blocked in the else-clause otherwise):


and recompile catg.c (or more simply just use the command "make"
within your nauty source directory).

- William

More information about the Nauty mailing list