Finite Element Domain Decomposition Library
FEDDLib
Loading...
Searching...
No Matches
NonLinElasAssFE_decl.hpp
1#ifndef NonLinElasAssFE_decl_hpp
2#define NonLinElasAssFE_decl_hpp
3#include "feddlib/problems/abstract/NonLinearProblem.hpp"
4#include <Thyra_PreconditionerBase.hpp>
5#include <Thyra_ModelEvaluatorBase_decl.hpp>
6#include "feddlib/problems/Solver/TimeSteppingTools.hpp"
7
16
17namespace FEDD{
18template <class SC = default_sc, class LO = default_lo, class GO = default_go, class NO = default_no>
19class NonLinElasAssFE : public NonLinearProblem<SC,LO,GO,NO> {
20
21public:
23
24 typedef Problem<SC,LO,GO,NO> Problem_Type;
25 typedef typename Problem_Type::Matrix_Type Matrix_Type;
26 typedef typename Problem_Type::MatrixPtr_Type MatrixPtr_Type;
27
28 typedef typename Problem_Type::MapConstPtr_Type MapConstPtr_Type;
29
30 typedef typename Problem_Type::BlockMatrix_Type BlockMatrix_Type;
31 typedef typename Problem_Type::BlockMatrixPtr_Type BlockMatrixPtr_Type;
32
33 typedef typename Problem_Type::MultiVector_Type MultiVector_Type;
34 typedef typename Problem_Type::MultiVectorPtr_Type MultiVectorPtr_Type;
35 typedef typename Problem_Type::MultiVectorConstPtr_Type MultiVectorConstPtr_Type;
36 typedef typename Problem_Type::BlockMultiVectorPtr_Type BlockMultiVectorPtr_Type;
37
38 typedef typename Problem_Type::DomainConstPtr_Type DomainConstPtr_Type;
39 typedef typename Problem_Type::CommConstPtr_Type CommConstPtr_Type;
40
41 typedef NonLinearProblem<SC,LO,GO,NO> NonLinearProblem_Type;
42 typedef typename NonLinearProblem_Type::BlockMultiVectorPtrArray_Type BlockMultiVectorPtrArray_Type;
43
44 typedef typename NonLinearProblem_Type::TpetraMatrix_Type TpetraMatrix_Type;
45
46 typedef typename NonLinearProblem_Type::ThyraVecSpace_Type ThyraVecSpace_Type;
47 typedef typename NonLinearProblem_Type::ThyraVec_Type ThyraVec_Type;
48 typedef typename NonLinearProblem_Type::ThyraOp_Type ThyraOp_Type;
49
50 typedef typename NonLinearProblem_Type::TpetraOp_Type TpetraOp_Type;
51
52 typedef Tpetra::CrsMatrix<SC, LO, GO, NO> tpetra_matrix;
53
54
56
58
59 NonLinElasAssFE( const DomainConstPtr_Type &domain, std::string FEType, ParameterListPtr_Type parameterList );
61 ~NonLinElasAssFE();
62
63 virtual void info();
64
65 virtual void assemble( std::string type = "" ) const;
66
67 void reAssemble(std::string type) const;
68
69 virtual void reAssemble( BlockMultiVectorPtr_Type previousSolution ) const{}
70
71 virtual void reAssemble( MatrixPtr_Type& massmatrix, std::string type ) const;
72
73 virtual void reAssembleExtrapolation(BlockMultiVectorPtrArray_Type previousSolutions);
74
75 virtual void calculateNonLinResidualVec(std::string type, double time=0.) const;
76
77 virtual void getValuesOfInterest( vec_dbl_Type& values ){}
78
79 virtual void computeValuesOfInterestAndExport() {}
80
81 void assembleSourceTermLoadstepping(double time=0.) const;
82
83 void updateTime() const;
84
85 void updateConcentration(MultiVectorConstPtr_Type concentration) {concentration_.reset(new MultiVector_Type (concentration));}
86// virtual void assembleExternal( std::string type ){}
87
88 mutable Teuchos::RCP<TimeSteppingTools> timeSteppingTool_;
89
90private:
91
92
93 mutable MultiVectorPtr_Type u_rep_;
94 MultiVectorPtr_Type concentration_;
95 double E_;
96 double mue_;
97 double C_;
98 double poissonRatio_;
99 double lambda_;
100 bool loadStepping_;
101 bool externalForce_;
102 bool nonlinearExternalForce_;
103
104 /*####################*/
105
106};
107}
108#endif
virtual void assemble(std::string type="") const
assemble of type exectuted by the derived specific non-linear problem classes
Definition NonLinElasAssFE_def.hpp:49
virtual void calculateNonLinResidualVec(std::string type, double time=0.) const
Virtual function which is implemented in the specific non-linear problem classes to calculate the non...
Definition NonLinElasAssFE_def.hpp:229
virtual void getValuesOfInterest(vec_dbl_Type &values)
Virtual class to extract values of interest that are computed during the solve.
Definition NonLinElasAssFE_decl.hpp:77
NonLinearProblem(CommConstPtr_Type comm)
Definition NonLinearProblem_def.hpp:23
Definition Problem_decl.hpp:42
Adaptive Mesh Refinement.
Definition AdaptiveMeshRefinement_decl.hpp:36