Questions tagged [mesh]

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

Filter by
Sorted by
Tagged with
3 votes
1 answer
75 views

Is it possible to solve a differential equation with a user-defined variable mesh in NDSolve?

For some differential equations, its solution may evolve to a cusp, for example, singular behavior. One may want to introduce additional mesh points near the cusp to accurately follow the solution ...
user avatar
8 votes
3 answers
325 views

How to generate a mesh in an area with curves inside

I would like to know how to generate a mesh inside an area, and be able to find the original curve outline inside the area from the mesh. For example: There is a rectangle inside which there is a ...
user avatar
  • 83
4 votes
2 answers
151 views

For "RegionPlot", how to fill lines, points, or grids in different areas?

For "RegionPlot", how to fill lines, points, or grids in different areas? I have tried "Mesh", but it fills all region in same mesh. I want to get the result just like this picture,...
user avatar
  • 41
8 votes
1 answer
212 views

Quarter a given triangular meshregion

For a given , examplary simple, triangular meshregion ...
user avatar
8 votes
2 answers
128 views

How to do boolean operations between a large amount of regions

I want to do boolean operations between a large amount of regions. For convenience, I consider a simplified problem. The problem is as follows, digging out a large number of small hemispheres on the ...
user avatar
  • 165
5 votes
1 answer
84 views

How to detect neighbours of a MeshRegion?

For a given triangle meshRegion(examplary) \[CapitalDelta]reg ...
user avatar
9 votes
2 answers
233 views

Controlling the discretization of a Tube around a ParametricPlot3D

I am playing around with using Tube as an option under PlotStyle for a ParametricPlot3D ...
user avatar
1 vote
0 answers
49 views

Problem with Mesh in Contour Plot

So I was using ContourPlot to plot an equation and I want to highlight the sampling points of the contour plot. So as written in the Mathematica documentation, I tried using ...
user avatar
14 votes
2 answers
221 views

Stretching a mesh

Imagine I want to stretch a mesh with a 'rubberband-type' effect. That is, upon and elastic stretch from both side edges, the mesh centres simply scale as follows where the points are seeds for ...
user avatar
  • 4,138
4 votes
3 answers
154 views

Mesh generation for a discrete set of points in ListContourPlot?

Given a (possibly disjoint) region, defined by a discrete set of points, how can I use ListContourPlot[] together with Mesh to ...
user avatar
1 vote
2 answers
81 views

ArrayPlot3D mesh customization

I am trying to visualize a few 2D arrays in ArraryPlot3D. I think I have made it work, however, there is a minor detail on the mesh of the plot I want to improve. For example, this is what the current ...
user avatar
  • 53
6 votes
4 answers
196 views

How to order the coordinates generated by ToBoundaryMesh counterclockwise?

The following code works for polygons. A square 4x4 is tried here: ...
user avatar
5 votes
1 answer
141 views

How to combine several surfaces into a solid and compute its volume?

plot1 is taken from the BSplineSurface document. I add two Disk ...
user avatar
0 votes
1 answer
88 views

Coordinates of mesh generated by Mathematica-FEM

MeshCoordinates function yields more nodal coordinates than expected. Can I extract the coordinates of vertices only. Here is an example of a square region with a course mesh to explain the problem. I ...
user avatar
3 votes
1 answer
82 views

The element mesh has insufficient quality

I am quite new at FEM. I was trying to create a triangular mesh of a rectangular region. I wanted to do something very basic: Discretize the domain using squares and then subdivide each square into ...
user avatar
  • 117
0 votes
1 answer
71 views

How to get mesh-information from `Plot3D`

In a simple example Plot3D shows a triangular mesh: pic = Plot3D[Sin[x] Sin[y], {x, 0, 1}, {y, 0, 1}, Mesh -> All] I know ...
user avatar
0 votes
1 answer
101 views

2nd Order Regular Triangular Mesh on Rectangular domain

I want to create a mesh of 6 noded triangular elements ( 2 nd order element) on a rectangular domain as shown. (0,0) can be seen at left bottom corner with the whole mesh in the positive quadrant. I ...
user avatar
12 votes
1 answer
198 views

Smooth refinement for a merged 2D mesh

