Flow123d  DF_patch_fe_data_tables-3df4116
Public Member Functions | Protected Attributes | List of all members
ElOp< spacedim > Class Template Reference

Class represents element or FE operations. More...

#include <patch_point_values.hh>

Collaboration diagram for ElOp< spacedim >:
Collaboration graph
[legend]

Public Member Functions

 ElOp (uint dim, std::initializer_list< uint > shape, uint result_row, ReinitFunction reinit_f, OpSizeType size_type, std::vector< uint > input_ops={}, uint n_dofs=1)
 
std::vector< uintset_shape_vec (std::initializer_list< uint > shape) const
 Aligns shape_vec to 2 items (equal to matrix number of dimensions) More...
 
uint n_comp () const
 
uint dim () const
 Getter for dimension. More...
 
uint result_row () const
 Getter for result_row_. More...
 
OpSizeType size_type () const
 Getter for size_type_. More...
 
uint n_dofs () const
 Getter for n_dofs_. More...
 
const std::vector< uint > & input_ops () const
 Getter for input_ops_. More...
 
const std::vector< uint > & shape () const
 Getter for shape_. More...
 
std::string format_shape () const
 
void reinit_function (std::vector< ElOp< spacedim >> &operations, TableDbl &data_table, TableInt &int_table)
 Call reinit function on element table if function is defined. More...
 
void allocate_result (size_t data_size, PatchArena &arena)
 
Eigen::Matrix< ArenaVec< double >, Eigen::Dynamic, Eigen::Dynamic > & result_matrix ()
 Return map referenced result as Eigen::Matrix. More...
 
const Eigen::Matrix< ArenaVec< double >, Eigen::Dynamic, Eigen::Dynamic > & result_matrix () const
 Same as previous but return const reference. More...
 
template<unsigned int dim1, unsigned int dim2>
Eigen::Map< Eigen::Matrix< ArrayDbl, dim1, dim2 > > value (TableDbl &op_results, uint i_dof=0) const
 Return map referenced Eigen::Matrix of given dimension. More...
 
Eigen::Map< Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > > matrix_value (TableDbl &op_results, uint dim1, uint dim2) const
 Return map referenced Eigen::Matrix of given dimensions. More...
 
Eigen::Map< Eigen::Vector< double, Eigen::Dynamic > > vector_value (TableDbl &op_results) const
 Return map referenced Eigen::Matrix of given dimensions. More...
 

Protected Attributes

uint dim_
 Dimension. More...
 
std::vector< uintshape_
 Shape of stored data (size of vector or number of rows and cols of matrix) More...
 
uint result_row_
 First row to scalar, vector or matrix result TODO replace. More...
 
Eigen::Matrix< ArenaVec< double >, Eigen::Dynamic, Eigen::Dynamic > result_
 Result matrix of operation. More...
 
OpSizeType size_type_
 Type of operation by size of vector (element, point or fixed size) More...
 
std::vector< uintinput_ops_
 Indices of operations in PatchPointValues::operations_ vector on which ElOp is depended. More...
 
uint n_dofs_
 Number of DOFs of FE operations (or 1 in case of element operations) More...
 
ReinitFunction reinit_func
 Pointer to patch reinit function of element data table specialized by operation. More...
 

Detailed Description

template<unsigned int spacedim = 3>
class ElOp< spacedim >

Class represents element or FE operations.

Definition at line 536 of file patch_point_values.hh.

Constructor & Destructor Documentation

◆ ElOp()

template<unsigned int spacedim = 3>
ElOp< spacedim >::ElOp ( uint  dim,
std::initializer_list< uint shape,
uint  result_row,
ReinitFunction  reinit_f,
OpSizeType  size_type,
std::vector< uint input_ops = {},
uint  n_dofs = 1 
)
inline

Constructor

Set all data members.

Definition at line 543 of file patch_point_values.hh.

Member Function Documentation

◆ allocate_result()

template<unsigned int spacedim = 3>
void ElOp< spacedim >::allocate_result ( size_t  data_size,
PatchArena arena 
)
inline

Definition at line 610 of file patch_point_values.hh.

◆ dim()

template<unsigned int spacedim = 3>
uint ElOp< spacedim >::dim ( ) const
inline

Getter for dimension.

Definition at line 565 of file patch_point_values.hh.

◆ format_shape()

template<unsigned int spacedim = 3>
std::string ElOp< spacedim >::format_shape ( ) const
inline

Format shape to string

Method is used in output development method.

Definition at line 599 of file patch_point_values.hh.

◆ input_ops()

template<unsigned int spacedim = 3>
const std::vector<uint>& ElOp< spacedim >::input_ops ( ) const
inline

Getter for input_ops_.

Definition at line 585 of file patch_point_values.hh.

◆ matrix_value()

template<unsigned int spacedim = 3>
Eigen::Map<Eigen::Matrix<double, Eigen::Dynamic, Eigen::Dynamic> > ElOp< spacedim >::matrix_value ( TableDbl op_results,
uint  dim1,
uint  dim2 
) const
inline

Return map referenced Eigen::Matrix of given dimensions.

Definition at line 639 of file patch_point_values.hh.

◆ n_comp()

