# Questions tagged [mesh]

Questions on the use and creation of meshes including the use of MeshRegion, ElementMesh, and TetGenLink.

402 questions
Filter by
Sorted by
Tagged with
91 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 ...
597 views

### Mismatch between Mathematica and COMSOL in 3D FEM problem

I would like to solve an advection-diffusion problem on a torus domain. There are three Dirichlet conditions: One at the inlet (concentration $c=0$), one at the outlet ($c=0.5$) and one at the wall (\$...
1k views

### A geometric multigrid solver for Mathematica?

Cross posted to community.wolfram.com Mathematica ships a variety of linear solvers through the interface LinearSolve[A, b, Method -> method] the most ...
44 views

### Non-convex hull mesh from 3d points

I am trying to create a 3d mesh object from list of points, but the only options I see in Mathematica are ConvexHullMesh and ...
59 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 ...
127 views

### Adjacent faces in a discrete mesh

I have a MeshRegion R and I want to extract all pairs of adjacent faces efficiently. The way that I've been computing this is demonstrated below: ...
100 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 ...
186 views

### Extracting points from 3D plot that lie along an arbitrarily oriented line

Starting from i.e. the following 3d plot: d = RandomReal[1, {100, 3}]; ListPlot3D[d] Is it possible to extract points that lay along an arbitrarily oriented line,...
68 views

### Set maximum space between elements in 3D mesh

A region in 3D space has been discretized to obtain a list of points. The resulting ListPointPlot3D plot is: I will like to obtain a mesh from these points, but ...
224 views

### Visualising Finite Element Mesh in 3D with MeshRefinementFunction

How do you check that a MeshRefinementFunction is doing what you want in a 3D mesh where you only see the boundary mesh? I started by making a block with a hole as ...
330 views

### 3D internal subregion

I'm trying to follow the documentation for Element Mesh Generation, but somehow I cannot understand it correctly. Here is a simplified version of my real problem. I'm trying to simulate the ...
221 views

### Trouble meshing a Corbino disc

I am trying to simulate current flow using FEM through this particular device (a Corbino disk) and I have difficulties generating the mesh for it. Here is the region: ...
2k views

### How to generate a mesh with quadrilateral elements?

I have the following code that generates a finite element mesh: ...
39 views

### Extra Lines in 3D ConvexHullMesh

I would like to make a picture of a truncated octahedron using ConvexHullMesh as follows: ...
58 views

### Mesh quality error with interpolation of table

I am trying to interpolate a table of the following form. {{x1,y1,z1},{x2,y2,z2}...} Where z depends on x and y, and x ranges from 0.01 to 1 in steps of 0.01, ...
141 views

### Given a cell in a Voronoi diagram, which point did it come from? [duplicate]

Given a set of points pts = Table[{RandomReal[], RandomReal[]}, {i, 1, 10}]; and their Voronoi diagram ...
67 views

### Find surrounding vertices (simplexes) of a given point for DelaunayMesh

Generating a Delaunay triangulation of some random points: pts = RandomReal[{-1, 1}, {50, 2}]; dm = DelaunayMesh[pts]; HighlightMesh[dm, Style[0, Black]] gives [...
76 views

### Create a tube from a section of a sphere using mesh

How does one make a meshed tube starting from a section of a sphere and later edit the tube's section parametrically.
65 views

### Difficulty in specifying mesh refinement

I am trying to give a region within a 3D volume a finer mesh than the rest of the volume. My problem is more complicated but here is a minimum working example. I define a 3D cuboid and try and have a ...
126 views

### Analyzing MethodOfLines

In this example the wave equation ...
61 views

### Mesh mixes up markers in multiple curves

Following is my code: ...
245 views

### Creating a MeshRegion object from a Graphics object

I am looking to convert a simple Graphics object that is defined by overlapping polygons into a MeshRegion object. For example, here is code that will create three overlapping triangles ...
336 views

### How to find ids in a curved line in a finite element mesh?

Previous discussion about this problem has already occurred in this link: How to get the node id in a specific coordinate in a finite element mesh? I have the following code that generates a finite ...
317 views

### How do I convert a mesh region back into a Graphics3D primitive?

The Graphics3D format has more styling options than mesh based graphics, so I was wondering if there was a way to convert mesh based objects such as region intersections and unions back into the ...
47 views

### RandomPoint returns compiler errors on RegionIntersection of two Meshs?

Consider the intersection of two ConvexHullMesh's, m1 and m2. ...
55 views

### Make MeshRegion/BoundaryMeshRegion work as a graphics primitive in M11

Mathematica 12 has the nice feature that MeshRegion and BoundaryMeshRegion objects render nicely when included as a primitive in ...
84 views

### How to draw individual mesh lines in ArrayPlot

Consider the following ArrayPlot. ...
66 views

### Creating a mesh from a very thin layer

I have the following code which works just fine: ...
115 views

### Holes in ElementMesh with ToElementMesh of ImplicitRegion

I am trying to plot a function in a region below a level curve of the function and within a cell. I have been doing this by calculating an ElementMesh using ...
291 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 ...
85 views

### Meshing control of NDEigensystem

I have to solve an Eigenvalue problem originating from the Electrodynamics. It is a 2-D problem with a rectangular region. More specifically, there is a hole on a rectangle made by magnetic material. ...
77 views

### How to create surface mesh from a given 2D mesh toplogy?

I would like to convert a very easy(examplary) mesh(2D) ...
158 views

### Volume of HexahedronElement with non-coplanar faces

Bug fixed in Version 12.0 I would like to calculate the volume of ElementMesh made of HexahedronElement. Even though ...
41 views

### Is there a way to automatically use triangular elements in ToElementMesh [closed]

I have some simple code to generate a mesh over a rectangle. ...
80 views

### Converting .STL from Shell to Solid for stress analysis of wing

I'm new to Mathematica as this is the first class I've had to used it in my undergrad time as an aerospace engineer. Anyway, I have run into a problem that I can't figure out. I have created .STL's of ...
115 views

### Finding the tangents of the function in each mesh

I have a 2D graphic which contains a table of curves within a circular region. ...
57 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 ...
39 views

### Uneven distribution of nodes by ToElementMesh[]

We are using FEM package to generate mesh in a circular sector. Somehow mesh becomes dense in upper right corner. Is there any way to circumvent this uneven distribution? ...
77 views

### Colorize mesh according to the nodepoint colors

Given a set p of points (2D), each with a unique color c, I can mesh these points easily ...
592 views

### Smoothing 3D contours as post processing

Context Following this question (and great answer!), It would be nice to have a function which also smooths 3D contours plots once they have been done. There are various solutions which involve ...
6k views

### Creating a 2D meshing algorithm in Mathematica

As what is proving to be a difficult, but entertaining task, I am attempting to adapt a 2D meshing algorithm created for MATLAB and port it to Mathematica. I understand meshing functions already exist ...
343 views

### Can one use MeshRefinementFunction to obtain a nonobtuse triangulation?

I have a planar convex polygonal region Rc. I would like to triangulate it such that every triangle is nonobtuse. I was hoping that the ...
72 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: ...
137 views

### ToElementMesh of Region with Hole

When I try to mesh the following region it fails. Why? Is there a workaround? ...
573 views

### Meshing the cow

As a simple example for applying stl-files I took "cow" out of MMA example data. I'm able to discretize the Graphic without problems ...
87 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: ...
186 views

### Point relaxation inside of Chromaticity Plot 3D

I'm trying out the new ChromaticityPlot3D function in Mathematica and noticed I can extract the mesh of the output graph using ...
252 views

### How to create “Volumemesh” from closed “surfacemesh”?

Given a surface region (MesgRegion netz2D), for example ...