Tag Info

New answers tagged

0

When you save it as PDF and open it later, Graphics content is no more the same. You may check it out with: ArrayPlot[1. - IdentityMatrix[4], ColorFunction -> GrayLevel, ColorFunctionScaling -> False, Mesh -> None] // FullForm Then you save the image output as PDF (copy should have the same effect) Reopen the PDF (or paste it), then examine ...


3

In Mathematica 10, you can use DelaunayMesh on a set of points. This returns a MeshRegion. You can use MeshCoordinates to return a list of coordinates of the points (should be the same as the initial set of points) and then MeshCells to return the triangles. See Interactive Computational Geometry for more details.


6

There are some new functions in Mathematica 10 that make this very easy: r = {{-6, 6}, {-6, 6}}; pts = RandomSample[Permutations[Range[-5, 5], {2}], 10]; Grid[{ {"The sites", "Delaunay trianguation", "Voronoi diagram"}, { Graphics[{Red, Point[pts]}, PlotRange -> r], Show[dm = DelaunayMesh[ pts], Graphics[{Red, Point[pts]}], PlotRange -> ...


8

In Version 10, this can be done elegantly in one line: SeedRandom[400] pts = RandomReal[5, {400, 3}]; Then: surftri = RegionBoundary @ TriangulateMesh @ DelaunayMesh @ pts We can look inside to see that only the surface triangulation remains: HighlightMesh[surftri, {Style[0, Directive[PointSize[0.015], Blue]], Style[1, Thin, Black], Style[2, ...


6

Well, you have to first convert it to a MeshRegion. Let's take the space shuttle for example: shuttle = ExampleData[{"Geometry3D", "SpaceShuttle"}] Now, we discretize it, since it's a Graphics3D object, we use DiscretizeGraphics: ds = DiscretizeGraphics[shuttle] Now, we can find the Area easily: Area[ds] 177.301907 Similarly for the horse: ...



Top 50 recent answers are included