From 15afa4757e52147dfa9b54c0a285a545b4546ed3 Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Sat, 24 Feb 2007 00:08:09 +0100 Subject: [PATCH] barvinok_maximize: optionally call evalue_split_periods --- maximize.cc | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/maximize.cc b/maximize.cc index d9276ec..0d407c0 100644 --- a/maximize.cc +++ b/maximize.cc @@ -14,8 +14,10 @@ using namespace bernstein; using namespace barvinok; #define OPT_VARS (BV_OPT_LAST+1) +#define OPT_SPLIT (BV_OPT_LAST+2) struct argp_option argp_options[] = { + { "split", OPT_SPLIT, "int" }, { "variables", OPT_VARS, "int", 0, "number of variables over which to maximize" }, { "verbose", 'V', 0, 0, }, @@ -25,6 +27,7 @@ struct argp_option argp_options[] = { struct options { int nvar; int verbose; + int split; }; static error_t parse_opt(int key, char *arg, struct argp_state *state) @@ -35,6 +38,7 @@ static error_t parse_opt(int key, char *arg, struct argp_state *state) case ARGP_KEY_INIT: options->nvar = -1; options->verbose = 0; + options->split = 0; break; case 'V': options->verbose = 1; @@ -42,6 +46,9 @@ static error_t parse_opt(int key, char *arg, struct argp_state *state) case OPT_VARS: options->nvar = atoi(arg); break; + case OPT_SPLIT: + options->split = atoi(arg); + break; default: return ARGP_ERR_UNKNOWN; } @@ -804,6 +811,9 @@ int main(int argc, char **argv) EP = evalue_read(stdin, &all_vars, &ntotal, bv_options->MaxRays); assert(EP); + if (options.split) + evalue_split_periods(EP, options.split, bv_options->MaxRays); + if (options.verbose) print_evalue(stderr, EP, all_vars); -- 2.11.4.GIT