33 #ifndef __H__UG__LIB_DISC__SPATIAL_DISC__DATA_EVALUATOR__
34 #define __H__UG__LIB_DISC__SPATIAL_DISC__DATA_EVALUATOR__
53 template <
typename TDomain,
typename TElemDisc>
63 const std::vector<TElemDisc*>& vElemDisc,
65 const bool bNonRegularGrid,
67 const std::vector<number>* vScaleMass = NULL,
68 const std::vector<number>* vScaleStiff = NULL);
149 template <
typename TDomain>
157 const bool bNonRegularGrid,
159 const std::vector<number>* vScaleMass = NULL,
160 const std::vector<number>* vScaleStiff = NULL)
161 :
DataEvaluatorBase<TDomain,
IElemError<TDomain> > (discPart, vElemDisc, fctPat, bNonRegularGrid, locTimeSeries, vScaleMass, vScaleStiff) {}
167 template <
typename TDomain>
179 const bool bNonRegularGrid,
181 const std::vector<number>* vScaleMass = NULL,
182 const std::vector<number>* vScaleStiff = NULL)
183 :
DataEvaluatorBase<TDomain,
IElemDisc<TDomain> > (discPart, vElemDisc, fctPat, bNonRegularGrid, locTimeSeries, vScaleMass, vScaleStiff) {}
Definition: smart_pointer.h:296
Definition: smart_pointer.h:108
helper class to evaluate data evaluation for local contributions during assembling
Definition: data_evaluator.h:55
bool m_bUseHanging
flag if hanging nodes are used
Definition: data_evaluator.h:128
void prepare_err_est_elem_loop(const ReferenceObjectID id, int si)
prepares the element loop for all IElemDiscs for the computation of the error estimator
Definition: data_evaluator_impl.h:331
bool m_bNeedLocTimeSeries
flag indicating if any elem disc needs local time series
Definition: data_evaluator.h:131
LocalVectorTimeSeries * m_pLocTimeSeries
local time series (non-const since mapping may change)
Definition: data_evaluator.h:134
std::vector< TElemDisc * > m_vElemDisc[MAX_PROCESS]
elem disc data
Definition: data_evaluator.h:122
std::vector< SmartPtr< ICplUserData< dim > > > m_vDependentData
Definition: data_evaluator.h:143
void clear_positions_in_user_data()
clears all requested positions in user data
Definition: data_evaluator_impl.h:297
static const int dim
world dimension
Definition: data_evaluator.h:58
void clear_extracted_data_and_mappings()
clears imports and user data and mappings betweem commonFctGrp and local
Definition: data_evaluator_impl.h:281
DataEvaluatorBase(int discPart, const std::vector< TElemDisc * > &vElemDisc, ConstSmartPtr< FunctionPattern > fctPat, const bool bNonRegularGrid, LocalVectorTimeSeries *locTimeSeries=NULL, const std::vector< number > *vScaleMass=NULL, const std::vector< number > *vScaleStiff=NULL)
sets the elem discs to evaluate
Definition: data_evaluator_impl.h:40
std::vector< IDataImport< dim > * > m_vImport[MAX_PROCESS][MAX_PART]
imports that must be evaluated
Definition: data_evaluator.h:137
int m_discPart
disc part needed (MASS and/or STIFF and/or RHS)
Definition: data_evaluator.h:119
void add_data_to_eval_data(std::vector< SmartPtr< ICplUserData< dim > > > &vEvalData, std::vector< SmartPtr< ICplUserData< dim > > > &vTryingToAdd)
tries to add the last entry of vTryingToAdd to the eval data
Definition: data_evaluator_impl.h:101
void prepare_err_est_elem(LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], const LocalIndices &ind, bool bDeriv=false)
prepares the element for all IElemDiscs
Definition: data_evaluator_impl.h:389
bool time_series_needed() const
returns if local time series is really needed for assembling
Definition: data_evaluator.h:74
void set_time_point(const size_t timePoint)
sets the time point for data evaluation
Definition: data_evaluator_impl.h:311
void extract_imports_and_userdata(int subsetIndex, int discPart)
extracts imports and userdata from IElemDiscs
Definition: data_evaluator_impl.h:147
std::vector< SmartPtr< ICplUserData< dim > > > m_vPosData
Definition: data_evaluator.h:142
void compute_err_est_rhs_elem(GridObject *elem, const MathVector< dim > vCornerCoords[], const LocalIndices &ind, const number scaleMass=(number) 1.0, const number scaleStiff=(number) 1.0)
compute contributions of the local error indicators in one element for all IElemDiscs
Definition: data_evaluator_impl.h:464
ConstSmartPtr< FunctionPattern > m_spFctPattern
underlying function pattern
Definition: data_evaluator.h:125
bool use_hanging() const
returns if one of the element discs needs hanging dofs
Definition: data_evaluator.h:77
void compute_err_est_M_elem(LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], const LocalIndices &ind, const number scaleMass=(number) 1.0, const number scaleStiff=(number) 1.0)
compute contributions of the local error indicators in one element for all IElemDiscs
Definition: data_evaluator_impl.h:445
std::vector< SmartPtr< ICplUserData< dim > > > m_vConstData
Definition: data_evaluator.h:141
void finish_err_est_elem_loop()
finishes the error estimator element loop for all IElemDiscs
Definition: data_evaluator_impl.h:374
void compute_err_est_A_elem(LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], const LocalIndices &ind, const number scaleMass=(number) 1.0, const number scaleStiff=(number) 1.0)
compute contributions of the local error indicators in one element for all IElemDiscs
Definition: data_evaluator_impl.h:426
Evaluation for IElemDisc.
Definition: data_evaluator.h:169
void finish_elem_loop()
finishes the element loop for all IElemDiscs
Definition: data_evaluator.cpp:91
void finish_timestep(const number time, VectorProxyBase *u, size_t algebra_id)
finishes all time-dependent IElemDiscs
Definition: data_evaluator.cpp:220
void add_jac_A_elem(LocalMatrix &A, LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], ProcessType type=PT_ALL)
compute local stiffness matrix for all IElemDiscs
Definition: data_evaluator.cpp:243
void add_def_M_elem(LocalVector &d, LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], ProcessType type=PT_ALL)
compute local mass defect for all IElemDiscs
Definition: data_evaluator.cpp:336
void prepare_timestep(number future_time, const number time, VectorProxyBase *u, size_t algebra_id)
prepares all time-dependent IElemDiscs
Definition: data_evaluator.cpp:135
void add_jac_M_elem(LocalMatrix &M, LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], ProcessType type=PT_ALL)
compute local mass matrix for all IElemDiscs
Definition: data_evaluator.cpp:280
void finish_timestep_elem(const number time, LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[])
finishes the elements of all time-dependent IElemDiscs
Definition: data_evaluator.cpp:232
void prepare_elem(LocalVector &u, GridObject *elem, const ReferenceObjectID roid, const MathVector< dim > vCornerCoords[], const LocalIndices &ind, bool bDeriv=false)
prepares the element for all IElemDiscs
Definition: data_evaluator.cpp:159
void prepare_elem_loop(const ReferenceObjectID id, int si)
prepares the element loop for all IElemDiscs
Definition: data_evaluator.cpp:48
DataEvaluator(int discPart, const std::vector< IElemDisc< TDomain > * > &vElemDisc, ConstSmartPtr< FunctionPattern > fctPat, const bool bNonRegularGrid, LocalVectorTimeSeries *locTimeSeries=NULL, const std::vector< number > *vScaleMass=NULL, const std::vector< number > *vScaleStiff=NULL)
sets the elem discs to evaluate
Definition: data_evaluator.h:176
void prepare_timestep_elem(const number time, LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[])
prepares the elements of all time-dependent IElemDiscs
Definition: data_evaluator.cpp:147
DataEvaluatorBase< TDomain, IElemDisc< TDomain > > base_type
Definition: data_evaluator.h:172
void add_def_A_elem(LocalVector &d, LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], ProcessType type=PT_ALL)
compute local stiffness defect for all IElemDiscs
Definition: data_evaluator.cpp:310
void add_rhs_elem(LocalVector &rhs, GridObject *elem, const MathVector< dim > vCornerCoords[], ProcessType type=PT_ALL)
compute local rhs for all IElemDiscs
Definition: data_evaluator.cpp:349
void add_def_A_expl_elem(LocalVector &d, LocalVector &u, GridObject *elem, const MathVector< dim > vCornerCoords[], ProcessType type=PT_ALL)
compute local stiffness defect for all IElemDiscs explicit
Definition: data_evaluator.cpp:323
Evaluation for IElemError.
Definition: data_evaluator.h:151
ErrorEvaluator(int discPart, const std::vector< IElemError< TDomain > * > &vElemDisc, ConstSmartPtr< FunctionPattern > fctPat, const bool bNonRegularGrid, LocalVectorTimeSeries *locTimeSeries=NULL, const std::vector< number > *vScaleMass=NULL, const std::vector< number > *vScaleStiff=NULL)
sets the elem discs to evaluate
Definition: data_evaluator.h:154
The base class for all geometric objects, such as vertices, edges, faces, volumes,...
Definition: grid_base_objects.h:157
Base class for UserData.
Definition: user_data.h:260
Definition: elem_disc_interface.h:800
Definition: elem_disc_interface.h:760
Definition: local_algebra.h:50
Definition: local_algebra.h:422
Definition: local_algebra.h:198
time series of local vectors
Definition: solution_time_series.h:167
double number
Definition: types.h:124
ReferenceObjectID
these ids are used to identify the shape of a geometric object.
Definition: grid_base_objects.h:74
ProcessType
Definition: data_evaluator.h:42
@ MAX_PROCESS
Definition: data_evaluator.h:42
@ PT_INSTATIONARY
Definition: data_evaluator.h:42
@ PT_ALL
Definition: data_evaluator.h:42
@ PT_STATIONARY
Definition: data_evaluator.h:42
@ MAX_PART
Definition: data_import.h:49
Proxy struct for generic passing of any vector type.
Definition: elem_disc_interface.h:70