34 #include "domain/mesh/element/utils/NodePtrsWithIDs.h" 35 #include "material/Material.h" 36 #include "domain/domain/Domain.h" 37 #include "utility/geom/pos_vec/Pos3d.h" 38 #include "utility/utils/misc_utils/colormod.h" 53 template <
class TIPOMAT>
84 boost::python::dict
getPyDict(
void)
const;
85 void setPyDict(
const boost::python::dict &);
98 :
Element(other), theNodes(other.theNodes)
102 template <
int NNODES>
105 Element::operator=(other);
112 template <
int NNODES>
114 {
return theNodes.size(); }
117 template <
int NNODES>
122 template <
int NNODES>
127 template <
int NNODES>
template <
class TIPOMAT>
130 TIPOMAT *retval=
nullptr;
133 const TIPOMAT *tmp =
dynamic_cast<const TIPOMAT *
>(ptr_mat);
135 retval= tmp->getCopy();
138 std::cerr << Color::red << getClassName() <<
"::" << __FUNCTION__
139 <<
"; on element: " << getTag()
140 <<
" the material " << ptr_mat->
getTag()
141 <<
" with name: " << ptr_mat->
getName()
143 <<
" has not a suitable type." 144 << Color::def << std::endl;
149 std::cerr << Color::red << getClassName() <<
"::" << __FUNCTION__
150 <<
"; on element: " << getTag()
151 <<
" can't get a copy of the material with tag: " 153 << Color::def << std::endl;
159 std::cerr << Color::red << getClassName() <<
"::" << __FUNCTION__
160 <<
"; on element: " << getTag()
161 <<
" pointer to material is null. " 162 << Color::def << std::endl;
169 template <
int NNODES>
172 int res= Element::sendData(comm);
178 template <
int NNODES>
181 int res= Element::recvData(comm);
187 template <
int NNODES>
190 boost::python::dict retval= Element::getPyDict();
191 retval[
"nodes"]= theNodes.getPyDict();
195 template <
int NNODES>
198 Element::setPyDict(d);
199 theNodes.setPyDict(boost::python::extract<boost::python::dict>(d[
"nodes"]));
203 template <
int NNODES>
208 template <
int NNODES>
214 template <
int NNODES>
219 template <
int NNODES>
225 template <
int NNODES>
231 template <
int NNODES>
237 template <
int NNODES>
244 template <
int NNODES>
250 template <
int NNODES>
int sendMovable(MovableObject &, DbTagData &, const CommMetaData &)
Sends a movable object through the communicator argument.
Definition: Communicator.cc:1163
Node::ElementConstPtrSet ElementConstPtrSet
Container of const element pointers.
Definition: NodePtrs.h:70
boost::python::list getConnectedElementsPy(void)
Return a python list of pointers to the elements that are connected with this node.
Definition: ElementBase.h:232
NodePtrsWithIDs theNodes
pointers to node.
Definition: ElementBase.h:51
boost::python::dict getPyDict(void) const
Return a Python dictionary with the object members values.
Definition: ElementBase.h:188
ElementBase & operator=(const ElementBase &)
Assignment operator.
Definition: ElementBase.h:103
int getNumExternalNodes(void) const
Return the number of external nodes.
Definition: ElementBase.h:113
Communication parameters between processes.
Definition: Communicator.h:66
std::string getName(void) const
Returns the name of the material.
Definition: Material.cpp:168
int receiveMovable(MovableObject &, DbTagData &, const CommMetaData &) const
Receives a movable object trhrough the communicator argument.
Definition: Communicator.cc:1174
Base class for materials.
Definition: Material.h:93
boost::python::list getConnectedElementTags(void) const
Return a python list containing the tags of the elements that are connected with this node...
Definition: ElementBase.h:245
Pos3d getCenterOfMassPosition(bool initialGeometry=true) const
Return position of the element centroid.
Definition: ElementBase.h:204
Base de las clases Set y SetEstruct.
Definition: SetBase.h:51
Base class for the finite elements.
Definition: Element.h:112
virtual std::string getClassName(void) const
Returns demangled class name.
Definition: EntityWithOwner.cc:90
NodePtrs::ElementConstPtrSet getConnectedElements(void) const
Return a set of pointers to the elements that are connected with this node.
Definition: ElementBase.h:209
TIPOMAT * cast_material(const Material *ptr_mat)
Casts the material pointer to a suitable type.
Definition: ElementBase.h:128
ElementBase(int tag, int classTag)
Default constructor.
Definition: ElementBase.h:92
Node pointer container for elements.
Definition: NodePtrsWithIDs.h:46
Posición en tres dimensiones.
Definition: Pos3d.h:44
NodePtrsWithIDs & getNodePtrs(void)
Returns a pointer to the node vector.
Definition: ElementBase.h:123
Node::ElementPtrSet ElementPtrSet
Container of element pointers.
Definition: NodePtrs.h:69
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:35
int sendData(Communicator &comm)
Send members through the communicator argument.
Definition: ElementBase.h:170
int getTag(void) const
Returns the tag associated with the object.
Definition: TaggedObject.h:119
Base class for finite element with pointer to nodes container.
Definition: ElementBase.h:48
void set_owner(EntityWithOwner *owr)
Assigns the owner of the object.
Definition: EntityWithOwner.cc:111
void setPyDict(const boost::python::dict &)
Set the values of the object members from a Python dictionary.
Definition: ElementBase.h:196
static const int numNodes(void)
Returns the element number of nodes.
Definition: ElementBase.h:65
int recvData(const Communicator &comm)
Receives members through the communicator argument.
Definition: ElementBase.h:179