35 #ifndef huertaerrorestimator_h 36 #define huertaerrorestimator_h 38 #include "../sm/refinedelement.h" 39 #include "../sm/refinedmesh.h" 50 #define _IFT_HuertaErrorEstimator_Name "huerta" 51 #define _IFT_HuertaErrorEstimator_normtype "normtype" 52 #define _IFT_HuertaErrorEstimator_refinelevel "refinelevel" 53 #define _IFT_HuertaErrorEstimator_requirederror "requirederror" 54 #define _IFT_HuertaErrorEstimator_skipsteps "skipsteps" 55 #define _IFT_HuertaErrorEstimator_initialskipsteps "initialskipsteps" 56 #define _IFT_HuertaErrorEstimator_werror "werror" 57 #define _IFT_HuertaErrorEstimator_perfectCSect "perCSect" 58 #define _IFT_HuertaErrorEstimator_impCSect "impCSect" 59 #define _IFT_HuertaErrorEstimator_impPos "imppos" 60 #define _IFT_HuertaErrorEstimator_exact "exact" 65 #define _IFT_HuertaRemeshingCriteria_requirederror "requirederror" 66 #define _IFT_HuertaRemeshingCriteria_minelemsize "minelemsize" 67 #define _IFT_HuertaRemeshingCriteria_noremesh "noremesh" 68 #define _IFT_HuertaRemeshingCriteria_werror "werror" 69 #define _IFT_HuertaRemeshingCriteria_refinecoeff "refinecoeff" 74 #define _IFT_HuertaErrorEstimatorInterface_coords "coords" 139 refinedElementList(), refinedMesh()
148 stepsToSkip = skippedSteps = initialSkipSteps = 0;
170 virtual const char *
giveClassName()
const {
return "HuertaErrorEstimator"; }
219 int nodes,
int elems,
int csects,
int mats,
int loads,
int funcs,
234 enum SetupMode { CountMode = 0, NodeMode = 1, ElemMode = 2, BCMode = 3 };
240 virtual void HuertaErrorEstimatorI_setupRefinedElementProblem(
RefinedElement *refinedElement,
int level,
int nodeId,
243 int &localNodeId,
int &localElemId,
int &localBcId,
251 int level,
int nodeId,
IntArray &localNodeIdArray,
IntArray &globalNodeIdArray,
254 int &localNodeId,
int &localElemId,
int &localBcId,
259 int level,
int nodeId,
IntArray &localNodeIdArray,
IntArray &globalNodeIdArray,
262 int &localNodeId,
int &localElemId,
int &localBcId,
267 int level,
int nodeId,
IntArray &localNodeIdArray,
IntArray &globalNodeIdArray,
270 int &localNodeId,
int &localElemId,
int &localBcId,
271 int hexaSideNode [ 1 ] [ 3 ],
int hexaFaceNode [ 1 ] [ 3 ],
317 virtual double giveRequiredDofManDensity(
int num,
TimeStep *tStep,
int relative = 0);
318 virtual double giveDofManDensity(
int num);
320 virtual int estimateMeshDensities(
TimeStep *tStep);
324 virtual const char *
giveClassName()
const {
return "HuertaErrorEstimator"; }
328 #endif // huertaerrorestimator_h HuertaRemeshingCriteriaModeType
Mode of receiver, allows to use it in more general situations.
void setupRefinedProblemEpilog1(int csects, int mats, int loads, int nlbarriers)
The base class for all remeshing criteria.
The class representing Huerta remeshing criteria.
void extractVectorFrom(Element *element, FloatArray &vector, FloatArray &answer, int dofs, TimeStep *tStep)
Extracts nodal vector from global vector for each dof of all element nodes.
HuertaErrorEstimatorInterface()
Constructor.
RefinedMesh refinedMesh
Mesh refinement.
std::vector< RefinedElement > refinedElementList
Fine mesh.
virtual double giveElementError(EE_ErrorType type, Element *elem, TimeStep *tStep)
Returns the element error.
void solveRefinedWholeProblem(IntArray &localNodeIdArray, IntArray &globalNodeIdArray, TimeStep *tStep)
Solves the refined whole problem.
virtual int estimateError(EE_ErrorMode err_mode, TimeStep *tStep)
Estimates the error on associated domain at given time step.
HuertaRemeshingCriteriaModeType mode
Mode of receiver.
The purpose of DataStream abstract class is to allow to store/restore context to different streams...
AnalysisMode giveAnalysisMode()
AnalysisMode
Mode of analysis.
double globalWENorm
Global weighted error norm.
long StateCounterType
StateCounterType type used to indicate solution state.
NormType
Type of norm used.
double globalErrorEstimate
Global error estimate (relative)
virtual const char * giveInputRecordName() const
StateCounterType stateCounter
Actual values (densities) state counter.
Abstract base class for all finite elements.
EE_ErrorType
Type characterizing different type of element errors.
virtual const char * giveClassName() const
virtual ~HuertaRemeshingCriteria()
Destructor.
Class implementing an array of integers.
void solveRefinedPatchProblem(int nodeId, IntArray &localNodeIdArray, IntArray &globalNodeIdArray, TimeStep *tStep)
Solves the refined patch problem.
double requiredError
Required error to obtain.
StateCounterType stateCounter
Actual state counter.
NormType normType
Type of norm used.
int giveRefinementLevel()
Returns refinement level.
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Restores the receiver state previously written in stream.
bool wError
Weighted error flag.
The element interface corresponding to HuertaErrorEstimator.
bool wError
Weighted error flag.
virtual RemeshingCriteria * giveRemeshingCrit()
Returns reference to associated remeshing criteria.
AnalysisMode mode
Linear analysis flag.
virtual const char * giveClassName() const
void solveRefinedElementProblem(int elemId, IntArray &localNodeIdArray, IntArray &globalNodeIdArray, TimeStep *tStep)
Solves the refined element problem.
void setupRefinedProblemEpilog2(int tfuncs)
void setupRefinedProblemProlog(const char *problemName, int problemId, IntArray &localNodeIdArray, int nodes, int elems, int csects, int mats, int loads, int funcs, IntArray &controlNode, IntArray &controlDof, TimeStep *tStep)
FloatArray nodalDensities
Array of nodal mesh densities.
SetupMode
Mode for problem setup.
double globalENorm
Global error norm.
FloatArray primaryUnknownError
Primary unknown nodal error.
The base class for all error estimation or error indicator algorithms.
virtual const char * giveInputRecordName() const
Class representing vector of real numbers.
virtual double giveValue(EE_ValueType type, TimeStep *tStep)
Returns the characteristic value of given type.
RemeshingStrategy
Type representing the remeshing strategy.
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Stores receiver state to output stream.
Implementation of matrix containing floating point numbers.
void buildRefinedMesh()
Builds refined mesh.
EE_ErrorMode
Type determining whether temporary or equilibrated variables are used for error evaluation.
IRResultType
Type defining the return values of InputRecord reading operations.
ErrorEstimatorType eeType
bool noRemesh
Remeshing flag.
FloatArray eNorms
Cache storing element norms.
double minElemSize
Minimum element size alloved.
HuertaErrorEstimator(int n, Domain *d)
Constructor.
double refineCoeff
Refinement coefficient.
virtual ~HuertaErrorEstimator()
Destructor.
long ContextMode
Context mode (mask), defining the type of information written/read to/from context.
EE_ValueType
Type characterizing different type of errors.
double requiredError
Required error to obtain.
the oofem namespace is to define a context or scope in which all oofem names are defined.
RemeshingStrategy remeshingStrategy
Remeshing strategy proposed.
The implementation of Zienkiewicz Zhu Error Estimator.
Class representing integration point in finite element program.
Class representing solution step.
double globalUNorm
Global norm of primary unknown.
int refineLevel
Refinement level.