The L-shaped plate of offset/l-block-grown, whose outline in the xy plane is the polygon through (0, 0), (20, 0), (20, 5), (5, 5), (5, 15) and (0, 15), extruded 8 along +z, with its inside corner's edge, the concave edge along (5, 5), rounded to radius 4 (a quarter cylinder about the line x = 9, y = 9, touching the faces y = 5 and x = 5). Grow it by 5, more than the round's radius: the solid of every point within 5 of the plate.
Its section at a height from z = 0 to z = 8 is the outline (with its rounded corner) grown by 5: each side moved out 5, the five convex corners rounded to radius 5, and the inside corner sharp, the round, of radius 4, having closed up. Above the top (and below the bottom), at a height u, the section is the outline grown by s = √(25 − u²): while s is at least 4 it is the sharp-cornered L grown by s, and once s is less than 4 its inside corner is the round's arc grown by s, of radius 4 − s about the line x = 9, y = 9, which leaves more than the sharp corner would. Where s is under 4 the grown plate's surface over the inside corner is the outer side of a tube of radius 5 about the round's top (and bottom) arc.
The section at height u is $A + Ps + ks^2 + (1 - \pi/4)\,\max(0,\ 4 - s)^2$, where A and P are the sharp-cornered outline's area and perimeter.
† works around a missing feature. Pick an entry to see its solid, its measures and its code.
Drag to turn, scroll or pinch to zoom, right-drag to move. The solid as its STEP file has it, meshed in the browser by Open CASCADE (occt-import-js): each face colored by the kind of its surface, and the edges that bound each face drawn between them.
Drag to turn, scroll or pinch to zoom, right-drag to move. Black lines are where the surface turns sharply; red ones, seen through the solid, are open edges, where the mesh is not closed.
Time
1.07 s; CPU time 1.15 s; peak memory 19.6 MB
Notes
pass Its volume and area are the expected ones, and its mesh is closed.
Its volume and area are its STEP file's, as the harness measures them from the file's exact geometry (harness/mass/); its triangles are Open CASCADE's mesh of the file, for the pictures.
Data
its STEP's
expected
rel. error
volume
9324.099511
9324.099511
3.9e-16
area
2485.947168
2485.947168
1.8e-16
agrees with
next.BREP, cadrs
mesh
33532 triangles, closed, 12 degenerate
centre of gravity
(8.01139, 5.49082, 4) its STEP's solid
inertia
about it, of unit density: Ixx 588257; Iyy 816376; Izz 971643; Ixy 156631; Iyz -3.98561e-11; Izx -5.14802e-12
//! The L-shaped plate through (0, 0), (20, 0), (20, 5), (5, 5), (5, 15), (0, 15), 8 thick, its//! inside corner's edge along (5, 5) rounded to radius 4, grown by 5, more than the round's radius.usecrate::sketch::{l_block, rolled};
use cad_kernel::offset::{grown, Join};
use cad_kernel::topo::Brep;
pubfnbuild() -> Result<Brep, String> {
// the concave upright edge, picked by its middle, filled with the quarter cylinder about the// line x = 9, y = 9let rounded = rolled(&l_block()?, &[[5., 5., 4.]], 4.)?;
grown(&rounded, 5., Join::Round)
}
occt left no solid to show.
Time
652 ms; CPU time 651 ms; peak memory 366.4 MB
Notes
refused BRepOffsetAPI_MakeOffsetShape answered done but made no shape of the solid offset by 5
"""An L-shaped plate with its inside corner rounded, grown past the round's radius. The L-shaped
plate whose outline in the xy plane is the polygon through (0, 0), (20, 0), (20, 5), (5, 5),
(5, 15) and (0, 15), extruded 8 along +z, its concave edge along (5, 5) rounded to radius 4, then
grown by 5: the round closes up inside the grown plate's section."""fromOCP.BRepBuilderAPIimportBRepBuilderAPI_MakeFace, BRepBuilderAPI_MakePolygonfromOCP.BRepPrimAPIimportBRepPrimAPI_MakePrismfromOCP.gp import gp_Pnt, gp_Vec
from blend import edges_where, rounded
from offset import offset
OUTLINE = [(0, 0), (20, 0), (20, 5), (5, 5), (5, 15), (0, 15)]
THICKNESS = 8INSIDE_CORNER = (5, 5)
ROUND = 4GROWTH = 5defbuild():
polygon = BRepBuilderAPI_MakePolygon()
for x, y inOUTLINE:
polygon.Add(gp_Pnt(x, y, 0))
polygon.Close()
outline = BRepBuilderAPI_MakeFace(polygon.Wire()).Face()
plate = BRepPrimAPI_MakePrism(outline, gp_Vec(0, 0, THICKNESS)).Shape()
x, y = INSIDE_CORNER
corner = edges_where(plate, lambda p: abs(p.X() - x) < 1e-9andabs(p.Y() - y) < 1e-9)
# BRepOffsetAPI_MakeOffsetShape reports itself done but makes no shape (a null one), as for# offset/drilled-plate-grown-past-its-hole, where a face it moves vanishes; `offset` refuses it.returnoffset(rounded(plate, ROUND, corner, "the inside corner"), GROWTH)
arris left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
kentron left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
vcad left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
solidcraft left no solid to show.
Time
115 ms; CPU time 114 ms; peak memory 42.9 MB
Notes
refused the operation failed: SMLib offset: operation: solidcore: offset::offset_executive::p2::offset_brep: the offset could not be built; caused by offset::offset_executive::p1: the rounded offset's tube about edge 4 by 5 folds over itself: the edge bends more tightly than that on the side the tube faces (the largest distance at which this edge's tube is proved not to fold is 3.9664642386050266)
//! The L-shaped plate of `offset/l-block-grown` (the polygon through (0, 0), (20, 0), (20, 5),//! (5, 5), (5, 15) and (0, 15), extruded 8 along +z) with its concave edge, along (5, 5), rounded//! to radius 4, grown by 5, more than the round's radius: every point within 5 of it, SolidCraft's//! offset of the whole solid (`offset_solid`), its convex edges rounded.usesuper::l_block_grown::l_block;
usecrate::solids::*;
pubfnbuild() -> R<Body> {
// the inside edge, picked at its middlelet plate = solidcraft_kernel::fillet(&l_block()?, &[v3(5.0, 5.0, 4.0)], 4.0)?;
solidcraft_kernel::offset_solid(&plate, 5.0, true)
}
brepkit left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
popkern left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
aetheris left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
Time
1.82 s; CPU time 1.82 s; peak memory 46.8 MB
Notes
pass Its volume and area are the expected ones, and its mesh is closed.
Its volume and area are its STEP file's, as the harness measures them from the file's exact geometry (harness/mass/); its triangles are Open CASCADE's mesh of the file, for the pictures.
Data
its STEP's
expected
rel. error
volume
9324.099511
9324.099511
2.0e-16
area
2485.947168
2485.947168
3.7e-16
agrees with
cad-kernel, cadrs
mesh
25126 triangles, closed, 12 degenerate
centre of gravity
(8.01139, 5.49082, 4) its STEP's solid
inertia
about it, of unit density: Ixx 588257; Iyy 816376; Izz 971643; Ixy 156631; Iyz -5.61497e-11; Izx -3.82661e-11
//! The L through (0, 0), (20, 0), (20, 5), (5, 5), (5, 15), (0, 15), extruded 8 along +z, its//! inside corner's concave edge, along (5, 5), rounded to radius 4 by the kernel's fillet, then//! grown by 5, more than the round's radius, to its parallel body.usecrate::solids::offset::parallel;
usecrate::solids::{p, polygon};
usecrate::Refusal;
use brep_kernel::{extrude_profile_brep, fillet_edges, BrepSolid};
pubfnbuild() -> Result<BrepSolid, Refusal> {
let l = polygon(&[
p(0.0, 0.0, 0.0), p(20.0, 0.0, 0.0), p(20.0, 5.0, 0.0),
p(5.0, 5.0, 0.0), p(5.0, 15.0, 0.0), p(0.0, 15.0, 0.0),
])?;
let block = extrude_profile_brep(&l, p(0.0, 0.0, 1.0), 8.0)?;
let rounded = fillet_edges(&block, &[p(5.0, 5.0, 4.0)], None, 4.0, false, None)?;
Ok(parallel(&rounded, 5.0)?)
}
geop left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
Time
68 ms; CPU time 109 ms; peak memory 14 MB
Notes
pass Its volume and area are the expected ones, and its mesh is closed.
Its volume and area are its STEP file's, as the harness measures them from the file's exact geometry (harness/mass/); its triangles are Open CASCADE's mesh of the file, for the pictures.
Data
its STEP's
expected
rel. error
volume
9324.099511
9324.099511
2.7e-13
area
2485.947167
2485.947168
5.7e-13
agrees with
cad-kernel, next.BREP
mesh
20168 triangles, closed, 12 degenerate
centre of gravity
(8.01139, 5.49082, 4) its STEP's solid
inertia
about it, of unit density: Ixx 588257; Iyy 816376; Izz 971643; Ixy 156631; Iyz -1.14167e-11; Izx -4.94266e-12
//! The L-shaped plate of `offset/l-block-grown` (the polygon through (0, 0), (20, 0), (20, 5),//! (5, 5), (5, 15) and (0, 15), extruded 8 along +z) with its inside corner's concave edge, along//! (5, 5), rounded to radius 4, grown by 5, more than the round's radius: the solid of every//! point within 5 of it.//!//! The outline extruded, the inside edge picked by a point on it and rounded by cadrs's Fillet,//! then cadrs's offset with rounded edges.usecrate::bench::{extrude, p3};
usecrate::shared::fillet::fillet;
usecrate::shared::offset::grown;
usecrate::Refusal;
use cadrs_kernel::{BodyId, DefaultKernel, Loop, Pick, Plane, Profile};
pubfnbuild(k: &mutDefaultKernel) -> Result<BodyId, Refusal> {
let outline =
Loop::polygon(&[[0.0, 0.0], [20.0, 0.0], [20.0, 5.0], [5.0, 5.0], [5.0, 15.0], [0.0, 15.0]]);
let plate = extrude(k, &Profile::of(Plane::xy(0.0), vec![outline]), 8.0)?;
let inside = k.edge_at(plate, p3(5.0, 5.0, 4.0))?;
let rounded = fillet(k, plate, &[inside], 4.0)?;
grown(k, rounded, 5.0)
}
smlib left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
Time
34 ms; CPU time 34 ms; peak memory 9.9 MB
Notes
wrong volume 9322.12353812 against 9324.09951094 (its STEP's); area 2486.41577581 against 2485.9471675 (its STEP's)
Its volume and area are its STEP file's, as the harness measures them from the file's exact geometry (harness/mass/); its triangles are Open CASCADE's mesh of the file, for the pictures.
Data
its STEP's
expected
rel. error
volume
9322.123538
9324.099511
2.1e-04
area
2486.415776
2485.947168
1.9e-04
agrees with
no other kernel
mesh
12480 triangles, closed
centre of gravity
(8.01157, 5.49046, 4) its STEP's solid
inertia
about it, of unit density: Ixx 588102; Iyy 816226; Izz 971634; Ixy 156629; Iyz -6.15969e-12; Izx 1.38948e-11
//! The L-shaped plate of `offset/l-block-grown` with its inside corner's edge rounded to radius 4,//! grown by 5, past the round's radius: springrep's own fillet, then its own offset.use springrep::blend::fillet;
use springrep::math::Vec2;
use springrep::profile::Profile;
use springrep::sweep::extrude;
use springrep::topo::Brep;
usecrate::shared::offset::grown;
usecrate::shared::{at, e};
pubfnbuild() -> Result<Brep, String> {
let outline = [(0., 0.), (20., 0.), (20., 5.), (5., 5.), (5., 15.), (0., 15.)]
.map(|(x, y)| Vec2::new(x, y));
// the inside corner is where the ledge (y = 5) meets the riser (x = 5)let section = Profile::polygon(&outline, &["front", "end", "ledge", "riser", "top", "back"]);
let plate = extrude(§ion, &at([0., 0., 0.]), 8., "plate").map_err(e)?;
let rounded = fillet(&plate, &[("plate.ledge", "plate.riser")], 4., "round").map_err(e)?;
grown(&rounded, 5.)
}
geomsolver left no solid to show.
Time
It has not run.
Notes
missing no implementation
Data
No measures: it built no solid to measure.
Implementation
No implementation yet.
anvilcad left no solid to show.
Time
1.1 ms; CPU time 970 µs; peak memory 3.5 MB
Notes
refused anvil-brep's offset moves each face along its normal and extends the moved faces until they meet, keeping the solid's edges; it adds no round about a convex edge or corner, so it cannot grow a solid to every point within a distance of it
//! An L-shaped plate with its inside corner rounded, grown past the round's radius.use anvil_brep::Solid;
pubfnbuild() -> Result<Solid, String> {
Err("anvil-brep's offset moves each face along its normal and extends the moved faces until they meet, keeping the solid's edges; it adds no round about a convex edge or corner, so it cannot grow a solid to every point within a distance of it".into())
}