find fixpoints in simplified graph
This commit is contained in:
parent
f9700589f8
commit
2a297a74ca
18
generate.c
18
generate.c
@ -10,6 +10,7 @@ int main(int argc, const char *argv[])
|
|||||||
semisimple_type_t type;
|
semisimple_type_t type;
|
||||||
unsigned long right_invariance, left_invariance;
|
unsigned long right_invariance, left_invariance;
|
||||||
int rank, order, hyperplanes, cosets;
|
int rank, order, hyperplanes, cosets;
|
||||||
|
int fixpoints;
|
||||||
|
|
||||||
node_t *graph;
|
node_t *graph;
|
||||||
|
|
||||||
@ -74,8 +75,21 @@ int main(int argc, const char *argv[])
|
|||||||
}
|
}
|
||||||
fprintf(stderr, "\n\n");
|
fprintf(stderr, "\n\n");
|
||||||
|
|
||||||
// enumerate balanced thickenings
|
fixpoints = 0;
|
||||||
|
for(int i = 0; i < cosets; i++)
|
||||||
|
if(graph[i].opposite == i) {
|
||||||
|
if(fixpoints == 0)
|
||||||
|
fprintf(stderr, "No thickenings since the longest element fixes the following cosets: %s", alphabetize(graph[i].word, graph[i].wordlength, alphabet, string_buffer1));
|
||||||
|
else
|
||||||
|
fprintf(stderr, " %s", alphabetize(graph[i].word, graph[i].wordlength, alphabet, string_buffer1));
|
||||||
|
fixpoints++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(fixpoints > 0) {
|
||||||
|
fprintf(stderr, "\n\n");
|
||||||
|
} else {
|
||||||
|
|
||||||
|
// enumerate balanced thickenings
|
||||||
fwrite(&type.n, sizeof(int), 1, stdout);
|
fwrite(&type.n, sizeof(int), 1, stdout);
|
||||||
fwrite(type.factors, sizeof(simple_type_t), type.n, stdout);
|
fwrite(type.factors, sizeof(simple_type_t), type.n, stdout);
|
||||||
fwrite(&left_invariance, sizeof(unsigned long), type.n, stdout);
|
fwrite(&left_invariance, sizeof(unsigned long), type.n, stdout);
|
||||||
@ -83,8 +97,8 @@ int main(int argc, const char *argv[])
|
|||||||
|
|
||||||
long count = enumerate_balanced_thickenings(type, graph, cosets, alphabet, stdout);
|
long count = enumerate_balanced_thickenings(type, graph, cosets, alphabet, stdout);
|
||||||
|
|
||||||
fprintf(stderr, "\n");
|
|
||||||
fprintf(stderr, "Found %ld balanced thickenings\n\n", count);
|
fprintf(stderr, "Found %ld balanced thickenings\n\n", count);
|
||||||
|
}
|
||||||
|
|
||||||
graph_free(type, graph);
|
graph_free(type, graph);
|
||||||
free(type.factors);
|
free(type.factors);
|
||||||
|
Loading…
Reference in New Issue
Block a user