-
Notifications
You must be signed in to change notification settings - Fork 12
Description
We have a few new workflows for getting to DAGMC geometry
export_dagmc_h5m_file previously used gmsh to make a 2d and optionally conformal 3d surface mesh
we can also make 2d meshes using a direct meshing approach in cadquery. This is good as it offers a low dependency route to making dagmc files (gmsh is not need)
we can also make 2d and conformal 3d meshes using the assembly mesh plugin with gmsh. This is good as it offers f flexibility over the mesh parameters (via gmsh api)
There are quite a few options now so I'm thinking we need to rethink the API or the break down of tasks
what Cad-to-dagmc does quite well:
- the piping of mesh data (vertices, nodes, faces) into a dagmc using pymoab. Basically this function vertices_to_h5m and the pymoab infrastructure is reasonable
What cad-to-dagmc doesn't do very well:
-
It tries to wrap gmsh, this masks lots of meshing options from the user. This PR is a step in the direction of improving upon that but using the assembly mesher to expose all the gmsh meshing options to the user
-
Another thing it doesn't do well is wrapping the cadquery direct mesher as it does not export the angular tolerance or to the user. See this line
cad_to_dagmc/src/cad_to_dagmc/core.py
Line 886 in 71e4d06
cq_mesh = assembly.toMesh(imprint, tolerance=0.1, angular_tolerance=0.1)
I'm am thinking we could end up with a route that goes from cadquery to dagmc with only cadquery + pymoab and provides 2d surface geometries
I'm am thinking we could end up with a route that goes from cadquery to dagmc with cadquery + pymoab + gmsh and provides 2d surface geometries and conformal 3d surface geometries.
blockers:
-
Perhaps there are several areas of code that we remove (such as building a CadToDagmc class) as we can make use of cadquery assembly once that has materials I think it would be a good time to look at that again.
-
Pymoab is not on pypi yet, this would really help with simplifying the pip install. pep508 prevents us using the extra infex wheel or the repo to pip install from.
options
perhaps we should replace export_dagmc_h5m_file with two functions
one called export_dagmc_h5m_file_with_cadquery_mesher
one called export_dagmc_h5m_file_with_gmsh
as they both have slightly different arguments
or perhaps we could make use of kwargs in the function for arguments that are not needed by both gmsh and cq routes (tolerance, angular_tolerance, min/max mesh size)
tagging @jmwright for your info