the -to-fq option allows specifying prime

This commit is contained in:
Zeno Rogue 2020-07-07 22:25:09 +02:00
parent 436fe7f367
commit 5c85f22ef3
1 changed files with 8 additions and 2 deletions

View File

@ -1036,11 +1036,17 @@ int read_geom_args() {
}
else if(argis("-to-fq")) {
cgi.require_basics();
shift(); unsigned hash = arghex();
int p = 2;
shift();
if(args() == "p") {
shift(); p = argi();
shift();
}
unsigned hash = arghex();
stop_game_and_switch_mode(rg::nothing);
fieldpattern::field_from_current();
set_geometry(gFieldQuotient);
for(int p=2;; p++) { currfp.Prime = p; currfp.force_hash = hash; if(!currfp.solve()) break; }
for(;; p++) { currfp.Prime = p; currfp.force_hash = hash; if(!currfp.solve()) break; }
println(hlog, "set prime = ", currfp.Prime);
}
else if(argis("-cs")) {