HomerReid / scuff-em

A comprehensive and full-featured computational physics suite for boundary-element analysis of electromagnetic scattering, fluctuation-induced phenomena (Casimir forces and radiative heat transfer), nanophotonics, RF device engineering, electrostatics, and more. Includes a core library with C++ and python APIs as well as many command-line applications.
http://www.homerreid.com/scuff-em
GNU General Public License v2.0
126 stars 50 forks source link

Gmsh .msh file format changed, cannot read the new .msh file #184

Open WenjieYao opened 5 years ago

WenjieYao commented 5 years ago

The .msh file format has changed since GMSH 4.0: GMSH File Format This new .msh file generated by gmsh cannot be read by current scuff-em. Better update the read .msh file to support the new file format.

HomerReid commented 5 years ago

Thanks for pointing this out. I remember back when I needed to update my reader for GMSH version-1 mesh files to accommodate version-2 files as well. It seems this process might never end if we attempted to guarantee compatibility with the latest versions of the GMSH format. Of course one workaround that always works in practice is simply to ask GMSH to convert from one format to another (something which can also be done in python using with the meshio module), but certainly you're right that it would be nice to avoid this extra layer of hassle for users.

However, I am going to punt on adding this feature to the C++ code base, because my main focus at present is fleshing out the python module to be fully powerful and feature-rich, and in python-driven SCUFF calculations this issue does not arise (or, it does, but is solved by the aforementioned meshio module). Let's keep this issue open for now, and when the native-python-meshing interface is ready to go I will ask you to revisit this issue in that new context and close it then if you are satisfied with the solution.