4#ifndef lethe_utilities_h
5#define lethe_utilities_h
9#include <deal.II/base/conditional_ostream.h>
10#include <deal.II/base/exceptions.h>
11#include <deal.II/base/mpi_remote_point_evaluation.h>
12#include <deal.II/base/parameter_handler.h>
13#include <deal.II/base/patterns.h>
14#include <deal.II/base/point.h>
15#include <deal.II/base/table_handler.h>
16#include <deal.II/base/tensor.h>
18#include <deal.II/dofs/dof_handler.h>
20#include <deal.II/fe/fe_values.h>
22#include <deal.II/numerics/vector_tools.h>
24#include <deal.II/particles/particle_iterator.h>
26#include <boost/archive/text_iarchive.hpp>
27#include <boost/archive/text_oarchive.hpp>
29#include <magic_enum.hpp>
101 table.add_value(
"Variable", variable);
102 table.add_value(
"Min", stats.
min);
103 table.add_value(
"Max", stats.
max);
104 table.add_value(
"Total", stats.
total);
105 table.add_value(
"Average", stats.
average);
137 const std::vector<T> &independent_values,
138 const std::string &independent_column_name,
139 const std::vector<std::vector<double>> &dependent_vector,
140 const std::vector<std::string> &dependent_column_names,
141 const unsigned int display_precision,
142 const bool display_scientific_notation =
false);
173template <
int dim,
typename T>
176 const std::vector<T> &independent_values,
177 const std::string &independent_column_name,
178 const std::vector<Tensor<1, dim>> &dependent_vector,
179 const std::vector<std::string> &dependent_column_names,
180 const unsigned int display_precision,
181 const bool display_scientific_notation =
false);
211template <
int dim,
typename T>
214 const std::vector<T> &independent_values,
215 const std::string &independent_column_name,
216 const std::vector<std::vector<Tensor<1, dim>>> &dependent_vector,
217 const std::vector<std::string> &dependent_column_names,
218 const unsigned int display_precision,
219 const bool display_scientific_notation =
false);
251 const std::vector<Tensor<1, dim>> &independent_vector,
252 const std::vector<std::string> &independent_column_names,
253 const std::vector<Tensor<1, dim>> &dependent_vector,
254 const std::vector<std::string> &dependent_column_names,
255 const unsigned int display_precision,
256 const bool display_scientific_notation =
false);
288 const std::vector<Tensor<1, dim>> &independent_vector,
289 const std::vector<std::string> &independent_column_names,
290 const std::vector<double> &dependent_values,
291 const std::string &dependent_column_name,
292 const unsigned int display_precision,
293 const bool display_scientific_notation =
false);
308 const double property0,
309 const double property1)
311 double property_eq =
phase * property1 + (1 -
phase) * property0;
316 const double property_min = std::min(property0, property1);
317 const double property_max = std::max(property0, property1);
318 if (property_eq < property_min)
320 property_eq = property_min;
322 if (property_eq > property_max)
324 property_eq = property_max;
343[[nodiscard]]
constexpr int
346 return (
static_cast<T
>(0) < val) - (val < static_cast<T>(0));
361clip(
const T &n,
const T &lower,
const T &upper)
363 return std::max(lower, std::min(n, upper));
379[[nodiscard]]
inline double
381 const double property0,
382 const double property1)
391 double property_avg = (property0 + property1) * 0.5;
392 double property_diff = (property0 - property1) * 0.5;
394 double property_eq =
phase * property_diff + property_avg;
420 const std::string &file_description);
436 const std::string &file_name,
437 const std::string &delimiter =
" ");
451 const std::string &file_name,
452 const std::string &delimiter =
" ");
464 std::map<std::string, std::vector<std::string>> &map,
465 const std::string &file_name,
466 const std::string &delimiter =
" ");
501 const std::string &expression,
502 const char delimiter =
'-')
504 pcout << std::string(expression.size() + 1, delimiter) << std::endl;
505 pcout << expression << std::endl;
506 pcout << std::string(expression.size() + 1, delimiter) << std::endl;
526 const std::string &expression,
527 const unsigned int banner_size,
528 const char delimiter =
'-')
530 pcout << std::string(banner_size + 1, delimiter) << std::endl;
531 pcout << expression << std::endl;
532 pcout << std::string(banner_size + 1, delimiter) << std::endl;
548 const std::string &filename,
549 const MPI_Comm &mpi_communicator,
550 const bool serialize_on_rank_zero =
true)
552 unsigned int this_mpi_process(
553 Utilities::MPI::this_mpi_process(mpi_communicator));
555 if (!serialize_on_rank_zero || this_mpi_process == 0)
557 std::ofstream ofile(filename);
558 boost::archive::text_oarchive oa(ofile, boost::archive::no_header);
577 const std::string &filename,
578 const MPI_Comm &mpi_communicator,
579 const bool deserialize_on_rank_zero =
true)
581 unsigned int this_mpi_process(
582 Utilities::MPI::this_mpi_process(mpi_communicator));
584 if (!deserialize_on_rank_zero || this_mpi_process == 0)
586 std::ifstream ifile(filename);
587 boost::archive::text_iarchive ia(ifile, boost::archive::no_header);
603 const std::vector<OutputStructTableHandler> &table_output_structs,
604 const MPI_Comm mpi_communicator)
606 for (
const auto &output_table : table_output_structs)
609 output_table.table_filename,
625 std::vector<OutputStructTableHandler> &table_output_structs,
626 const MPI_Comm mpi_communicator)
628 for (
auto &output_table : table_output_structs)
631 output_table.table_filename,
648 const std::string ¶meter_name);
683 const bool require_subsection_size =
true);
702template <
typename EnumType>
703 requires std::is_enum_v<EnumType>
707 const std::string_view name = magic_enum::enum_name(value);
708 Assert(!name.empty(), ExcInternalError());
709 return std::string(name);
731template <
typename EnumType>
732 requires std::is_enum_v<EnumType>
736 const std::optional<EnumType> value = magic_enum::enum_cast<EnumType>(name);
737 if (!value.has_value())
740 for (
const std::string_view choice : magic_enum::enum_names<EnumType>())
742 if (!choices.empty())
748 "Invalid value \"" + name +
"\" for " +
749 std::string(magic_enum::enum_type_name<EnumType>()) +
750 ". The choices are <" + choices +
">."));
764template <
typename EnumType>
780 const std::string &deprecated_value,
781 const std::string &new_value);
804template <
typename EnumType>
805 requires std::is_enum_v<EnumType>
808 const std::vector<EnumType> &allowed_values = {})
810 const auto is_allowed = [&allowed_values](
const EnumType value) {
811 return allowed_values.empty() ||
812 std::find(allowed_values.begin(), allowed_values.end(), value) !=
813 allowed_values.end();
816 std::string selection;
817 const auto add_choice = [&selection](
const std::string_view choice) {
818 if (!selection.empty())
823 if (allowed_values.empty())
824 for (
const std::string_view name : magic_enum::enum_names<EnumType>())
827 for (
const EnumType value : allowed_values)
830 for (
const auto &[deprecated_name, value] : deprecated_names)
831 if (is_allowed(value))
832 add_choice(deprecated_name);
851template <
typename EnumType>
852 requires std::is_enum_v<EnumType>
885template <
typename EnumType>
886 requires std::is_enum_v<EnumType>
889 const std::string &entry_name,
890 const EnumType default_value,
891 const std::string &description,
893 const std::vector<EnumType> &allowed_values = {})
920template <
typename EnumType>
921 requires std::is_enum_v<EnumType>
925 const std::string ¶meter_name)
927 for (
const auto &[deprecated_name, value] : deprecated_names)
928 if (name == deprecated_name)
954template <
int spacedim>
955inline Tensor<1, spacedim>
958 std::vector<std::string> vector_of_string(
959 Utilities::split_string_list(value_string));
960 std::vector<double> vector_of_double =
961 Utilities::string_to_double(vector_of_string);
963 Assert(vector_of_double.size() == 3 || vector_of_double.size() == 2,
964 ExcMessage(
"Invalid string: " + value_string +
965 ". This should be a two or three dimensional vector "
968 Tensor<1, spacedim> output_tensor;
969 for (
int i = 0; i < spacedim; ++i)
970 output_tensor[i] = vector_of_double[i];
972 return output_tensor;
992 if constexpr (dim == 2)
993 h = std::sqrt(4. * cell_measure / numbers::PI) / fe_degree;
994 else if constexpr (dim == 3)
995 h = std::cbrt(6. * cell_measure / numbers::PI) / fe_degree;
999 ExcMessage(std::string(
1000 "'dim' should have a value of either 2 or 3. Only 2D and 3D simulations "
1001 "are supported.")));
1019 double cell_measure = 0;
1020 for (
const double &JxW : JxW_values)
1021 cell_measure += JxW;
1022 return cell_measure;
1045 const DoFHandler<dim> &dof_handler,
1046 const Quadrature<dim> &cell_quadrature,
1047 const MPI_Comm &mpi_communicator)
1050 FEValues<dim> fe_values(mapping,
1051 dof_handler.get_fe(),
1059 const unsigned int degree = fe_values.get_fe().degree;
1061 for (
const auto &cell : dof_handler.active_cell_iterators())
1063 if (cell->is_locally_owned())
1065 fe_values.reinit(cell);
1068 double cell_measure =
1073 h = std::min(h, h_local);
1078 h = Utilities::MPI::min(h, mpi_communicator);
1100 const double cell_extent_here,
1101 const double cell_extent_there)
1103 return (fe_degree + 1) * (fe_degree + 1.) * 0.5 *
1104 (1. / cell_extent_here + 1. / cell_extent_there);
1116template <
typename key,
typename val>
1120 std::vector<key> keys;
1121 keys.reserve(map.size());
1122 for (
const auto &pair : map)
1123 keys.push_back(pair.first);
1136template <
typename key,
typename val>
1140 std::vector<val> values;
1141 values.reserve(map.size());
1142 for (
const auto &pair : map)
1143 values.push_back(pair.second);
1177std::tuple<std::map<std::string, bool>, std::vector<std::string>>
1190 const ParameterHandler &prm,
1191 const std::string &file_name);
1216 ParameterHandler &prm);
1235 const Point<dim> ¢er_of_rotation = Point<dim>(),
1236 const unsigned int rotation_axis_direction = 2)
1238 if constexpr (dim == 3)
1240 const unsigned int coord1 = (rotation_axis_direction + 1) % 3;
1241 const unsigned int coord2 = (rotation_axis_direction + 2) % 3;
1243 return std::fmod(std::atan2(point[coord2] - center_of_rotation[coord2],
1244 point[coord1] - center_of_rotation[coord1]) +
1249 return std::fmod(std::atan2(point[1] - center_of_rotation[1],
1250 point[0] - center_of_rotation[0]) +
1267 const double angle_rad,
1268 const Point<dim> ¢er_of_rotation = Point<dim>(),
1269 const unsigned int rotation_axis_direction = 2)
1273 if constexpr (dim == 3)
1275 const unsigned int coord1 = (rotation_axis_direction + 1) % 3;
1276 const unsigned int coord2 = (rotation_axis_direction + 2) % 3;
1278 point[coord1] = radius * std::cos(angle_rad) + center_of_rotation[coord1];
1279 point[coord2] = radius * std::sin(angle_rad) + center_of_rotation[coord2];
1280 point[rotation_axis_direction] =
1281 center_of_rotation[rotation_axis_direction];
1285 point[0] = radius * std::cos(angle_rad) + center_of_rotation[0];
1286 point[1] = radius * std::sin(angle_rad) + center_of_rotation[1];
1303 const unsigned int number_of_elements,
1304 const double maximum_range,
1305 const unsigned int prn_seed)
1307 for (
unsigned int i = 0; i < number_of_elements; ++i)
1309 srand(prn_seed * (i + 1));
1310 random_container.push_back((((
double)rand()) / ((
double)RAND_MAX)) *
1328template <
typename T>
1331 const std::string &entry_string)
1333 std::string full_str = prm.get(entry_string);
1334 std::vector<std::string> vector_of_string(
1335 Utilities::split_string_list(full_str));
1336 if constexpr (std::is_same_v<T, int>)
1338 std::vector<T> vector = Utilities::string_to_int(vector_of_string);
1341 if constexpr (std::is_same_v<T, double>)
1343 std::vector<T> vector = Utilities::string_to_double(vector_of_string);
1346 if constexpr (std::is_same_v<T, std::string>)
1348 return vector_of_string;
1350 if constexpr (std::is_same_v<T, types::boundary_id>)
1352 std::vector<int> vector_int = Utilities::string_to_int(vector_of_string);
1353 std::vector<T> vector;
1354 for (
const auto var_int : vector_int)
1359 "You are trying to convert a negative integer to a boundary id. Lethe does not support negative boundary id."));
1360 vector.push_back(
static_cast<types::boundary_id
>(var_int));
1366 ExcMessage(
"Error: convert_string_to_vector only works for "
1367 "int, double and string types."));
1369 return std::vector<T>();
1381 const typename Triangulation<dim>::active_cell_iterator &cell_1,
1382 const typename Triangulation<dim>::active_cell_iterator &cell_2)
const
1384 return cell_1->global_active_cell_index() <
1385 cell_2->global_active_cell_index();
1398 const Particles::ParticleIterator<dim> &particle_2)
1400 return particle_1->id() < particle_2->id();
1414 const typename Triangulation<dim - 1, dim>::active_cell_iterator &cell_1,
1415 const typename Triangulation<dim - 1, dim>::active_cell_iterator &cell_2)
1418 return cell_1->global_active_cell_index() <
1419 cell_2->global_active_cell_index();
1433 operator()(
const typename Triangulation<dim - 1, dim>::active_cell_iterator
1436 return std::hash<int>()(cell->global_active_cell_index());
1465template <
int dim,
typename VectorType>
1468 const Mapping<dim> &mapping,
1469 const DoFHandler<dim> &dof_handler,
1471 const std::vector<Point<dim>> &evaluation_points,
1472 Utilities::MPI::RemotePointEvaluation<dim> &remote_point_evaluator,
1473 std::vector<double> &evaluated_scalar_values,
1474 const unsigned int first_selected_component = 0);
1501template <
int n_component,
int dim,
typename VectorType>
1504 const Mapping<dim> &mapping,
1505 const DoFHandler<dim> &dof_handler,
1507 const std::vector<Point<dim>> &evaluation_points,
1508 Utilities::MPI::RemotePointEvaluation<dim> &remote_point_evaluator,
1509 std::vector<Tensor<1, dim, double>> &evaluated_vector_values,
1510 const unsigned int first_selected_component = 0);
1528 const std::vector<Point<dim>> &evaluation_points,
1529 const Utilities::MPI::RemotePointEvaluation<dim, dim> &remote_point_evaluator)
1531 if (!remote_point_evaluator.all_points_found())
1533 for (
unsigned int i = 0; i < evaluation_points.size(); ++i)
1535 AssertThrow(remote_point_evaluator.point_found(i),
1538 Patterns::Tools::Convert<Point<dim>>::to_string(
1539 evaluation_points[i]) +
1540 ") is not defined within the simulated domain."));
A simple container for storing basic statistical values.
double average
The average value of the dataset.
double max
The maximum value in the dataset.
statistics()
Default constructor.
double min
The minimum value in the dataset.
double total
The sum of all values in the dataset.
void create_random_number_container(std::vector< double > &random_container, const unsigned int number_of_elements, const double maximum_range, const unsigned int prn_seed)
Creates a vector of random doubles between 0 and a maximum value using a pseudo random seed.
void check_file_exists(const std::string &file_name, const std::string &file_description)
Verify that a file that Lethe must read exists and can be opened, and raise an error stated in the us...
unsigned int get_dimension(const std::string &file_name)
Extract the dimension in which to run Lethe from the contents of the parameter file....
void deserialize_table(TableHandler &table, const std::string &filename, const MPI_Comm &mpi_communicator, const bool deserialize_on_rank_zero=true)
Loads a TableHandler from a file using Boost serialization.
std::string get_last_value_of_parameter(const std::string &file_name, const std::string ¶meter_name)
Retrieves the value of a specific parameter from an input file. Returns an empty string if the parame...
Tensor< 1, spacedim > value_string_to_tensor(const std::string &value_string)
Return the tensor corresponding to the value_string. If the dimension correspondence of the value_str...
std::tuple< std::map< std::string, bool >, std::vector< std::string > > parse_args(int argc, char **argv)
Parse the arguments given to the application.
double compute_cell_measure_with_JxW(const std::vector< double > &JxW_values)
Computes the area (2D) or volume (3D) of the cell by integrating 1 over the cell, by summing JxW valu...
TableHandler make_table_scalars_tensors(const std::vector< T > &independent_values, const std::string &independent_column_name, const std::vector< Tensor< 1, dim > > &dependent_vector, const std::vector< std::string > &dependent_column_names, const unsigned int display_precision, const bool display_scientific_notation=false)
Generate a table from a vector of scalars (independent variable) and a vector of Tensor<1,...
void fill_string_vectors_from_file(std::map< std::string, std::vector< std::string > > &map, const std::string &file_name, const std::string &delimiter=" ")
Function that read a file that was build from a dealii table and create a map with the key being the ...
TableHandler make_table_tensors_scalars(const std::vector< Tensor< 1, dim > > &independent_vector, const std::vector< std::string > &independent_column_names, const std::vector< double > &dependent_values, const std::string &dependent_column_name, const unsigned int display_precision, const bool display_scientific_notation=false)
Generate a table from a vector of Tensor<1,dim> (independent variables) and a vector of scalars (depe...
double identify_minimum_cell_size(const Mapping< dim > &mapping, const DoFHandler< dim > &dof_handler, const Quadrature< dim > &cell_quadrature, const MPI_Comm &mpi_communicator)
Identify minimum cell size. The cell size corresponds to the diameter of a disk (2D) or sphere (3D) o...
std::vector< val > extract_values_from_map(const std::map< key, val > &map)
Extract the values from map object.
void create_output_folder(const std::string &dirname)
Creates the simulation output folder.
double point_to_angle(const Point< dim > &point, const Point< dim > ¢er_of_rotation=Point< dim >(), const unsigned int rotation_axis_direction=2)
Converts point to angle (in radians) based on rotation axis.
void evaluate_values_at_points(const Mapping< dim > &mapping, const DoFHandler< dim > &dof_handler, const VectorType &solution_field, const std::vector< Point< dim > > &evaluation_points, Utilities::MPI::RemotePointEvaluation< dim > &remote_point_evaluator, std::vector< double > &evaluated_scalar_values, const unsigned int first_selected_component=0)
Evaluates the values of a scalar field at remote points of the domain from the mapping,...
std::vector< std::pair< std::string, EnumType > > DeprecatedEnumNames
Deprecated strings of an enum parameter, each paired with the enumerator it stands for....
std::string enum_to_string(const EnumType value)
Return the name of an enumerator, e.g. to derive the default value string of a parameter entry from t...
TableHandler make_table_scalars_vectors(const std::vector< T > &independent_values, const std::string &independent_column_name, const std::vector< std::vector< double > > &dependent_vector, const std::vector< std::string > &dependent_column_names, const unsigned int display_precision, const bool display_scientific_notation=false)
Generate a table from a vector of scalars (independent variable) and a vector of vectors of scalars (...
void serialize_table(const TableHandler &table, const std::string &filename, const MPI_Comm &mpi_communicator, const bool serialize_on_rank_zero=true)
Serializes a TableHandler to a file using Boost serialization.
void print_parameters_to_output_file(const ConditionalOStream &pcout, const ParameterHandler &prm, const std::string &file_name)
Print the parameters given by the parameter file of the application.
std::vector< T > convert_string_to_vector(const ParameterHandler &prm, const std::string &entry_string)
Return the vector of size N of entry @entry_string. If the entry is specified in the ....
void delete_output_folder(const std::string &dirname)
Delete the output folder and its content.
void delete_vtu_and_pvd_files(const std::string &output_path)
Delete vtu and pvd files.
bool points_are_in_domain(const std::vector< Point< dim > > &evaluation_points, const Utilities::MPI::RemotePointEvaluation< dim, dim > &remote_point_evaluator)
Checks that the evaluation points are within the simulated domain and returns true if all points are ...
void fill_vectors_from_file(std::map< std::string, std::vector< double > > &map, const std::string &file_name, const std::string &delimiter=" ")
function that read a file that was build from a dealii table and fill 2 vectors. The first vector con...
TableHandler make_table_tensors_tensors(const std::vector< Tensor< 1, dim > > &independent_vector, const std::vector< std::string > &independent_column_names, const std::vector< Tensor< 1, dim > > &dependent_vector, const std::vector< std::string > &dependent_column_names, const unsigned int display_precision, const bool display_scientific_notation=false)
Generate a table from a vector of Tensor<1,dim> (independent variables) and a vector of Tensor<1,...
int get_max_subsection_size(const std::string &file_name, const bool require_subsection_size=true)
Extract the maximum value between the number of boundary conditions and the number of manifolds from ...
void serialize_tables_vector(const std::vector< OutputStructTableHandler > &table_output_structs, const MPI_Comm mpi_communicator)
Serializes all the TableHandler objects in table_output_structs.
EnumType string_to_enum(const std::string &name)
Return the enumerator whose identifier is name, e.g. to parse the value of a parameter entry into its...
void print_version_info(const ConditionalOStream &pcout)
Print the information of the deal.II and Lethe branches used to run an application in the "git descri...
void announce_string(const ConditionalOStream &pcout, const std::string &expression, const char delimiter='-')
Prints a string and then adds a line above and below made with dashes containing as many dashes as th...
double calculate_point_property(const double phase, const double property0, const double property1)
Calculate the equivalent properties for a given phase. Method called in quadrature points loops in CL...
constexpr int sgn(const T val) noexcept
Retrieve the sign of a value.
T clip(const T &n, const T &lower, const T &upper)
Clip a property between a lower and a higher value.
double compute_cell_diameter(const double cell_measure, const unsigned int fe_degree)
Computes equivalent cell diameter by comparing the area to a disk (2D) or the volume to a sphere (3D)...
std::string concatenate_strings(const int argc, char **argv)
Concatenate words which are passed from the command line to a main function into a single string in w...
void add_statistics_to_table_handler(const std::string &variable, const statistics &stats, TableHandler &table)
Add statistical values to a TableHandler.
std::vector< key > extract_keys_from_map(const std::map< key, val > &map)
Extract the keys from map object.
std::string enum_to_selection(const DeprecatedEnumNames< EnumType > &deprecated_names={}, const std::vector< EnumType > &allowed_values={})
Return the selection string (e.g. "quiet|verbose|extra_verbose") of an enum parameter,...
void warn_deprecated_parameter_value(const std::string ¶meter_name, const std::string &deprecated_value, const std::string &new_value)
Print a warning stating that a deprecated value was given to a parameter, along with the value which ...
double calculate_point_property_cahn_hilliard(const double phase_cahn_hilliard, const double property0, const double property1)
Calculate the equivalent property for a given phase.
void interpret_escape_sequences(std::string &s)
Identify escape sequences listed below and apply them to the string.
double get_penalty_factor(const unsigned int fe_degree, const double cell_extent_here, const double cell_extent_there)
Calculate the penalty factor for the SIPG method for the case when two cells are of different sizes....
std::string enum_to_choices(const std::vector< EnumType > &allowed_values={})
Return the sentence listing the choices of an enum parameter (e.g. "Choices are <quiet|verbose|extra_...
void declare_enum_entry(ParameterHandler &prm, const std::string &entry_name, const EnumType default_value, const std::string &description, const DeprecatedEnumNames< EnumType > &deprecated_names={}, const std::vector< EnumType > &allowed_values={})
Declare a parameter entry whose value is an enumerator. The default value, the accepted values and th...
void print_comment_to_output_file(const ConditionalOStream &pcout, ParameterHandler &prm)
Print a user comment at the beginning of the simulation on the console output.
void fill_table_from_file(TableHandler &table, const std::string &file_name, const std::string &delimiter=" ")
Reads a file generated by a deal.II TableHandler and fills a TableHandler with its data.
Point< dim > radius_to_point(const double radius, const double angle_rad, const Point< dim > ¢er_of_rotation=Point< dim >(), const unsigned int rotation_axis_direction=2)
Converts radius to point in cartesian coordinates based on rotation axis.
void deserialize_tables_vector(std::vector< OutputStructTableHandler > &table_output_structs, const MPI_Comm mpi_communicator)
Deserializes all the TableHandler objects in table_output_structs.
@ phase_cahn_hilliard
Phase order scalar field from Cahn Hilliard.
@ phase
Phase indicator scalar field from CLS.
Operator overloading to enable using triangulation cells as map keys.
bool operator()(const typename Triangulation< dim >::active_cell_iterator &cell_1, const typename Triangulation< dim >::active_cell_iterator &cell_2) const
bool operator()(const typename Triangulation< dim - 1, dim >::active_cell_iterator &cell_1, const typename Triangulation< dim - 1, dim >::active_cell_iterator &cell_2) const
Hash functor to enable using cut-cell (embedded triangulation) active cell iterators as keys of an un...
std::size_t operator()(const typename Triangulation< dim - 1, dim >::active_cell_iterator &cell) const
Operator overloading to enable using particle iterators as map keys.
bool operator()(const Particles::ParticleIterator< dim > &particle_1, const Particles::ParticleIterator< dim > &particle_2)
GlobalVectorType VectorType