diff --git a/tests/kernel-cases/fillets/cov-chamfer-outer-corner-edge-of-a-shelled-box-with-a-lip/expected.json b/tests/kernel-cases/fillets/cov-chamfer-outer-corner-edge-of-a-shelled-box-with-a-lip/expected.json index 17ca65bdc..c41cd8687 100644 --- a/tests/kernel-cases/fillets/cov-chamfer-outer-corner-edge-of-a-shelled-box-with-a-lip/expected.json +++ b/tests/kernel-cases/fillets/cov-chamfer-outer-corner-edge-of-a-shelled-box-with-a-lip/expected.json @@ -1,7 +1,8 @@ { "sources": [], "what": "a vertical outer corner edge of an 80 x 50 x 30 box shelled 2 mm open at the top with a 1 x 2 lip raised on its rim, chamfered 3: wider than the wall but clear of the inside corner, its top end on the lip (action matrix (apps/solidcraft-cli/tests/action_matrix.rs): corpus/modern-plastic, Body1 F1:+y|F1:-x edge.chamfer)", - "source": "invariants", - "method": "the chamfer's plane x + (50 - y) = 3 stays clear of the inside corner (2, 48), where x + 50 - y = 4, so it fits along the whole edge; where it ends on the lip's walls is the lip's geometry: one closed valid solid is the right answer", - "body_count": 1 + "source": "analytic", + "method": "shelled: 80*50*30 - 76*46*28 = 22112; the lip is the band along the rim's inner edge (76 x 46 to 78 x 48), raised 2: 496 (as cov-lip-inside-on-a-shelled-box): V0 = 22608. The chamfer's plane x + (50 - y) = 3 stays clear of the inside corner (2, 48), where x + 50 - y = 4, so its triangle (legs 3, area 4.5) lies in the wall and floor all the way up: it takes 4.5 x 30 = 135. At the top the triangle reaches under the lip's corner, whose part x + 50 - y < 3 (the half square (1, 48), (1, 49), (2, 49), 0.5 x 2 = 1) goes or stays by where the chamfer ends on the lip's walls: V = 22473 or 22472, graded as 22472.5 (both within 1e-3)", + "body_count": 1, + "volume_mm3": 22472.5 } diff --git a/tests/kernel-cases/fillets/report-fillet-edge-tangent-at-one-end-into-cylinder/expected.json b/tests/kernel-cases/fillets/report-fillet-edge-tangent-at-one-end-into-cylinder/expected.json index 116bf9774..51ebf0ee4 100644 --- a/tests/kernel-cases/fillets/report-fillet-edge-tangent-at-one-end-into-cylinder/expected.json +++ b/tests/kernel-cases/fillets/report-fillet-edge-tangent-at-one-end-into-cylinder/expected.json @@ -1,6 +1,10 @@ { "what": "after the round of a bar's top edge running into a cylinder, an r2 round of the edge where that round meets the cylinder's wall (tangent at its lower end only, a crease elsewhere) with its tangent chain (the concave arc of the top): it was refused as a smooth edge; reported from the app (2026-10-30, test-peg part)", - "source": "invariants", - "method": "a bar 40 x 16 x 10 whose far end is a half disc R8 about (40, 8), a disc R8 about the same centre sketched on its top (the top's outline projected) and extruded 10 up, joined: the bar's sides run tangent into the cylinder, V0 = 6400 + 960 pi; then the front round (the r2 round of the front top edge (y = 0, z = 10) runs into the cylinder's wall: removed = integral over y in [0, 2] of (2 - sqrt(4 - (2 - y)^2)) (40 - sqrt(64 - (8 - y)^2)) dy = 32.3064821881 (Simpson)); the second round fades to nothing at the edge's tangent end, no closed form: one valid body", - "body_count": 1 + "source": "analytic", + "method": "a bar 40 x 16 x 10 whose far end is a half disc R8 about (40, 8), a disc R8 about the same centre sketched on its top (the top's outline projected) and extruded 10 up, joined: the bar's sides run tangent into the cylinder, V0 = 6400 + 960 pi; then the front round (the r2 round of the front top edge (y = 0, z = 10) runs into the cylinder's wall: removed = integral over y in [0, 2] of (2 - sqrt(4 - (2 - y)^2)) (40 - sqrt(64 - (8 - y)^2)) dy = 32.3064821881 (Simpson)): V1 = 9383.622465. The second round is on concave edges (the round and the top meet the cylinder's wall from outside it), so it adds material, and its chain stops where the back top edge, convex, runs on tangent at (40, 16, 10). Lower end: about the cylinder's axis at angles a (from +x) in 126.87..216.87 deg the top runs on flat for 2 or more past the wall (8 + 10 sin a stays in 2..16), so there the round is the rolling ball's torus and adds its whole section, the corner r 8..10, z 10..12 less the quarter disc about (10, 12): Pappus, Int r dA = 8 (4 - pi) + (4 - 2 pi + 8/3) = 7.250740 a radian, over pi/2: 11.389. Upper end: what it adds lies outside V1, within 2 of the chain (on r = 8, angles 90..270 deg, z 8..10): r 8..10, angles within asin(1/4) = 14.48 deg of the chain's, z 6..12; that is z 10..12 over 75.52..284.48 deg (36 a radian: 131.29), and below z = 10 only in front of the bar or over the front round (214.11..284.48 deg, z 6..10, 72 a radian: 88.42) or behind its back face (75.52..104.48 deg, z 8..10: 18.19): 237.9. V in V1 + [11.389, 237.9]; one valid body", + "body_count": 1, + "volume_mm3": [ + 9395.0, + 9622.0 + ] } diff --git a/tests/kernel-cases/sheet-metal/1797-tray-with-torn-corners-at-72-degrees-folded/expected.json b/tests/kernel-cases/sheet-metal/1797-tray-with-torn-corners-at-72-degrees-folded/expected.json index 88118ca75..3abd59d8f 100644 --- a/tests/kernel-cases/sheet-metal/1797-tray-with-torn-corners-at-72-degrees-folded/expected.json +++ b/tests/kernel-cases/sheet-metal/1797-tray-with-torn-corners-at-72-degrees-folded/expected.json @@ -4,7 +4,20 @@ "tangency-labs/solidcraft#1799" ], "what": "a tray whose flanges lean at 72 degrees with the tear corner relief: the torn ends are helices over slanted bends", - "source": "invariants", - "method": "one valid closed body (the helical torn ends must sew into a closed shell)", - "body_count": 1 + "source": "analytic", + "method": "T = 2, R = 1, K = 0.5, gap 0.5. A 72 deg flange leans out 18 deg, its outer face from the virtual sharp on the base's edge line (z = 0): it stands back s = (R+T) tan 36 = 2.179628, its bend has the allowance BA = 0.4 pi (R + T/2) = 2.513274 and its panel the leg 38.6 - s = 36.420372. With K = 0.5 every bend is bent about mid-thickness, so the folded volume is the flat area times T. The base is (120 - 2s) x (90 - 2s); the bends run along its edges to its corners, BA wide. Each corner is closed on the vertical plane halving it (x = y at the origin's): a panel's end is square to the sheet and keeps half the gap from that plane on its nearer, inner face, so at sigma along the panel it lies u(sigma) = g/sqrt2 + T sin72 - (s + sigma) cos72 from the sketch's corner along the edge (1.582124 at the bend, -9.672390 at the top): each panel is a trapezoid of mean length L - 2 u(leg/2) = L + 8.090265. The tear cuts nothing out of the base either and keeps the bends running to the corner where their start lines meet, cutting each bend's end straight in the flat from there to where its panel's closed end starts, s - u(0) = 0.597503 past the trimmed base's corner: each of the 8 bend ends gains a triangle BA x 0.597503 / 2 (folded, a helical end of the same volume at K = 0.5). Flat area 27390.468926 + 6.006757, V = 54792.951364 (the tear adds 12 mm3 to the notch's 405-tray-with-72-degree-flanges-folded, under the volume's tolerance: what tells them apart is validity). Bbox: the walls' outer top edges stand 38.6 cos72 = 11.928056 outside the base's edge lines, their inner top edges 38.6 sin72 + 2 cos72 = 37.328816 above the underside.", + "body_count": 1, + "volume_mm3": 54792.95136427714, + "bbox": { + "min": [ + -11.928055982872973, + -11.928055982872973, + 0 + ], + "max": [ + 131.92805598287296, + 101.92805598287298, + 37.32881551774282 + ] + } } \ No newline at end of file diff --git a/tests/kernel-cases/sheet-metal/3417-rhombus-with-a-flange-on-each-edge-and-square-reliefs/expected.json b/tests/kernel-cases/sheet-metal/3417-rhombus-with-a-flange-on-each-edge-and-square-reliefs/expected.json index 297dbd5a5..4be282916 100644 --- a/tests/kernel-cases/sheet-metal/3417-rhombus-with-a-flange-on-each-edge-and-square-reliefs/expected.json +++ b/tests/kernel-cases/sheet-metal/3417-rhombus-with-a-flange-on-each-edge-and-square-reliefs/expected.json @@ -5,7 +5,20 @@ "tangency-labs/solidcraft#3280" ], "what": "a 60 mm rhombus (120 and 60 degree corners) with a 90 degree flange on each of its four edges and a square corner relief 8 mm across: the reliefs at the two 120 degree corners would overlap", - "source": "invariants", - "method": "one valid closed body whichever relief is left out; a square relief 8 mm across at a 120 degree corner reaches 2r from the corner along the bisector, so the reliefs at the two opposite 120 degree corners reach each other and are left out together, which makes the result independent of the order the flanges were made in; no volume is graded because the corner closure has no simple closed form", - "body_count": 1 + "source": "analytic", + "method": "T = 2, R = 1, K = 0.5, gap 0.5, square relief 8 across (r = 4). The 90 deg flanges stand back R + T = 3: the base is the rhombus inset 3, side 53.071797, height 45.961524, area 2439.260673. A square relief cuts r along both edges from the trimmed base's corner, square to them: a kite of area r^2 tan(alpha/2), 9.237604 at 60 and 27.712813 at 120 deg, reaching r/cos(alpha/2) = 4.618802 and 8 along the bisector. Here every corner keeps its relief: the two 120 deg corners are the trimmed short diagonal, 53.071797, apart, so their kites are far from meeting (they would meet with the corners under 16 mm apart), every edge is longer than 2r and every other edge further than 8 from a corner. The bends stop at the reliefs: 4 x (53.071797 - 8) long, BA = (pi/2)(R + T/2) = pi wide. Each panel (leg 20 - 3 = 17, its outer face on the rhombus' edge, its inner face 2 in) is closed with its end square to it, half the gap from the corner's bisector on its inner face: (g/2 + T cos(alpha/2)) / sin(alpha/2) from the rhombus' corner along the edge, 3.964102 at 60 and 1.443376 at 120 deg, so each panel is 54.592523 long. Flat area 6644.040285; K = 0.5, so V = T x flat = 13288.080571. Bbox: the walls stand 20 high on the rhombus' edges (y 0 and 51.961524), and the panel ends at the 60 deg corners keep them 3.964102 x cos 60 = 1.982051 from x = 0 and x = 90 (the bends, stopped 4 past the trimmed corners, reach no nearer)", + "body_count": 1, + "volume_mm3": 13288.08057084238, + "bbox": { + "min": [ + 1.9820508075688776, + 0, + 0 + ], + "max": [ + 88.01794919243112, + 51.96152422706631, + 20 + ] + } } \ No newline at end of file diff --git a/tests/kernel-cases/sheet-metal/405-tray-with-72-degree-flanges-folded/expected.json b/tests/kernel-cases/sheet-metal/405-tray-with-72-degree-flanges-folded/expected.json index 48b917e25..0c4239c6b 100644 --- a/tests/kernel-cases/sheet-metal/405-tray-with-72-degree-flanges-folded/expected.json +++ b/tests/kernel-cases/sheet-metal/405-tray-with-72-degree-flanges-folded/expected.json @@ -4,7 +4,20 @@ "tangency-labs/solidcraft#406" ], "what": "a 120 x 90 tray with four 38.6 mm flanges at 72 degrees closed with the rule's gap: the corners used to stay open as a V", - "source": "invariants", - "method": "one valid closed body: the four flanges end a gap apart at every corner, so they are joined to the base only and the part is one shell", - "body_count": 1 + "source": "analytic", + "method": "T = 2, R = 1, K = 0.5, gap 0.5. A 72 deg flange leans out 18 deg, its outer face from the virtual sharp on the base's edge line (z = 0): it stands back s = (R+T) tan 36 = 2.179628, its bend has the allowance BA = 0.4 pi (R + T/2) = 2.513274 and its panel the leg 38.6 - s = 36.420372. With K = 0.5 every bend is bent about mid-thickness, so the folded volume is the flat area times T. The base is (120 - 2s) x (90 - 2s); the bends run along its edges to its corners, BA wide. Each corner is closed on the vertical plane halving it (x = y at the origin's): a panel's end is square to the sheet and keeps half the gap from that plane on its nearer, inner face, so at sigma along the panel it lies u(sigma) = g/sqrt2 + T sin72 - (s + sigma) cos72 from the sketch's corner along the edge (1.582124 at the bend, -9.672390 at the top): each panel is a trapezoid of mean length L - 2 u(leg/2) = L + 8.090265. The notch cuts nothing. Flat area 27390.468926, V = 54780.937851. Bbox: the walls' outer top edges stand 38.6 cos72 = 11.928056 outside the base's edge lines, their inner top edges 38.6 sin72 + 2 cos72 = 37.328816 above the underside.", + "body_count": 1, + "volume_mm3": 54780.93785112385, + "bbox": { + "min": [ + -11.928055982872973, + -11.928055982872973, + 0 + ], + "max": [ + 131.92805598287296, + 101.92805598287298, + 37.32881551774282 + ] + } } \ No newline at end of file