Thanks to @user21 response and FEMAddOns I have been able to create a multi-region mesh. I am trying to make a smooth transitional mesh refinement with respect to a ...
user avatar
  • 1,554
3 votes
1 answer
104 views

How to visualize an externally calculated FEM solution

I am trying to make animations of results of a FEM solver from an external model. Basically, I am pre- and post-processing in MMA. As a simple example, let's say I have a mesh such as: ...
user avatar
  • 1,554
3 votes
1 answer
83 views

Finite Element Mesh generation with varying element order

I am trying to do a finiteElement Simulation of the Sun - Earth system for some modified gravity model in cylindrical coordinates. I find that 2nd order elements approximate the gravitational field ...
user avatar
  • 75
4 votes
2 answers
175 views

Refine a quadrilateral mesh

I have created the following mesh for a slope stability problem: ...
user avatar
  • 2,760
0 votes
0 answers
29 views

Meshgrid Visible in RegionPlot when Saving Figure as PDF [duplicate]

I have a region and a contour plot. My goal is to superimpose them to compare them. So, I used the Opacity[] on the region plot function but when I save the figure ...
user avatar
0 votes
0 answers
69 views

Error calculating RegionDifference of two disk sectors

I am trying to implement an exercise that should be straightforward. I have two sectors of disks (in blue and orange below) with an overlap. I am trying to calculate their Region Difference, but it ...
user avatar
  • 473
2 votes
1 answer
99 views

RegionIntersection for big mesh, AnatomyData["skin","MeshRegion"]

I want to cut a human in half. Say skin=Entity["AnatomicalStructure","Skin"]. So, ...
user avatar
  • 2,648
3 votes
4 answers
252 views

How can I create a mesh of closed shape?

I have this hexagon that defined according to these points ...
user avatar
6 votes
2 answers
113 views

How to just set MeshStyle but don't change the BoundaryStyle?

This is my code: ...
user avatar
  • 23.2k
2 votes
1 answer
56 views

Disappearing level curves on ParametricPlot3D

The mesh of level curves on ParametricPlot3D[] does not work for some functions. For many functions it works normally, e.g.: ...
user avatar
  • 365
0 votes
0 answers
50 views

TriangulateMesh failed at this kind mesh

mesh = ImageMesh@ImageResize[imgB, 512] TriangulateMesh or DiscreteRegion failed at mesh,...
user avatar
  • 8,085
3 votes
1 answer
78 views

FEM in 3D: assigning proper mesh for NDSolveValue

I am trying to compute electric potential in a simple 3D geometry containing (in a simplied version) 3 conductive rings (2 outer rings at 0 V, and the inner at 1 V) in different planes and I don't get ...
user avatar
  • 33
0 votes
0 answers
49 views

Umbilic torus - Export to stl format produces bad mesh in MeshLab

I am interested to 3d print the following structure from this link. I assigned FaceForm and Thickness to check check for orientations and to give some thickness for printing. The resulting stl is ...
user avatar
1 vote
2 answers
64 views

I need to make a Hexolnikov grid from a 2-D array AND in the row and column refer to the corresponding hexagon by painting over it

I'm new to mathematika. I need to access the hexagon by the index of the two-dimensional array that I set. This hexagon needs to be painted over, I was able to find how to set the grid only with a one-...
user avatar
5 votes
1 answer
117 views

Avoiding Concave Polygons

In a vertex model, vertices in a lattice are modelled by a set of ODEs. A T1 transition is the following: when a certain edge becomes small enough (given a threshold), two cells stop being connected, ...
user avatar
  • 4,138
7 votes
4 answers
619 views

Problem with exporting RegionPlot as PDF

