1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
//! # Multi-objective search
//!
//! Multi-objective shortest paths over Pareto frontiers: BOA*, BOBA*, EMOA*, NAMOA*dr, A*pex
//! and their approximate, anytime and parallel variants.
//!
//! Given a graph whose edges carry cost vectors, the algorithms find one path
//! for every Pareto-optimal cost vector from a start state to a goal.
//!
//! ## Contents
//!
//! | Function | Objectives | Heuristic | Notes |
//! |---|---|---|---|
//! | [`boa_star`] | 2 | consistent | Fastest unidirectional choice for two objectives. |
//! | [`boa_star_approx`] | 2 | consistent | BOA* with an additive tolerance on the second objective. |
//! | [`boa_star_eps`] | 2 | consistent | BOA*ε: BOA* with a factor `1 + ε` on the second objective. |
//! | [`boa_star_anytime`] | 2 | consistent | A-BOA*ε: anytime, ever better approximations down to the exact front; `_ws` adds weighted-sum pruning, `_basic` is the no-reuse baseline. |
//! | [`pp_a_star_iterative`] | 2 | consistent | Iterative-PP-A*: PP-A* from scratch over a falling tolerance schedule, the anytime baseline. |
//! | [`pp_a_star`] | 2 | consistent | PP-A*: path pairs, factors `1 + ε1` and `1 + ε2` on both objectives. |
//! | [`apex_star`] | any `N` | consistent | A*pex: apex-path pairs, a factor `1 + ε_i` per objective. |
//! | [`apex_star_anytime`] | any `N` | consistent | A-A*pex: A*pex over a falling tolerance schedule, reusing earlier solutions. |
//! | [`boba_star`] | 2 | computed internally | Bidirectional; needs a [`ReverseGraph`] and a single goal. |
//! | [`boba_star_with`] | 2 | consistent, both directions | [`boba_star`] with caller-supplied heuristics. |
//! | [`emoa_star`] | any `N` | consistent | Lazy open list, truncated dominance; `O(log n)` checks for 3 objectives. |
//! | [`emoa_star_tree`] | any `N` | consistent | EMOA* with the paper's balanced-tree frontiers. |
//! | [`namoa_star_dr`] | any `N` | consistent | NAMOA* with dimensionality reduction. |
//! | [`namoa_star_dr_mvh_lazy`] | any `N` | admissible, multi-valued | L-NAMOA*dr-mvh: NAMOA*dr with a [`MvHeuristic`] and lazy dimensionality reduction. |
//! | [`namoa_star_dr_mvh`] | any `N` | consistent, multi-valued | NAMOA*dr-mvh: one label per estimate; a baseline, slower than the lazy variant. |
//! | [`namoa_star`] | any `N` | admissible | Classic baseline; label-setting with [`ZeroHeuristic`]. |
//! | [`minsum_maxmin`] | sum + bottleneck | consistent on the sum | Minimal cost, maximal bottleneck capacity (Martins 1984). |
//! | [`minsum_maxmin_multi`] | `N` sums + `M` bottlenecks | consistent on the sums | Several maxmin objectives. |
//! | [`min_cost_capacity_ratio`], [`quickest_path`] | sum + bottleneck | consistent on the sum | Ratio and quickest-path objectives read off the minsum–maxmin front. |
//! | [`constrained_shortest_path`] | 2 | consistent | Cheapest path with the second cost within a budget. |
//! | [`two_phase`](fn@two_phase) | 2 | consistent | Two-phase method: supported solutions by weighted sums ([`supported_solutions`]), then the rest. |
//! | [`ReferencePoint`] | any `N` | admissible | Interactive: non-dominated solutions by Chebyshev distance to a movable reference point. |
//! | [`fptas_constrained`] | 2 | none | FPTAS for the constrained shortest path: polynomially many labels, first cost within `1 + ε`. |
//! | [`min_ratio_path`], [`min_cost_reliability_ratio`] | ratio | none | Linear fractional (Dinkelbach, exact signed arithmetic) and cost/reliability ratios. |
//! | [`ranking`](fn@ranking) | 2 | consistent | The classic ranking method: loopless paths by first cost. |
//! | [`disjoint_pair`] | scalar | none | Suurballe: the cheapest edge- or state-disjoint pair; [`supported_disjoint_pairs`] for two objectives, [`disjoint_pair_front`] for the full bi-objective front, [`maximally_disjoint_pairs`] for cost against shared edges, [`dissimilar_paths`] for k dissimilar paths. Needs an [`EdgeGraph`]. |
//! | [`aggregated_search`] | `M` hidden, `K` solution | admissible in the hidden space | Objective-aggregation functions over hidden objectives, exact or ε-approximate. |
//! | [`label_correcting`](fn@label_correcting) | any `N` | none | Multi-objective label correcting (Guerriero and Musmanno). |
//! | [`DynamicSearch`] | any `N` | none | Dynamic MOS: incremental repair after edge changes on a [`DynamicGraph`]. |
//! | [`pareto_spanning_trees`] | any `N` | none | Multi-objective minimum spanning trees; [`two_phase_spanning_trees`] for two objectives. |
//! | [`tpa_paths`] | any `N` | admissible | TPA: exact anytime box splitting with augmented-Tchebycheff subproblems, well spread early; [`tpa`](fn@tpa) over any solver. |
//! | [`brute_force`] | any `N` | none | Exhaustive reference for tests on small graphs. |
//!
//! Supporting types:
//!
//! - [`Front`] and [`BiFront`]: Pareto frontiers, `O(log n)` queries for two
//! objectives; [`TreeFront`]: a balanced-tree frontier for four or more.
//! - [`Graph`] and [`ReverseGraph`]: the search-space interface.
//! - [`Heuristic`], [`heuristic_fn`] and [`ZeroHeuristic`]: per-objective
//! lower bounds. The trait comes from `search-core` and takes `&mut self`;
//! algorithms take the heuristic by value, so pass `&mut h` to keep it.
//! - [`MvHeuristic`], [`mv_heuristic_fn`] and [`SingleValued`]: multi-valued
//! heuristics, a set of lower bounds per state.
//! - [`IdealPoint`] and [`DifferentialHeuristic`]: heuristic builders, the
//! ideal point from per-objective backward Dijkstras and landmark-based
//! differential heuristics.
//! - [`Cost`] (from `search-core`) and [`Dominates`]: scalar costs and
//! Pareto dominance.
//! - [`Output`]: solutions sorted lexicographically by cost, plus counters.
//! - [`RoadGraph`]: a loader for 9th DIMACS Challenge road networks
//! (`.gr` distance and time files, `.co` coordinates).
//! - [`KnapsackGraph`] and [`LabelCount`]: graphs that encode
//! multi-objective knapsacks and the minimum-label objective as additive
//! paths for every search.
//! - [`BenchmarkGraph`] with [`random_grid`], [`netmaker`], [`guards_grid`]
//! and [`road_extended`]: the standardized benchmark suite of Peer et al.,
//! generated from its definitions.
//! - [`Epsilon`]: a rational tolerance `ε = num / den` for the approximate
//! searches, tested with [`Cost::saturating_times`].
//!
//! ## Features
//!
//! - `std`: links `std`; no API of its own.
//! - `parallel` (implies `std`): multi-threaded BOBA*,
//! `boba_star_parallel` and `boba_star_with_parallel`, and SIP-MOSP
//! (`sip_mosp`), an asynchronous parallel exact search for any `N`, and
//! parallel MOA* (`parallel_moa_star`), one search per objective order.
//!
//! Without features the crate is `no_std` with `alloc`.
//!
//! Repository: <https://github.com/sunsided/multiobjective-search>
extern crate alloc;
extern crate std;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use constrained_shortest_path;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use Epsilon;
pub use fptas_constrained;
pub use ;
pub use ;
pub use ;
pub use hypervolume;
pub use label_correcting;
pub use ;
pub use ;
pub use ;
pub use ;
pub use parallel_moa_star;
pub use ;
pub use ;
pub use ranking;
pub use brute_force;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
/// Doctests for the code examples in README.md (not part of the API).