#include <stdlib.h>
#include <polylib/polylib.h>
Go to the source code of this file.
Classes | |
struct | _Polyhedron_union |
Defines | |
#define | WS 200 |
Typedefs | |
typedef struct _Polyhedron_union | Polyhedron_union |
Functions | |
static int | ppcm1 (int a, int b) |
Matrix * | CalcBase (Matrix *R) |
static void | Soustraire_ligne (Matrix *R, int l1, int l2, int piv) |
static int | existepivot (Matrix *R, int l) |
static void | swap_line (Matrix *R, int l1, int l2) |
int | pgcd1 (int a, int b) |
void | new_eadd (evalue *e1, evalue *res) |
Matrix * | Reduce_Matrix (Matrix *Mat) |
void | Scalar_product (Value *p1, Value *p2, unsigned length, Value *r) |
Matrix * | Orthogonal_Base (Matrix *Mat) |
void | Remove_Element (Enumeration *en, Enumeration **re, Enumeration *prev) |
void | Remove_RedundantDomains (Enumeration **Ures) |
int | IncludeInRes (Polyhedron *p, Enumeration *e, unsigned MR) |
Polyhedron * | DMUnion (Enumeration *en, unsigned MR) |
void | AffConstraints (Polyhedron *Poldisj) |
int | Degenerate (Enumeration *en) |
Enumeration * | Domain_Enumerate (Polyhedron *D, Polyhedron *C, unsigned MAXRAYS, const char **pn) |
Enumeration * | Polyhedron_Image_Enumerate (Polyhedron *D, Polyhedron *C, Matrix *T, unsigned MAXRAYS, const char **par_name) |
#define WS 200 |
Definition at line 20 of file ext_ehrhart.c.
Referenced by main().
typedef struct _Polyhedron_union Polyhedron_union |
void AffConstraints | ( | Polyhedron * | Poldisj | ) |
Definition at line 680 of file ext_ehrhart.c.
References polyhedron::next, p, P_VALUE_FMT, and Polyhedron_PrintConstraints().
Referenced by Domain_Enumerate(), and Polyhedron_Image_Enumerate().
Definition at line 45 of file ext_ehrhart.c.
References existepivot(), Matrix_Alloc(), matrix::NbRows, matrix::p, p, Soustraire_ligne(), swap_line(), value_addmul, value_divexact, value_gcd, value_multiply, value_neg_p, value_notzero_p, value_oppose, value_set_si, and value_zero_p.
Referenced by Polyhedron_Image_Enumerate().
int Degenerate | ( | Enumeration * | en | ) |
Definition at line 690 of file ext_ehrhart.c.
References _evalue::d, _enumeration::EP, value_mone_p, and value_notzero_p.
Referenced by Domain_Enumerate().
Polyhedron* DMUnion | ( | Enumeration * | en, | |
unsigned | MR | |||
) |
Definition at line 668 of file ext_ehrhart.c.
References DomainUnion(), _enumeration::next, and _enumeration::ValidityDomain.
Referenced by Domain_Enumerate().
Enumeration* Domain_Enumerate | ( | Polyhedron * | D, | |
Polyhedron * | C, | |||
unsigned | MAXRAYS, | |||
const char ** | pn | |||
) |
Definition at line 702 of file ext_ehrhart.c.
References AffConstraints(), _evalue::d, Degenerate(), Disjoint_Domain(), DMUnion(), Domain_Free(), DomainDifference(), DomainIntersection(), ecopy(), emptyQ, _enumeration::EP, free_evalue_refs(), IncludeInRes(), new_eadd(), _Polyhedron_union::next, _enumeration::next, polyhedron::next, POL_ENSURE_FACETS, POL_ENSURE_VERTICES, Polyhedron_Enumerate(), _Polyhedron_union::pt, Remove_RedundantDomains(), _enumeration::ValidityDomain, value_assign, value_init, and value_zero_p.
Referenced by main(), Polyhedron_Image_Enumerate(), and Polyhedron_LexSmallerEnumerate().
static int existepivot | ( | Matrix * | R, | |
int | l | |||
) | [static] |
Definition at line 218 of file ext_ehrhart.c.
References matrix::NbRows, matrix::p, value_notzero_p, and value_zero_p.
Referenced by CalcBase().
int IncludeInRes | ( | Polyhedron * | p, | |
Enumeration * | e, | |||
unsigned | MR | |||
) |
Definition at line 658 of file ext_ehrhart.c.
References _enumeration::next, PolyhedronIncludes(), and _enumeration::ValidityDomain.
Referenced by Domain_Enumerate().
Definition at line 320 of file ext_ehrhart.c.
References _enode::arr, _evalue::d, ecopy(), new_eadd(), new_enode(), p, periodic, polynomial, ppcm1(), value_addto, value_assign, value_clear, value_divexact, value_gcd, value_init, value_multiply, value_notone_p, value_notzero_p, value_set_si, and value_zero_p.
Referenced by Domain_Enumerate(), and new_eadd().
Definition at line 555 of file ext_ehrhart.c.
References Matrix_Alloc(), matrix::NbColumns, matrix::NbRows, Vector::p, matrix::p, p, Scalar_product(), value_assign, value_clear, value_divexact, value_gcd, value_init, value_lcm, value_multiply, value_notone_p, value_set_si, value_subtract, Vector_Alloc(), Vector_AntiScale(), and Vector_Gcd().
int pgcd1 | ( | int | a, | |
int | b | |||
) |
Definition at line 257 of file ext_ehrhart.c.
Referenced by ppcm1().
Enumeration* Polyhedron_Image_Enumerate | ( | Polyhedron * | D, | |
Polyhedron * | C, | |||
Matrix * | T, | |||
unsigned | MAXRAYS, | |||
const char ** | par_name | |||
) |
Definition at line 835 of file ext_ehrhart.c.
References AddConstraints(), AddPolyToDomain(), AffConstraints(), CalcBase(), polyhedron::Constraint, polyhedron::Dimension, Domain_Enumerate(), DomainImage(), emptyQ, Matrix_Alloc(), Matrix_Copy(), Matrix_Free(), Matrix_Print(), matrix::NbColumns, polyhedron::NbConstraints, matrix::NbRows, Vector::p, matrix::p, P_VALUE_FMT, POL_ENSURE_FACETS, POL_ENSURE_VERTICES, Polyhedron_Copy(), Polyhedron_Free(), Reduce_Matrix(), Scalar_product(), Transpose(), value_assign, value_clear, value_decrement, value_init, value_oppose, value_pos_p, value_set_si, value_subtract, value_zero_p, Vector_Alloc(), and Vector_Free().
int ppcm1 | ( | int | a, | |
int | b | |||
) | [static] |
Definition at line 514 of file ext_ehrhart.c.
References matrix::NbColumns, matrix::NbRows, matrix::p, p, and value_clear.
Referenced by Polyhedron_Image_Enumerate().
void Remove_Element | ( | Enumeration * | en, | |
Enumeration ** | re, | |||
Enumeration * | prev | |||
) |
Definition at line 622 of file ext_ehrhart.c.
References _enumeration::next.
Referenced by Remove_RedundantDomains().
void Remove_RedundantDomains | ( | Enumeration ** | Ures | ) |
Definition at line 634 of file ext_ehrhart.c.
References _enumeration::next, PolyhedronIncludes(), Remove_Element(), and _enumeration::ValidityDomain.
Referenced by Domain_Enumerate().
void Scalar_product | ( | Value * | p1, | |
Value * | p2, | |||
unsigned | length, | |||
Value * | r | |||
) |
Definition at line 533 of file ext_ehrhart.c.
References value_addmul, and value_set_si.
Referenced by Orthogonal_Base(), and Polyhedron_Image_Enumerate().
static void Soustraire_ligne | ( | Matrix * | R, | |
int | l1, | |||
int | l2, | |||
int | piv | |||
) | [static] |
Definition at line 279 of file ext_ehrhart.c.
References matrix::NbColumns, matrix::p, p, value_clear, value_divexact, value_gcd, value_init, value_multiply, value_set_si, value_subtract, and value_zero_p.
Referenced by CalcBase().
static void swap_line | ( | Matrix * | R, | |
int | l1, | |||
int | l2 | |||
) | [static] |
Definition at line 241 of file ext_ehrhart.c.
References matrix::NbColumns, matrix::p, and value_assign.
Referenced by CalcBase().