parametric.hpp file
Classes
-
template<typename DiGraph, typename ParametricAPI>class MaxParametricSolver
- Maximum Parametric Solver.
Functions
-
template<typename DiGraph, typename T, typename Fn1, typename Fn2, typename Mapping, typename D>auto max_parametric(const DiGraph& gra, T& r_opt, Fn1&& distance, Fn2&& zero_cancel, Mapping& dist, D) -> auto
Function documentation
template<typename DiGraph, typename T, typename Fn1, typename Fn2, typename Mapping, typename D>
auto max_parametric(const DiGraph& gra,
T& r_opt,
Fn1&& distance,
Fn2&& zero_cancel,
Mapping& dist,
D)
| Template parameters | |
|---|---|
| DiGraph | |
| T | |
| Fn1 | |
| Fn2 | |
| Mapping | |
| D | |
| Parameters | |
| gra in | The parameter "gra" is a directed graph. |
| r_opt in/out | The parameter r_opt is the parameter to be maximized in the network parametric problem. It is initially set to a large number and will be updated during the optimization process. |
| distance in | A monotone decreasing function that calculates the distance between two vertices in the graph given a parameter r. It takes in two arguments: the parameter r and an edge of the graph. |
| zero_cancel in | The zero_cancel parameter is a function that takes a critical cycle ci and returns a modified version of it. This function is used to cancel out any zero-weight edges in the critical cycle. |
| dist in | A mapping from vertices to their distances from a source vertex in the graph. |
| Returns | the optimal value of parameter r and the critical cycle. |
The function solves a network parametric problem by maximizing a parameter while satisfying a set of constraints:
max r s.t. dist[v] - dist[u] <= distrance(e, r) \forall e(u, v) \in gra(V, E)