![]() |
NeoPZ
|
Public Member Functions | |
TPZGradientData () | |
~TPZGradientData () | |
TPZGradientData (const TPZGradientData &cp) | |
TPZGradientData & | operator= (const TPZGradientData ©) |
void | SetCel (TPZCompEl *cel, bool useweight, REAL paramK) |
void | Print (std::ostream &out) const |
void | GetCenterPointAndCellAveraged (TPZCompEl *cel, TPZManVector< REAL, 3 > &xcenter, STATE &solcel) |
void | InitializeGradData (TPZCompEl *cel) |
void | ComputeGradient () |
void | QRFactorization (TPZFMatrix< REAL > &matA, TPZFMatrix< REAL > &vecb) |
void | ComputeSlopeLimiter () |
Methods to calculate the slope limiter (alphaK) More... | |
void | ComputeSlopeLimiter2 () |
void | ComputeSlopeLimiter3 () |
void | ComputeWeights (REAL paramk) |
Method to calculate the weights that we will use in distorted meshes. More... | |
void | NodeCloserCenterX (TPZManVector< REAL, 3 > &nodecelX) |
Method to choose the node of the cell closer of your center point. More... | |
void | InsertWeights (TPZFMatrix< REAL > &DeltaH, TPZFMatrix< REAL > &DifSol) |
Method to insert the weights in the matrices of the system by least squares. More... | |
void | GetData (TPZManVector< REAL, 3 > ¢erPoint, TPZManVector< STATE, 3 > &grad, STATE &cellAverage, STATE &slopeLimiter) |
void | SetForcingFunctionExact (TPZAutoPointer< TPZFunction< STATE > > fp) |
Sets a procedure as exact solution for the problem. More... | |
void | EnableForcinFucnction () |
void | DisableForcinFucnction () |
int | HasForcingFunctionExact () |
void | UseGhostsNeighbors (TPZVec< REAL > LxLyLz, TPZVec< int > MatIdBC, TPZManVector< TPZVec< REAL > > coordmin, TPZManVector< TPZVec< REAL > > coordmax) |
void | CreateGhostsNeighbors (TPZCompEl *cel) |
Method to create ghosts neighbors of the element cel. This method is used only for regular domain. More... | |
Public Attributes | |
TPZAutoPointer< TPZFunction< STATE > > | fForcingFunctionExact |
Pointer to exact solution function, needed to calculate exact error. More... | |
bool | fUseForcinfFuncion |
Protected Attributes | |
TPZStack< STATE > | fSolCellAndNeighbors |
TPZStack< TPZManVector< REAL, 3 > > | fCenterPointCellAndNeighbors |
TPZStack< TPZManVector< REAL, 3 > > | fCenterPointInterface |
TPZManVector< STATE, 3 > | fGradient |
STATE | fSlopeLimiter |
int | fdim |
TPZStack< TPZCompEl * > | fCelAndNeighbors |
TPZManVector< REAL, 3 > | fWeightsGrad |
bool | fUseWeight |
REAL | fparamK |
bool | fGhostNeighbor |
TPZVec< REAL > | fLxLyLz |
TPZVec< int > | fMatIdBC |
TPZManVector< TPZVec< REAL > > | fcoordminBC |
TPZManVector< TPZVec< REAL > > | fcoordmaxBC |
Definition at line 26 of file pzgradientreconstruction.h.
TPZGradientReconstruction::TPZGradientData::TPZGradientData | ( | ) |
Definition at line 206 of file pzgradientreconstruction.cpp.
TPZGradientReconstruction::TPZGradientData::~TPZGradientData | ( | ) |
Definition at line 230 of file pzgradientreconstruction.cpp.
TPZGradientReconstruction::TPZGradientData::TPZGradientData | ( | const TPZGradientData & | cp | ) |
Definition at line 236 of file pzgradientreconstruction.cpp.
References fCelAndNeighbors, fCenterPointCellAndNeighbors, fCenterPointInterface, fcoordmaxBC, fcoordminBC, fdim, fForcingFunctionExact, fGhostNeighbor, fGradient, fLxLyLz, fMatIdBC, fparamK, fSlopeLimiter, fSolCellAndNeighbors, fUseForcinfFuncion, fUseWeight, and fWeightsGrad.
void TPZGradientReconstruction::TPZGradientData::ComputeGradient | ( | ) |
Definition at line 621 of file pzgradientreconstruction.cpp.
References DebugStop, TPZFMatrix< TVar >::Decompose_LU(), ELU, TPZFMatrix< TVar >::Redim(), TPZMatrix< TVar >::Rows(), TPZMatrix< TVar >::SolveDirect(), TPZFMatrix< TVar >::Substitution(), and TPZFMatrix< TVar >::Transpose().
void TPZGradientReconstruction::TPZGradientData::ComputeSlopeLimiter | ( | ) |
Methods to calculate the slope limiter (alphaK)
Definition at line 801 of file pzgradientreconstruction.cpp.
References DebugStop, fabs, IsZero(), TPZStack< T, NumExtAlloc >::Push(), PZError, and TPZVec< T >::size().
void TPZGradientReconstruction::TPZGradientData::ComputeSlopeLimiter2 | ( | ) |
Definition at line 887 of file pzgradientreconstruction.cpp.
References DebugStop, fabs, IsZero(), TPZStack< T, NumExtAlloc >::Push(), PZError, and TPZVec< T >::size().
void TPZGradientReconstruction::TPZGradientData::ComputeSlopeLimiter3 | ( | ) |
Definition at line 973 of file pzgradientreconstruction.cpp.
References DebugStop, IsZero(), TPZStack< T, NumExtAlloc >::Push(), PZError, and TPZVec< T >::size().
void TPZGradientReconstruction::TPZGradientData::ComputeWeights | ( | REAL | paramk | ) |
Method to calculate the weights that we will use in distorted meshes.
paramk | [in]: parameter used in the harmonic mean, equal 1 or 2 |
Definition at line 1053 of file pzgradientreconstruction.cpp.
References DebugStop, dist(), TPZGeoEl::Distance(), pow(), TPZGeoEl::Reference(), and TPZVec< T >::size().
void TPZGradientReconstruction::TPZGradientData::CreateGhostsNeighbors | ( | TPZCompEl * | cel | ) |
Method to create ghosts neighbors of the element cel. This method is used only for regular domain.
cel | [in]: computational element of the cell |
Definition at line 1145 of file pzgradientreconstruction.cpp.
References DebugStop, TPZCompElSide::EqualLevelElementList(), TPZMaterial::Id(), TPZCompEl::Material(), TPZGeoEl::NCornerNodes(), TPZVec< T >::NElements(), TPZGeoEl::NSides(), PZError, TPZCompEl::Reference(), TPZManVector< T, NumExtAlloc >::Resize(), and TPZBndCond::Type().
Referenced by UseGhostsNeighbors().
|
inline |
Definition at line 126 of file pzgradientreconstruction.h.
|
inline |
Definition at line 123 of file pzgradientreconstruction.h.
void TPZGradientReconstruction::TPZGradientData::GetCenterPointAndCellAveraged | ( | TPZCompEl * | cel, |
TPZManVector< REAL, 3 > & | xcenter, | ||
STATE & | solcel | ||
) |
Definition at line 406 of file pzgradientreconstruction.cpp.
References TPZGeoEl::CenterPoint(), TPZGeoEl::CreateSideIntegrationRule(), DebugStop, TPZVec< T >::Fill(), TPZCompEl::GetgOrder(), TPZIntPoints::NPoints(), TPZGeoEl::NSides(), TPZIntPoints::Point(), PZError, TPZGeoEl::RefElVolume(), TPZCompEl::Reference(), TPZVec< T >::Resize(), TPZVec< T >::size(), TPZCompEl::Solution(), and TPZGeoEl::X().
|
inline |
Definition at line 101 of file pzgradientreconstruction.h.
References fCenterPointCellAndNeighbors, fGradient, fSlopeLimiter, and fSolCellAndNeighbors.
|
inline |
Definition at line 129 of file pzgradientreconstruction.h.
void TPZGradientReconstruction::TPZGradientData::InitializeGradData | ( | TPZCompEl * | cel | ) |
Definition at line 457 of file pzgradientreconstruction.cpp.
References TPZGeoElSide::CenterPoint(), DebugStop, TPZCompElSide::EqualLevelElementList(), TPZCompElSide::HigherLevelElementList(), TPZCompElSide::LowerLevelElementList(), TPZGeoEl::NCornerNodes(), TPZVec< T >::NElements(), TPZGeoEl::NSides(), TPZStack< T, NumExtAlloc >::Push(), TPZCompEl::Reference(), TPZCompElSide::Reference(), TPZManVector< T, NumExtAlloc >::Resize(), TPZVec< T >::size(), and TPZGeoElSide::X().
void TPZGradientReconstruction::TPZGradientData::InsertWeights | ( | TPZFMatrix< REAL > & | DeltaH, |
TPZFMatrix< REAL > & | DifSol | ||
) |
Method to insert the weights in the matrices of the system by least squares.
DeltaH | [out]: matrix of distances between the center points |
DifSol | [out]: matrix of differences between the solutions |
Definition at line 1125 of file pzgradientreconstruction.cpp.
References TPZMatrix< TVar >::Cols(), DebugStop, and TPZMatrix< TVar >::Rows().
void TPZGradientReconstruction::TPZGradientData::NodeCloserCenterX | ( | TPZManVector< REAL, 3 > & | nodecelX | ) |
Method to choose the node of the cell closer of your center point.
cel | [in]: computational element of the cell |
nodecelX | [out]: node closer of the center point in coord X |
Definition at line 1091 of file pzgradientreconstruction.cpp.
References DebugStop, dist(), TPZGeoEl::Distance(), TPZGeoNode::GetCoordinates(), TPZGeoEl::NCornerNodes(), TPZGeoEl::Node(), TPZGeoEl::Reference(), TPZManVector< T, NumExtAlloc >::Resize(), and TPZVec< T >::size().
TPZGradientReconstruction::TPZGradientData & TPZGradientReconstruction::TPZGradientData::operator= | ( | const TPZGradientData & | copy | ) |
Definition at line 260 of file pzgradientreconstruction.cpp.
References fCelAndNeighbors, fCenterPointCellAndNeighbors, fCenterPointInterface, fcoordmaxBC, fcoordminBC, fdim, fForcingFunctionExact, fGhostNeighbor, fGradient, fLxLyLz, fMatIdBC, fparamK, fSlopeLimiter, fSolCellAndNeighbors, fUseForcinfFuncion, fUseWeight, and fWeightsGrad.
void TPZGradientReconstruction::TPZGradientData::Print | ( | std::ostream & | out | ) | const |
Definition at line 322 of file pzgradientreconstruction.cpp.
void TPZGradientReconstruction::TPZGradientData::QRFactorization | ( | TPZFMatrix< REAL > & | matA, |
TPZFMatrix< REAL > & | vecb | ||
) |
Definition at line 706 of file pzgradientreconstruction.cpp.
References TPZMatrix< TVar >::Cols(), DebugStop, m, TPZMatrix< TVar >::Multiply(), TPZFMatrix< TVar >::Redim(), test::res, TPZMatrix< TVar >::Rows(), and TPZFMatrix< TVar >::Transpose().
void TPZGradientReconstruction::TPZGradientData::SetCel | ( | TPZCompEl * | cel, |
bool | useweight, | ||
REAL | paramK | ||
) |
Definition at line 287 of file pzgradientreconstruction.cpp.
References DebugStop, TPZCompMesh::Dimension(), TPZCompEl::Dimension(), and TPZCompEl::Mesh().
|
inline |
Sets a procedure as exact solution for the problem.
fp | pointer of exact solution function |
Definition at line 116 of file pzgradientreconstruction.h.
|
inline |
Definition at line 139 of file pzgradientreconstruction.h.
References CreateGhostsNeighbors(), fcoordmaxBC, fcoordminBC, fGhostNeighbor, fLxLyLz, and fMatIdBC.
fNeighborsCel | Neighbors of the cell |
Definition at line 177 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().
|
protected |
CenterPointCellAndNeighbors | Center point of the element and neighbors |
Definition at line 162 of file pzgradientreconstruction.h.
Referenced by GetData(), operator=(), and TPZGradientData().
|
protected |
CenterPointInterface | Center point of the interface between element and neighbors |
Definition at line 165 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().
|
protected |
fcoordminBC | The minimum coordinate for each boundary (xmin,ymin,zmin) |
Definition at line 202 of file pzgradientreconstruction.h.
Referenced by operator=(), TPZGradientData(), and UseGhostsNeighbors().
|
protected |
fMatIdBC | Indices of the boundary conditions (Neumann type, No flux) that there are ghosts |
Definition at line 199 of file pzgradientreconstruction.h.
Referenced by operator=(), TPZGradientData(), and UseGhostsNeighbors().
|
protected |
fdim | Dimension of the element |
Definition at line 174 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().
TPZAutoPointer<TPZFunction<STATE> > TPZGradientReconstruction::TPZGradientData::fForcingFunctionExact |
Pointer to exact solution function, needed to calculate exact error.
Definition at line 110 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().
|
protected |
fGhostNeighbor | Parameter that indicates the use of ghosts neighbors in some boundary of the mesh. |
Definition at line 191 of file pzgradientreconstruction.h.
Referenced by operator=(), TPZGradientData(), and UseGhostsNeighbors().
|
protected |
Gradient | gradient reconstructed |
Definition at line 168 of file pzgradientreconstruction.h.
Referenced by GetData(), operator=(), and TPZGradientData().
|
protected |
Definition at line 193 of file pzgradientreconstruction.h.
Referenced by operator=(), TPZGradientData(), and UseGhostsNeighbors().
|
protected |
fLxLyLz | Dimension of the domain: Lx X Ly X Lz |
Definition at line 196 of file pzgradientreconstruction.h.
Referenced by operator=(), TPZGradientData(), and UseGhostsNeighbors().
|
protected |
fparamK | parameter used in the harmonic mean, equal 1 or 2 |
Definition at line 186 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().
|
protected |
SlopeLimiter | Value of the slope limiter |
Definition at line 171 of file pzgradientreconstruction.h.
Referenced by GetData(), operator=(), and TPZGradientData().
|
protected |
SolCellAndNeighbors | Value of the cells averaged |
Definition at line 159 of file pzgradientreconstruction.h.
Referenced by GetData(), operator=(), and TPZGradientData().
bool TPZGradientReconstruction::TPZGradientData::fUseForcinfFuncion |
Definition at line 121 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().
|
protected |
fUseWeight | Parameter indicates if the mesh is distorted |
Definition at line 183 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().
|
protected |
fWeightsGrad | vector with weights to each neighbor |
Definition at line 180 of file pzgradientreconstruction.h.
Referenced by operator=(), and TPZGradientData().