Skip to content

Commit 2e8dd5e

Browse files
committed
2 parents 8a35050 + d870c74 commit 2e8dd5e

25 files changed

Lines changed: 3141 additions & 54 deletions

docs/paper/reductions.typ

Lines changed: 319 additions & 0 deletions
Large diffs are not rendered by default.

docs/paper/references.bib

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -449,6 +449,17 @@ @article{heldkarp1962
449449
doi = {10.1137/0110015}
450450
}
451451

452+
@article{gilmore1964,
453+
author = {P. C. Gilmore and R. E. Gomory},
454+
title = {Sequencing a One State-Variable Machine: A Solvable Case of the Traveling Salesman Problem},
455+
journal = {Operations Research},
456+
volume = {12},
457+
number = {5},
458+
pages = {655--679},
459+
year = {1964},
460+
doi = {10.1287/opre.12.5.655}
461+
}
462+
452463
@article{beigel2005,
453464
author = {Richard Beigel and David Eppstein},
454465
title = {3-Coloring in Time {$O(1.3289^n)$}},
@@ -1068,6 +1079,27 @@ @article{frederickson1979
10681079
doi = {10.1145/322139.322150}
10691080
}
10701081

1082+
@article{frederickson1978routing,
1083+
author = {Greg N. Frederickson and Matthew S. Hecht and Chul E. Kim},
1084+
title = {Approximation Algorithms for Some Routing Problems},
1085+
journal = {SIAM Journal on Computing},
1086+
volume = {7},
1087+
number = {2},
1088+
pages = {178--193},
1089+
year = {1978},
1090+
doi = {10.1137/0207017}
1091+
}
1092+
1093+
@article{fredericksonguan1993,
1094+
author = {Greg N. Frederickson and Da-Wei Guan},
1095+
title = {Nonpreemptive Ensemble Motion Planning on a Tree},
1096+
journal = {Journal of Algorithms},
1097+
volume = {15},
1098+
number = {1},
1099+
pages = {29--60},
1100+
year = {1993}
1101+
}
1102+
10711103
@article{gottlob2002,
10721104
author = {Georg Gottlob and Nicola Leone and Francesco Scarcello},
10731105
title = {Hypertree Decompositions and Tractable Queries},
@@ -1282,3 +1314,22 @@ @inproceedings{williams2002
12821314
pages = {299--307},
12831315
year = {2002}
12841316
}
1317+
1318+
@article{papadimitriou1976edge,
1319+
author = {Christos H. Papadimitriou},
1320+
title = {On the Complexity of Edge Traversing},
1321+
journal = {Journal of the ACM},
1322+
volume = {23},
1323+
number = {3},
1324+
pages = {544--554},
1325+
year = {1976}
1326+
}
1327+
1328+
@article{edmondsjohnson1973,
1329+
author = {Jack Edmonds and Ellis L. Johnson},
1330+
title = {Matching, Euler Tours and the Chinese Postman},
1331+
journal = {Mathematical Programming},
1332+
volume = {5},
1333+
pages = {88--124},
1334+
year = {1973}
1335+
}

problemreductions-cli/src/cli.rs

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ TIP: Run `pred create <PROBLEM>` (no other flags) to see problem-specific help.
216216
217217
Flags by problem type:
218218
MIS, MVC, MaxClique, MinDomSet --graph, --weights
219-
MaxCut, MaxMatching, TSP --graph, --edge-weights
219+
MaxCut, MaxMatching, TSP, BottleneckTravelingSalesman --graph, --edge-weights
220220
ShortestWeightConstrainedPath --graph, --edge-lengths, --edge-weights, --source-vertex, --target-vertex, --length-bound, --weight-bound
221221
MaximalIS --graph, --weights
222222
SAT, NAESAT --num-vars, --clauses
@@ -231,6 +231,7 @@ Flags by problem type:
231231
GeneralizedHex --graph, --source, --sink
232232
MinimumCutIntoBoundedSets --graph, --edge-weights, --source, --sink, --size-bound, --cut-bound
233233
HamiltonianCircuit, HC --graph
234+
LongestCircuit --graph, --edge-weights, --bound
234235
BoundedComponentSpanningForest --graph, --weights, --k, --bound
235236
UndirectedTwoCommodityIntegralFlow --graph, --capacities, --source-1, --sink-1, --source-2, --sink-2, --requirement-1, --requirement-2
236237
IsomorphicSpanningTree --graph, --tree
@@ -265,7 +266,9 @@ Flags by problem type:
265266
SequencingWithinIntervals --release-times, --deadlines, --lengths
266267
OptimalLinearArrangement --graph, --bound
267268
MinMaxMulticenter (pCenter) --graph, --weights, --edge-weights, --k, --bound
269+
MixedChinesePostman (MCPP) --graph, --arcs, --edge-weights, --arc-costs, --bound [--num-vertices]
268270
RuralPostman (RPP) --graph, --edge-weights, --required-edges, --bound
271+
StackerCrane --arcs, --graph, --arc-costs, --edge-lengths, --bound [--num-vertices]
269272
MultipleChoiceBranching --arcs [--weights] --partition --bound [--num-vertices]
270273
AdditionalKey --num-attributes, --dependencies, --relation-attrs [--known-keys]
271274
ConsistencyOfDatabaseFrequencyTables --num-objects, --attribute-domains, --frequency-tables [--known-values]
@@ -498,7 +501,7 @@ pub struct CreateArgs {
498501
/// Required edge indices for RuralPostman (comma-separated, e.g., "0,2,4")
499502
#[arg(long)]
500503
pub required_edges: Option<String>,
501-
/// Upper bound or length bound (for BoundedComponentSpanningForest, LengthBoundedDisjointPaths, LongestCommonSubsequence, MultipleCopyFileAllocation, MultipleChoiceBranching, OptimalLinearArrangement, RuralPostman, ShortestCommonSupersequence, or StringToStringCorrection)
504+
/// Bound parameter (lower bound for LongestCircuit; upper or length bound for BoundedComponentSpanningForest, LengthBoundedDisjointPaths, LongestCommonSubsequence, MultipleCopyFileAllocation, MultipleChoiceBranching, OptimalLinearArrangement, RuralPostman, ShortestCommonSupersequence, or StringToStringCorrection)
502505
#[arg(long, allow_hyphen_values = true)]
503506
pub bound: Option<i64>,
504507
/// Upper bound on total path length
@@ -849,4 +852,22 @@ mod tests {
849852
assert!(help.contains("--potential-edges"));
850853
assert!(help.contains("--budget"));
851854
}
855+
856+
#[test]
857+
fn test_create_help_mentions_stacker_crane_flags() {
858+
let cmd = Cli::command();
859+
let create = cmd.find_subcommand("create").expect("create subcommand");
860+
let help = create
861+
.get_after_help()
862+
.expect("create after_help")
863+
.to_string();
864+
865+
assert!(help.contains("StackerCrane"));
866+
assert!(help.contains("--arcs"));
867+
assert!(help.contains("--graph"));
868+
assert!(help.contains("--arc-costs"));
869+
assert!(help.contains("--edge-lengths"));
870+
assert!(help.contains("--bound"));
871+
assert!(help.contains("--num-vertices"));
872+
}
852873
}

0 commit comments

Comments
 (0)