I have the following RegionPlot (which code I don't present since it comes from a long expression): When I right click on it (within the notebook) and try to save ...
user avatar
  • 4,138
3 votes
1 answer
208 views

3D FEM Mesh - Accessing values of individual boundary elements

I have 3D mesh and calculate the heat equation using NDSolve. I want to access the temperature values on the individual boundary elements to solve another problem (...
user avatar
  • 563
7 votes
1 answer
104 views

FEM Mesh - how to get elements belonging to ElementMarker

I want to get a list of all boundary elements belonging to a certain ElementMarker of a boundary mesh. This code creates a simple mesh and allows to inspect the <...
user avatar
  • 563
3 votes
1 answer
87 views

FEM Meshrefinement for 1D Interval and Elements of order 2

I would like to create a 1D mesh of the intervall (-pi/2,pi/2) for solving a DE with FEM, with more elements close to +-1 - these elements should be of order 2, since order 1 elements yield too low ...
user avatar
  • 75
5 votes
1 answer
98 views

3D FEM - How to use element markers for boundary integration

I am having trouble integrating over some curved boundaries and was thinking about using the element markers of the boundary mesh for integration rather than conditionals. Is it possible to use ...
user avatar
  • 563
2 votes
0 answers
150 views

NURBS model from a entire mesh

I have a mesh in STL file format and imported it into Mathematica. data=Import["mesh.stl"]; or ...
user avatar
2 votes
0 answers
95 views

Mesh Control Problem

I am having trouble combining two graphical objects. The problem has to do with controlling mesh lines. The simplest failing example is combining a circle graphics primitive with a RegionPlot. Either ...
user avatar
3 votes
0 answers
79 views

Custom mesh to help with a Fokker Planck eqn (refined rectangular mesh?)

Physicist here, new to SE and fairly new to MMA. I'm looking to solve a Brownian motion problem with inertia (m ≠ 0) and a velocity dependent diffusion coefficient, which in dimensionless units and ...
user avatar
  • 31
0 votes
0 answers
73 views

Solving differential equation system with FEM when the equations depend on the mesh cell size

I am trying to implement Large eddy simulation with FEM for solving air flow simulation using Smagorinsky sub-grid stress model. In order to implement this there is a parameter (filter size) in the ...
user avatar
  • 9
5 votes
2 answers
234 views

Modified Heat Transfer in Fluid Flow

I am trying to simulate Modified Heat Transfer in Fluid Flow (based on Buoyancy-Driven Flow in a Square Cavity ). The modified heat transfer takes the form: with the solid volume fraction: The ...
user avatar
  • 1,624
8 votes
3 answers
304 views

Smoother boundaries between components of segmented image

I'd like to use boundaries between components of a segmented image to create a mesh for finite elements, as described in Mesh for Images for three materials and meshes with multiple regions from 2D ...
user avatar
  • 1,110
1 vote
1 answer
55 views

Two figures in same graph, how to add mesh to figure 1 but not figure 2?

I plot two figures on the same graph. The following code adds mesh to both figures. But how do I add mesh to the first figure only (not to the second figure)? ...
user avatar
  • 39
8 votes
4 answers
646 views

Mesh from Images for three materials

I want to mesh a figure which contains three different materials (organic-based materials and polymers) using Mathematica. Namely: Black color: material A White color: material B Grey color: material ...
user avatar
2 votes
2 answers
214 views

How to create a 2D mesh along a specified path?

I am trying to create a mesh along specific lines connecting specific points. Here I used Subdivide to create n steps along the ...
user avatar
2 votes
2 answers
117 views

Parametric Plot: different coordinates for texture and mesh

I try to create a parametric plot which maps from the complex unit circle to a different region in the complex plane. That works fine but I have one problem: I want to see the images of a mesh with ...
user avatar
4 votes
1 answer
134 views

How to create a 2D mesh and obtain all the coordinates and connectivity

I know this is a really amateur question, but I´m kind of new in here. Though I´ve been trying for the last few days I simply cannot convert a set of points (well actually a region) to a mesh. But ...
user avatar
6 votes
1 answer
153 views

3D FEM Mesh problem - either bad mesh or inaccurate geometry

I am having trouble obtaining a good 3D mesh. I have tried lots of stuff, either resulting in a bad mesh or inaccurate geometry. My geometry consists of a cuboid with a quarter cylinder cut out on a ...
user avatar
  • 563
3 votes
1 answer
116 views

Lighting/Mesh problem after GeometricTransform

This is probably a silly question but... Context I have gathered from this site Functions to draw sets of concentric 3D rings as follows: ...
user avatar
  • 21.7k

1
2 3 4 5
14