Types and functions for linear expressions. More...
#include <ppl_c_header.h>
Related Functions | |
(Note that these are not member functions.) | |
Constructors, Assignment and Destructor | |
| int | ppl_new_Linear_Expression (ppl_Linear_Expression_t *ple) |
Creates a new linear expression corresponding to the constant 0 in a zero-dimensional space; writes a handle for the new linear expression at address ple. | |
| int | ppl_new_Linear_Expression_with_dimension (ppl_Linear_Expression_t *ple, ppl_dimension_type d) |
Creates a new linear expression corresponding to the constant 0 in a d-dimensional space; writes a handle for the new linear expression at address ple. | |
| int | ppl_new_Linear_Expression_from_Linear_Expression (ppl_Linear_Expression_t *ple, ppl_const_Linear_Expression_t le) |
Builds a linear expression that is a copy of le; writes a handle for the newly created linear expression at address ple. | |
| int | ppl_new_Linear_Expression_from_Constraint (ppl_Linear_Expression_t *ple, ppl_const_Constraint_t c) |
Builds a linear expression corresponding to constraint c; writes a handle for the newly created linear expression at address ple. | |
| int | ppl_new_Linear_Expression_from_Generator (ppl_Linear_Expression_t *ple, ppl_const_Generator_t g) |
Builds a linear expression corresponding to generator g; writes a handle for the newly created linear expression at address ple. | |
| int | ppl_new_Linear_Expression_from_Congruence (ppl_Linear_Expression_t *ple, ppl_const_Congruence_t c) |
Builds a linear expression corresponding to congruence c; writes a handle for the newly created linear expression at address ple. | |
| int | ppl_new_Linear_Expression_from_Grid_Generator (ppl_Linear_Expression_t *ple, ppl_const_Grid_Generator_t g) |
Builds a linear expression corresponding to grid generator g; writes a handle for the newly created linear expression at address ple. | |
| int | ppl_assign_Linear_Expression_from_Linear_Expression (ppl_Linear_Expression_t dst, ppl_const_Linear_Expression_t src) |
Assigns a copy of the linear expression src to dst. | |
| int | ppl_delete_Linear_Expression (ppl_const_Linear_Expression_t le) |
Invalidates the handle le: this makes sure the corresponding resources will eventually be released. | |
Functions that Do Not Modify the Linear Expression | |
| int | ppl_Linear_Expression_space_dimension (ppl_const_Linear_Expression_t le, ppl_dimension_type *m) |
Writes to m the space dimension of le. | |
| int | ppl_Linear_Expression_coefficient (ppl_const_Linear_Expression_t le, ppl_dimension_type var, ppl_Coefficient_t n) |
Copies into n the coefficient of variable var in the linear expression le. | |
| int | ppl_Linear_Expression_inhomogeneous_term (ppl_const_Linear_Expression_t le, ppl_Coefficient_t n) |
Copies into n the inhomogeneous term of linear expression le. | |
| int | ppl_Linear_Expression_OK (ppl_const_Linear_Expression_t le) |
Returns a positive integer if le is well formed, i.e., if it satisfies all its implementation invariants; returns 0 and perhaps makes some noise if le is broken. Useful for debugging purposes. | |
| int | ppl_Linear_Expression_is_zero (ppl_const_Linear_Expression_t le) |
Returns true if and only if *this is . | |
| int | ppl_Linear_Expression_all_homogeneous_terms_are_zero (ppl_const_Linear_Expression_t le) |
Returns true if and only if all the homogeneous terms of *this are . | |
Functions that May Modify the Linear Expression | |
| int | ppl_Linear_Expression_add_to_coefficient (ppl_Linear_Expression_t le, ppl_dimension_type var, ppl_const_Coefficient_t n) |
Adds n to the coefficient of variable var in the linear expression le. The space dimension is set to be the maximum between var + 1 and the old space dimension. | |
| int | ppl_Linear_Expression_add_to_inhomogeneous (ppl_Linear_Expression_t le, ppl_const_Coefficient_t n) |
Adds n to the inhomogeneous term of the linear expression le. | |
| int | ppl_add_Linear_Expression_to_Linear_Expression (ppl_Linear_Expression_t dst, ppl_const_Linear_Expression_t src) |
Adds the linear expression src to dst. | |
| int | ppl_subtract_Linear_Expression_from_Linear_Expression (ppl_Linear_Expression_t dst, ppl_const_Linear_Expression_t src) |
Subtracts the linear expression src from dst. | |
| int | ppl_multiply_Linear_Expression_by_Coefficient (ppl_Linear_Expression_t le, ppl_const_Coefficient_t n) |
Multiply the linear expression dst by n. | |
Types and functions for linear expressions.
The types and functions for linear expression provide an interface towards Linear_Expression.
| int ppl_add_Linear_Expression_to_Linear_Expression | ( | ppl_Linear_Expression_t | dst, | |
| ppl_const_Linear_Expression_t | src | |||
| ) | [related] |
Adds the linear expression src to dst.
Definition at line 557 of file ppl_c_implementation_common.cc.
| int ppl_assign_Linear_Expression_from_Linear_Expression | ( | ppl_Linear_Expression_t | dst, | |
| ppl_const_Linear_Expression_t | src | |||
| ) | [related] |
Assigns a copy of the linear expression src to dst.
Definition at line 526 of file ppl_c_implementation_common.cc.
| int ppl_delete_Linear_Expression | ( | ppl_const_Linear_Expression_t | le | ) | [related] |
Invalidates the handle le: this makes sure the corresponding resources will eventually be released.
Definition at line 518 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_add_to_coefficient | ( | ppl_Linear_Expression_t | le, | |
| ppl_dimension_type | var, | |||
| ppl_const_Coefficient_t | n | |||
| ) | [related] |
Adds n to the coefficient of variable var in the linear expression le. The space dimension is set to be the maximum between var + 1 and the old space dimension.
Definition at line 535 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_add_to_inhomogeneous | ( | ppl_Linear_Expression_t | le, | |
| ppl_const_Coefficient_t | n | |||
| ) | [related] |
Adds n to the inhomogeneous term of the linear expression le.
Definition at line 546 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_all_homogeneous_terms_are_zero | ( | ppl_const_Linear_Expression_t | le | ) | [related] |
Returns true if and only if all the homogeneous terms of *this are
.
Definition at line 628 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_coefficient | ( | ppl_const_Linear_Expression_t | le, | |
| ppl_dimension_type | var, | |||
| ppl_Coefficient_t | n | |||
| ) | [related] |
Copies into n the coefficient of variable var in the linear expression le.
Definition at line 594 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_inhomogeneous_term | ( | ppl_const_Linear_Expression_t | le, | |
| ppl_Coefficient_t | n | |||
| ) | [related] |
Copies into n the inhomogeneous term of linear expression le.
Definition at line 605 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_is_zero | ( | ppl_const_Linear_Expression_t | le | ) | [related] |
Returns true if and only if *this is
.
Definition at line 621 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_OK | ( | ppl_const_Linear_Expression_t | le | ) | [related] |
Returns a positive integer if le is well formed, i.e., if it satisfies all its implementation invariants; returns 0 and perhaps makes some noise if le is broken. Useful for debugging purposes.
Definition at line 615 of file ppl_c_implementation_common.cc.
| int ppl_Linear_Expression_space_dimension | ( | ppl_const_Linear_Expression_t | le, | |
| ppl_dimension_type * | m | |||
| ) | [related] |
Writes to m the space dimension of le.
Definition at line 586 of file ppl_c_implementation_common.cc.
| int ppl_multiply_Linear_Expression_by_Coefficient | ( | ppl_Linear_Expression_t | le, | |
| ppl_const_Coefficient_t | n | |||
| ) | [related] |
Multiply the linear expression dst by n.
Definition at line 576 of file ppl_c_implementation_common.cc.
| int ppl_new_Linear_Expression | ( | ppl_Linear_Expression_t * | ple | ) | [related] |
Creates a new linear expression corresponding to the constant 0 in a zero-dimensional space; writes a handle for the new linear expression at address ple.
Definition at line 492 of file ppl_c_implementation_common.cc.
| int ppl_new_Linear_Expression_from_Congruence | ( | ppl_Linear_Expression_t * | ple, | |
| ppl_const_Congruence_t | c | |||
| ) | [related] |
Builds a linear expression corresponding to congruence c; writes a handle for the newly created linear expression at address ple.
Definition at line 1366 of file ppl_c_implementation_common.cc.
| int ppl_new_Linear_Expression_from_Constraint | ( | ppl_Linear_Expression_t * | ple, | |
| ppl_const_Constraint_t | c | |||
| ) | [related] |
Builds a linear expression corresponding to constraint c; writes a handle for the newly created linear expression at address ple.
Definition at line 757 of file ppl_c_implementation_common.cc.
| int ppl_new_Linear_Expression_from_Generator | ( | ppl_Linear_Expression_t * | ple, | |
| ppl_const_Generator_t | g | |||
| ) | [related] |
Builds a linear expression corresponding to generator g; writes a handle for the newly created linear expression at address ple.
Definition at line 1079 of file ppl_c_implementation_common.cc.
| int ppl_new_Linear_Expression_from_Grid_Generator | ( | ppl_Linear_Expression_t * | ple, | |
| ppl_const_Grid_Generator_t | g | |||
| ) | [related] |
Builds a linear expression corresponding to grid generator g; writes a handle for the newly created linear expression at address ple.
| int ppl_new_Linear_Expression_from_Linear_Expression | ( | ppl_Linear_Expression_t * | ple, | |
| ppl_const_Linear_Expression_t | le | |||
| ) | [related] |
Builds a linear expression that is a copy of le; writes a handle for the newly created linear expression at address ple.
Definition at line 510 of file ppl_c_implementation_common.cc.
| int ppl_new_Linear_Expression_with_dimension | ( | ppl_Linear_Expression_t * | ple, | |
| ppl_dimension_type | d | |||
| ) | [related] |
Creates a new linear expression corresponding to the constant 0 in a d-dimensional space; writes a handle for the new linear expression at address ple.
Definition at line 499 of file ppl_c_implementation_common.cc.
| int ppl_subtract_Linear_Expression_from_Linear_Expression | ( | ppl_Linear_Expression_t | dst, | |
| ppl_const_Linear_Expression_t | src | |||
| ) | [related] |
Subtracts the linear expression src from dst.
Definition at line 567 of file ppl_c_implementation_common.cc.
1.6.3