20 uint64_t max_boundary_id = 0;
21 for (
const auto&
id : globl_unique_bndry_ids)
22 max_boundary_id = std::max(
id,max_boundary_id);
24 Chi::log.
Log() <<
"Max boundary id identified: " << max_boundary_id;
26 for (
int bndry=0; bndry<(max_boundary_id+1); ++bndry)
31 auto& bndry_vals = bndry_info.second;
33 switch (bndry_info.first)
38 Chi::log.
Log() <<
"Boundary " << bndry <<
" set to reflecting.";
43 if (bndry_vals.size()!=3)
44 throw std::logic_error(std::string(__PRETTY_FUNCTION__) +
45 " Robin needs 3 values in bndry vals.");
47 Chi::log.
Log() <<
"Boundary " << bndry <<
" set to robin.";
53 std::vector<double> a_values(ng, 0.25);
54 std::vector<double> b_values(ng, 0.5);
55 std::vector<double> f_values(ng, 0.0);
57 {a_values,b_values,f_values}});
58 Chi::log.
Log() <<
"Boundary " << bndry <<
" set to vacuum.";
63 if (bndry_vals.size()!=3)
64 throw std::logic_error(std::string(__PRETTY_FUNCTION__) +
65 " Neumann needs 3 values in bndry vals.");
67 Chi::log.
Log() <<
"Boundary " << bndry <<
" set to neumann.";
75 std::vector<double> a_values(ng, 0.25);
76 std::vector<double> b_values(ng, 0.5);
77 std::vector<double> f_values(ng, 0.0);
80 <<
"No boundary preference found for boundary index " << bndry
81 <<
"Vacuum boundary added as default.";
LogStream Log(LOG_LVL level=LOG_0)
BoundaryPreferences boundary_preferences_
std::vector< Boundary > boundaries_
std::pair< BoundaryType, std::array< std::vector< double >, 3 > > BoundaryInfo
void Set_BCs(const std::vector< uint64_t > &globl_unique_bndry_ids)