How to import a Gmsh-generated quad mesh geo file into FEniCS?

Hello, how can I import a quad mesh geo file generated by Gmsh into FEniCS? This is the command I am using, but the generated file lacks the facet_region (I have checked that the Physical Curve in the geo file exists)

gmsh trapezoid.geo -format msh2 -2
dolfin-convert trapezoid.msh trapezoid.xml


Hi, I think that legacy dolfin only supports triangular meshes. See this post

I have a question, if I install dolfinx on top of the existing dolfin, will it overwrite dolfin? I don’t want to affect the use of dolfin.

Then I would recommend using a Docker container for dolfinx. This way all libraries are localized in this container

I installed dolfin through conda, if I continue to install dolfinx, will it affect the old dolfin?

Can you create a new conda environment? In that way, you’ll have an environment with dolfin, and a separate one with dolfinx.

I am not sure if it is possible to create two conda environments in the Ubuntu system, do you know?

I am not a conda user, but Managing environments — conda 24.5.1.dev20 documentation has commands to create conda environments, and I don’t see why ubuntu (or any other OS) should disable that functionality.

Thanks for your reply!

The Legacy version does not support quad mesh. dolfinx is a good aternative.