Types and functions for MIP problems. More...
#include <ppl_c.h>
Related Functions | |
(Note that these are not member functions.) | |
Symbolic Constants | |
| int | PPL_OPTIMIZATION_MODE_MAXIMIZATION |
| Code of the "maximization" optimization mode. | |
| int | PPL_OPTIMIZATION_MODE_MINIMIZATION |
| Code of the "minimization" optimization mode. | |
| int | PPL_MIP_PROBLEM_STATUS_UNFEASIBLE |
| Code of the "unfeasible MIP problem" status. | |
| int | PPL_MIP_PROBLEM_STATUS_UNBOUNDED |
| Code of the "unbounded MIP problem" status. | |
| int | PPL_MIP_PROBLEM_STATUS_OPTIMIZED |
| Code of the "optimized MIP problem" status. | |
| int | PPL_MIP_PROBLEM_CONTROL_PARAMETER_NAME_PRICING |
| Code for the MIP problem's "pricing" control parameter name. | |
| int | PPL_MIP_PROBLEM_CONTROL_PARAMETER_PRICING_TEXTBOOK |
| Code of MIP problem's "textbook" pricing method. | |
| int | PPL_MIP_PROBLEM_CONTROL_PARAMETER_PRICING_STEEPEST_EDGE_EXACT |
| Code of MIP problem's "exact steepest-edge" pricing method. | |
| int | PPL_MIP_PROBLEM_CONTROL_PARAMETER_PRICING_STEEPEST_EDGE_FLOAT |
| Code of MIP problem's "float steepest-edge" pricing method. | |
Constructors, Assignment and Destructor | |
| int | ppl_new_MIP_Problem_from_space_dimension (ppl_MIP_Problem_t *pmip, ppl_dimension_type d) |
Builds a trivial MIP problem of dimension d and writes a handle to it at address pmip. | |
| int | ppl_new_MIP_Problem (ppl_MIP_Problem_t *pmip, ppl_dimension_type d, ppl_const_Constraint_System_t cs, ppl_const_Linear_Expression_t le, int m) |
Builds a MIP problem of space dimension d having feasible region cs, objective function le and optimization mode m; writes a handle to it at address pmip. | |
| int | ppl_new_MIP_Problem_from_MIP_Problem (ppl_MIP_Problem_t *pmip, ppl_const_MIP_Problem_t mip) |
Builds a MIP problem that is a copy of mip; writes a handle for the newly created system at address pmip. | |
| int | ppl_assign_MIP_Problem_from_MIP_Problem (ppl_MIP_Problem_t dst, ppl_const_MIP_Problem_t src) |
Assigns a copy of the MIP problem src to dst. | |
| int | ppl_delete_MIP_Problem (ppl_const_MIP_Problem_t mip) |
Invalidates the handle mip: this makes sure the corresponding resources will eventually be released. | |
Functions that Do Not Modify the MIP_Problem | |
| int | ppl_MIP_Problem_space_dimension (ppl_const_MIP_Problem_t mip, ppl_dimension_type *m) |
Writes to m the dimension of the vector space enclosing mip. | |
| int | ppl_MIP_Problem_number_of_integer_space_dimensions (ppl_const_MIP_Problem_t mip, ppl_dimension_type *m) |
Writes to m the number of integer space dimensions of mip. | |
| int | ppl_MIP_Problem_integer_space_dimensions (ppl_const_MIP_Problem_t mip, ppl_dimension_type ds[]) |
Writes in the first positions of the array ds all the integer space dimensions of problem mip. If the array is not big enough to hold all of the integer space dimensions, the behavior is undefined. | |
| int | ppl_MIP_Problem_number_of_constraints (ppl_const_MIP_Problem_t mip, ppl_dimension_type *m) |
Writes to m the number of constraints defining the feasible region of mip. | |
| int | ppl_MIP_Problem_constraint_at_index (ppl_const_MIP_Problem_t mip, ppl_dimension_type i, ppl_const_Constraint_t *pc) |
Writes at address pc a const handle to the i-th constraint defining the feasible region of the MIP problem mip. | |
| int | ppl_MIP_Problem_objective_function (ppl_const_MIP_Problem_t mip, ppl_const_Linear_Expression_t *ple) |
Writes a const handle to the linear expression defining the objective function of the MIP problem mip at address ple. | |
| int | ppl_MIP_Problem_optimization_mode (ppl_const_MIP_Problem_t mip) |
Returns the optimization mode of the MIP problem mip. | |
| int | ppl_MIP_Problem_OK (ppl_const_MIP_Problem_t mip) |
Returns a positive integer if mip is well formed, i.e., if it satisfies all its implementation invariants; returns 0 and perhaps makes some noise if mip is broken. Useful for debugging purposes. | |
Functions that May Modify the MIP_Problem | |
| int | ppl_MIP_Problem_clear (ppl_MIP_Problem_t mip) |
| Resets the MIP problem to be a trivial problem of space dimension 0. | |
| int | ppl_MIP_Problem_add_space_dimensions_and_embed (ppl_MIP_Problem_t mip, ppl_dimension_type d) |
Adds d new dimensions to the space enclosing the MIP problem mip and to mip itself. | |
| int | ppl_MIP_Problem_add_to_integer_space_dimensions (ppl_MIP_Problem_t mip, ppl_dimension_type ds[], size_t n) |
Sets the space dimensions that are specified in first n positions of the array ds to be integer dimensions of problem mip. The presence of duplicates in ds is a waste but an innocuous one. | |
| int | ppl_MIP_Problem_add_constraint (ppl_MIP_Problem_t mip, ppl_const_Constraint_t c) |
Modifies the feasible region of the MIP problem mip by adding a copy of the constraint c. | |
| int | ppl_MIP_Problem_add_constraints (ppl_MIP_Problem_t mip, ppl_const_Constraint_System_t cs) |
Modifies the feasible region of the MIP problem mip by adding a copy of the constraints in cs. | |
| int | ppl_MIP_Problem_set_objective_function (ppl_MIP_Problem_t mip, ppl_const_Linear_Expression_t le) |
Sets the objective function of the MIP problem mip to a copy of le. | |
| int | ppl_MIP_Problem_set_optimization_mode (ppl_MIP_Problem_t mip, int mode) |
Sets the optimization mode of the MIP problem mip to mode. | |
Computing the Solution of the MIP_Problem | |
| int | ppl_MIP_Problem_is_satisfiable (ppl_const_MIP_Problem_t mip) |
Returns a positive integer if mip is satisfiable; returns 0 otherwise. | |
| int | ppl_MIP_Problem_solve (ppl_const_MIP_Problem_t mip) |
Solves the MIP problem mip, returning an exit status. | |
| int | ppl_MIP_Problem_evaluate_objective_function (ppl_const_MIP_Problem_t mip, ppl_const_Generator_t g, ppl_Coefficient_t num, ppl_Coefficient_t den) |
Evaluates the objective function of mip on point g. | |
| int | ppl_MIP_Problem_feasible_point (ppl_const_MIP_Problem_t mip, ppl_const_Generator_t *pg) |
Writes a const handle to a feasible point for the MIP problem mip at address pg. | |
| int | ppl_MIP_Problem_optimizing_point (ppl_const_MIP_Problem_t mip, ppl_const_Generator_t *pg) |
Writes a const handle to an optimizing point for the MIP problem mip at address pg. | |
| int | ppl_MIP_Problem_optimal_value (ppl_const_MIP_Problem_t mip, ppl_Coefficient_t num, ppl_Coefficient_t den) |
Returns the optimal value for mip. | |
Querying/Setting Control Parameters | |
| int | ppl_MIP_Problem_get_control_parameter (ppl_const_MIP_Problem_t mip, int name) |
Returns the value of control parameter name in problem mip. | |
| int | ppl_MIP_Problem_set_control_parameter (ppl_MIP_Problem_t mip, int value) |
Sets control parameter value in problem mip. | |
| int | ppl_MIP_Problem_total_memory_in_bytes (ppl_const_MIP_Problem_t mip, size_t *sz) |
Writes into *sz the size in bytes of the memory occupied by mip. | |
| int | ppl_MIP_Problem_external_memory_in_bytes (ppl_const_MIP_Problem_t mip, size_t *sz) |
Writes into *sz the size in bytes of the memory managed by mip. | |
Types and functions for MIP problems.
The types and functions for MIP problems provide an interface towards MIP_Problem.
| int ppl_assign_MIP_Problem_from_MIP_Problem | ( | ppl_MIP_Problem_t | dst, | |
| ppl_const_MIP_Problem_t | src | |||
| ) | [related] |
Assigns a copy of the MIP problem src to dst.
Definition at line 1902 of file ppl_c_implementation_common.cc.
| int ppl_delete_MIP_Problem | ( | ppl_const_MIP_Problem_t | mip | ) | [related] |
Invalidates the handle mip: this makes sure the corresponding resources will eventually be released.
Definition at line 1895 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_add_constraint | ( | ppl_MIP_Problem_t | mip, | |
| ppl_const_Constraint_t | c | |||
| ) | [related] |
Modifies the feasible region of the MIP problem mip by adding a copy of the constraint c.
Definition at line 2010 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_add_constraints | ( | ppl_MIP_Problem_t | mip, | |
| ppl_const_Constraint_System_t | cs | |||
| ) | [related] |
Modifies the feasible region of the MIP problem mip by adding a copy of the constraints in cs.
Definition at line 2020 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_add_space_dimensions_and_embed | ( | ppl_MIP_Problem_t | mip, | |
| ppl_dimension_type | d | |||
| ) | [related] |
Adds d new dimensions to the space enclosing the MIP problem mip and to mip itself.
Definition at line 1988 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_add_to_integer_space_dimensions | ( | ppl_MIP_Problem_t | mip, | |
| ppl_dimension_type | ds[], | |||
| size_t | n | |||
| ) | [related] |
Sets the space dimensions that are specified in first n positions of the array ds to be integer dimensions of problem mip. The presence of duplicates in ds is a waste but an innocuous one.
Definition at line 1997 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_clear | ( | ppl_MIP_Problem_t | mip | ) | [related] |
Resets the MIP problem to be a trivial problem of space dimension 0.
Definition at line 1981 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_constraint_at_index | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_dimension_type | i, | |||
| ppl_const_Constraint_t * | pc | |||
| ) | [related] |
Writes at address pc a const handle to the i-th constraint defining the feasible region of the MIP problem mip.
Definition at line 1950 of file ppl_c_implementation_common.cc.
int PPL_MIP_PROBLEM_CONTROL_PARAMETER_NAME_PRICING [related] |
int PPL_MIP_PROBLEM_CONTROL_PARAMETER_PRICING_TEXTBOOK [related] |
| int ppl_MIP_Problem_evaluate_objective_function | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_const_Generator_t | g, | |||
| ppl_Coefficient_t | num, | |||
| ppl_Coefficient_t | den | |||
| ) | [related] |
Evaluates the objective function of mip on point g.
| mip | The MIP problem defining the objective function; | |
| g | The generator on which the objective function will be evaluated; | |
| num | Will be assigned the numerator of the objective function value; | |
| den | Will be assigned the denominator of the objective function value; |
Definition at line 2062 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_external_memory_in_bytes | ( | ppl_const_MIP_Problem_t | mip, | |
| size_t * | sz | |||
| ) | [related] |
Writes into *sz the size in bytes of the memory managed by mip.
Definition at line 2138 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_feasible_point | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_const_Generator_t * | pg | |||
| ) | [related] |
Writes a const handle to a feasible point for the MIP problem mip at address pg.
Definition at line 2076 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_get_control_parameter | ( | ppl_const_MIP_Problem_t | mip, | |
| int | name | |||
| ) | [related] |
Returns the value of control parameter name in problem mip.
Definition at line 2105 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_integer_space_dimensions | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_dimension_type | ds[] | |||
| ) | [related] |
Writes in the first positions of the array ds all the integer space dimensions of problem mip. If the array is not big enough to hold all of the integer space dimensions, the behavior is undefined.
Definition at line 1929 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_is_satisfiable | ( | ppl_const_MIP_Problem_t | mip | ) | [related] |
Returns a positive integer if mip is satisfiable; returns 0 otherwise.
Definition at line 2050 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_number_of_constraints | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_dimension_type * | m | |||
| ) | [related] |
Writes to m the number of constraints defining the feasible region of mip.
Definition at line 1941 of file ppl_c_implementation_common.cc.
Referenced by ppl_MIP_Problem_constraint_at_index().
| int ppl_MIP_Problem_number_of_integer_space_dimensions | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_dimension_type * | m | |||
| ) | [related] |
Writes to m the number of integer space dimensions of mip.
Definition at line 1920 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_objective_function | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_const_Linear_Expression_t * | ple | |||
| ) | [related] |
Writes a const handle to the linear expression defining the objective function of the MIP problem mip at address ple.
Definition at line 1966 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_OK | ( | ppl_const_MIP_Problem_t | mip | ) | [related] |
Returns a positive integer if mip is well formed, i.e., if it satisfies all its implementation invariants; returns 0 and perhaps makes some noise if mip is broken. Useful for debugging purposes.
Definition at line 2124 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_optimal_value | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_Coefficient_t | num, | |||
| ppl_Coefficient_t | den | |||
| ) | [related] |
Returns the optimal value for mip.
| mip | The MIP problem; | |
| num | Will be assigned the numerator of the optimal value; | |
| den | Will be assigned the denominator of the optimal value. |
Definition at line 2094 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_optimization_mode | ( | ppl_const_MIP_Problem_t | mip | ) | [related] |
Returns the optimization mode of the MIP problem mip.
Definition at line 1975 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_optimizing_point | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_const_Generator_t * | pg | |||
| ) | [related] |
Writes a const handle to an optimizing point for the MIP problem mip at address pg.
Definition at line 2085 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_set_control_parameter | ( | ppl_MIP_Problem_t | mip, | |
| int | value | |||
| ) | [related] |
Sets control parameter value in problem mip.
Definition at line 2114 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_set_objective_function | ( | ppl_MIP_Problem_t | mip, | |
| ppl_const_Linear_Expression_t | le | |||
| ) | [related] |
Sets the objective function of the MIP problem mip to a copy of le.
Definition at line 2030 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_set_optimization_mode | ( | ppl_MIP_Problem_t | mip, | |
| int | mode | |||
| ) | [related] |
Sets the optimization mode of the MIP problem mip to mode.
Definition at line 2040 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_solve | ( | ppl_const_MIP_Problem_t | mip | ) | [related] |
Solves the MIP problem mip, returning an exit status.
PPL_MIP_PROBLEM_STATUS_UNFEASIBLE if the MIP problem is not satisfiable; PPL_MIP_PROBLEM_STATUS_UNBOUNDED if the MIP problem is satisfiable but there is no finite bound to the value of the objective function; PPL_MIP_PROBLEM_STATUS_OPTIMIZED if the MIP problem admits an optimal solution. Definition at line 2056 of file ppl_c_implementation_common.cc.
| int ppl_MIP_Problem_space_dimension | ( | ppl_const_MIP_Problem_t | mip, | |
| ppl_dimension_type * | m | |||
| ) | [related] |
Writes to m the dimension of the vector space enclosing mip.
Definition at line 1912 of file ppl_c_implementation_common.cc.
int PPL_MIP_PROBLEM_STATUS_OPTIMIZED [related] |
int PPL_MIP_PROBLEM_STATUS_UNBOUNDED [related] |
int PPL_MIP_PROBLEM_STATUS_UNFEASIBLE [related] |
| int ppl_MIP_Problem_total_memory_in_bytes | ( | ppl_const_MIP_Problem_t | mip, | |
| size_t * | sz | |||
| ) | [related] |
Writes into *sz the size in bytes of the memory occupied by mip.
Definition at line 2130 of file ppl_c_implementation_common.cc.
| int ppl_new_MIP_Problem | ( | ppl_MIP_Problem_t * | pmip, | |
| ppl_dimension_type | d, | |||
| ppl_const_Constraint_System_t | cs, | |||
| ppl_const_Linear_Expression_t | le, | |||
| int | m | |||
| ) | [related] |
Builds a MIP problem of space dimension d having feasible region cs, objective function le and optimization mode m; writes a handle to it at address pmip.
Definition at line 1872 of file ppl_c_implementation_common.cc.
| int ppl_new_MIP_Problem_from_MIP_Problem | ( | ppl_MIP_Problem_t * | pmip, | |
| ppl_const_MIP_Problem_t | mip | |||
| ) | [related] |
Builds a MIP problem that is a copy of mip; writes a handle for the newly created system at address pmip.
Definition at line 1886 of file ppl_c_implementation_common.cc.
| int ppl_new_MIP_Problem_from_space_dimension | ( | ppl_MIP_Problem_t * | pmip, | |
| ppl_dimension_type | d | |||
| ) | [related] |
Builds a trivial MIP problem of dimension d and writes a handle to it at address pmip.
Definition at line 1864 of file ppl_c_implementation_common.cc.
int PPL_OPTIMIZATION_MODE_MAXIMIZATION [related] |
int PPL_OPTIMIZATION_MODE_MINIMIZATION [related] |
1.6.3