forked from idaholab/moose
-
Notifications
You must be signed in to change notification settings - Fork 0
/
BreakMeshByBlockGenerator.h
45 lines (34 loc) · 1.27 KB
/
BreakMeshByBlockGenerator.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
//* This file is part of the MOOSE framework
//* https://www.mooseframework.org
//*
//* All rights reserved, see COPYRIGHT for full restrictions
//* https://github.com/idaholab/moose/blob/master/COPYRIGHT
//*
//* Licensed under LGPL 2.1, please see LICENSE for details
//* https://www.gnu.org/licenses/lgpl-2.1.html
#pragma once
#include "BreakMeshByBlockGeneratorBase.h"
#include <unordered_set>
class BreakMeshByBlockGenerator;
template <>
InputParameters validParams<BreakMeshByBlockGenerator>();
class BreakMeshByBlockGenerator : public BreakMeshByBlockGeneratorBase
{
public:
static InputParameters validParams();
BreakMeshByBlockGenerator(const InputParameters & parameters);
std::unique_ptr<MeshBase> generate() override;
protected:
int blockRestricteElementSubdomainID(const Elem * elem);
std::unique_ptr<MeshBase> & _input;
std::vector<SubdomainID> _block;
std::unordered_set<SubdomainID> _block_set;
const bool _block_restricted;
const bool _create_transition_boundary;
private:
/// generate the new boundary interface
void addInterfaceBoundary(MeshBase & mesh);
std::set<std::pair<subdomain_id_type, subdomain_id_type>> _neighboring_block_list;
std::map<std::pair<int, int>, std::set<std::pair<dof_id_type, unsigned int>>>
_new_boundary_sides_map;
};