add isl_set_from_point
[platform/upstream/isl.git] / doc / user.pod
index 06133c4..3f9129d 100644 (file)
@@ -96,7 +96,7 @@ C<piplib> functionality is currently used by default.
 The C<--with-piplib> option can
 be used to specify which C<piplib>
 library to use, either an installed version (C<system>),
-an externally built version (C<build>), a bundled version (C<bundled>)
+an externally built version (C<build>)
 or no version (C<no>).  The option C<build> is mostly useful
 in C<configure> scripts of larger projects that bundle both C<isl>
 and C<piplib>.
@@ -117,9 +117,7 @@ Installation prefix for C<GMP> (architecture-dependent files).
 
 =item C<--with-piplib>
 
-Which copy of C<piplib> to use, either C<no> (default), C<system>, C<build>
-or C<bundled>.  Note that C<bundled> only works if you have obtained
-C<isl> and its submodules from the git repository.
+Which copy of C<piplib> to use, either C<no> (default), C<system> or C<build>.
 
 =item C<--with-piplib-prefix>
 
@@ -1072,7 +1070,12 @@ Points can be copied or freed using
                __isl_keep isl_point *pnt);
        void isl_point_free(__isl_take isl_point *pnt);
 
-A box can be created from two opposite extremal points using
+A singleton set can be created from a point using
+
+       __isl_give isl_set *isl_set_from_point(
+               __isl_take isl_point *pnt);
+
+and a box can be created from two opposite extremal points using
 
        __isl_give isl_set *isl_set_box_from_points(
                __isl_take isl_point *pnt1,
@@ -1186,6 +1189,50 @@ functions.
        void isl_pw_qpolynomial_free(
                __isl_take isl_pw_qpolynomial *pwqp);
 
+=head3 Inspecting (Piecewise) Quasipolynomials
+
+To iterate over the cells in a piecewise quasipolynomial,
+use the following function
+
+       int isl_pw_qpolynomial_foreach_piece(
+               __isl_keep isl_pw_qpolynomial *pwqp,
+               int (*fn)(__isl_take isl_set *set,
+                         __isl_take isl_qpolynomial *qp,
+                         void *user), void *user);
+
+As usual, the function C<fn> should return C<0> on success
+and C<-1> on failure.
+
+To iterate over all terms in a quasipolynomial,
+use
+
+       int isl_qpolynomial_foreach_term(
+               __isl_keep isl_qpolynomial *qp,
+               int (*fn)(__isl_take isl_term *term,
+                         void *user), void *user);
+
+The terms themselves can be inspected and freed using
+these functions
+
+       unsigned isl_term_dim(__isl_keep isl_term *term,
+               enum isl_dim_type type);
+       void isl_term_get_num(__isl_keep isl_term *term,
+               isl_int *n);
+       void isl_term_get_den(__isl_keep isl_term *term,
+               isl_int *d);
+       int isl_term_get_exp(__isl_keep isl_term *term,
+               enum isl_dim_type type, unsigned pos);
+       __isl_give isl_div *isl_term_get_div(
+               __isl_keep isl_term *term, unsigned pos);
+       void isl_term_free(__isl_take isl_term *term);
+
+Each term is a product of parameters, set variables and
+integer divisions.  The function C<isl_term_get_exp>
+returns the exponent of a given dimensions in the given term.
+The C<isl_int>s in the arguments of C<isl_term_get_num>
+and C<isl_term_get_den> need to have been initialized
+using C<isl_int_init> before calling these functions.
+
 =head3 Properties of (Piecewise) Quasipolynomials
 
 To check whether a quasipolynomial is actually a constant,