New answers tagged polygons
3
votes
How to Find "n" for n-th Triangular Number
WolframLanguageData["PolygonalNumber", {"VersionIntroduced",
"DateIntroduced"}]
Using ...
2
votes
Accepted
Generate A Point Inside An Arbitrary Concave Polygon
Here's a fast algo: 1) find convex vertices, 2) from those find one with the maximum Cross between its segments, 3) then pick a point using bisector and a small ...
2
votes
Generate A Point Inside An Arbitrary Concave Polygon
I posted a hasty answer which without having Mathematica. I have deleted that one. Here is a better version if someone else wants a go.
Take two points A, B on a polygon side.
If A is B and the side ...
2
votes
Accepted
How to Handle Non-Coplanar Vertices in BoundaryMeshRegion Constructed from ParametricPlot3D?
The same way as
https://mathematica.stackexchange.com/a/302959/72111
https://mathematica.stackexchange.com/a/306411/72111
https://mathematica.stackexchange.com/a/306683/72111
https://mathematica....
6
votes
How to Handle Non-Coplanar Vertices in BoundaryMeshRegion Constructed from ParametricPlot3D?
There are a couple issues with your current approach.
(1) You're trying to make a Polygon cell from the points on a spiraling line (red line shown in plots). I'm not sure what your intention is here, ...
7
votes
Generate A Point Inside An Arbitrary Concave Polygon
decomposition the polygon into several triangles (or convex set) before select points.
...
13
votes
Generate A Point Inside An Arbitrary Concave Polygon
We can use mesh regions instead. For $n = 1000$ here's timings on my machine:
SeedRandom[1];
RandomPoint@Polygon[points]; // AbsoluteTiming
...
8
votes
Accepted
How can I make all the lines within the polygon turn gray in that region?
RegionFunction with RegionMember.
To make difference color, we use ConditionalExpression.
<...
Top 50 recent answers are included
Related Tags
polygons × 164graphics × 53
regions × 52
geometry × 32
computational-geometry × 25
graphics3d × 24
plotting × 20
mesh × 15
bugs × 10
performance-tuning × 5
intersection × 5
generative-art × 5
polyhedra × 5
functions × 4
numerical-integration × 4
export × 4
finite-element-method × 4
pdf-format × 4
geography × 4
manipulate × 3
drawing × 3
calculus-and-analysis × 2
function-construction × 2
graphs-and-networks × 2
numerics × 2