Questions tagged [gmsh]

A three-dimensional finite element mesh generator with built-in pre- and post-processing facilities

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

Parametric surface in 3D

I want to create a mesh for a 3D surface with coordinates defined by a parametric function. Is it possible to define this mesh using Gmsh? If it is not possible, what free software do you recommend me?...
-1
votes
1answer
60 views

Generating structured paraboloid using gmsh

I am trying to get the structured mesh as shown in the figure. I have used the transfinite surface and curve to achieve the same. Though I get the structured mesh but I do not know how to do for body-...
0
votes
0answers
34 views

OpenFOAM: Using icoFoam after snappyHexMesh

I am trying to run icoFoam through a geometry made by Gmsh. For meshing, I have used snappyHexMesh. For that I had the geometry made with Gmsh by someone else and converted to a *.stl file. The ...
1
vote
0answers
48 views

How can I improve the accuracy of the calculation of the magnetic field in Gmsh/GetDP?

I need to calculate the magnetic field along a straight line in proximity of an array of 6 magnets. I used the tutorial files "magnets" included in Gmsh and I slightly modified the file in ...
4
votes
2answers
213 views

Meshing surface of a sphere with a subdomain

I am trying to build a triangle mesh of the surface of a sphere which also includes a subdomain defined by a 'polygon'. Here is a successful example (subdomain defined by the red dots): Note that the ...
0
votes
0answers
35 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
1answer
92 views

Going From Blender Structure defined by triangles to full 3D mesh (Using GMSH?)

I currently have created a model airplane in Blender by drawing a closed volume with triangular planes. I want to do a FEM calculation on this object, meaning I need a fine 3D tetrahedral mesh of this ...
1
vote
1answer
65 views

Does 'Recombine' work for this geometry in Gmsh?

I am struggling to recombine the remaining triangular cells into unstructured quadrangular ones in this geometry using Gmsh. Do I need to add auxiliary lines somewhere or do some geometries just don't ...
0
votes
1answer
45 views

Convert existing gmsh mesh from first- to second-order elements?

Is there a way to take an existing gmsh .msh file, and convert it to second-order elements? Specifically, I'm trying to go from 8-point hexahedra (hex8) to 20-point hexahedra (hex20). Ideally, I'd ...
0
votes
1answer
56 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
547 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
1answer
101 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 ...
0
votes
1answer
136 views

Retaining or mapping sets (physical tags) after remeshing a compounded surface/curve in Gmsh?

For my current work, I need to remesh a given geometry with Gmsh (currently trying all Gmsh versions to achieve this) to continue my Abaqus simulations. As can be seen in the image, the geometry has ...
0
votes
0answers
221 views

Heat diffusion simulation in a 3D piston using FENICS

I'm trying to simulate the heat diffusion in a 3D piston. I marked the boundaries on GMSH. I have used a Dirichlet BC of 300 on the top face of piston. But the results look abnormal. There is a ...
0
votes
1answer
523 views

Multi-domain 3D Geometries for MATLAB PDE Toolbox

In principle the PDE Toolbox in MATLAB can handle multi-domain 3D geometries as noted here. This feature and the associated function geometryfromMesh were introduced in MATLAB R2018a. The associated ...
2
votes
1answer
111 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
0answers
127 views

Is it possible to retain sets (physical tags) after remeshing the model in Gmsh?

I am currently working on a remeshing algorithm for Abaqus using Gmsh as part of my Bachelors thesis and I seem to be stuck at some point. I am able to remesh .geo and .msh files using the script ...
3
votes
1answer
1k 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 ...
1
vote
0answers
228 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. ...
4
votes
2answers
5k 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 ...
4
votes
1answer
128 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 ...
0
votes
1answer
286 views

Node re-numbering in 1D mesh GMSH

I'm working with Gmsh to generate 1D meshes of polygon edges. I have noticed that drawing a polygon by "vertices and lines" the program always assigns to the first N nodes of the mesh the coordinates ...
1
vote
1answer
2k 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
551 views

Gmsh: Recombine 2D in script file or command line

I have many STL files and I want to reduce their size, so I use Gmsh in this way: gmsh -2 -bin -format vtk -o file.vtk file.stl -0 It reduces the size from 7 MB ...
4
votes
0answers
755 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 ...
1
vote
1answer
939 views

C++ library unstructured mesh writer to VTK format (or similar)

I am working on a 2D unstructured code in C++. I am using gmsh to generate a 2D unstructured mesh and reading it into my program with a library called ...
2
votes
1answer
4k 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
1k 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
169 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 ...
1
vote
0answers
64 views

surface triangulation to boundary representation

Are there any open source tools available which can take a surface triangulation of mesh volumes and convert them to a boundary representation? I am interested in refining multiple region tetrahedral ...
3
votes
1answer
5k views

Custom Mesh Sizes in GMSH [closed]

I have a simple question today. I am new to GMSH and I am currently learning how to use the software program. I am using GMSH 3.0.4. What I am looking to do is to set a different mesh size for ...
2
votes
2answers
691 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
1answer
1k views

what is the meaning of mesh smoothing steps in Gmsh?

In Gmsh mesh option list ,there is a smoothing concept, what does this mean and what is the effect of its number to the mesh quality?
4
votes
0answers
762 views

Meshing two parts together [closed]

I have two parts, which need to be meshed. One part is located inside another. To simplify the problem, imagine two cubes: one inside another. Geometries are stored in STL files. From CAD point of ...
4
votes
1answer
2k views

Using Gmsh to create a mesh with zero thickness (quad) interface elements

I acknowledge the following post where a similar question is posed and a very nice answer has been provided: Is there a mesh generator that will generate zero thickness elements for interfaces? ...
1
vote
1answer
2k views

Triangular mesh of a 3D surface

I have an irregular grid of points describing this surface (a large subduction fault in South America). The color is depth. Anyway I have 3D coordinates (lon,lat,depth) at irregular intervals. I'm ...
0
votes
1answer
3k views

Convert STL file to other formats like .msh (Gmsh) and .inp (Abaqus)

After reading some stuff on STL files, I realized that they do no contain information about a mesh (connectivity for instance) , but they represent the surface geometry of the part to be meshed. ...
2
votes
1answer
2k views

Gmsh - dividing a plane surface

How to divide a surface to subdomains, which can be recognized in msh file? Avoiding duplicated nodes is necessary. In general I have geo file which contains definition of smaller and bigger region, ...