/claim #78
Fixes #78
Extra trace lines appear in schematic diagrams after the post-processing step. When UntangleTraceSubsolver._applyBestRoute() replaces an L-shaped corner with a rerouted path, the direct concatenation of path segments can leave:
These manifest as short spurious line segments in the rendered output.
simplifyPath() after rerouting in _applyBestRoute() — cleans up the concatenated path immediately after assemblysimplifyPath() to handle duplicate points — added a preprocessing step that removes duplicate consecutive points (within epsilon tolerance) before the existing collinear reduction passeslib/solvers/TraceCleanupSolver/sub-solver/UntangleTraceSubsolver.ts — apply simplifyPath() to the new trace pathlib/solvers/TraceCleanupSolver/simplifyPath.ts — add duplicate point removaltests/functions/simplifyPath.test.ts — new test suite for simplifyPathtests/examples/__snapshots__/example29.snap.svg — updated snapshotAll 56 tests pass.
Janis A.
@janisag07
tscircuit
@tscircuit