23 "the name of the new interface. Cannot be used whit `split_interface=true`");
24 params.
addParam<
bool>(
"split_interface",
26 "If true, it create a "
27 "different interface for each block pair.");
29 "mesh by blocks pairs");
36 _interface_name(getParam<
std::string>(
"interface_name")),
37 _split_interface(getParam<bool>(
"split_interface"))
42 mooseError(
"if split_interface == true, the new interface_name"
43 " cannot be specified by the user. It will be autoamtically assigned");
50 const std::set<boundary_id_type> & currentBoundaryIds =
51 mesh.get_boundary_info().get_boundary_ids();
52 bool freeBoundaryNotFound =
true;
53 boundary_id_type freeId;
54 for (freeId = 0; freeId < std::numeric_limits<boundary_id_type>::max(); freeId++)
56 if (currentBoundaryIds.count(freeId) == 0)
59 freeBoundaryNotFound =
false;
64 if (freeBoundaryNotFound)
65 mooseError(
"Too many boundaries. Maximum limit exceeded!");
72 const subdomain_id_type & masterBlockID,
73 const subdomain_id_type & slaveBlockID)
75 std::string master_block_name = mesh.subdomain_name(masterBlockID);
76 std::string slave_block_name = mesh.subdomain_name(slaveBlockID);
77 if (master_block_name.empty())
78 master_block_name =
"Block" + std::to_string(masterBlockID);
79 if (slave_block_name.empty())
80 slave_block_name =
"Block" + std::to_string(slaveBlockID);
82 return master_block_name +
"_" + slave_block_name;
87 const std::string & boundaryName)
89 _bName_bID_set.insert(std::pair<std::string, int>(boundaryName, boundaryID));
94 const subdomain_id_type & masterBlockID,
95 const subdomain_id_type & slaveBlockID,
96 std::string & boundaryName,
97 boundary_id_type & boundaryID,
98 BoundaryInfo & boundary_info)
108 bool checkBoundaryAlreadyExist =
false;
111 if (b.first.compare(boundaryName) == 0)
113 boundaryID = b.second;
114 checkBoundaryAlreadyExist =
true;
118 if (checkBoundaryAlreadyExist)
128 boundary_info.sideset_name(boundaryID) = boundaryName;