Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
| Download
GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it
Project: cocalc-sagemath-dev-slelievre
Views: 418346/****************************************************************************1**2*A exponent_info.c ANUPQ source Eamonn O'Brien3**4*Y Copyright 1995-2001, Lehrstuhl D fuer Mathematik, RWTH Aachen, Germany5*Y Copyright 1995-2001, School of Mathematical Sciences, ANU, Australia6**7*/89#include "pq_defs.h"10#include "constants.h"11#include "pcp_vars.h"12#include "exp_vars.h"13#include "pq_functions.h"1415/* read information for exponent checking */1617void exponent_info(struct exp_vars *exp_flag, struct pcp_vars *pcp)18{19Logical reading = TRUE;20Logical Default;2122read_value(TRUE, "Accept default exponent checking? ", &Default, INT_MIN);2324if (Default) {25exp_flag->list = (pcp->m == 0) ? ALL_WORDS : REDUCED_LIST;26exp_flag->process = TRUE;27exp_flag->complete = FALSE;28exp_flag->partitions = FALSE;29exp_flag->filter = FALSE;30exp_flag->start_process = 0;31exp_flag->report_unit = 0;32exp_flag->word_list = FALSE;33exp_flag->all_trivial = TRUE;34exp_flag->check_exponent = FALSE;35return;36}3738while (reading) {39read_value(TRUE,40"Complete list (1), reduced list (2), or word list (3)? ",41&exp_flag->list,421);43reading =44!(exp_flag->list == ALL_WORDS || exp_flag->list == REDUCED_LIST ||45exp_flag->list == INITIAL_SEGMENT);46if (reading)47printf("Supplied value must be one of %d, %d, or %d\n",48ALL_WORDS,49REDUCED_LIST,50INITIAL_SEGMENT);51}5253read_value(TRUE,54"Power valid words and echelonise results? ",55&exp_flag->process,56INT_MIN);5758if (exp_flag->process) {59read_value(TRUE,60"Input number of the first valid word to process? ",61&exp_flag->start_process,620);63read_value(TRUE,64"Report after collecting how many words (0 for no report)? ",65&exp_flag->report_unit,660);67} else {68exp_flag->start_process = 0;69exp_flag->report_unit = 0;70}7172read_value(TRUE,73"Print list prior to applying filters? ",74&exp_flag->complete,75INT_MIN);767778read_value(TRUE,79"Identify filter applied to remove word? ",80&exp_flag->filter,81INT_MIN);8283read_value(TRUE,84"Write list of test words to relation file? ",85&exp_flag->word_list,86INT_MIN);8788exp_flag->partitions = FALSE;89}9091/* default exponent flag settings */9293void initialise_exponent(struct exp_vars *exp_flag, struct pcp_vars *pcp)94{95int length;9697exp_flag->list = ALL_WORDS;98exp_flag->process = TRUE;99exp_flag->complete = FALSE;100exp_flag->partitions = FALSE;101exp_flag->filter = FALSE;102exp_flag->start_process = 0;103exp_flag->report_unit = 0;104exp_flag->word_list = FALSE;105exp_flag->all_trivial = TRUE;106exp_flag->check_exponent = FALSE;107108if (pcp->m != 0) {109length = MAX(1, pcp->lastg - pcp->ccbeg + 1);110exp_flag->queue = allocate_vector(length, 1, FALSE);111exp_flag->queue_length = 0;112}113}114115116