2 #ifndef TPZANALYTICSOLUTION 3 #define TPZANALYTICSOLUTION 44 fAnalytic->
Force(x,f);
49 fAnalytic->
Force(x,f);
83 fAnalytic->
Sigma(x,df);
178 enum EDefState {ENone, EDispx, EDispy, ERot, EStretchx, EUniAxialx, EStretchy, EShear, EBend, ELoadedBeam, Etest1, Etest2, EThiago, EPoly,
179 ESquareRootUpper, ESquareRootLower, ESquareRoot
182 EDefState fProblemType = EDispx;
186 int fPlaneStress = 1;
190 static REAL gPoisson;
192 static int gOscilatoryElasticity;
197 for(
int i=0; i<3; i++) xstate[i]=x[i];
198 DivSigma(x, locforce);
199 force[0] = -locforce[0];
200 force[1] = -locforce[1];
206 virtual ~TElasticity2DAnalytic()
215 TElasticity2DAnalytic(
const TElasticity2DAnalytic &cp);
217 TElasticity2DAnalytic &
operator=(
const TElasticity2DAnalytic ©);
235 template<
typename TVar1,
typename TVar2>
238 template<
typename TVar1,
typename TVar2>
241 for(
int i=0; i<2; i++)
251 for (
int i=0; i<2; i++) {
252 for (
int j=0; j<2; j++)
254 grad(j,i) = result[i].d(j);
259 template<
typename TVar>
260 static void Elastic(
const TPZVec<TVar> &x, TVar &Elast, TVar &nu);
270 enum EDefState {ENone, EDispx, EDispy, ERot, EStretchx, EUniAxialx, EStretchy, EShear, EBend, ELoadedBeam, Etest1,Etest2, ETestShearMoment, ESphere };
272 EDefState fProblemType = ENone;
281 DivSigma(x, locforce);
282 force[0] = -locforce[0];
283 force[1] = -locforce[1];
284 force[2] = -locforce[2];
294 virtual ~TElasticity3DAnalytic()
299 TElasticity3DAnalytic (
const TElasticity3DAnalytic &cp);
301 TElasticity3DAnalytic &
operator=(
const TElasticity3DAnalytic ©);
318 void Elastic(
const TPZVec<TVar> &x, TVar &Elast, TVar &nu)
const;
328 enum EExactSol {ENone, EConst, EX, ESinSin, ECosCos, EArcTan, EArcTanSingular,ESinDist, E10SinSin,E2SinSin, ESinSinDirNonHom,ESinMark,ESteklovNonConst,EGalvisNonConst,EBoundaryLayer,EBubble,ESinCosCircle, EHarmonic};
332 EExactSol fExact = EArcTan;
342 fTensorPerm = fInvPerm = {{1,0,0},{0,1,0},{0,0,1}};
353 virtual ~TLaplaceExample1()
359 TLaplaceExample1(
const TLaplaceExample1 &cp);
361 TLaplaceExample1 &
operator=(
const TLaplaceExample1 ©);
373 static void Permeability(
const TPZVec<TVar> &x, TVar &Elast);
381 void DivSigma(
const TPZVec<REAL> &x, TVar &divsigma)
const;
387 DivSigma(x, locforce);
394 for (
int i=0; i<3; i++) {
397 SigmaLoc<STATE>(xco,tensor);
407 enum MProblemType {ENone, ELinear,
ESin,
ECos};
409 MProblemType fProblemType =
ESin;
417 virtual ~TLaplaceExampleTimeDependent()
432 void Permeability(
const TPZVec<TVar> &x, TVar &Elast)
const;
441 void DivSigma(
const TPZVec<REAL> &x, TVar &divsigma)
const;
454 enum MProblemType {EStokes, ENavierStokes, EOseen, ENavierStokesCDG, EOseenCDG, EBrinkman};
456 enum EExactSol {ENone, ECavity, EKovasznay, EKovasznayCDG, ESinCos, EPconst, EObstacles, EOneCurve ,EStokesLimit, EDarcyLimit};
460 MProblemType fProblemType = EStokes;
462 EExactSol fExactSol = ESinCos;
470 REAL lambda = Re/2.-
sqrt(Re*Re/4.+4.*Pi*Pi);
472 REAL falphaBrinkman = 1.;
481 virtual ~TStokesAnalytic()
int fSignConvention
integer to correct for the sign convention of the forcing term
TPZAutoPointer< TPZFunction< STATE > > ForcingFunction() const
TExactState(const TPZAnalyticSolution *root)
TPZAutoPointer< TPZFunction< STATE > > TensorFunction()
Templated vector implementation.
virtual void Execute(const TPZVec< REAL > &x, TPZVec< STATE > &f, TPZFMatrix< STATE > &df)
Performs function computation.
std::function< void(const TPZVec< REAL > &loc, TPZVec< STATE > &result, TPZFMatrix< STATE > &deriv)> ExactSolution() const
virtual void Execute(const TPZVec< REAL > &x, TPZVec< STATE > &f)
Performs function computation.
Implements a function. Utility.
virtual void Execute(const TPZVec< REAL > &x, TPZVec< STATE > &f, TPZFMatrix< STATE > &df)
Performs function computation.
TPZAutoPointer< TPZFunction< STATE > > Exact() const
virtual void Execute(const TPZVec< REAL > &x, TPZVec< STATE > &f, TPZFMatrix< STATE > &nada)
Simpler version of Execute method which does not compute function derivatives.
TPZAnalyticSolution & operator=(const TPZAnalyticSolution ©)
virtual void Sigma(const TPZVec< REAL > &x, TPZFMatrix< STATE > &tensor) const =0
int64_t size() const
Returns the number of elements of the vector.
const TPZAnalyticSolution * fAnalytic
expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ expr_ sqrt
TPZAnalyticSolution * fAnalytic
Contains declaration of the TPZAutoPointer class which has Increment and Decrement actions are mutexe...
virtual void Force(const TPZVec< REAL > &x, TPZVec< STATE > &force) const =0
Contains declaration of TPZCompMesh class which is a repository for computational elements...
virtual int PolynomialOrder() const
Polynomial order of this function.
const TPZAnalyticSolution * fAnalytic
Tensor(TPZAnalyticSolution *root)
virtual int PolynomialOrder() const
Polynomial order of this function.
virtual void Execute(const TPZVec< REAL > &x, TPZVec< STATE > &f)
Simpler version of Execute method which does not compute function derivatives.
virtual void Solution(const TPZVec< REAL > &x, TPZVec< STATE > &u, TPZFMatrix< STATE > &gradu) const =0
int Resize(const int64_t newRows, const int64_t wCols) override
Redimension a matrix, but maintain your elements.
virtual ~TPZAnalyticSolution()
virtual int PolynomialOrder() const
Polynomial order of this function.
This class implements a reference counter mechanism to administer a dynamically allocated object...
TForce(const TPZAnalyticSolution *root)