简体   繁体   中英

How to create unstructured 2D meshes from CAD files in python

I'm working on a finite differences code to solve 2D problems. I want to be able to solve complex geometries written as STEP or IGES files. However I don't know how to read and mesh this kind of files.

While I know that there are free and independent meshing applications, I want my code to be self-contained. Is there a way to achieve this on python?

You might be interested in GMSH API . GMSH is well-known for a while as a free open-source mesher, and recently (by relative means), they introduced an API for C,C++, Python, and Julia.

At first, a simple usage of Top level functions GMSH::open and Mesh function GMSH::generate(2) can get you started.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM