Questions tagged [mesh-generation]

The generation of a set of interconnected geometric objects that approximate a desired domain or region in euclidean space.

Filter by
Sorted by
Tagged with
0
votes
1answer
143 views

Gmsh for .inp file

How do I get an .inp file from Gmsh? I need to create a simple geometry and mesh it and define the boundary conditions in Gmsh and export it as an ...
0
votes
0answers
21 views

Hi I am trying to model a 2D Lug angle using Gmsh 4.6. How can I combine transfinite quad and regular full quad meshes in the following geo file?

I need transfinite mesh a small section of the bolt hole to insert a crack. However, The transfinite mesh and regular full quad mesh seem being incompatible and throwing errors. How can I combine ...
2
votes
3answers
138 views

Flux sign and face normal confusion in finite volume method

I implemented a solver for the 2D steady-state heat equation (without heat generation and homogeneous material) $\nabla. (k\nabla T) = 0$, using finite volume method, however, I am having some ...
2
votes
3answers
164 views

For traditional FEM and FVM, why can't we use mesh to represent geometry and use the mesh which represent the geometry to do the computation directly?

Isogeometric analysis [1] has the advantage of integrating geometric and mesh models using NURBS or Spline. At the same time, I would like to ask a question to my friends: for traditional FEM and FVM, ...
4
votes
4answers
153 views

Can the mesh generation methods in FVM and FEM be totally based on the knowledge of the mesh generation theory in computer graphics?

The main references of mesh generation methods in computer graphics (CG) I found are discrete Differential Geometry [1] and a famous book "Polygon Mesh Processing" [2], while the "...
2
votes
2answers
615 views

Combined translational and rotational meshing in gmsh

For a flow simulation I am trying to reproduce a specific screw element design for an intermeshing co-rotating twin-screw extruder. I am using gmsh (v2.16) where the element is made from a 2D surface ...
0
votes
0answers
44 views

Surface mesh from labeled 3D points

I'm trying to figure out how to create a surface mesh from a set of labeled 3D points. The 3D object could be something like part of a cave system or asteroid where there would be parts of the surface ...
3
votes
1answer
126 views

Mesh with constraints

Is it possible to construct a constrained tetrahedral mesh of a domain using Tetgen or similar software? What I mean by constrained is that there are some nodes or edges that are not free but are ...
1
vote
1answer
95 views

Partial differential equation FEM application

I have a PDE which looks like Helmholtz wave equation on one dimensional domain. $$\dfrac{d^2u(x)}{dx^2}+\pi^2u(x)=f(x)$$ where $-\infty <x<\infty $ Also, $f(x)= 1$ for $-0.25<x<0.25$, I ...
0
votes
0answers
31 views

Determining the voxels between two boundary surfaces

I am working on human brain tACS simulations where I have the models of the skin, skull, csf, brain and ventricles in STL format. The shape does not matter and there are no intersections. I want to ...
0
votes
0answers
37 views

Adding a boundary surface on a STL model in Gmsh

Background info I want to run brain simulations with models from the PHM repository (not relevant to the problem but suits the narrative) which are shipped in STL format. The meshes of the STL have ...
2
votes
1answer
63 views

Mesh partition quality

I am working on static FE mesh partitioning and in order to achieve a good quality partitioning I want to know how to drecrease interprocessor communication by increasing the connectivity of elements ...
0
votes
1answer
921 views

Quadtree type Grid

I would like to code for a quadtree type meshing but don't know how to do. If anyone can help or can share any starting code?
0
votes
1answer
43 views

Why addCylinder function not respecting the given coordinates?

I tried to generate 3 very simple cylinders, each other connected to it end, however the cylinder get connected to an unexistent point in space as the image shows: It was supposed to each segment be ...
0
votes
1answer
65 views

Creating a mesh around an 1-D line to form a 2-D object

Given the following code, how can I perform a mesh generation around the line, to make a 2D form in GMSH API? Extrude or Mirror ...
3
votes
2answers
207 views

Minimum number of elements (mesh size) for electromagnetic simulation

Does someone have a reference for the minimum number of elements (or maximum mesh size) for electromagnetic simulations where a mathematical or numerical explanation is given? I have found several ...
1
vote
2answers
87 views

What are the alternatives for ABAQUS in generating an *.inp file from a CAD model

