NeoPZ
Public Member Functions | Private Attributes | List of all members
TPZMeshSolution Class Reference

class which represents the solution and its derivative as a function More...

#include <TPZMeshSolution.h>

Inheritance diagram for TPZMeshSolution:
[legend]
Collaboration diagram for TPZMeshSolution:
[legend]

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

TPZCompMeshfMesh
 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 TPZSavableCreateInstance (const int &classId)
 

Detailed Description

class which represents the solution and its derivative as a function

Definition at line 20 of file TPZMeshSolution.h.

Constructor & Destructor Documentation

◆ TPZMeshSolution()

TPZMeshSolution::TPZMeshSolution ( TPZCompMesh cmesh,
int  materialid 
)

◆ ~TPZMeshSolution()

TPZMeshSolution::~TPZMeshSolution ( )

Class destructor.

Definition at line 58 of file TPZMeshSolution.cpp.

Member Function Documentation

◆ ClassId()

int TPZMeshSolution::ClassId ( ) const
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().

◆ Execute()

void TPZMeshSolution::Execute ( const TPZVec< REAL > &  x,
TPZVec< STATE > &  f,
TPZFMatrix< STATE > &  df 
)
overridevirtual

Performs function computation.

Parameters
xpoint coordinate which is suppose to be in real coordinate system but can be in master coordinate system in derived classes.
ffunction values
dffunction 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().

◆ NFunctions()

virtual int TPZMeshSolution::NFunctions ( ) const
inlineoverridevirtual

Returns number of functions.

Reimplemented from TPZFunction< STATE >.

Definition at line 67 of file TPZMeshSolution.h.

References fNumSolutions.

Referenced by Print().

◆ PolynomialOrder()

virtual int TPZMeshSolution::PolynomialOrder ( ) const
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().

◆ Print()

void TPZMeshSolution::Print ( std::ostream &  out)
overridevirtual

Print a brief statement.

Reimplemented from TPZFunction< STATE >.

Definition at line 91 of file TPZMeshSolution.cpp.

References NFunctions(), and PolynomialOrder().

Referenced by PolynomialOrder().

Member Data Documentation

◆ fDimension

int TPZMeshSolution::fDimension
private

dimension of the problem

Definition at line 33 of file TPZMeshSolution.h.

Referenced by Execute(), and TPZMeshSolution().

◆ fGeoElIndex

int64_t TPZMeshSolution::fGeoElIndex
private

Geometric element index where the last point was found.

Definition at line 27 of file TPZMeshSolution.h.

Referenced by Execute(), and TPZMeshSolution().

◆ fGradVarindex

int TPZMeshSolution::fGradVarindex
private

variable index of the gradient of the solution

Definition at line 39 of file TPZMeshSolution.h.

Referenced by Execute(), and TPZMeshSolution().

◆ fLastLoc

TPZManVector<REAL,3> TPZMeshSolution::fLastLoc
private

Parametric coordinate where the last point was found.

Definition at line 30 of file TPZMeshSolution.h.

Referenced by Execute(), and TPZMeshSolution().

◆ fMaterialIndex

int TPZMeshSolution::fMaterialIndex
private

index of the material object

Definition at line 48 of file TPZMeshSolution.h.

◆ fMesh

TPZCompMesh* TPZMeshSolution::fMesh
private

Mesh for which the solution applies.

Definition at line 24 of file TPZMeshSolution.h.

Referenced by Execute(), and TPZMeshSolution().

◆ fNumSolutions

int TPZMeshSolution::fNumSolutions
private

number of state variables of the differential equation

Definition at line 42 of file TPZMeshSolution.h.

Referenced by Execute(), NFunctions(), and TPZMeshSolution().

◆ fPolynomialOrder

int TPZMeshSolution::fPolynomialOrder
private

the polynomial order of the function

Definition at line 45 of file TPZMeshSolution.h.

Referenced by PolynomialOrder().

◆ fSolutionVarindex

int TPZMeshSolution::fSolutionVarindex
private

variable index of the solution variable

Definition at line 36 of file TPZMeshSolution.h.

Referenced by Execute(), and TPZMeshSolution().


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