59 template <
int spacedim, class
Value>
66 "GMSH mesh with data. Can be different from actual computational mesh.")
68 "Section where to find the field.\n Some sections are specific to file format: " 69 "point_data/node_data, cell_data/element_data, -/element_node_data, native/-.\n" 70 "If not given by a user, we try to find the field in all sections, but we report an error " 71 "if it is found in more than one section.")
73 "The values of the Field are read from the ```$ElementData``` section with field name given by this key.")
75 "Default value is set on elements which values have not been listed in the mesh data file.")
77 "Definition of the unit of all times defined in the mesh data file.")
79 "This key allows reading field data from the mesh data file shifted in time. Considering the time 't', field descriptor with time 'T', " 80 "time shift 'S', then if 't > T', we read the time frame 't + S'.")
82 IT::Default(
"\"equivalent_mesh\""),
"Type of interpolation applied to the input spatial data.\n" 83 "The default value 'equivalent_mesh' assumes the data being constant on elements living on the same mesh " 84 "as the computational mesh, but possibly with different numbering. In the case of the same numbering, " 85 "the user can set 'identical_mesh' to omit algorithm for guessing node and element renumbering. " 86 "Alternatively, in case of different input mesh, several interpolation algorithms are available.")
90 template <
int spacedim,
class Value>
94 "Specify the section in mesh input file where field data is listed.\nSome sections are specific to file format.")
95 .
add_value(OutputTime::DiscreteSpace::NODE_DATA,
"node_data",
"point_data (VTK) / node_data (GMSH)")
96 .
add_value(OutputTime::DiscreteSpace::ELEM_DATA,
"element_data",
"cell_data (VTK) / element_data (GMSH)")
97 .
add_value(OutputTime::DiscreteSpace::CORNER_DATA,
"element_node_data",
"element_node_data (only for GMSH)")
98 .
add_value(OutputTime::DiscreteSpace::NATIVE_DATA,
"native_data",
"native_data (only for VTK)")
102 template <
int spacedim,
class Value>
105 return it::Selection(
"interpolation",
"Specify interpolation of the input data from its input mesh to the computational mesh.")
106 .
add_value(DataInterpolation::identic_msh,
"identic_mesh",
"Topology and indices of nodes and elements of" 107 "the input mesh and the computational mesh are identical. " 108 "This interpolation is typically used for GMSH input files containing only the field values without " 109 "explicit mesh specification.")
110 .
add_value(DataInterpolation::equivalent_msh,
"equivalent_mesh",
"Topologies of the input mesh and the computational mesh " 111 "are the same, the node and element numbering may differ. " 112 "This interpolation can be used also for VTK input data.")
113 .
add_value(DataInterpolation::gauss_p0,
"P0_gauss",
"Topologies of the input mesh and the computational mesh may differ. " 114 "Constant values on the elements of the computational mesh are evaluated using the Gaussian quadrature of the fixed order 4, " 115 "where the quadrature points and their values are found in the input mesh and input data using the BIH tree search." 117 .
add_value(DataInterpolation::interp_p0,
"P0_intersection",
"Topologies of the input mesh and the computational mesh may differ. " 118 "Can be applied only for boundary fields. For every (boundary) element of the computational mesh the " 119 "intersection with the input mesh is computed. Constant values on the elements of the computational mesh " 120 "are evaluated as the weighted average of the (constant) values on the intersecting elements of the input mesh.")
124 template <
int spacedim,
class Value>
126 Input::register_class< FieldFE<spacedim, Value>,
unsigned int >(
"FieldFE") +
131 template <
int spacedim,
class Value>
134 field_name_(
""), fe_values_(4)
140 template <
int spacedim,
class Value>
144 if (dof_values.
size()==0) {
152 this->fill_fe_item<0>();
153 this->fill_fe_item<1>();
154 this->fill_fe_item<2>();
155 this->fill_fe_item<3>();
156 this->
fe_ =
dh_->ds()->fe();
158 this->fill_fe_system_data<0>(block_index);
159 this->fill_fe_system_data<1>(block_index);
160 this->fill_fe_system_data<2>(block_index);
161 this->fill_fe_system_data<3>(block_index);
170 unsigned int ndofs =
dh_->max_elem_dofs();
176 init_data.
ndofs = ndofs;
205 template <
int spacedim,
class Value>
218 ASSERT(
false).error(
"Invalid element dimension!");
229 template <
int spacedim,
class Value>
250 ASSERT(
false).error(
"Invalid element dimension!");
256 template <
int spacedim,
class Value>
265 unsigned int last_element_idx = -1;
268 unsigned int range_bgn=0, range_end=0;
270 for (
unsigned int i_data = reg_chunk_begin; i_data < reg_chunk_end; ++i_data) {
272 if (elm_idx != last_element_idx) {
275 cell =
dh_->cell_accessor_from_element( elm_idx );
277 last_element_idx = elm_idx;
278 range_bgn = this->
fe_item_[elm.dim()].range_begin_;
279 range_end = this->
fe_item_[elm.dim()].range_end_;
285 for (
unsigned int i_dof=range_bgn, i_cdof=0; i_dof<range_end; i_dof++, i_cdof++) {
288 data_cache.
set(i_data) = mat_value;
293 template <
int spacedim,
class Value>
296 std::shared_ptr<EvalPoints> eval_points = cache_map.
eval_points();
297 std::array<Quadrature, 4> quads{
QGauss(0, 1), this->init_quad<1>(eval_points), this->init_quad<2>(eval_points), this->init_quad<3>(eval_points)};
305 template <
int spacedim,
class Value>
306 template <
unsigned int dim>
310 for (
unsigned int k=0; k<eval_points->size(dim); k++)
311 quad.
set(k) = eval_points->local_point<dim>(k);
316 template <
int spacedim,
class Value>
339 template <
int spacedim,
class Value>
343 ASSERT(
field_name_ !=
"").error(
"Uninitialized FieldFE, did you call init_from_input()?\n");
354 WarningOut().fmt(
"Source mesh of FieldFE '{}' is not compatible with target mesh.\nInterpolation of input data will be changed to 'P0_gauss'.\n",
357 }
else if (this->
interpolation_ == DataInterpolation::interp_p0) {
358 if (!boundary_domain) {
360 WarningOut().fmt(
"Interpolation 'P0_intersection' of FieldFE '{}' can't be used on bulk region.\nIt will be changed to 'P0_gauss'.\n",
371 template <
int spacedim,
class Value>
375 auto bc_mesh =
dh_->mesh()->get_bc_mesh();
377 boundary_dofs_ = std::make_shared< std::vector<IntIdx> >( n_comp * bc_mesh->n_elements() );
381 for (
auto ele : bc_mesh->elements_range()) {
382 IntIdx elm_shift = n_comp * ele.idx();
383 for (
unsigned int i=0; i<
n_comp; ++i, ++j) {
384 in_vec[j] = elm_shift + i;
398 template <
int spacedim,
class Value>
403 switch (this->
value_.n_rows() * this->
value_.n_cols()) {
419 ASSERT(
false).error(
"Should not happen!\n");
422 std::shared_ptr<DOFHandlerMultiDim> dh_par = std::make_shared<DOFHandlerMultiDim>(
const_cast<Mesh &
>(*mesh) );
423 std::shared_ptr<DiscreteSpace> ds = std::make_shared<EqualOrderDiscreteSpace>( &
const_cast<Mesh &
>(*mesh), fe);
424 dh_par->distribute_dofs(ds);
426 unsigned int ndofs =
dh_->max_elem_dofs();
428 this->fill_fe_item<0>();
429 this->fill_fe_item<1>();
430 this->fill_fe_item<2>();
431 this->fill_fe_item<3>();
432 this->
fe_ =
dh_->ds()->fe();
441 init_data.ndofs = ndofs;
442 init_data.n_comp = this->
n_comp();
443 init_data.mixed_fe = this->
fe_;
446 init_data.range_begin = this->
fe_item_[0].range_begin_;
447 init_data.range_end = this->
fe_item_[0].range_end_;
449 init_data.range_begin = this->
fe_item_[1].range_begin_;
450 init_data.range_end = this->
fe_item_[1].range_end_;
452 init_data.range_begin = this->
fe_item_[2].range_begin_;
453 init_data.range_end = this->
fe_item_[2].range_end_;
455 init_data.range_begin = this->
fe_item_[3].range_begin_;
456 init_data.range_end = this->
fe_item_[3].range_end_;
462 template <
int spacedim,
class Value>
466 ASSERT(
field_name_ !=
"").error(
"Uninitialized FieldFE, did you call init_from_input()?\n");
470 unsigned int n_components = this->
value_.n_rows() * this->
value_.n_cols();
473 double read_time = (time.
end()+time_shift) / time_unit_coef;
478 unsigned int n_entities;
479 bool is_native = (header_query.discretization == OutputTime::DiscreteSpace::NATIVE_DATA);
487 n_entities = boundary ?
dh_->mesh()->get_bc_mesh()->n_elements() :
dh_->mesh()->n_elements();
503 }
else if (this->
interpolation_==DataInterpolation::identic_msh) {
505 }
else if (this->
interpolation_==DataInterpolation::equivalent_msh) {
519 template <
int spacedim,
class Value>
522 static const unsigned int quadrature_order = 4;
527 unsigned int quadrature_size=0;
529 unsigned int elem_count;
535 QGauss quad(3, quadrature_order);
536 q_points.resize(quad.
size());
537 q_weights.resize(quad.
size());
540 for (
auto cell :
dh_->own_range()) {
541 auto ele = cell.elm();
542 std::fill(elem_value.begin(), elem_value.end(), 0.0);
543 switch (cell.dim()) {
546 q_points[0] = *ele.node(0);
559 searched_elements.clear();
560 source_mesh->get_bih_tree().find_bounding_box(ele.bounding_box(), searched_elements);
562 for (
unsigned int i=0; i<quadrature_size; ++i) {
563 std::fill(sum_val.begin(), sum_val.end(), 0.0);
568 switch (elm->
dim()) {
570 contains = arma::norm(*elm.
node(0) - q_points[i], 2) < 4*std::numeric_limits<double>::epsilon();
582 ASSERT(
false).error(
"Invalid element dimension!");
586 unsigned int index = sum_val.size() * (*it);
587 for (
unsigned int j=0; j < sum_val.size(); j++) {
588 sum_val[j] += (*data_vec)[index+j];
594 if (elem_count > 0) {
595 for (
unsigned int j=0; j < sum_val.size(); j++) {
596 elem_value[j] += (sum_val[j] / elem_count) * q_weights[i];
603 else loc_dofs = cell.get_loc_dof_indices();
606 for (
unsigned int i=0; i < elem_value.size(); i++) {
614 template <
int spacedim,
class Value>
620 double total_measure;
625 else mesh =
dh_->mesh();
627 if (elm.dim() == 3) {
628 xprintf(
Err,
"Dimension of element in target mesh must be 0, 1 or 2! elm.idx() = %d\n", elm.idx());
631 double epsilon = 4* numeric_limits<double>::epsilon() * elm.measure();
634 if (elm.dim() == 0) {
635 searched_elements.clear();
636 source_mesh->get_bih_tree().find_point(*elm.node(0), searched_elements);
639 searched_elements.clear();
640 source_mesh->get_bih_tree().find_bounding_box(bb, searched_elements);
654 if (ele->
dim() == 3) {
658 arma::vec::fixed<3> real_point = *elm.node(0);
662 measure = (std::fabs(arma::sum( unit_point )-1) <= 1e-14
663 && arma::min( unit_point ) >= 0)
690 if (measure > epsilon) {
691 unsigned int index =
value.size() * (*it);
693 for (
unsigned int i=0; i <
value.size(); i++) {
694 value[i] += vec[index+i] * measure;
696 total_measure += measure;
702 if (total_measure > epsilon) {
711 for (
unsigned int i=0; i <
value.size(); i++) {
715 WarningOut().fmt(
"Processed element with idx {} is out of source mesh!\n", elm.idx());
723 template <
int spacedim,
class Value>
727 unsigned int dof_size, data_vec_i;
734 for (
auto cell :
dh_->own_range()) {
735 dof_size = cell.get_dof_indices(global_dof_indices);
736 LocDofVec loc_dofs = cell.get_loc_dof_indices();
737 data_vec_i = source_target_vec[cell.elm_idx()] * dof_size;
739 for (
unsigned int i=0; i<dof_size; ++i, ++data_vec_i) {
740 data_vec_.
add( loc_dofs[i], (*data_cache)[ data_vec_i ] );
741 ++count_vector[ loc_dofs[i] ];
752 template <
int spacedim,
class Value>
756 unsigned int data_vec_i, i_elm;
762 Mesh *mesh =
dh_->mesh()->get_bc_mesh();
766 data_vec_i = i_elm *
dh_->max_elem_dofs();
767 for (
unsigned int i=0; i<loc_dofs.n_elem; ++i, ++data_vec_i) {
769 data_vec_.
add( loc_dofs[i], (*data_cache)[data_vec_i] );
770 ++count_vector[ loc_dofs[i] ];
778 for (
auto cell :
dh_->own_range()) {
779 LocDofVec loc_dofs = cell.get_loc_dof_indices();
780 data_vec_i = i_elm *
dh_->max_elem_dofs();
781 for (
unsigned int i=0; i<loc_dofs.n_elem; ++i, ++data_vec_i) {
783 data_vec_.
add( loc_dofs[i], (*data_cache)[data_vec_i] );
784 ++count_vector[ loc_dofs[i] ];
797 template <
int spacedim,
class Value>
801 unsigned int data_vec_i;
808 Mesh *mesh =
dh_->mesh()->get_bc_mesh();
814 for (
unsigned int i=0; i<loc_dofs.n_elem; ++i) {
817 ++count_vector[ loc_dofs[i] ];
820 data_vec_i = source_target_vec[ele.mesh_idx()] *
dh_->max_elem_dofs();
821 for (
unsigned int i=0; i<loc_dofs.n_elem; ++i, ++data_vec_i) {
823 data_vec_.
add( loc_dofs[i], (*data_cache)[data_vec_i] );
824 ++count_vector[ loc_dofs[i] ];
831 for (
auto cell :
dh_->own_range()) {
832 LocDofVec loc_dofs = cell.get_loc_dof_indices();
836 for (
unsigned int i=0; i<loc_dofs.n_elem; ++i) {
839 ++count_vector[ loc_dofs[i] ];
842 data_vec_i = source_target_vec[cell.elm_idx()] *
dh_->max_elem_dofs();
843 for (
unsigned int i=0; i<loc_dofs.n_elem; ++i, ++data_vec_i) {
845 data_vec_.
add( loc_dofs[i], (*data_cache)[data_vec_i] );
846 ++count_vector[ loc_dofs[i] ];
859 template <
int spacedim,
class Value>
862 double loc_values[output_data_cache.
n_comp()];
865 for (
auto dh_cell :
dh_->own_range()) {
866 LocDofVec loc_dofs = dh_cell.get_loc_dof_indices();
867 for (i=0; i<loc_dofs.n_elem; ++i) loc_values[i] =
data_vec_.
get( loc_dofs[i] );
868 for ( ; i<output_data_cache.
n_comp(); ++i) loc_values[i] = numeric_limits<double>::signaling_NaN();
869 output_data_cache.
store_value( dh_cell.local_idx(), loc_values );
877 template <
int spacedim,
class Value>
884 template <
int spacedim,
class Value>
891 template <
int spacedim,
class Value>
913 template <
int spacedim,
class Value>
unsigned int region_chunk_begin(unsigned int region_patch_idx) const
Return begin position of region chunk in FieldValueCache.
Armor::ArmaMat< typename Value::element_type, Value::NRows_, Value::NCols_ > handle_fe_shape(unsigned int dim, unsigned int i_dof, unsigned int i_qp)
Class MappingP1 implements the affine transformation of the unit cell onto the actual cell...
virtual ~FieldFE()
Destructor.
void init_unit_conversion_coefficient(const Input::Record &rec, const struct FieldAlgoBaseInitData &init_data)
Init value of unit_conversion_coefficient_ from input.
unsigned int size() const
Return size of output data.
Bounding box in 3d ambient space.
void set_dof_handler_hash(std::size_t hash)
void interpolate_gauss(ElementDataCache< double >::ComponentDataPtr data_vec)
Interpolate data (use Gaussian distribution) over all elements of target mesh.
unsigned int size() const
FEValueHandler< 0, spacedim, Value > value_handler0_
Value handler that allows get value of 0D elements.
Armor::Array< double >::ArrayMatSet set(uint i)
#define ASSERT_EQ_DBG(a, b)
Definition of comparative assert macro (EQual) only for debug mode.
std::shared_ptr< std::vector< T > > ComponentDataPtr
arma::Col< IntIdx > LocDofVec
MixedPtr< FiniteElement > fe_
double read_coef(Input::Iterator< std::string > unit_it) const
Classes with algorithms for computation of intersections of meshes.
void calculate_equivalent_values(ElementDataCache< double >::ComponentDataPtr data_cache)
Calculate data of equivalent_mesh interpolation on input over all elements of target mesh...
Some value(s) is set to NaN.
void initialize(FEValueInitData init_data)
Initialize data members.
std::vector< FEValues< spacedim > > fe_values_
List of FEValues objects of dimensions 0,1,2,3 used for value calculation.
unsigned int n_values() const
unsigned int component_idx_
Specify if the field is part of a MultiField and which component it is.
LocDofVec get_loc_dof_indices(unsigned int cell_idx) const
TODO: Temporary solution. Fix problem with merge new DOF handler and boundary Mesh. Will be removed in future.
static void get_element_ids(const FilePath &file_path, const Mesh &mesh)
std::string field_name_
field name read from input
void local_to_ghost_begin()
local_to_ghost_{begin,end} updates the ghost values on neighbouring processors from local values ...
double compute_measure() const override
Computes the relative measure of intersection object.
unsigned int i_element_
mesh_idx of ElementAccessor appropriate to element
void value_list(const Armor::array &point_list, const ElementAccessor< spacedim > &elm, std::vector< typename Value::return_type > &value_list)
Returns std::vector of scalar values in several points at once.
static const unsigned int undef_idx
FEValueHandler< 2, spacedim, Value > value_handler2_
Value handler that allows get value of 2D elements.
const EvalPointData & eval_point_data(unsigned int point_idx) const
Return item of eval_point_data_ specified by its position.
unsigned int range_end
Holds end of component range of evaluation.
VectorMPI data_vec_
Store data of Field.
void store_value(unsigned int idx, const T *value)
Fundamental simplicial intersections.
static BaryPoint project_real_to_unit(const RealPoint &point, const ElementMap &map)
unsigned int dim() const
Return dimension of element appropriate to cell.
FilePath reader_file_
mesh reader file
#define INSTANCE_ALL(field)
void init()
Initializes lower dimensional objects. Sets correctly the pointers to Plucker coordinates and product...
Directing class of FieldValueCache.
void initialize(FEValueInitData init_data)
Initialize data members.
Cell accessor allow iterate over DOF handler cells.
Helper struct stores data for initizalize descentants of FieldAlgorithmBase.
Value::return_type const & value(const Point &p, const ElementAccessor< spacedim > &elm)
Returns one value in one given point.
Class FESystem for compound finite elements.
LocDofVec get_loc_dof_indices() const
Returns the local indices of dofs associated to the cell on the local process.
void set_mesh(const Mesh *mesh, bool boundary_domain) override
#define ASSERT(expr)
Allow use shorter versions of macro names if these names is not used with external library...
#define ADD_CALLS(n_calls)
Increase number of calls in actual timer.
double default_value_
Default value of element if not set in mesh data file.
FEValueHandler< 3, spacedim, Value > value_handler3_
Value handler that allows get value of 3D elements.
bool set_time(const TimeStep &time) override
static const Input::Type::Selection & get_interp_selection_input_type()
Value::return_type const & value(const Point &p, const ElementAccessor< spacedim > &elm)
Returns one value in one given point.
Value::return_type r_value_
void fill_boundary_dofs()
NodeAccessor< 3 > node(unsigned int ni) const
Base class for quadrature rules on simplices in arbitrary dimensions.
Symmetric Gauss-Legendre quadrature formulae on simplices.
VectorMPI set_fe_data(std::shared_ptr< DOFHandlerMultiDim > dh, VectorMPI dof_values=VectorMPI::sequential(0), unsigned int block_index=FieldFE< spacedim, Value >::undef_uint)
unsigned int data_size() const
constexpr bool match(Mask mask) const
void init()
Initializes lower dimensional objects. Sets correctly the pointers to Plucker coordinates and product...
double unit_conversion_coefficient_
Coeficient of conversion of user-defined unit.
MixedPtr< FiniteElement > mixed_fe
FiniteElement objects of all dimensions.
bool boundary_domain_
Is set in set_mesh method. Value true means, that we accept only boundary element accessors in the va...
OutputTime::DiscreteSpace discretization_
Specify section where to find the field data in input mesh file.
std::shared_ptr< DOFHandlerMultiDim > dh_
DOF handler object.
Quadrature init_quad(std::shared_ptr< EvalPoints > eval_points)
Initialize FEValues object of given dimension.
static const Input::Type::Tuple & get_input_time_type(double lower_bound=-std::numeric_limits< double >::max(), double upper_bound=std::numeric_limits< double >::max())
DataInterpolation interpolation_
Specify type of FE data interpolation.
Compound finite element on dim dimensional simplex.
std::array< FEItem, 4 > fe_item_
Holds specific data of field evaluation over all dimensions.
Definitions of basic Lagrangean finite elements with polynomial shape functions.
void resize(unsigned int local_size)
#define START_TIMER(tag)
Starts a timer with specified tag.
void interpolate_intersection(ElementDataCache< double >::ComponentDataPtr data_vec)
Interpolate data (use intersection library) over all elements of target mesh.
std::shared_ptr< std::vector< IntIdx > > boundary_dofs_
unsigned int region_chunk_end(unsigned int region_patch_idx) const
Return end position of region chunk in FieldValueCache.
virtual Value::return_type const & value(const Point &p, const ElementAccessor< spacedim > &elm)
ArrayMatSet set(uint index)
virtual Range< ElementAccessor< 3 > > elements_range() const
Returns range of bulk elements.
void local_to_ghost_data_scatter_begin()
Call begin scatter functions (local to ghost) on data vector.
unsigned int ndofs
number of dofs
Space< spacedim >::Point Point
void add(unsigned int pos, double val)
Add value to item on given position.
void local_to_ghost_data_scatter_end()
Call end scatter functions (local to ghost) on data vector.
unsigned int i_eval_point_
index of point in EvalPoint object
void set_boundary_dofs_vector(std::shared_ptr< std::vector< IntIdx > > boundary_dofs)
TODO: Temporary solution. Fix problem with merge new DOF handler and boundary Mesh. Will be removed in future.
unsigned int compute_quadrature(std::vector< arma::vec::fixed< 3 >> &q_points, std::vector< double > &q_weights, const ElementAccessor< spacedim > &elm, unsigned int order=3)
Compute real coordinates and weights (use QGauss) for given element.
CheckResult
Return type of method that checked data stored in ElementDataCache (NaN values, limits) ...
std::shared_ptr< DOFHandlerMultiDim > dh
DOF handler object.
double read_time(Input::Iterator< Input::Tuple > time_it, double default_time=std::numeric_limits< double >::quiet_NaN()) const
typename arma::Mat< Type >::template fixed< nr, nc > ArmaMat
void local_to_ghost_end()
local_to_ghost_{begin,end} updates the ghost values on neighbouring processors from local values ...
#define ASSERT_LE_DBG(a, b)
Definition of comparative assert macro (Less or Equal) only for debug mode.
FEValueHandler< 1, spacedim, Value > value_handler1_
Value handler that allows get value of 1D elements.
Dedicated class for storing path to input and output files.
void set(unsigned int pos, double val)
Set value on given position.
static const Input::Type::Selection & get_disc_selection_input_type()
double get(unsigned int pos) const
Return value on given position.
int LongIdx
Define type that represents indices of large arrays (elements, nodes, dofs etc.)
bool is_constant_in_space_
Flag detects that field is only dependent on time.
void value_list(const Armor::array &point_list, const ElementAccessor< spacedim > &elm, std::vector< typename Value::return_type > &value_list)
Returns std::vector of scalar values in several points at once.
Value value_
Last value, prevents passing large values (vectors) by value.
Input::Record in_rec_
Accessor to Input::Record.
#define ASSERT_PTR(ptr)
Definition of assert macro checking non-null pointer (PTR)
void normalize(unsigned int pos, double divisor)
Normalize value on given position.
FieldFE(unsigned int n_comp=0)
std::shared_ptr< EvalPoints > eval_points() const
Getter of eval_points object.
MixedPtr< FESystem > mixed_fe_system(MixedPtr< FiniteElement > fe, Args &&...args)
Definitions of particular quadrature rules on simplices.
Class for 2D-2D intersections.
#define WarningOut()
Macro defining 'warning' record of log.
void cache_update(FieldValueCache< typename Value::element_type > &data_cache, ElementCacheMap &cache_map, unsigned int region_patch_idx) override
void set_boundary_dofs_vector(std::shared_ptr< std::vector< IntIdx > > boundary_dofs)
TODO: Temporary solution. Fix problem with merge new DOF handler and boundary Mesh. Will be removed in future.
#define END_TIMER(tag)
Ends a timer with specified tag.
std::shared_ptr< std::vector< LongIdx > > source_target_mesh_elm_map_
Maps element indices between source (data) and target (computational) mesh if data interpolation is s...
virtual void value_list(const Armor::array &point_list, const ElementAccessor< spacedim > &elm, std::vector< typename Value::return_type > &value_list)
virtual void init_from_input(const Input::Record &rec, const struct FieldAlgoBaseInitData &init_data)
static std::shared_ptr< Mesh > get_mesh(const FilePath &file_path)
VectorMPI data_vec
Store data of Field.
void cache_reinit(const ElementCacheMap &cache_map) override
static ElementMap element_map(ElementAccessor< 3 > elm)
unsigned int n_comp() const
static constexpr Mask equation_input
The field is data parameter of the owning equation. (default on)
static bool contains_point(arma::vec point, ElementAccessor< 3 > elm)
Test if element contains given point.
Internal auxiliary class representing intersection object of simplex<dimA> and simplex<dimB>.
static std::shared_ptr< BaseMeshReader > get_reader(const FilePath &file_path)
unsigned int n_comp
number of components
unsigned int size() const
Returns number of quadrature points.
void calculate_native_values(ElementDataCache< double >::ComponentDataPtr data_cache)
Calculate native data over all elements of target mesh.
FieldFlag::Flags flags_
Field flags.
Initialization structure of FEValueHandler class.
unsigned int range_begin
Holds begin of component range of evaluation.
#define THROW(whole_exception_expr)
Wrapper for throw. Saves the throwing point.
Representation of one time step..
static std::shared_ptr< std::vector< LongIdx > > get_target_mesh_element_map(const FilePath &file_path, Mesh *computational_mesh)
void make_dof_handler(const Mesh *mesh)
Create DofHandler object.
Implementation of range helper class.
void native_data_to_cache(ElementDataCache< double > &output_data_cache)
#define FLOW123D_FORCE_LINK_IN_CHILD(x)
#define ASSERT_EQ(a, b)
Definition of comparative assert macro (EQual)
static constexpr Mask declare_input
The field can be set from input. The key in input field descriptor is declared. (default on) ...
static VectorMPI sequential(unsigned int size)
unsigned int n_comp() const
Internal class representing intersection object.
#define ASSERT_LT_DBG(a, b)
Definition of comparative assert macro (Less Than) only for debug mode.
void calculate_identic_values(ElementDataCache< double >::ComponentDataPtr data_cache)
Calculate data of identict_mesh interpolation on input data over all elements of target mesh...