NeoPZ
|
class which represents the solution and its derivative as a function More...
#include <TPZMeshSolution.h>
Public Member Functions | |
TPZMeshSolution (TPZCompMesh *cmesh, int materialid) | |
Class constructor. More... | |
~TPZMeshSolution () | |
Class destructor. More... | |
virtual void | Execute (const TPZVec< REAL > &x, TPZVec< STATE > &f, TPZFMatrix< STATE > &df) override |
Performs function computation. More... | |
virtual int | NFunctions () const override |
Returns number of functions. More... | |
virtual int | PolynomialOrder () const override |
Polynomial order of this function. More... | |
virtual void | Print (std::ostream &out) override |
Print a brief statement. More... | |
int | ClassId () const override |
Define the class id associated with the class. More... | |
Public Member Functions inherited from TPZFunction< STATE > | |
TPZFunction () | |
Class constructor. More... | |
~TPZFunction () | |
Class destructor. More... | |
virtual void | Execute (const TPZVec< REAL > &x, REAL time, TPZVec< STATE > &f, TPZFMatrix< STATE > &gradf) |
Performs time dependent function computation. More... | |
virtual void | Execute (const TPZVec< REAL > &x, const TPZFMatrix< REAL > &axes, TPZVec< STATE > &f, TPZFMatrix< STATE > &df) |
Execute method receiving axes. It is used in shape functions. More... | |
virtual void | Execute (const TPZVec< REAL > &x, TPZVec< STATE > &f) |
Simpler version of Execute method which does not compute function derivatives. More... | |
int | ClassId () const override |
Define the class id associated with the class. More... | |
void | Write (TPZStream &buf, int withclassid) const override |
Writes this object to the TPZStream buffer. Include the classid if withclassid = true. More... | |
void | Read (TPZStream &buf, void *context) override |
read objects from the stream More... | |
Public Member Functions inherited from TPZSavable | |
TPZSavable () | |
virtual | ~TPZSavable () |
virtual std::list< std::map< std::string, uint64_t > > | VersionHistory () const |
virtual std::pair< std::string, uint64_t > | Version () const |
virtual bool | Compare (TPZSavable *copy, bool override=false) |
Compares the object for identity with the object pointed to, eventually copy the object. More... | |
virtual bool | Compare (TPZSavable *copy, bool override=false) const |
Compares the object for identity with the object pointed to, eventually copy the object. More... | |
Public Member Functions inherited from TPZRegisterClassId | |
template<typename T > | |
TPZRegisterClassId (int(T::*)() const) | |
TPZRegisterClassId ()=default | |
Private Attributes | |
TPZCompMesh * | fMesh |
Mesh for which the solution applies. More... | |
int64_t | fGeoElIndex |
Geometric element index where the last point was found. More... | |
TPZManVector< REAL, 3 > | fLastLoc |
Parametric coordinate where the last point was found. More... | |
int | fDimension |
dimension of the problem More... | |
int | fSolutionVarindex |
variable index of the solution variable More... | |
int | fGradVarindex |
variable index of the gradient of the solution More... | |
int | fNumSolutions |
number of state variables of the differential equation More... | |
int | fPolynomialOrder |
the polynomial order of the function More... | |
int | fMaterialIndex |
index of the material object More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from TPZSavable | |
static std::set< TPZRestoreClassBase * > & | RestoreClassSet () |
This static function guarantees that the gMap object is available when needed. More... | |
static std::map< int, TPZRestore_t > & | ClassIdMap () |
This static function guarantees that the gMap object is available when needed. More... | |
static std::pair< std::string, uint64_t > | NeoPZVersion () |
static void | Register (TPZRestoreClassBase *restore) |
static void | RegisterClassId (int classid, TPZRestore_t fun) |
static TPZSavable * | CreateInstance (const int &classId) |
class which represents the solution and its derivative as a function
Definition at line 20 of file TPZMeshSolution.h.
TPZMeshSolution::TPZMeshSolution | ( | TPZCompMesh * | cmesh, |
int | materialid | ||
) |
Class constructor.
Definition at line 30 of file TPZMeshSolution.cpp.
References DebugStop, TPZCompMesh::Dimension(), TPZGeoEl::Dimension(), TPZGeoMesh::Element(), fDimension, fGeoElIndex, fGradVarindex, TPZCompMesh::FindMaterial(), fLastLoc, fMesh, fNumSolutions, fSolutionVarindex, TPZGeoMesh::NElements(), TPZMaterial::NSolutionVariables(), TPZCompMesh::Reference(), TPZManVector< T, NumExtAlloc >::Resize(), and TPZMaterial::VariableIndex().
TPZMeshSolution::~TPZMeshSolution | ( | ) |
Class destructor.
Definition at line 58 of file TPZMeshSolution.cpp.
|
overridevirtual |
Define the class id associated with the class.
This id has to be unique for all classes A non unique id is flagged at the startup of the program
Implements TPZSavable.
Definition at line 99 of file TPZMeshSolution.cpp.
References TPZFunction< TVar >::ClassId(), and Hash().
Referenced by PolynomialOrder().
|
overridevirtual |
Performs function computation.
x | point coordinate which is suppose to be in real coordinate system but can be in master coordinate system in derived classes. |
f | function values |
df | function derivatives |
Reimplemented from TPZFunction< STATE >.
Definition at line 69 of file TPZMeshSolution.cpp.
References TPZGeoMesh::Element(), fDimension, fGeoElIndex, fGradVarindex, TPZGeoMesh::FindElement(), fLastLoc, fMesh, fNumSolutions, fSolutionVarindex, TPZCompMesh::Reference(), TPZGeoEl::Reference(), TPZMatrix< TVar >::Rows(), and TPZCompEl::Solution().
|
inlineoverridevirtual |
Returns number of functions.
Reimplemented from TPZFunction< STATE >.
Definition at line 67 of file TPZMeshSolution.h.
References fNumSolutions.
Referenced by Print().
|
inlineoverridevirtual |
Polynomial order of this function.
In case of non-polynomial function it can be a reasonable approximation order.
Reimplemented from TPZFunction< STATE >.
Definition at line 74 of file TPZMeshSolution.h.
References ClassId(), fPolynomialOrder, and Print().
Referenced by Print().
|
overridevirtual |
Print a brief statement.
Reimplemented from TPZFunction< STATE >.
Definition at line 91 of file TPZMeshSolution.cpp.
References NFunctions(), and PolynomialOrder().
Referenced by PolynomialOrder().
|
private |
dimension of the problem
Definition at line 33 of file TPZMeshSolution.h.
Referenced by Execute(), and TPZMeshSolution().
|
private |
Geometric element index where the last point was found.
Definition at line 27 of file TPZMeshSolution.h.
Referenced by Execute(), and TPZMeshSolution().
|
private |
variable index of the gradient of the solution
Definition at line 39 of file TPZMeshSolution.h.
Referenced by Execute(), and TPZMeshSolution().
|
private |
Parametric coordinate where the last point was found.
Definition at line 30 of file TPZMeshSolution.h.
Referenced by Execute(), and TPZMeshSolution().
|
private |
index of the material object
Definition at line 48 of file TPZMeshSolution.h.
|
private |
Mesh for which the solution applies.
Definition at line 24 of file TPZMeshSolution.h.
Referenced by Execute(), and TPZMeshSolution().
|
private |
number of state variables of the differential equation
Definition at line 42 of file TPZMeshSolution.h.
Referenced by Execute(), NFunctions(), and TPZMeshSolution().
|
private |
the polynomial order of the function
Definition at line 45 of file TPZMeshSolution.h.
Referenced by PolynomialOrder().
|
private |
variable index of the solution variable
Definition at line 36 of file TPZMeshSolution.h.
Referenced by Execute(), and TPZMeshSolution().