mirror of
https://github.com/ajisaacs/OpenNest.git
synced 2026-12-03 19:09:25 -05:00
feat(engine): break equal-cost ties toward the larger free offcut
Without salvage credit (desktop Auto Nest on a single plate size) every complete one-sheet layout costs the same, so engines kept whichever layout came first. N26-23S nested 27.86" long when turning two parts fits it in 21.3". NestJobCost.CompactnessOffcut measures the largest full-width/full-length edge offcut as salvage does, whatever the salvage rate. Default and Circles (CandidateScore), Rectangles and Circles sheet choice (SheetByStock) and Irregular sheet and plan ranking use it only after cost, so no cost changes. Sheet-level keys round to 1e-6 to keep ties platform-independent. Rectangles layout digests are re-captured: each changed fixture keeps its sheets, parts and cost and leaves a larger offcut. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
ad3443f60d
commit
33f60d3dcb
10 files changed
+201
-33
No files matched your search
@@ -235,8 +235,10 @@ With prices, gross sheet cost is the supplied value. Salvage is still computed f
|
||||
the largest qualifying material-edge offcut; net cost is
|
||||
`Cost * (NetSheetArea / SheetArea)`. Set desktop salvage rate to zero for purchase-price
|
||||
comparisons. Entering prices preserves the selected salvage settings. MCP and API
|
||||
currently disable salvage. Without prices, scores retain their existing area units
|
||||
and tie ordering; fixed strategies retain their legacy no-salvage area tie-break.
|
||||
currently disable salvage. Without prices, scores retain their existing area units;
|
||||
whole-job engines break exact cost ties by the compactness offcut (see
|
||||
[cost basis](nesting-engines.md#cost-basis-and-heuristic-limits)), and fixed strategies retain
|
||||
their legacy no-salvage area tie-break.
|
||||
|
||||
Desktop reports gross cost, estimated salvage credit and net score. MCP reports
|
||||
`basis`, each stock's used physical count, supplied cost and gross subtotal, plus
|
||||
|
||||
Reference in new issue
Block a user