ABAQUS gives a .inp file (in pre-processing stage) where the information with regard to the preprocessed model is defined, information such as geometry, mesh type, number of elements, boundary ...
3
votes
2answers
179 views

Why FVM can handle unstructured meshes while FDM cannot?

How come Finite Volume Method(FVM) handle the unstructured meshes and Finite difference Method cannot, whereas in FVM to approximate the fluxes at the boundary we use the central differencing? My ...
2
votes
2answers
84 views

How to find out the difference between a structured and unstructured mesh using the file containing the mesh information?

I have two different mesh files (both are .inp files obtained from Abaqus) that represent the exact same geometries with the same boundary conditions, etc. The only difference is that one of them is ...
1
vote
1answer
48 views

Filling a volume with generalised polyhedra

Given a volume (say, some polyhedron), I need to fill it with smaller polyhedra, such that the space is filled as much as possible. The constraints and relaxations are: (0) For a computation ...
5
votes
2answers
2k views

Minimal surface solution in Python

Note: this question was also posted in StackOverflow and math.stackexchange. I have a set of 3D points defining a 3D contour, as shown below. The points in this contour lie in their best-fit plane ...
1
vote
3answers
741 views

Create mesh for complicated 3D object for finite element analysis

I see images of steel connections, concrete dams, and other complicated 3D objects in papers which finite element analysis has been performed on them. My questions are: How these objects are created ...
1
vote
1answer
47 views

stretch elliptic mesh to fit a circle

I've generated a 2D O-mesh around an airfoil. Unfortunately, the mesh O shape is not a perfect circle as you can see in the figure below (in the figure I plotted only the mesh nodes in blue). The red ...
2
votes
1answer
86 views

Gmsh meshes flat faces incorrectly for cylindrical faces

I have some C++ code that generates meshes from step files and then analyses these meshes for visibility of the faces from different viewing directions. I currently use CGAL but I would like to switch ...
3
votes
1answer
594 views

Is it possible to remesh with gmsh?

I am currently working on remeshers for my simulations (academic purpose) and I try to find a method to remesh previous meshes using Gmsh. The first mesh (normalMesh.msh) was created using a .geo file ...
3
votes
1answer
125 views

Single nodes after mpmetis partitioning

I was checking partitioning capabilities of Metis (mpmetis) when I noticed, that it leaves two single nodes. I have marked them in red Have you seen something similar or maybe it is my mistake? The ...
1
vote
0answers
123 views

Duplicate Surface Meshes in different Gmsh files

My objective is to get a conformal surface mesh between two geometries meshed independently in different files. By example, I can start with a simple cube in one .geo file and mesh this geometry. ...
2
votes
0answers
40 views

Isosurface extraction when you know the derivatives

I have a complicated equation that defines a shape in 3D, and I would like to generate a surface mesh. The shape is defined by an isosurface, i.e. the function is positive inside the shape and ...
0
votes
1answer
81 views

Comparing the following mesh grids for a star-shaped plate

Between these four different meshes for the same shape, compare them whilst considering the different results for displacement and stress. Moreover, the difference in computational cost and accuracy ...
8
votes
2answers
206 views

How many cells/elements do I need?

I'm relatively new in the CFD modelling and I'm making a VOF model of a rectangular box ($l \times w \times h = 120\times 80 \times8$ m) with an inlet ($w\times h = 10\times 8$) at the long side. ...
2
votes
1answer
3k views

Creating a proper quad-mesh in GMSH for an “I”-shaped geometry

I'm trying to make a 2-D quad-only mesh of an "I"-shaped cross-section, with elements of size 5. So far I've managed to make it quad only, but some elements are very distorted when they shouldn't be. ...
1
vote
1answer
194 views

Is there any fundamental difference between meshing for FEM, FVM and FDM?

