TaPAS  0.2
genepi-util.h
Go to the documentation of this file.
1 /*
2  * genepi-util.h -- Generic operations on GENEPI sets
3  *
4  * This file is a part of the GENEric Presburger programming Interface.
5  *
6  * Copyright (C) 2010 CNRS UMR 5800 & Université Bordeaux I (see AUTHORS file).
7  *
8  * This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, write to the Free Software
20  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21  * 02110-1301 USA
22  */
23 
28 #ifndef __GENEPI_UTIL_H__
29 # define __GENEPI_UTIL_H__
30 
31 # include <genepi/genepi.h>
32 
33 BEGIN_C_DECLS
34 
38 extern genepi_set *
40 
44 extern genepi_set *
46 
50 extern genepi_set *
52  genepi_set *e);
53 
58 extern genepi_set *
59 genepi_set_linear_transform (genepi_solver *solver, int n, int *alpha, int c,
60  genepi_set **X);
61 
66 static inline genepi_set *
67 genepi_set_aX_plus_bY (genepi_solver *solver, int a, genepi_set *X, int b,
68  genepi_set *Y);
69 
73 static inline genepi_set *
75 
80 extern genepi_set *
81 genepi_set_add_constant (genepi_solver *solver, int a, genepi_set *X, int *c,
82  int cden);
83 
87 static inline genepi_set *
89 
93 static inline genepi_set *
94 genepi_set_scale (genepi_solver *solver, int s, genepi_set *X);
95 
100 extern genepi_set *
101 genepi_set_mul_vector (genepi_solver *solver, genepi_set *X, int width,
102  const int *vector, int den);
103 
107 static inline genepi_set *
109 
113 extern genepi_set *
115  genepi_set *Y);
116 
120 extern genepi_set *
121 genepi_set_singleton (genepi_solver *solver, int width, const int *vector,
122  int den);
123 
127 extern genepi_set *
129 
133 extern genepi_set *
135 
139 extern genepi_set *
140 genepi_set_interleave (genepi_solver *solver, int nb_X, genepi_set **X);
141 
145 extern genepi_set *
147 
151 extern genepi_set *
153 
154 
155 END_C_DECLS
156 
157 # include <genepi/genepi-util-inline.h>
158 
159 #endif /* ! __GENEPI_UTIL_H__ */
genepi_set * genepi_set_mul_vector(genepi_solver *solver, genepi_set *X, int width, const int *vector, int den)
Given a set X of scalar values and a vector/den, computes the set .
static genepi_set * genepi_set_sub(genepi_solver *solver, genepi_set *X, genepi_set *Y)
Computes .
genepi_set * genepi_set_monoid(genepi_solver *solver, genepi_set *X)
Computes .
static genepi_set * genepi_set_scale(genepi_solver *solver, int s, genepi_set *X)
Computes .
genepi_set * genepi_set_delta(genepi_solver *solver, genepi_set *X, genepi_set *Y)
Computes .
genepi_set * genepi_set_add_constant(genepi_solver *solver, int a, genepi_set *X, int *c, int cden)
Computes .
genepi_set * genepi_set_cartesian_product(genepi_solver *solver, genepi_set *X, genepi_set *Y)
Computes .
struct genepi_set_st genepi_set
Abstraction of Presburger definable set.
Definition: genepi.h:190
genepi_set * genepi_set_equiv(genepi_solver *solver, genepi_set *S1, genepi_set *S2)
Computes .
genepi_set * genepi_set_interleave(genepi_solver *solver, int nb_X, genepi_set **X)
Computes a genepi_set encoding the interleaving of columns of X[i]s.
genepi_set * genepi_set_diff(genepi_solver *solver, genepi_set *X, genepi_set *Y)
Computes .
static genepi_set * genepi_set_aX_plus_bY(genepi_solver *solver, int a, genepi_set *X, int b, genepi_set *Y)
Computes .
static genepi_set * genepi_set_neg(genepi_solver *solver, genepi_set *X)
Computes .
GENEPI Solver Interface.
genepi_set * genepi_set_singleton(genepi_solver *solver, int width, const int *vector, int den)
Computes .
static genepi_set * genepi_set_add(genepi_solver *solver, genepi_set *X, genepi_set *Y)
Computes .
genepi_set * genepi_set_if_then_else(genepi_solver *solver, genepi_set *i, genepi_set *t, genepi_set *e)
Computes .
struct genepi_solver_st genepi_solver
Type of GENEPI solver.
Definition: genepi.h:180
genepi_set * genepi_set_linear_transform(genepi_solver *solver, int n, int *alpha, int c, genepi_set **X)
Computes .
genepi_set * genepi_set_imply(genepi_solver *solver, genepi_set *S1, genepi_set *S2)
Computes .
genepi_set * genepi_set_instable(genepi_solver *solver, genepi_set *X)
Computes .