For a regular Polygon
in 3D I would expect some Line
regions for the boundary
poly = Polygon[{{1, 0, 0}, {1, 1, 1}, {0, 0, 1}}];
SimplePolygonQ[poly] (* True*)
boundary=RegionBoundary[poly]
but I get a Polygon-object
boundary = Polygon[{{1, 0, 0}, {1, 1, 1}, {0, 0, 1}}, {1, 2, 3}]
instead.
Expecting a one dimensional region RegionMeasure
evaluates to my surprise
RegionMeasure[boundary,1] (* \[Infinity]*)
RegionMeasure[boundary,2] (* Sqrt[3]/2 *)
My questions
Why RegionMeasure[boundary,1]
doesn't give the correct length of the boundary?
Shouldn't RegionMeasure[boundary,2]
be undefined?
Is there a simple way to get Line-objects as boundary
Thanks
Region /@ {#, RegionBoundary[#]} &@Disk[]
works as one would expect. $\endgroup$Polygon[{{0, 0}, {1, 0}, {0, 1}}] // RegionBoundary
$\endgroup$Perimeter@boundary
works. Maybe it is looking for a 3D region with some volume to it.RegionDimension@poly
being2
might have something to do with it. $\endgroup$