40 "Compute the Euler characteristic.",
41 "Compute the Euler characteristic of a monomial ideal I. This is defined as " 42 "the Euler characteristic of the simplicial complex D where I is the dual of " 43 "the Stanley-Reisner ideal of D. The translation between I and D is " 44 "computationally efficient. Define f by\n" 46 " f(v) = product of all variables not in the set v\n" 48 "Then f is a bijection from the facets of D to the minimal generators of I. " 49 "So this action can easily be used to compute Euler characteristics of " 50 "abstract simplicial complexes given by their facets. If you have an input " 51 "file where the 0-1 exponents are opposite of what you need for this " 52 "action, use the -swap01 option.",
57 "Which kind of pivots to use. Options are\n" 58 " std: Use standard pivots only.\n" 59 " gen: Use generator pivots only.\n" 60 " hybrid: Use a heuristic to choose at each split.\n",
65 "Which kind of standard pivots to use. The options are\n" 66 " popvar: Use a popular variable as pivot.\n" 67 " rarevar: Use a rare variable as pivot.\n" 68 " popgcd: Use the gcd of 3 generators divisible by a popular variable.\n" 69 " any: Use some variable in a way that does not vary between runs.\n" 70 " random: Use a random variable. Choices may vary between runs.\n" 71 "A rare variable is a variable that divides a minimum number of " 72 "generators. A popular variable is a variable that divides a " 73 "maximum number of generators.\n" 75 "In addition, widen_X where X is one of the strategies above will " 76 "compute a preliminary pivot according to X, and then select the actual " 77 "pivot to be the gcd of all generators that the preliminary pivot divides.",
82 "Which kind of generator pivots to use. The options are\n" 83 " rarevar: Pick a generator divisible by a rare variable.\n" 84 " popvar: Pick a generator divisible by a popular variable.\n" 85 " maxsupp: Pick a generator with maximum support.\n" 86 " minsupp: Pick a generator with minimum support.\n" 87 " any: Pick some generator in a way that does not vary between runs.\n" 88 " random: Pick a random generator. Choices may vary between runs.\n" 89 " rarest: Pick a generator that is divisible by a maximum number of\n" 90 " rare variables. Break ties by picking the generator that is divisible\n" 91 " by the maximum number of second-most-rare variables and so on.\n" 92 " raremax: as rarevar_maxsupp.\n" 93 "A rare variable is a variable that divides a minimum number of " 94 "generators. A popular variable is a variable that divides a " 95 "maximum number of generators.\n" 97 "All of these strategies except any and random can have ties. Combine " 98 "strategies A and B by writing A_B. If A has a tie then A_B will use " 99 "B to break the tie. For example rarevar_minsupp will pick some rare " 101 "and select the generator with maximum support divisible by that variable. " 102 "For another example, rarevar_minsupp_random will do the same thing, but " 103 "if two generators divisible by the rare variable has the same " 105 "then it will pick one at random instead of deterministically.\n" 107 "All choices implicitly have _any appended to them, so any remaining " 108 "ties are broken arbitrarily in a deterministic way. If a strategy would " 109 "eliminate all candidates for a pivot it will instead preserve all the " 110 "candidates. This can happen for example in minsupp_rarevar where the " 111 "minsupp strategy might have eliminated all generators that are divisible " 112 "by the rare variable that rarevar selects. Then rarevar cannot make a " 113 "choice so it will refrain from doing so.",
118 "The two algorithms prefer more variables and more generators " 119 "respectively. Transposing the variable-generator divides " 120 "matrix swaps the number of variables and generators without " 121 "changing the Euler characteristic. If this option is on it " 122 "will transpose at each step if the preferred one of " 123 "variables and generators is not larger. If this option is " 124 "set to \"once\", it will do this but only at the first step. " 125 "If this option is off, no transposes are done.",
130 "Print what the algorithm does at each step.",
135 "Print statistics on what the algorithm did.",
138 _useUniqueDivSimplify
140 "Simplify ideals at each step where a variable divides only one generator.",
145 "Simplify ideals at each step where a variable divides all generators " 151 "Simplify ideals at each step with variables X and Y such that all " 152 "generators divisible by A are also divisible by B.",
157 "Change all 0 exponents to 1 and vice versa.",
165 parameters.push_back(&
_pivot);
174 parameters.push_back(&
_swap01);
181 auto_ptr<PivotStrategy> strat;
186 else if (
_pivot ==
"hybrid")
232 reportError(
"Unknown setting for -autoTranspose of \"" +
240 gmp_fprintf(stdout,
"%Zd\n", euler.get_mpz_t());
StringParameter _genPivot
virtual void obtainParameters(vector< Parameter *> ¶meters)
void validateFormats() const
const RawSquareFreeIdeal * getRawIdeal() const
void setInitialAutoTranspose(bool value)
void swap01Exponents()
Change 0 exponents into 1 and vice versa.
BoolParameter _printActions
virtual void obtainParameters(vector< Parameter *> ¶meters)
StringParameter _stdPivot
The intention of this class is to describe the different kinds of mathematical structures that Frobby...
void autoDetectInputFormat(Scanner &in)
If using the input format, this must be called before validating the ideals, since the auto detect fo...
auto_ptr< PivotStrategy > newStatisticsPivotStrategy(auto_ptr< PivotStrategy > strat, FILE *out)
auto_ptr< PivotStrategy > newStdPivotStrategy(const string &name)
This class offers an input interface which is more convenient and for some purposes more efficient th...
void setAutoTranspose(bool value)
auto_ptr< PivotStrategy > newGenPivotStrategy(const string &name)
StringParameter _autoTranspose
void readSquareFreeIdeal(Scanner &in, SquareFreeIdeal &ideal)
Read a square free ideal from in and place it in the parameter ideal.
const string & getInputFormat() const
BoolParameter _useAllPairsSimplify
BoolParameter _useManyDivSimplify
BoolParameter _printDebug
BoolParameter _useUniqueDivSimplify
void setUseManyDivSimplify(bool value)
A facade for input and output of mathematical objects.
void setUseUniqueDivSimplify(bool value)
auto_ptr< PivotStrategy > newHybridPivotStrategy(auto_ptr< PivotStrategy > stdStrat, auto_ptr< PivotStrategy > genStrat)
void obtainParameters(vector< Parameter *> ¶meters)
auto_ptr< PivotStrategy > newDebugPivotStrategy(auto_ptr< PivotStrategy > strat, FILE *out)
void setPivotStrategy(auto_ptr< PivotStrategy > strategy)
void reportError(const string &errorMsg)
const mpz_class & computeEulerCharacteristic(const Ideal &ideal)
BoolParameter _printStatistics
void setUseAllPairsSimplify(bool value)
const string & getValue() const
static const char * staticGetName()