writeMesh (write mesh to inp, bdf, and msh files)

Versión 1.11 (2,27 MB) por Jiexian Ma
Write MATLAB 2D or 3D finite element mesh to popular mesh file formats (for software Abaqus, Nastran, COMSOL, Gmsh)
34 Descargas
Actualizado 6 sep 2025
writeMesh is a MATLAB project for writing MATLAB finite element mesh to inp, bdf, and msh files. writeMesh is a part of Im2mesh package. Tested in MATLAB R2017b.
writeMesh supports mesh with single or multiple phases. Note that phase is also known as part, domain, or physical surface. In finite element modeling of composite materials, each phase in the mesh represents a distinct material component.
writeMesh woks for 2D mesh (triangular and quadrilateral); also works for 3D mesh (tetrahedral and hexahedral).
Mesh file formats
  • inp file (Abaqus)
  • bdf file (Nastran bulk data, compatible with COMSOL)
  • msh file (Gmsh mesh file format)
  • For other formats, you can import the generated msh file into software Gmsh and then export.
How to start
You could go through the README file and the examples.
Examples are live script mlx files (demo01.mlx ~ demo09.mlx). If you find some text in the mlx file is missing, read the html file instead. Examples are also available as html files in the folder "demo_html".
Examples:
  • demo01 - Triangular mesh with single phase
  • demo02 - Triangular mesh with multiple phases
  • demo03 - Quadrilateral mesh
  • demo04 - 2D Mesh with quadratic elements
  • demo05 - Node sets at the boundary and interface when writing inp files
  • demo06 - Select formats when writing inp files
  • demo07 - Tetrahedral mesh
  • demo08 - Hexahedral mesh
  • demo09 - Set tolerance when searching boundary node set
  • inp_example1 - Format #1 of inp file
  • inp_example2 - Format #2 of inp file
  • inp_example3 - Format #3 of inp file
Acknowledgments
Great thanks Dr. Yang Lu for providing valuable suggestions.

Citar como

The development of writeMesh is nontrivial. If you use writeMesh for your project, please cite Im2mesh package as follows.

Ma, Jiexian, and Yuanyuan Li. Im2mesh: A MATLAB/Octave Package for Generating Finite Element Mesh Based on 2D Multi-Phase Image. Zenodo, 2025, https://doi.org/10.5281/ZENODO.14847059.

Ver más estilos
Compatibilidad con la versión de MATLAB
Se creó con R2021b
Compatible con cualquier versión desde R2017b
Compatibilidad con las plataformas
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Versión Publicado Notas de la versión
1.11

See release notes for this release on GitHub: https://github.com/mjx888/writeMesh/releases/tag/v1.11

1.02

See release notes for this release on GitHub: https://github.com/mjx888/writeMesh/releases/tag/v1.02

1.00

See release notes for this release on GitHub: https://github.com/mjx888/writeMesh/releases/tag/v1.00

0.9.1

See release notes for this release on GitHub: https://github.com/mjx888/writeMesh/releases/tag/v0.9.1

0.9.0

See release notes for this release on GitHub: https://github.com/mjx888/writeMesh/releases/tag/v0.9.0

0.8.2

See release notes for this release on GitHub: https://github.com/mjx888/writeMesh/releases/tag/v0.8.2

0.8

Para consultar o notificar algún problema sobre este complemento de GitHub, visite el repositorio de GitHub.
Para consultar o notificar algún problema sobre este complemento de GitHub, visite el repositorio de GitHub.