template<unsigned int spacedim = 3>
uint ElOp< spacedim >::n_comp ( ) const
inline

Return number of operation components

Value is computed from shape_ vector

Definition at line 560 of file patch_point_values.hh.

Here is the caller graph for this function:

◆ n_dofs()

template<unsigned int spacedim = 3>
uint ElOp< spacedim >::n_dofs ( ) const
inline

Getter for n_dofs_.

Definition at line 580 of file patch_point_values.hh.

◆ reinit_function()

template<unsigned int spacedim = 3>
void ElOp< spacedim >::reinit_function ( std::vector< ElOp< spacedim >> &  operations,
TableDbl data_table,
TableInt int_table 
)
inline

Call reinit function on element table if function is defined.

Definition at line 606 of file patch_point_values.hh.

◆ result_matrix() [1/2]

template<unsigned int spacedim = 3>
Eigen::Matrix<ArenaVec<double>, Eigen::Dynamic, Eigen::Dynamic>& ElOp< spacedim >::result_matrix ( )
inline

Return map referenced result as Eigen::Matrix.

Definition at line 617 of file patch_point_values.hh.

Here is the caller graph for this function:

◆ result_matrix() [2/2]

template<unsigned int spacedim = 3>
const Eigen::Matrix<ArenaVec<double>, Eigen::Dynamic, Eigen::Dynamic>& ElOp< spacedim >::result_matrix ( ) const
inline

Same as previous but return const reference.

Definition at line 625 of file patch_point_values.hh.

◆ result_row()

template<unsigned int spacedim = 3>
uint ElOp< spacedim >::result_row ( ) const
inline

Getter for result_row_.

Definition at line 570 of file patch_point_values.hh.

Here is the caller graph for this function:

◆ set_shape_vec()

template<unsigned int spacedim = 3>
std::vector<uint> ElOp< spacedim >::set_shape_vec ( std::initializer_list< uint shape) const
inline

Aligns shape_vec to 2 items (equal to matrix number of dimensions)

Definition at line 548 of file patch_point_values.hh.

◆ shape()

template<unsigned int spacedim = 3>
const std::vector<uint>& ElOp< spacedim >::shape ( ) const
inline

Getter for shape_.

Definition at line 590 of file patch_point_values.hh.

Here is the caller graph for this function:

◆ size_type()

template<unsigned int spacedim = 3>
OpSizeType ElOp< spacedim >::size_type ( ) const
inline

Getter for size_type_.

Definition at line 575 of file patch_point_values.hh.

◆ value()

template<unsigned int spacedim = 3>
template<unsigned int dim1, unsigned int dim2>
Eigen::Map<Eigen::Matrix<ArrayDbl, dim1, dim2> > ElOp< spacedim >::value ( TableDbl op_results,
uint  i_dof = 0 
) const
inline

Return map referenced Eigen::Matrix of given dimension.

Definition at line 634 of file patch_point_values.hh.

◆ vector_value()

template<unsigned int spacedim = 3>
Eigen::Map<Eigen::Vector<double, Eigen::Dynamic> > ElOp< spacedim >::vector_value ( TableDbl op_results) const
inline

Return map referenced Eigen::Matrix of given dimensions.

Definition at line 644 of file patch_point_values.hh.

Member Data Documentation

◆ dim_

template<unsigned int spacedim = 3>
uint ElOp< spacedim >::dim_
protected

Dimension.

Definition at line 650 of file patch_point_values.hh.

◆ input_ops_

template<unsigned int spacedim = 3>
std::vector<uint> ElOp< spacedim >::input_ops_
protected

Indices of operations in PatchPointValues::operations_ vector on which ElOp is depended.

Definition at line 656 of file patch_point_values.hh.

◆ n_dofs_

template<unsigned int spacedim = 3>
uint ElOp< spacedim >::n_dofs_
protected

Number of DOFs of FE operations (or 1 in case of element operations)

Definition at line 657 of file patch_point_values.hh.

◆ reinit_func

template<unsigned int spacedim = 3>
ReinitFunction ElOp< spacedim >::reinit_func
protected

Pointer to patch reinit function of element data table specialized by operation.

Definition at line 659 of file patch_point_values.hh.

◆ result_

template<unsigned int spacedim = 3>
Eigen::Matrix<ArenaVec<double>, Eigen::Dynamic, Eigen::Dynamic> ElOp< spacedim >::result_
protected

Result matrix of operation.

Definition at line 653 of file patch_point_values.hh.

◆ result_row_

template<unsigned int spacedim = 3>
uint ElOp< spacedim >::result_row_
protected

First row to scalar, vector or matrix result TODO replace.

Definition at line 652 of file patch_point_values.hh.

◆ shape_

template<unsigned int spacedim = 3>
std::vector<uint> ElOp< spacedim >::shape_
protected

Shape of stored data (size of vector or number of rows and cols of matrix)

Definition at line 651 of file patch_point_values.hh.

◆ size_type_

template<unsigned int spacedim = 3>
OpSizeType ElOp< spacedim >::size_type_
protected

Type of operation by size of vector (element, point or fixed size)

Definition at line 655 of file patch_point_values.hh.


The documentation for this class was generated from the following file: