https://mooseframework.inl.gov
SurfaceSubdomainsDelaunayRemesher.h
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #pragma once
11 
13 #include "LevelSetMeshingHelper.h"
14 
15 #include "libmesh/meshfree_interpolation.h"
16 #include "libmesh/unstructured_mesh.h"
17 
23 {
24 public:
26 
28 
29  virtual std::unique_ptr<MeshBase> generate() override;
30 
31 protected:
33  std::unique_ptr<MeshBase> & _input;
34 
36  std::vector<std::vector<SubdomainName>> _subdomain_names;
37 
39  unsigned int _num_groups;
40 
42  const std::vector<std::vector<BoundaryName>> _hole_boundary_names;
43 
45  std::vector<unsigned int> _interpolate_boundaries;
46 
48  std::vector<Real> _desired_areas;
49 
58  std::unique_ptr<UnstructuredMesh>
59  General2DDelaunay(UnstructuredMesh & mesh_2d,
60  std::vector<std::unique_ptr<UnstructuredMesh>> & hole_meshes_2d,
61  unsigned int group_i);
62 };
Base class for Delaunay mesh generators applied to a surface.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
virtual std::unique_ptr< MeshBase > generate() override
Generate / modify the mesh.
std::unique_ptr< UnstructuredMesh > General2DDelaunay(UnstructuredMesh &mesh_2d, std::vector< std::unique_ptr< UnstructuredMesh >> &hole_meshes_2d, unsigned int group_i)
Generate a 2D mesh using Delaunay triangulation based on the input 2D surface mesh and the 2D hole me...
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
Helper class to define, parameterize and create a level set function used in meshing, often to correct the position of nodes on a surface.
unsigned int _num_groups
Number of groups of subdomains, also number of times we will call the Delaunay generator.
const std::vector< std::vector< BoundaryName > > _hole_boundary_names
The edge boundaries delineating holes.
std::vector< Real > _desired_areas
Target areas for the triangulation for each group of surface subdomains.
SurfaceSubdomainsDelaunayRemesher(const InputParameters &parameters)
std::vector< std::vector< SubdomainName > > _subdomain_names
The subdomains to be converted to a 2D mesh.
std::vector< unsigned int > _interpolate_boundaries
Number of points added to boundaries around each group of surface subdomains.
std::unique_ptr< MeshBase > & _input
The input mesh name.
Class to remesh surface subdomains using a triangle mesh inside the subdomain boundaries.