I am a novice to the field of computational science and have just started studying the FDM and FEM (haven't started on FVM yet). While trying the understand the subject I got this question and trying ...
4
votes
2answers
3k views

Creating 3D Mesh from stl files with gmsh

After long hours of searching for an answer I thought it might be better to ask the community. The problem I have is that I need to convert STL files to mesh files. I know that I therefore need to ...
1
vote
0answers
73 views

Metis: how to use and tutorial recommendation

I am new to METIS and trying to use it in my fortran code. I read the manual online. But still, I am not sure about how to implement it my code. I tried the test cases in the graphs directory. For ...
4
votes
1answer
69 views

Definition of Lagrange nodes in Gmsh

When gmsh uses higher-order tetrahedral elements, there is an underlying Lagrange basis used to specify the map from reference space to the element. I'm trying to load a gmsh mesh of 3rd degree ...
1
vote
1answer
435 views

Can TETGEN generate triangulation of a 2D point set?

I would like to link my Fortran 90 application to a library which would give me Delaunay triangulation (for a 2D set of points) and tetrahedralization (for a 3D set of points). As suggested in Fastest ...
1
vote
1answer
1k views

How can I coarsen a mesh in Gmsh when 'Mesh options' include 'Refine by splitting' but nothing about coarsening?

I am new to Gmsh and I am having trouble creating a circle with a coarse mesh. I use Geometry->Elementary entities->Add->Circle to create the geometry ...
0
votes
1answer
239 views

Load the mesh file with boundary marks

I'm want to load a mesh from a file, generated by triangle, and I want to use the boundary marks of its nodes (boundary marks of the file). It is possible? Also, I can change the mesh generator (or ...
1
vote
1answer
252 views

How to generate a face list from vertices?

I have a little background in writing toy finite volume CFD codes. In 2D Cartesian scenarios, I typically take $x_{\min}$, $x_{\max}$, $y_{\min}$, $y_{\max}$, and the number of points in $x$ and $y$ ...
3
votes
0answers
522 views

Gmsh for 3D volume with inclusions [closed]

In an attempt to create three-dimensional volumes with inclusions in Gmsh I stumble upon a problem which was non-existent in the two-dimensional case. I'm using the OpenCASCADE geometry kernel ...
3
votes
1answer
263 views

Is there any open-source code for a hybrid 2D mesh (triangles and quadrilaterals)?

The question is pretty much the title. Note that I have lots of experience using open-source meshing tool, e.g. Gmsh and OpenFoam blockMesh & snappyHexMesh. Nevertheless, I have no idea on how to ...
5
votes
2answers
506 views

Unstructured mesh vs hybrid structured/unstructured for numerical simulations

While answering one of the questions on meshing process, I encountered a lack of understanding on my end for the comparison of the mesh quality. First, consider an unstructured mesh created in GMSH ...
0
votes
1answer
651 views

Connectivity matrix in Finite Element Method in Triangular elements

Imagine a simple triangular base mesh in finite element method with an unknown number of elements (varying by the user). How can connectivity matrix be coded to be generated automatically?
17
votes
7answers
1k views

Scripted Mesh Generation Software

I'm looking for a mesh generation software that is free and open source, provides a sane scripting interface for domain specification, works for complex geometries, can generate 2D and 3D meshes, ...
4
votes
2answers
540 views

3D contour mesh computation

I have the value of a function in three dimensions, $f(x, y, z)$, which varies smoothly. I would like to compute a 3D mesh where $f(x, y, z)$ has a particular value. Are there algorithms to do this? ...
2
votes
1answer
207 views

Mesh generation with mostly the same elements (type/size..)

I'm searching for a way to generate a mesh that consists mostly of the same elements and i mean not only the same type, but the exact same size to ease the FEM-calculation. Is there a particular ...
1
vote
0answers
57 views

Efficient initial identification of solid or liquid domains for a block structured Cartesian grid generation system

INTRO Within the last 5 days I was able to generate a block structured Cartesian grid generation system with a combination of Fortran,C++ and Python. I am running intersection tests of the ...
1
vote
1answer
760 views

A difference running Gmsh in command line and in GUI for 3-D mesh generation [closed]

In Gmsh, I have a test.geo file. The question is: if I run gmsh -3 test.geo in the command line, I get the below error. ...
0
votes
1answer
78 views

Structural mechanics simulation using FLUENT compared to analytical solution

This is a continuation of my previous post, 1D analytical solution vs FEM solution for a bar under compression. For some reason, I cannot comment in it. The analytical solution to the 1-D static ...
0
votes
1answer
106 views

Gmsh exporting wrong mesh DATA [closed]

so hopefully I'll be using gmsh to make meshes out of 2-D cross sections with o thickness. I tried to make a structured mesh with quad elements of a rectangular ...