Skip to content

Commit

Permalink
Set gmsh file name in FractureNetwork3d meshing.
Browse files Browse the repository at this point in the history
  • Loading branch information
keileg committed Feb 15, 2019
1 parent 7326c4b commit 5a82464
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/porepy/fracs/fractures.py
Original file line number Diff line number Diff line change
Expand Up @@ -869,7 +869,7 @@ def add(self, f):
f.set_index(0)
self._fractures.append(f)

def mesh(self, mesh_args, subdomains=None, dfn=False, **kwargs):
def mesh(self, mesh_args, subdomains=None, dfn=False, file_name=None, **kwargs):
""" Mesh the fracture network, and generate a mixed-dimensional grid.
The mesh itself is generated by Gmsh.
Expand All @@ -882,6 +882,9 @@ def mesh(self, mesh_args, subdomains=None, dfn=False, **kwargs):
into subdomains. The planes are defined in the same way as a fracture.
dfn (boolean, optional): If True, a DFN mesh (of the network, but not
the surrounding matrix) is created.
file_name (str, optional): Name of file used to communicate with gmsh.
defaults to gmsh_frac_file. The gmsh configuration file will be
file_name.geo, while the mesh is dumped to file_name.msh.
Returns:
GridBucket: Mixed-dimensional mesh.
Expand All @@ -907,7 +910,8 @@ def mesh(self, mesh_args, subdomains=None, dfn=False, **kwargs):
# intersecting lines and polygons
self.split_intersections()

file_name = "gmsh_frac_file"
if file_name is None:
file_name = "gmsh_frac_file"
in_file = file_name + ".geo"
out_file = file_name + ".msh"

Expand Down

0 comments on commit 5a82464

Please sign in to comment.