[Nauty-list] What is possible cause of this error? Thank you very much!

Anjie [Eric] Guo guo_anjie at hotmail.com
Mon Mar 26 13:12:18 EST 2007

I am trying to write a function that takes a graph g and write a canonically labelled isomorph of g into the graph canong. This procedure worked perfectly when I was trying it out in the main function, but turned out to cause memory error when I tried to enclose it in a independent function. When I was debugging it, I found out that the graph g was actually changed after I called nauty(g, lab, ptn, NULL, orbits, &options, &stats, workspace, 50 * MAXM, m, n, canong), although g is supposed to be read-only according to the nauty User's Guide (Version 2.2). Hence I am wondering what could be causing this situation? Thank you!
My function is as follows:
void getcanong(graph g[MAXN * MAXM], graph canong[MAXN * MAXM], int n) {  int lab[MAXN], ptn[MAXN], orbits[MAXN];  static DEFAULTOPTIONS(options);  statsblk(stats);  setword workspace[50 * MAXM];    int m = (n + WORDSIZE - 1) / WORDSIZE;  int v;  set *gv;    options.getcanon = TRUE;    nauty(g, lab, ptn, NULL, orbits, &options, &stats, workspace, 50 * MAXM, m, n, canong);}
I also wrote a similar function dealing with digraphs, and it has the same problem.
Eric Guo

"Intelligence is not a privilege, it's a gift, and you should use it for the good of mankind."
--- Doc Ock/Dr. Otto Octavius, <Spider-Man 2>
Discover the new Windows Vista
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.anu.edu.au/mailman/private/nauty/attachments/20070325/b41776ad/attachment.html 

More information about the Nauty mailing list