Questions tagged [computational-geometry]

Questions on constructing graphical objects using relatively complex computations relating to the mathematical structures defining those objects. Examples include convex hulls, Voronoi diagrams, Delaunay triangulations, mathematical constructions, symmetries, genuses of curves and graphs and programmatic constructions of polyhedra.

Filter by
Sorted by
Tagged with
0
votes
1answer
36 views

How to get the overlap's percentage that occurs between 2 circles or among more than 2 circles?

The following code draws the following circles; ...
1
vote
1answer
70 views

Computing cross section area between cylinder and disk

I am creating a cylinder, whose center disk is placed at position vector v1 and whose orientation is given by the disk's normal vector ...
4
votes
5answers
410 views

Computing the intersection area of two disks in 3D

Closely related to this question about highlighting intersection of two disks, I am trying to figure out if one can do so similarly for disks embedded in $3D$ (e.g. in a bounding box). The difference ...
3
votes
0answers
64 views

Hafnian of a matrix

Is there a Mathematica built-in function for the calculation of the Hafnian of a matrix? I am interested in the function as it appears naturally in the calculation of moments of a multivariate ...
0
votes
1answer
85 views

RegionDifference not working properly for a region from a printable STL file

Some time ago I created a printable STL-file with a certain software of my own and now I want to modify it with Mathematica programmatically, mainly by subtracting certain geometric objects (e.g. ...
0
votes
0answers
30 views

Constrain values to numeric during Minimize

I understand, that similar questions have been asked before, but I am absolutely new to Mathematica and can not solve it myself: In nuce it is the following: I want to calculate ...
2
votes
1answer
113 views

Visualising and detecting stacked oblate particles

Context: I am trying to learn how to visualize a box filled with oblate-shaped particles. These are in contrast to prolates which can be drawn using for example ...
0
votes
1answer
73 views

Find the points closest to and farthest from the origin for a region in $\mathbb{R}^6$

Given $A$ being the intersection set between $x + y + z + u + v + w = 1$ and $x^2 + y^2 + z^2 + u^2 + v^2 = 1$, find the closest and farthest points to the origin that belong to $A$ in the space $\...
1
vote
1answer
58 views

Making cuts in a paraboloid of revolution modified [closed]

I need my to have like parabolic holes where the bumps or fins are ubicated, like in this image, so that they match with the same fins or bumps: The graphic I have was done with a paraboloid and the ...
0
votes
1answer
47 views

Plotting a disk with a z-value different to zero

I'm plotting a disk with ParametricPlot3d, but I need it to be drawn at z = 0.4, in order to join it with another plot. ...
3
votes
2answers
129 views

Is there any command similar to Delaunay of matlab?

After finding this webpage where they mention the generation of land using matlab, In its section how it works, explain its operation in detail, I started trying to do it in MMA but I am doubtful of ...
2
votes
3answers
80 views

How to rotate a lattice points about an arbitrary axis

I have hexpoints = Table[{Cos[n Pi/3] + 1, Sin[n Pi/3] + \[Sqrt]3/2}, {n, 6}]; Which gives the fundamental cell to be applied in ...
0
votes
1answer
47 views

How to obtain the positions of the points in a lattice

I want to know the positions of each point in a hexagon lattice, like I saw some posts where they obtain this lattice using a function ...
15
votes
3answers
275 views

Computing the surface area and volume of molecules

Here is a somewhat difficult problem I've had for a long while. Space-filling models of molecules can be easily generated by ChemicalData[], ...
0
votes
1answer
63 views

BoundaryDiscretizeRegion Plots does not work with ParametricPlot3D

I am trying wit this data ...
1
vote
0answers
45 views

How to find coordinates of the points A, B of a sphere with screen coordinates?

I put my question at here https://tex.stackexchange.com/questions/503745/how-can-i-get-correct-the-point-a-and-b-automatically-in-this-picture/503838?noredirect=1#comment1272706_503838 to find the way ...
1
vote
0answers
102 views

Calculate the intersection points of a line and a parametrically defined 3D surface

Thanks to Henrik Schumacher for advice to simplify the sample code: I would be grateful for any pointers on the following issue. A line from an external point intersects the surface at 2 points (...
1
vote
1answer
66 views

Getting a list of cities that are located in more than one county (within a state; in this case Florida, USA)

To get the list of counties in the State of Florida, I first evaluate: EntityClass["AdministrativeDivision", "USCountiesFlorida"] which gives me a pill-shaped ...
5
votes
2answers
129 views

Automatic solution to label boundary elements with BoundaryMarkerFunction

Preparations Mathematica 11.3, Windows. Let us say I have a rectangular region with 10 little holes inside. Their coordinates are given by positionList. The ...
1
vote
0answers
46 views

Non-convex hull mesh from 3d points [duplicate]

I am trying to create a 3d mesh object from list of points, but the only options I see in Mathematica are ConvexHullMesh and ...
3
votes
1answer
68 views

Signed cell adjacency matrices (boundary operators)

In How to obtain the cell-adjacency graph of a mesh? there are some great answers that show how to obtain the cell adjacency matrix of a mesh. How would one generalize these to incorporate the ...
3
votes
3answers
117 views

RegionMember does not work with RandomPolyhedron or Polyhedron object

According to the documentation RegionMember should work with regions that are true for ConstantRegionQ. However, the function ...
8
votes
1answer
369 views

How can I select a specific triangle in my Delaunay mesh?

Here is the code I am working with. I create a list of random coordinates, then I create a triangular mesh with the code: ...
6
votes
0answers
86 views

How to make a function for image recognition

For example given a big set of random points, and I extract a small section of the random set of points, how can I find the small set on the big set? As a first approach I tried to do a Delaunay ...
0
votes
0answers
55 views

How can I create a Delaunay mesh in set of points inside an image?

Is there a possible way to create a Delaunay mesh inside an image given a set of points inside the image? for instance use the pixel coordinates to create the Delaunay mesh.
0
votes
0answers
39 views

Regions detecting/counting

Recently, I solved an analytical problem on the number of possible regions in a similar figure: I conducted numerical experiments on Mathematica to verify the results. Intersection points are easy to ...
1
vote
0answers
39 views

Possible bug with InnerPolygon and RegionUnion in version 12

case1 case2 case3 ...
0
votes
1answer
44 views

Quadric surface reduced form [closed]

I was just wondering, is there any way to determine which surface is the one given by the equation in general implicit form Without calculating the eigenvalues and basis vectors etc. Or if you ...
0
votes
1answer
59 views

Complex infinity at a point and division by zero

Edit: I've found out that the book was written for Mathematica 7, which was a pretty long time ago. It boils down to changes in syntax most probably, but simple renaming to lower lettercase does not ...
0
votes
0answers
33 views

Triangulations of a convex polygon

I have a piece of code which finds all triangulations of a convex polygon. It is known that a number of such triangulations for a given $n$-gon is is given by ($n-2$)th Catalan Number, so for instance,...
0
votes
0answers
58 views

Showing the geodesics on an ellipsoid [duplicate]

I have have code to the parametric plot of an ellipsoid: ...
1
vote
2answers
53 views

Problem defining a polygon

I have two polygons that are very similar as: ...
4
votes
3answers
209 views

Deleting the same lines from a list

Say I have a list of Lines: ...
2
votes
2answers
107 views

Fill points into a pre-rotated convex Dodecahedron

I am trying to fill a rotated convex polyhedron with points. This functions well in the unrotated case: ...
4
votes
0answers
76 views

Ideas for visualizing the shape of a random walk

Context: In the context of (3D) random walks or polymer chains, a useful quantity for capturing and characterizing the shape of the walk or the conformation of the polymer in space is the gyration ...
0
votes
0answers
68 views

Find two points (of maximum distance) lying on perpendicular intersecting polygon border

On a randomly generated convex hull, I found the two points of maximum distance on the region's perimeter (the points in black). I would like to find two points that lie on the perpendicular to this ...
8
votes
2answers
398 views

Catmull-Clark and Doo-Sabin Subdivision Implementations

I want to work on subdivision surfaces. Unfortunately, I don’t have any source code to start with. I need some Mathematica codes for applying Catmull-Clark and Doo-Sabin methods. I would like to ...
0
votes
1answer
52 views

Solve: line and rectangle intersections

I have been trying to find the intersections between a rectangle and a line, following the example given in the Solve function: ...
5
votes
1answer
59 views

Mesh cell count for Voronoi mesh too low

I was trying to solve this question out of interest and thought perhaps creating a Voronoi mesh, cropping it to a circle, and colouring the mesh cells might work. However, if I ask ...
0
votes
0answers
92 views

Graphics error in orthogonal trajectory

OT_Circles/Tractrices To find an orthogonal trajectory we generally replace slope by its negative reciprocal in its originating differential equation (DE). I.e., replacing $\phi\rightarrow \pi/2-\...
12
votes
2answers
267 views

Unexpected behavior of the procedure `Area` on the object 'Polygon'

Bug introduced in 11.3 or earlier and fixed on 12.0. Sometimes get a results, sometimes left unevaluated. For instance ...
4
votes
1answer
79 views

VoronoiMesh with custom distance function

I'm failing at reading the documentation. Is there a way to specify the distance function used by VoronoiMesh? As a stripped down example say I have a rank-1 lattice such as: ...
4
votes
2answers
142 views

Intersection lines of surfaces from list contour plots

I have two plots made with ListContourPlot3D. Is there a way to find the intersection curves of the surfaces represented in the two plots? I have tried ...
4
votes
1answer
144 views

Calculate total length of edges in select Voronoi diagram

I want to calculate the total length of edges in a Voronoi diagram like this I can calculate this with ...
5
votes
2answers
253 views

Draw bounding region by list of points

Suppose you have a list of data points, either in 2D or 3D; is it possible to plot the minimal bounding region containing all the points? Ignoring holes etc.
2
votes
2answers
161 views

Find the smallest and largest distance between two points distributed in 3D space

Suppose I have some 3D points, e.g. {{0, 0, 1}, {0, 0, 1.3}, {0, 1, 0}, {1.2, 0, 0}}. Now I want to find the smallest and largest distance between two points. A ...
1
vote
2answers
96 views

Trouble with Calculating Area of Parametric Region

This question stems from an attempt to solve the following question: How to calculate specific area on surface of sphere? First, I parametrize a circular loop: ...
4
votes
0answers
71 views

How to calculate specific area on surface of sphere?

I am trying to calculate the solid angle subtended by arbitrary-shaped loops on a sphere's surface. First, I parametrize circular loops by: $$\theta(t,k_{x0},r) = k_{x_0} + r \cos(t);$$ $$\phi(t,k_{...
6
votes
2answers
538 views

Calculate of total length of edges in Voronoi diagram

Does anyone have any suggestions how to determine the total sum of edges length in a Voronoi diagram?
1
vote
2answers
116 views

How to calculate arbitrary area on surface of sphere?

I am trying to calculate the solid angle subtended by arbitrary-shaped loops on a sphere's surface. First, I parametrize circular loops by: $$\theta(t,k_{x0},r) = k_{x_0} + r \cos(t);$$ $$\phi(t,k_{...