Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
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.
4
votes
Simplifying an expression to a sensible conic section polynomial
This is not a general-purpose answer but it works in this case at least. First step is to obtain an implicit polynomial in {x,y} for that second expression. Often enough, GroebnerBasis can do this. It …
3
votes
Generate convex-hull of a 15 dimensional space
Start with the definition (I use Together to make it somewhat shorter).
func = {1/225 (-15 x5^2 y1^2 - 15 x6^2 y1^2 - 15 x5^2 y2^2 - 15 x6^2 y2^2 -
5 Sqrt[15] x2 x5 y3^2 - 25 x5^2 y3^2 + 5 Sqrt[ …
0
votes
Accepted
Finding a set of characteristics of a system of polynomial equations
This is a bit of a wild guess, based on two articles sent by the poster (references below).
First rewrite the system using lower case names, making the N into a time-dependent "input" variable, and c …
3
votes
Help finding the point(s) inside "non-star" closed shape with the highest average ray length?
One approach is to parametrize the boundary, and use that parametization for the innermost integral that defines the averaged radius. This might or might not correspond to the definition you have in m …
6
votes
Approximating Voronoi diagram without any distance checks
Here is a method that combines usage of "fast marching" and Nearest from responses here. It is not as pretty as the one shown here but is probably more efficient computationally. The idea is to work o …
4
votes
Place spheres randomly in a box without collisions?
Okay, here goes.
Given a distro, box length, and number of desired points one can generate a bunch more, remove the ones that are too close to the edges to fit, then iterate through what remains to d …
3
votes
How to efficiently implement k-FN (k-Furthest Neighbors)?
Not necessarily best of quality but maybe could be made better with a bit of tuning.
kDistant[pts_List, n_] := Module[
{objfun, len = Length[pts], ords, a, c1},
ords = Array[a, n];
c1 = Flatten …
17
votes
Accepted
Determine whether points lie within a cow
This is basically a rehash of code I posted in a prior thread on this topic. The underlying method is to shoot a ray from the point and see how many surface triangles it intersects.
elsie = ExampleDa …
13
votes
Find the nearest locations for multiple points
I will crib shamelessly from example and code for illustrating by @ybeltukov.
The example:
n = {5, 5};
holes = N@Tuples@Range@n;
balls = RandomReal[{0, # + 1}, Times @@ n] & /@ n // Transpose;
We …
4
votes
Ordering the Boundary Points of a Polygon
Could use ConvexHull in the ComputationalGeometry standard add-on package.
Needs["ComputationalGeometry`"]
We'll create a simple example.
pts = RandomReal[{-10, 10}, {6, 2}];
ListPlot[Append[pts, …
16
votes
Insphere for Irregular Tetrahedron
This may not be as neat as the other methods posted. About the only things I can say are that it is derived from basic principles, and it is fortunate that I had my hair buzzed rather short a few days …
1
vote
Accepted
Calculating a minimum bounding box for a set of 3-space coordinates / spheres
Here is an idea for an approximate method. Center the data, compute the singular value decomposition, and use the right factor rotation matrix to align the singular values axes with the coordinate axe …
21
votes
Voronoi diagrams for generators other than points
Here is a Nearest-based method. This is quite similar to what @Mr. Wizard did for approximating 3D (ordinary) Voronoi.
comps = MorphologicalComponents[img];
cmap = Flatten[MapIndexed[#2 -> # …
16
votes
Voronoi diagrams for generators other than points
While I cannot match @whuber's simple elegance, I will show a bit of brutishness by using Fast Marching from scratch. This finds distances from a specified boundary. I'll modify it so that, for each p …
18
votes
Efficiently determining if 3D points are within a surface composed of polygons
Here is a more general approach. It is based on the 2D method from here. It assumes the polyhedron is not self-intersecting but imposes no requirement of convexity or even connectedness, other than th …