19 static LoggerPtr logger(Logger::getLogger(
"pz.mesh.TPZMultiPhysicsElement"));
34 int nsides = ref->
NSides();
38 for(side=nsides;side>=0;side--) {
54 for(is=0; is<ns; is++) {
55 const int higheldim = highlist[is].Reference().Dimension();
56 if(higheldim != InterfaceDimension)
continue;
66 PZError <<
"\nERROR AT " << __PRETTY_FUNCTION__ <<
" - CASE NOT AVAILABLE\n";
92 LOGPZ_WARN(logger,
"Exiting CreateInterface Null reference reached - NULL interface returned");
93 return newcreatedinterface;
104 for (int64_t is=0; is<size; is++)
110 int neighbourdim = list[is].Element()->Dimension();
112 if(thisdim != neighbourdim)
114 if (thisdim < neighbourdim)
157 if (logger->isDebugEnabled())
159 std::stringstream sout;
160 sout <<
"CreateBCGeoEl devolveu zero!@@@@";
193 return newcreatedinterface;
213 if (thisdim < neighbourdim)
242 return newcreatedinterface;
268 if (logger->isDebugEnabled())
270 std::stringstream sout;
271 sout << __PRETTY_FUNCTION__ <<
" left element";
272 sout << lowcelcompelside << thiscompelside;
273 sout <<
"Left Element ";
274 lowcelcompelside.Element()->Print(sout);
275 sout <<
"Right Element ";
276 thiscompelside.Element()->Print(sout);
291 return newcreatedinterface;
293 return newcreatedinterface;
324 std::stringstream mess;
325 mess << __PRETTY_FUNCTION__ <<
" - this->Material() == NULL, I can't RemoveInterfaces()";
326 PZError << mess.str() << std::endl;
333 for(is=0;is<nsides;is++){
345 LOGPZ_DEBUG(logger,
"Removing interface element from the list of higher level elements");
351 if(!list[i].
Element())
continue;
353 if(geolist.
Dimension() != InterfaceDimension)
continue;
355 list[i].EqualLevelElementList(equal,0,0);
359 if(!neq || k == neq){
366 PZError <<
"\nERROR AT " << __PRETTY_FUNCTION__ <<
" - CASE NOT AVAILABLE\n";
383 if(!size || i == size){
385 if (logger->isDebugEnabled())
387 std::stringstream sout;
388 sout << __PRETTY_FUNCTION__ <<
" no interface element found\n";
399 if (logger->isDebugEnabled())
401 std::stringstream sout;
402 sout << __PRETTY_FUNCTION__ <<
" element index " <<
Index() <<
" side " << std::endl;
403 sout <<
"geometric element reference count " << gel->
NumInterfaces();
413 int64_t nindices = indices.
size();
415 for (int64_t iel = 0; iel<nindices; iel++) {
416 int64_t indicel = indices.operator[](iel);
424 trvec[indicel].Apply(point, locpt);
425 datavec[indicel].intGlobPtIndex = -1;
429 for (int64_t iel = 0; iel<nmeshes; iel++) {
437 trvec[iel].Apply(point, locpt);
438 datavec[iel].intGlobPtIndex = -1;
450 for (
int imesh = 0; imesh < nmeshes; imesh++) {
459 for (
int iconloc = 0; iconloc < ncon; iconloc++, icon++) {
468 if (blsz != blszloc) {
474 for (
int ibl = 0; ibl < blsz; ibl++) {
475 for (
int iload = 0; iload < nload; iload++) {
TPZGeoMesh * Reference() const
Returns a pointer to the geometrical mesh associated.
virtual void ComputeRequiredData(TPZVec< REAL > &point, TPZVec< TPZTransform<> > &trvec, TPZVec< TPZMaterialData > &datavec, TPZVec< int64_t > indices)
int Position(const int block_diagonal) const
Returns the position of first element block dependent on matrix diagonal.
TPZCompElSide LowerLevelElementList(int onlyinterpolated)
Returns all connected elements which have level lower to the current element.
Implements computational element and a side. Computational Element.
Represents a set of shape functions associated with a computational element/side. Computational Eleme...
Contains definitions to LOGPZ_DEBUG, LOGPZ_INFO, LOGPZ_WARN, LOGPZ_ERROR and LOGPZ_FATAL, and the implementation of the inline InitializePZLOG(string) function using log4cxx library or not. It must to be called out of "#ifdef LOG4CXX" scope.
virtual MElementType Type()
Return the type of the element.
TPZCompElSide Left() const
access function to the left element
TPZMultiphysicsInterfaceElement * CreateInterface(int side)
Contains the declaration of the TPZCompElWithMem class, it is as TPZCompEl with enable material memor...
virtual TPZCompEl * Element(int64_t elindex)=0
TPZGeoElSide Reference() const
Reference to the geometric element.
virtual int ComputeIntegrationOrder() const override
virtual int Dimension() const =0
Dimension of the element.
virtual int64_t NMeshes()=0
Contains declaration of TPZInterpolationSpace class which implements the interface for interpolated c...
virtual int Dimension() const =0
Returns the integrable dimension of the material.
Contains the declaration of the TPZMultiphysicsElement class. This class is abstract.
Utility class which represents an element with its side. The Geometric approximation classes Geometry...
REAL val(STATE &number)
Returns value of the variable.
#define LOGPZ_WARN(A, B)
Define log for warnings.
TPZGeoElSide Neighbour() const
virtual void EvaluateError(std::function< void(const TPZVec< REAL > &loc, TPZVec< STATE > &val, TPZFMatrix< STATE > &deriv)> func, TPZVec< REAL > &errors, bool store_error) override
Performs an error estimate on the elemen.
virtual int NSides() const =0
Returns the number of connectivities of the element.
virtual int SideDimension(int side) const =0
Return the dimension of side.
virtual void Resize(const int64_t newsize, const T &object)
Resizes the vector object.
void RemoveInterface(int side)
#define LOGPZ_FATAL(A, B)
Define log for fatal errors (cout)
This abstract class defines the behaviour which each derived class needs to implement.
Contains the TPZBndCond class which implements a boundary condition for TPZMaterial objects...
virtual TPZMaterial * Material() const
Identify the material object associated with the element.
void HigherLevelElementList(TPZStack< TPZCompElSide > &elsidevec, int onlyinterpolated, int removeduplicates)
Returns all connected elements which have level higher to the current element.
int64_t size() const
Returns the number of elements of the vector.
TPZCreateApproximationSpace & ApproxSpace()
int64_t SequenceNumber() const
Returns the Sequence number of the connect object.
void Push(const T object)
Pushes a copy of the object on the stack.
void EqualLevelElementList(TPZStack< TPZCompElSide > &elsidevec, int onlyinterpolated, int removeduplicates)
Returns all connected elements which have equal level to the current element This method will not put...
Defines the behaviour of all geometric elements. GeometryTPZGeoEl is the common denominator for all g...
#define DebugStop()
Returns a message to user put a breakpoint in.
#define LOGPZ_DEBUG(A, B)
Define log for debug info.
This class defines the boundary condition for TPZMaterial objects.
TPZCompMesh * Mesh() const
Return a pointer to the grid of the element.
int Dimension() const
Returns the dimension of the simulation.
virtual TPZCompEl * ReferredElement(int64_t mesh)=0
Contains the declaration of multiphysic interface class.
int NumInterfaces()
Returns number of TPZInterfaceElement pointing to this.
TPZCompEl * Reference() const
Return a pointer to the element referenced by the geometric element.
TPZMultiphysicsElement()
Default constructor.
bool ExistsInterface(int side)
virtual TPZGeoEl * CreateBCGeoEl(int side, int bc)=0
Method which creates a geometric element on the side of an existing element.
This class implements the TPZCompEl structure to enable material memory feature. It should be instan...
const TPZBlock< STATE > & Block() const
Access the block structure of the solution vector.
int Exists() const
Verifies if the object is non null (initialized)
int64_t Index() const
Returns element index of the mesh fELementVec list.
#define LOGPZ_ERROR(A, B)
Define log for errors (cout)
virtual TPZConnect & Connect(int i) const
Returns a pointer to the ith node.
Implements the interfaces for TPZCompElDisc, TPZInterfaceElement and TPZInterpolatedElement. Computational element.
virtual int NConnects() const =0
Returns the number of nodes of the element.
TPZGeoEl * Element() const
virtual int Dimension() const =0
Returns the dimension of the element.
TPZCompEl * Element() const
Gives a pointer to the reference computational element.
TPZGeoEl * Reference() const
Return a pointer to the corresponding geometric element if such exists, return 0 otherwise.
TPZCompElSide Reference() const
Returns a pointer to the elementside referenced by the geometric elementside.
int Dimension() const
the dimension associated with the element/side
Computes the contribution over an interface between two discontinuous elements. Computational Element...
Implements computational mesh. Computational Mesh.
int Size(const int block_diagonal) const
Returns block dimension.
virtual void Print(std::ostream &out=std::cout) const
Prints element data.
int Side() const
Returns the side index.
int64_t Cols() const
Returns number of cols.
int InterfaceMaterial(int leftmaterial, int rightmaterial)
Returns the interface material associated to left and right element materials. If no interface materi...
int64_t NElements() const
Returns the number of elements of the vector.
#define GMESHNOMATERIAL
Identifier indicating the no material is associated.
TPZCompElSide Right() const
Access function to the right element.
virtual void ComputeRequiredData(TPZMaterialData &data, TPZVec< REAL > &qsi)
Compute and fill data with requested attributes.
virtual bool IsActiveApproxSpaces(int space_index)
virtual void TransferMultiphysicsElementSolution() override
Defines the interface of a computational element. Computational Element.
TPZFMatrix< STATE > & Solution()
Access the solution vector.
#define PZError
Defines the output device to error messages and the DebugStop() function.
TPZCompMesh * fMesh
Computational mesh to which the element belongs.