88
votes
Accepted
How can we make publication-quality PlotMarkers without version 10?
Based on Oleksandr's excellent design idea here is my re-implementation of his package which offers a much richer set of shapes.
UPDATE from July 2022
A minor update: now the form ...
45
votes
How can we make publication-quality PlotMarkers without version 10?
Fortunately, Wikipedia has the answer, as long as we are content to restrict ourselves to non-intersecting closed polygons. This will probably be an acceptable limitation, given that excessively ...
29
votes
Accepted
Rounding the Corners of a Shape
UPDATE:
The previous version of my answer worked, but did not give control on the rounding radius, nor did it fully work with as a starting point for a geometric region for further calculations. Here ...
27
votes
How can we make publication-quality PlotMarkers without version 10?
Here is an alternative answer. Of course, since you answered your own question, you may not need this. But I think the following is a viable alternative that may end up looking comparable, and has ...
21
votes
Filling Space with Pursuit Polygons
The reason that these are called "pursuit polygons" is because they are formed from a dynamical system in which different agents pursue each other. Example:
In this image, one agent starts in each ...
20
votes
Rounding the Corners of a Shape
Just wanted to add purely mathematical approach using complex mapping technique.
...
18
votes
Accepted
Pentagonal spiral in Mathematica
Late to the party~
A slight modification to make them more similar:
...
17
votes
Rounding the Corners of a Shape
Since you mention that you want to use the rounded polygon in NDSolve[] as a region, you might want to look at the following construction:
...
16
votes
Accepted
How can I build a 3D slab of hexagons or a thick hexagon mesh?
Does this do what you are looking for?
The following function takes a parameterization surface and a region region and tries to ...
15
votes
Rounding the Corners of a Shape
FilledCurve will do the job because it can be styled by JoinForm:
...
15
votes
Rounding the Corners of a Shape
Here is a more general method for producing polygons with rounded corners. Using a bit of vector algebra and trigonometry, I came up with the following:
...
15
votes
15
votes
Pentagonal spiral in Mathematica
It's something like this:
steps = Table[{r, 1.001 (2 Pi/5)}, {r, 1, 25, 0.1}];
Graphics[{Red, Line@AnglePath[steps]}, Background -> Black]
15
votes
Accepted
A Smooth and Round Voronoi Mesh
1 + 4
We can discretize the rounded Polygon objects and then add the negative of the mesh through Prolog.
...
15
votes
Accepted
On the ordering of the vertices of a polygon
One way to solve the case provided is to apply a DistanceFunction to FindShortestTour. Here, I apply a stiff penalty to the next ...
14
votes
Polygon mesh: Compute vertex normals for smooth shading
In case the undocumented internal function Region`Mesh`MeshCellNormals[meshregion, dimension] is of use to someone:
...
14
votes
Rounding an Irregular Polygon
A quick hack, essentially interpolating a point travelling at constant speed on polygon edge and averaging the position over a time interval:
...
13
votes
Accepted
Plot polygonal surface
(grabbing a lot of code from this answer)
This is just to get you started, adding in colors to the final GraphicsComplex should be pretty easy.
...
13
votes
Accepted
Exact symbolic area of an intersection of two polygons with parameters
Having Area generate conditions is informative:
...
12
votes
Accepted
11
votes
RegionMember[ ] in polygon
This seems like a bug. It might even be a bug I have reported in the past.
In particular, your polygon is slightly degenerate: it has {-3, 16} twice in a row, ...
11
votes
Unexpected behavior of the procedure `Area` on the object 'Polygon'
EDIT: Reported to WRI as CASE:4237867 - fixed on V12. :)
Seems like a bug in my opinion. Consider the following:
...
11
votes
Accepted
Rounding an Irregular Polygon
Not an anwser, yet. This is how the curve shorthening flow would act on the cells:
As you can see, the cells lose contact. So this is probably not what you are looking for, right?
Something similar ...
10
votes
Accepted
10
votes
Accepted
RegionMember[ ] in polygon
I think it's worth reporting this to support. As a workaround you can numericize the polygon:
...
10
votes
Accepted
Unexpected behavior of the procedure `Area` on the object 'Polygon'
This is a packed array issue:
Area @ Polygon[Developer`ToPackedArray @ {{0, 0}, {4, 0}, {2, 2}, {4, 4}, {0, 4}}]
Area[Polygon[{{0, 0}, {4, 0}, {2, 2}, {4, 4}, {...
9
votes
Accepted
How to make sure polygon is drawn flat in 3D?
A shot in the dark: Reverse the orientation. Hey, it works...but I don't know why...???
Graphics3D[Polygon /@ Reverse@*pentagram /@ (vert[[#]] & /@ ind)]
A ...
9
votes
Accepted
Two 5-gons - One with a concave vertex and another with a convex vertex
H3110 customer,
thank you for contacting StackExchange coding service. We propose the following solution to your urgent problem:
...
9
votes
9
votes
Filling Space with Pursuit Polygons
Here's an extension of @C.E.'s code to non-triangular polygons - polygons taken from a Voronoi mesh of roughly equidistributed (https://mathematica.stackexchange.com/a/141215/3056) 31 points over a ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
polygons × 118graphics × 40
regions × 31
geometry × 22
computational-geometry × 20
graphics3d × 18
plotting × 12
mesh × 12
bugs × 7
numerical-integration × 4
finite-element-method × 4
geography × 4
intersection × 4
manipulate × 3
polyhedra × 3
drawing × 3
calculus-and-analysis × 2
performance-tuning × 2
numerics × 2
export × 2
style × 2
pdf-format × 2
undocumented × 2
3d-printing × 2
differential-equations × 1