Commit 31ed79e
* Add plan for #244: [Model] IsomorphicSpanningTree
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add IsomorphicSpanningTree satisfaction problem model (#244)
Implements the Isomorphic Spanning Tree decision problem: given a graph G
and a tree T with |V(G)| = |V(T)|, determine if G contains a spanning
tree isomorphic to T. NP-complete (Garey & Johnson ND8).
- Model with SatisfactionProblem (Metric = bool), permutation-based config
- Constructor validates tree connectivity and edge count
- CLI support with --graph and --tree flags
- 11 unit tests covering evaluation, solver, serialization, edge cases
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* chore: remove plan file after implementation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Fix #412: Add ShortestCommonSupersequence model (#627)
* Add plan for #412: ShortestCommonSupersequence model
* Implement #412: Add ShortestCommonSupersequence model
* style: apply rustfmt formatting
* Address review: fix docs, add --alphabet-size flag, add edge case tests
* chore: remove plan file after implementation
* Address Copilot review comments
- Align docs/schema wording: bound is exact config length, equivalent to |w| ≤ B via padding
- Add alphabet_size > 0 validation in constructor
- Handle empty string segments in --strings CLI parsing
- Add --alphabet-size to CLI help text
- Regenerate problem_schemas.json
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Fix agentic test issues: add SCS to prelude, fix CLI duplicate fields
- Add ShortestCommonSupersequence to prelude re-exports (was missing unlike
all other misc models)
- Fix duplicate CLI struct fields (strings, bound) by sharing between LCS/SCS
and RuralPostman/SCS with i64 type and casts at usage sites
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* chore: trigger CI
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* style: apply rustfmt formatting
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: GiggleLiu <cacate0129@gmail.com>
* Fix #507: Add FlowShopScheduling model (#629)
* Add plan for #507: FlowShopScheduling model
* Implement #507: Add FlowShopScheduling model
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* chore: remove plan file after implementation
* fix: address Copilot review comments on FlowShopScheduling
- Switch dims() from vec![n;n] to Lehmer code encoding [n,n-1,...,1]
- Update evaluate() to decode Lehmer code into permutations
- Fix complexity from "3^num_jobs" to "num_jobs^num_jobs"
- Add validation to compute_makespan() for out-of-bounds indices
- Add --num-processors CLI flag instead of overloading --m
- Validate task_lengths row lengths in CLI with bail! instead of panic
- Fix test comment about deadline value
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* docs: add Lehmer code encoding explanation to FlowShopScheduling
Add concrete example of how Lehmer code configs map to job orderings
in the struct doc comment, improving discoverability for new users.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: remove unused enumerate in Lehmer code decoding
Fixes clippy::unused_enumerate_index warning.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: add missing paper section, trait_consistency entry, and correct complexity
- Add FlowShopScheduling problem-def and display-name to docs/paper/reductions.typ
- Add FlowShopScheduling to trait_consistency test
- Fix complexity from "num_jobs^num_jobs" to "factorial(num_jobs)" (n! is the exact search space)
- Relax check_problem_trait assertion from >= 2 to >= 1 (Lehmer code encoding produces trailing dim of 1)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* docs: add Gantt chart visualization and use issue's 5-job example in paper
Replace the simple 2-machine example with the issue's canonical 3-machine,
5-job example. Add a CeTZ Gantt chart showing the feasible schedule with
job order (j4, j1, j5, j3, j2) achieving makespan 23 within deadline 25.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: GiggleLiu <cacate0129@gmail.com>
* Add paper section, trait_consistency entry, and formatting fixes for IsomorphicSpanningTree
- Add display-name and problem-def entry in docs/paper/reductions.typ
with formal definition, background (Garey & Johnson ND8), and CeTZ figure
- Add bibliography entry for Papadimitriou & Yannakakis 1982
- Add check_problem_trait for IsomorphicSpanningTree in trait_consistency.rs
- Apply cargo fmt formatting fixes from merge
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: GiggleLiu <cacate0129@gmail.com>
1 parent 837bc1e commit 31ed79e
16 files changed
Lines changed: 528 additions & 21 deletions
File tree
- docs
- paper
- src/reductions
- problemreductions-cli/src
- commands
- mcp
- src
- models
- graph
- unit_tests
- models
- graph
- misc
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
34 | 35 | | |
35 | 36 | | |
36 | 37 | | |
| |||
451 | 452 | | |
452 | 453 | | |
453 | 454 | | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
454 | 504 | | |
455 | 505 | | |
456 | 506 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
532 | 532 | | |
533 | 533 | | |
534 | 534 | | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
158 | 158 | | |
159 | 159 | | |
160 | 160 | | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
161 | 177 | | |
162 | 178 | | |
163 | 179 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
210 | 210 | | |
211 | 211 | | |
212 | 212 | | |
| 213 | + | |
213 | 214 | | |
214 | 215 | | |
215 | 216 | | |
| |||
337 | 338 | | |
338 | 339 | | |
339 | 340 | | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
340 | 344 | | |
341 | 345 | | |
342 | 346 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| 53 | + | |
53 | 54 | | |
54 | 55 | | |
55 | 56 | | |
| |||
93 | 94 | | |
94 | 95 | | |
95 | 96 | | |
| 97 | + | |
96 | 98 | | |
97 | 99 | | |
98 | 100 | | |
| |||
101 | 103 | | |
102 | 104 | | |
103 | 105 | | |
104 | | - | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
105 | 109 | | |
106 | 110 | | |
107 | 111 | | |
| |||
239 | 243 | | |
240 | 244 | | |
241 | 245 | | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
242 | 254 | | |
243 | 255 | | |
244 | | - | |
| 256 | + | |
245 | 257 | | |
246 | 258 | | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
247 | 285 | | |
248 | | - | |
| 286 | + | |
249 | 287 | | |
250 | 288 | | |
251 | 289 | | |
| |||
609 | 647 | | |
610 | 648 | | |
611 | 649 | | |
612 | | - | |
| 650 | + | |
| 651 | + | |
| 652 | + | |
| 653 | + | |
| 654 | + | |
613 | 655 | | |
614 | 656 | | |
615 | 657 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
216 | 216 | | |
217 | 217 | | |
218 | 218 | | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
219 | 222 | | |
220 | 223 | | |
221 | 224 | | |
| |||
285 | 288 | | |
286 | 289 | | |
287 | 290 | | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
288 | 294 | | |
289 | 295 | | |
290 | 296 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
6 | | - | |
| 5 | + | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
528 | 528 | | |
529 | 529 | | |
530 | 530 | | |
531 | | - | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
532 | 537 | | |
533 | 538 | | |
534 | 539 | | |
| |||
672 | 677 | | |
673 | 678 | | |
674 | 679 | | |
675 | | - | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
676 | 686 | | |
677 | 687 | | |
678 | 688 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| 42 | + | |
42 | 43 | | |
43 | 44 | | |
44 | 45 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
| 44 | + | |
| 45 | + | |
45 | 46 | | |
46 | 47 | | |
47 | 48 | | |
48 | 49 | | |
49 | | - | |
50 | | - | |
| 50 | + | |
| 51 | + | |
51 | 52 | | |
52 | 53 | | |
53 | 54 | | |
| |||
0 commit comments