30 #include "PlaneElement.h" 35 #include "preprocessor/multi_block_topology/matrices/ElemPtrArray3d.h" 36 #include "preprocessor/multi_block_topology/aux_meshing.h" 37 #include "preprocessor/prep_handlers/LoadHandler.h" 38 #include "domain/load/plane/BidimStrainLoad.h" 39 #include "vtkCellType.h" 45 template <
class PhysProp>
52 TriBase3N(
int tag,
int classTag,
const PhysProp &);
53 TriBase3N(
int tag,
int classTag,
int node1,
int node2,
int node3,
const PhysProp &pp);
68 template <
class PhysProp>
73 template <
class PhysProp>
78 template <
class PhysProp>
82 this->theNodes.set_id_nodes(node1,node2,node3);
88 template <
class PhysProp>
92 retval.assign(1,1,1,
false);
97 template <
class PhysProp>
100 std::cerr << this->getClassName() <<
"::" << __FUNCTION__
101 <<
"; not implemented." << std::endl;
107 template <
class PhysProp>
112 const size_t sz= nodes.size();
117 retval[1]= nodes(i+1);
126 template <
class PhysProp>
131 const int i1= nodes.
find(n1);
132 const int i2= nodes.
find(n2);
133 if((i1>=0) && (i2>=0))
135 const int dif= i2-i1;
140 else if((i1==3) && (i2==0))
142 else if((i1==0) && (i2==3))
149 template <
class PhysProp>
154 const size_t sz= nodes.size();
167 template <
class PhysProp>
171 this->physicalProperties.getMaterialsVector().zeroInitialGeneralizedStrains();
176 template <
class PhysProp>
180 std::cerr << this->getClassName()
181 <<
"; load over inactive element: " 182 << this->getTag() << std::endl;
185 if(
const BidimStrainLoad *strainLoad= dynamic_cast<const BidimStrainLoad *>(theLoad))
187 static std::vector<Vector> initStrains;
188 initStrains= strainLoad->getStrains();
189 for(std::vector<Vector>::iterator i= initStrains.begin();i!=initStrains.end();i++)
191 this->physicalProperties.getMaterialsVector().incrementInitialGeneralizedStrains(initStrains);
195 std::cerr <<
"TriBase3N::addLoad -- load type unknown for element with tag: " <<
196 this->getTag() << std::endl;
204 template <
class PhysProp>
206 {
return VTK_TRIANGLE; }
std::vector< const Node * > NodesEdge
Nodes on an element edge.
Definition: Element.h:116
Base class for grids of bool in 3D (used to express if something exists or not in a (layer...
Definition: BoolArray3d.h:34
TriBase3N(int classTag, const PhysProp &)
Constructor.
Definition: TriBase3N.h:69
BoolArray3d getNodePattern(void) const
Return a grid of booleans, one for each of the element nodes.
Definition: TriBase3N.h:89
Element::NodesEdge getNodesEdge(const size_t &i) const
Returns the nodes de un lado of the element.
Definition: TriBase3N.h:108
Vector of integers.
Definition: ID.h:95
Three-dimensional array of pointers to elements.
Definition: ElemPtrArray3d.h:47
iterator find(const int &)
Returns an iterator to the node identified by the tag being passed as parameter.
Definition: NodePtrs.cc:151
int getVtkCellType(void) const
Interfaz con VTK.
Definition: TriBase3N.h:205
Base class for 3 node triangles.
Definition: TriBase3N.h:46
void zeroLoad(void)
Zeroes loads on element.
Definition: TriBase3N.h:168
ID getLocalIndexNodesEdge(const size_t &i) const
Returns the local indexes of the nodes that lies on the i-th edge.
Definition: TriBase3N.h:150
int addLoad(ElementalLoad *theLoad, double loadFactor)
Adds to the element the load being passed as parameter.
Definition: TriBase3N.h:177
Node pointer container for elements.
Definition: NodePtrsWithIDs.h:46
Three-dimensional array of pointers to nodes.
Definition: NodePtrArray3d.h:51
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:35
int getEdgeNodes(const Node *, const Node *) const
Returns the edge of the element that ends in the nodes being passed as parameters.
Definition: TriBase3N.h:127
Base class for loads over elements.
Definition: ElementalLoad.h:79
Load due to restricted material expansion or contraction on bidimensional elements.
Definition: BidimStrainLoad.h:39
Mesh node.
Definition: Node.h:111
ElemPtrArray3d put_on_mesh(const NodePtrArray3d &, meshing_dir dm) const
Put the element on the mesh being passed as parameter.
Definition: TriBase3N.h:98
Base class for plane elements.
Definition: PlaneElement.h:55