Questions tagged [mesh]
Questions on the use and creation of meshes including the use of MeshRegion, ElementMesh, and TetGenLink.
601
questions
2
votes
0answers
54 views
0
votes
1answer
63 views
How to find out the number of nodes in the interval of mesh [closed]
I have a mesh created for the femur. I need to apply a total load of 800 N in the range 480 < z < 500. To do this, I need to know the number of nodes in this interval in order to apply Force to ...
7
votes
2answers
480 views
How to add 'border' to Voronoi diagram
Suppose I have a set of points pts, from which I generate a Voronoi diagram VD:
...
3
votes
2answers
134 views
FEM 2D mesh with inclusion
I want to create a FEM mesh with an inclusion, but I want to define the coordinates of the edge nodes manually, since I need the nodes for a problem that requires periodic boundary conditions.
The ...
0
votes
0answers
25 views
modify the elements numbers of a mesh file
I have loaded the mesh of simulation on Mathematica:
geo = Import["geometry.vtk"];
The elements of geo are:
...
0
votes
0answers
53 views
How can I convert such a model into a BoundaryMeshRegion
The obj file is here
As you see, I cannot import such a house model into Mathematica with BoundaryMeshRegion Option.
Import[objFile, "BoundaryMeshRegion"]
So my ...
1
vote
0answers
44 views
How to find intersection of higher dimensional convex hull?
I have often used ConvexHullMesh to obtain a convex hull for 2-d and 3-d points. But when I try to find it for 4-D points I encounter error even for simple cases.
<...
1
vote
1answer
72 views
Represent a Concave Mesh Volume
I programmatically generate a shape, where the top surface is defined by a series of polygons. I generate all the points of the polygon.
...
3
votes
2answers
136 views
Finding mesh elements within a given region
I write a code that generates the following mesh. I would like to find out the elements that completely lie within a certain circular region inside this meshed area. How do I do that?
The code that I ...
3
votes
1answer
57 views
Euler Characteristic of MengerMesh
When I ask Mathematica to give me the Euler characteristic of MengerMesh[1, 3], it returns 16. It seems to me the 1-step Menger sponge has genus 5 and should ...
0
votes
0answers
114 views
Projecting a 3D mesh region to 2D
How do I project a 3D MeshRegion to a 2D MeshRegion (or equivalent for a BoundaryMeshRegion). This question is similar to ...
5
votes
1answer
127 views
How to export a volume mesh?
Let's say that I generate a volume mesh using the following command:
Icosahedron[] // BoundaryDiscretizeGraphics // TriangulateMesh
which gives the following:
As ...
0
votes
1answer
54 views
1
vote
0answers
29 views
NearestMeshCells in Mathematica 11.3
Is there an efficient way of writing a function equivalent to NearestMeshCells (Mathematica 12.1) in Mathematica 11.3? I'm trying to write my own code, which I can ...
6
votes
2answers
342 views
8
votes
1answer
204 views
Generating a Periodic Voronoi Mesh
Consider the following hexagonal mesh, created from VoronoiMesh
...
0
votes
1answer
39 views
0
votes
0answers
44 views
0
votes
0answers
33 views
Discretize a 1D Region (Boundary) into exactly N Points
I would like to obtain exactly N points of the boundary of a given (randomized) region, or at the very least, always the same number of boundary points for similar regions.
Here is an example what I ...
2
votes
1answer
81 views
4
votes
1answer
116 views
2
votes
1answer
74 views
How can I calculate volume of such a MeshRegion Object
The Data is here:
meshData
===
PolygonData is here
...
5
votes
1answer
101 views
Assigning ElementMarkers to existing ElementMesh boundaries
I've imported a 2D element mesh from another program as a list of triangle coordinates {{x1,y1},{x2,y2}....} ("nodes") and element connections {{n1,n2,n3},...} ("elements"). Then I create an ...
3
votes
1answer
114 views
How to divide a region in FEM with a parametric curve?
I'm using NDSolve with finite element to try to solve a heat transfer problem. The region I have is a rectangle where the four vertices are at ...
1
vote
2answers
54 views
Different style for vertical and horizontal lines in ListStepPlot
I would like to color the horizontal portions (the data) of a ListStepPlot in one style (e.g., blue) and the vertical (linking lines) in a different style (e.g., ...
6
votes
1answer
107 views
FEM Simulation: Meshing two Arbitrary objects in an “air” mesh
Based on this excellent answer to my previous question: FEM: Electric Field between two arbitrary defined shapes
I wanted to try out other shapes:
...
5
votes
2answers
161 views
Mesh on cross section of meshes / 2D Region on cross section of 3D Regions
Context
This is fairly general and simple question, (probably because it has a simple solution?). I want to define a mesh (e.g. to be used with Plot3D or FEM or ...
5
votes
1answer
174 views
Piecewise Continuous Linear Basis on a Triangular Mesh
Question
Given a FEM mesh, I would like to define a set of basis functions
anchored to the mesh, so that any piecewise linear continuous function on the mesh can be expanded over that set.
Such a ...
0
votes
1answer
50 views
How to smoothen the mesh lines of a translucent sphere
This code generates a nice sphere with distorted mesh lines, in the sense that they are not smooth enough. One can clearly see many disjoint lines trying to imitate a curve. I would like a smoothened ...
0
votes
0answers
40 views
Torus Hex Mesh - Need Unique Hex Dimensions
I'm looking to laser cut a bunch of hexagons and assemble them into a torus (using hot glue or tape). How do I get the dimensions of the individual unique hexagons? I've seen Create a torus with a ...
7
votes
2answers
145 views
Penalty function on discrete mesh using Laplace-Beltrami operator?
Context
I am interested in extending to the ill-condionned regime the inversion of linear equations
arising from inverting differential equations which have been solved via 0-splines over a mesh ...
4
votes
4answers
160 views
How do I list start and endpoints of CantorMesh?
How do I extract start and endpoints of each defined interval of iteration n of CantorMesh[n]? The furthest I can go is
...
2
votes
1answer
121 views
Mathematica Won't Recognize a MeshRegion
I've implemented the code in the top answer of this question on the Plateau problem in differential geometry, and it works with the example shown in Example 1, so there is nothing wrong with the code. ...
2
votes
2answers
58 views
Replacing every shape in a geometric set with another shape
Consider a Mathematica function that produces some number of identical, but separate shapes; like CantorMesh[2, 2], for example.
Is there a simple way to "replace" ...
1
vote
1answer
42 views
How to Resize/Rescale a Mesh?
Consider, for example, the mesh given by
mesh = VoronoiMesh[RandomReal[10, {6, 2}]]
Imagine I want to resize it so that it is framed in the $[0,1]\times [0,1]$ ...
6
votes
2answers
112 views
How to group points based on mesh primitive membership
As a simple example of what I want to do, let's say I have a Voronoi mesh in a $10\times10$ area with $10$ random "seed points":
...
0
votes
0answers
53 views
Plotting non-square data array without interpolation
This is a related question to the one I posed a while ago at Non-square data array distorted when using InterpolationOrder->0 in ListDensityPlot
I am trying to plot XYZ data that does not ...
5
votes
1answer
100 views
Minimization problem and Voronoi Mesh
I have a random convex mesh $Q$, made of $n$ polygons, and I want to test how close it is to a Voronoi tessellation. In other words, I'm looking for generators (seeds) $\{(x_i,y_i)\}_{1\leq i\leq n}$.
...
1
vote
2answers
54 views
Selecting Shared Edges from a Mesh
Consider the following mesh
mesh0 = VoronoiMesh[RandomReal[1, {50, 2}]]
I can select interior polygons with
...
1
vote
0answers
52 views
How to implement meshing in DiscretePlot3D?
In this answer I show a method to use DiscretePlot3D to plot a numerical function which requires a discrete step-size to be plotted, making ...
11
votes
3answers
347 views
Why the mesh generated for NDSolve is different from the final plotted mesh?
When I try the following code to solve the Laplace's equation, the mesh generated by bmesh = ToElementMesh[bmesh] is different from the mesh shown in ...
4
votes
2answers
242 views
Closing a Graph
Consider the following graph g
I want to "close" it by adding the following edges
Alternatively, I would also be happy with something like
where I've added four "...
2
votes
1answer
53 views
Plotting space defined by implicit equations via pure functions (ContourPlot3d, RegionPlot3D, Graphics3D)
Is there a simple elegant way to plot any implicit curve or surface in 2D or 3D, given the input reg (list of intervals, i.e. cube) and ...
6
votes
1answer
95 views
Checking if a Graph forms a Mesh
Given a random graph, I want to define a function MeshGraphQ that tests if the graph is a lattice (or mesh) graph. Here, I don't need the tiling to be regular. ...
8
votes
2answers
631 views
How to visualize a spherical mesh on a squared plane?
I need to visualize the points of a spherical mesh on a squared plane (this question is different than this one, I believe). For instance, let us first generate points ...
4
votes
1answer
84 views
Why are those two mesh regions not the same?
In Mathematica, one can triangulate a mesh starting from a boundary mesh region. For example:
...
2
votes
2answers
117 views
An ImplicitRegion with a boundary which is an Interpolated Function is not a ConstantRegion
I create an ImplicitRegion from a box-shaped region with one face replaced by a function h[x,y]. If h[x,y] is a "normal" function, e.g.
...
0
votes
0answers
53 views
Triangle mesh (set of points 2D) with minmal total area: ' Convave Hull' [duplicate]
modified question
In the following example
...
7
votes
3answers
218 views
Reduce quality of an imported MeshRegion
Importing STL files using Import results in a MeshRegion composed by the triangulation of the original file, and a similar ...
2
votes
2answers
97 views