XC Open source finite element analysis program
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members

Mesh node. More...

#include <Node.h>

Inheritance diagram for XC::Node:
XC::MeshComponent XC::ContinuaReprComponent XC::DomainComponent XC::TaggedObject XC::MovableObject XC::DistributedBase XC::DummyNode

Public Types

typedef std::set< Element * > ElementPtrSet
 Container of element pointers.
 
typedef std::set< const Element * > ElementConstPtrSet
 Container of const element pointers.
 

Public Member Functions

 Node (int classTag)
 Default constructor. More...
 
 Node (int tag, int classTag)
 Constructor. More...
 
 Node (int tag, int ndof, double Crd1)
 Constructor. More...
 
 Node (int tag, int ndof, double Crd1, double Crd2)
 Constructor for 2d nodes. More...
 
 Node (int tag, int ndof, double Crd1, double Crd2, double Crd3)
 constructor for 3d nodes More...
 
 Node (int tag, int ndof, const Vector &crds)
 Constructor. More...
 
 Node (const Node &theCopy, bool copyMass=true)
 used for domain decomposition & external nodes copy everything but the mass we should really set the mass to 0.0
 
NodegetCopy (void) const
 Virtual constructor.
 
virtual ~Node (void)
 destructor
 
virtual int getNumberDOF (void) const
 Return the number of node DOFs.
 
virtual void setDOF_GroupPtr (DOF_Group *theDOF_Grp)
 Sets the DOF_Group pointer.
 
virtual DOF_GroupgetDOF_GroupPtr (void)
 Gets the DOF_Group pointer.
 
void connect (ContinuaReprComponent *el) const
 Inserts a component (element, constraint,...) to the connected component list.
 
void disconnect (ContinuaReprComponent *el) const
 Removes a component (element, constraint,...) from the connected component list.
 
ElementConstPtrSet getConnectedElements (void) const
 Return a list of pointers to the elements that are connected with this node.
 
ElementPtrSet getConnectedElements (void)
 Return a list of pointers to the elements that are connected with this node.
 
const MeshEdgenext (const std::deque< MeshEdge > &, const std::set< const MeshEdge * > &) const
 Returns an edge that has its origin in this node (and is not in visited).
 
const bool isDead (void) const
 True if node is inactive.
 
const bool isAlive (void) const
 True if node is active.
 
const bool isFrozen (void) const
 returns true if the node is frozen.
 
const bool isFree (void) const
 returns true if the node has no constraints.
 
void kill (void)
 
void alive (void)
 
void freeze_if_dead (NodeLocker *locker)
 Imposes zero displacement (zero value for all node DOFs).
 
void melt_if_alive (NodeLocker *locker)
 Deletes the constraint over the node DOFs previously created by the freeze method.
 
SFreedom_Constraintfix (const SFreedom_Constraint &)
 Introduce en el nodo una constraint como la being passed as parameter.
 
void fix (const std::vector< int > &, const std::vector< double > &)
 Sets prescribed displacements on the DOFs being passed as parameter.
 
void fix (const ID &, const Vector &)
 Sets prescribed displacements on the DOFs being passed as parameter.
 
virtual size_t getDim (void) const
 Return the dimension of the node vector position (1,2 or 3).
 
virtual const VectorgetCrds (void) const
 return the vector of nodal coordinates
 
virtual VectorgetCrds (void)
 return the vector of nodal coordinates
 
Vector getCrds3d (void) const
 Returns the coordenadas del nodo en un espacio 3d.
 
Pos2d getPosInicial2d (void) const
 Return the intial position of the node in 2D.
 
Pos3d getPosInicial3d (void) const
 Return the intial position of the node in 3D.
 
Pos2d getPosFinal2d (void) const
 Return the final position of the node.
 
Pos3d getPosFinal3d (void) const
 Return the final position of the node.
 
void setPos (const Pos3d &)
 Sets the node position.
 
void Mueve (const Vector3d &desplaz)
 Moves the node (intended only for its use from XC::Set).
 
void Transforma (const TrfGeom &trf)
 Applies to the node position the transformation being passed as parameter.
 
double getDist2 (const Pos2d &p, bool initialGeometry=true) const
 Returns the square of the distance from the node to the point being passed as parameter. More...
 
double getDist (const Pos2d &p, bool initialGeometry=true) const
 Returns the distance from the node to the point being passed as parameter. More...
 
double getDist2 (const Pos3d &p, bool initialGeometry=true) const
 Returns the square of the distance from the node to the point being passed as parameter. More...
 
double getDist (const Pos3d &p, bool initialGeometry=true) const
 Returns the distance from the node to the point being passed as parameter. More...
 
virtual const VectorgetDisp (void) const
 Returns the displacement of the node.
 
Vector getDispXYZ (void) const
 Returns the XYZ components of node displacement.
 
Vector getRotXYZ (void) const
 Returns the XYZ components of node rotation.
 
virtual const VectorgetVel (void) const
 Returns the velocity of the node.
 
Vector getVelXYZ (void) const
 Returns the XYZ components of the translational velocity of the node.
 
Vector getOmegaXYZ (void) const
 Returns the XYZ components of the angular velocity of the node.
 
virtual const VectorgetAccel (void) const
 Returns the acceleration of the node.
 
Vector getAccelXYZ (void) const
 Returns the XYZ components of the translational acceleration of the node.
 
Vector getAlphaXYZ (void) const
 Returns the XYZ components of the angular acceleration of the node.
 
virtual const VectorgetIncrDisp (void) const
 Returns the displacement increment.
 
virtual const VectorgetIncrDeltaDisp (void) const
 
virtual const VectorgetTrialDisp (void) const
 Returns the trial value of the displacement of the node.
 
virtual const VectorgetTrialVel (void) const
 Returns the trial value of the velocity of the node.
 
virtual const VectorgetTrialAccel (void) const
 Returns the trial value of the acceleration of the node.
 
virtual int setTrialDispComponent (double value, int dof)
 
virtual int setTrialDisp (const Vector &)
 
virtual int setTrialVel (const Vector &)
 
virtual int setTrialAccel (const Vector &)
 
virtual int incrTrialDisp (const Vector &)
 
virtual int incrTrialVel (const Vector &)
 
virtual int incrTrialAccel (const Vector &)
 
virtual void zeroUnbalancedLoad (void)
 
virtual int addUnbalancedLoad (const Vector &load, double fact=1.0)
 Adds vector to unbalanced load. More...
 
virtual int addInertiaLoadToUnbalance (const Vector &accel, double fact=1.0)
 Adds inertial loads to unbalanced load vector.
 
virtual const VectorgetUnbalancedLoad (void)
 Returns unbalanced load vector.
 
virtual const VectorgetUnbalancedLoadIncInertia (void)
 Return unbalanced load vector including inertial forces.
 
virtual int commitState ()
 Commits the state of the node.
 
virtual int revertToLastCommit ()
 Returns to the last commited state.
 
virtual int revertToStart ()
 Returns to the initial state.
 
virtual const MatrixgetMass (void)
 Return the matriz de masas del nodo.
 
virtual int setMass (const Matrix &theMass)
 Asigna la matriz de masas to the node.
 
virtual int setNumColR (int numCol)
 
virtual int setR (int row, int col, double Value)
 
virtual const VectorgetRV (const Vector &V)
 
virtual int setRayleighDampingFactor (double alphaM)
 Returns the coeficiente de amortiguamiento de Rayleigh.
 
virtual const MatrixgetDamp (void)
 Return the matriz de amortiguamiento del nodo.
 
void addTributaria (const double &) const
 Adds to the magnitud tributaria la longitud, área o volumen being passed as parameter.
 
void resetTributaria (void) const
 Anula la magnitud tributaria (longitud, área o volumen).
 
const double & getTributaria (void) const
 Return the magnitud tributaria (longitud, área o volumen).
 
virtual int setNumEigenvectors (int numVectorsToStore)
 Dimensiona la matriz que contiene a los eigenvectors.
 
virtual int setEigenvector (int mode, const Vector &eigenVector)
 Asigna el autovector eigenvector al modo mode.
 
int getNumModes (void) const
 
virtual Vector getEigenvector (int mode) const
 Returns the autovector correspondiente al modo i.
 
Vector getNormalizedEigenvector (int mode) const
 Returns the autovector correspondiente al modo i normalizado de modo que la componente máxima valga 1 (norma_infinito).
 
virtual const MatrixgetEigenvectors (void)
 Returns the eigenvectors correspondientes to the node.
 
Matrix getNormalizedEigenvectors (void) const
 Returns a matriz con los eigenvectors normalizados colocados por columnas (norma_infinito).
 
double getAngularFrequency (int) const
 Return the angular frequency corresponding to the i-th mode.
 
Vector getAngularFrequencies (void) const
 Returns the angular frequencies from the modal analysis.
 
virtual double getModalParticipationFactor (int mode) const
 Returns the modal participation factor corresponding to i-th mode.
 
Vector getModalParticipationFactors (void) const
 Returns the modal participation factors.
 
virtual double getModalParticipationFactor (int mode, const std::set< int > &gdls) const
 Returns the modal participation factor corresponding to i-th mode. If the gdls argument is not empty it "projects" the i-th mode over the selected DOFs in the argument. It's written to allow expressing the participation with respect to a DOF (see verification test: test_cqc_01.xc). THE RESULTS OF THIS FUNCTION DOESN'T MATCH WITH THOSE OBTAINED FROM THE EIGENVALUE PROBLEM. More...
 
Vector getModalParticipationFactors (const std::set< int > &gdls) const
 Returns the modal participation factors. If gdls argument is not empty it "projects" the i-th mode over the selected DOFs in the argument. More...
 
Vector getModalParticipationFactorsForGdls (const boost::python::list &) const
 Returns the modal participation factors. If gdls argument is not empty it "projects" the i-th mode over the selected DOFs in the argument. More...
 
Vector getDistributionFactor (int mode) const
 Returns the distribution factor of the i-th mode.
 
Vector getDistributionFactor (int mode, const std::set< int > &gdls) const
 Returns the distribution factor corresponding to the mode being passed as parameter. If gdls argument is not it "projects" the i-th mode over the selected DOFs in the argument. More...
 
Matrix getDistributionFactors (void) const
 Returns the matrix with the computed distribution factors placed by columns.
 
double getEffectiveModalMass (int mode) const
 Return the masa modal efectiva correspondiente al modo i.
 
Vector getEffectiveModalMasses (void) const
 Returns the effective modal mases.
 
Vector getEquivalentStaticLoad (int mode, const double &) const
 Return the equivalent static load for the mode being passed as parameter and the acceleration corresponding to that mode.
 
Vector getMaxModalDisplacement (int mode, const double &) const
 Returns the maximal modal displacement for the node being passed as parameter and the acceleration corresponding to that mode.
 
Vector getMaxModalVelocity (int mode, const double &) const
 Return the maximal modal velocity for the mode being passed as parameter and the acceleration corresponding to that mode.
 
Vector getMaxModalAcceleration (int mode, const double &) const
 Return the maximal modal acceleration for the mode being passed as parameter and the acceleration corresponding to that mode.
 
Vector getMaxModalDisplacementForGdls (int mode, const double &, const std::set< int > &gdls) const
 Returns the maximal modal displacement on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode. More...
 
Vector getMaxModalVelocityForGdls (int mode, const double &, const std::set< int > &gdls) const
 Returns the maximum modal velocity on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode. More...
 
Vector getMaxModalAccelerationForGdls (int mode, const double &, const std::set< int > &gdls) const
 Return the maximal modal acceleration on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode. More...
 
Vector getMaxModalDisplacementForGdls (int mode, const double &, const boost::python::list &gdls) const
 Returns the maximal modal displacement on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode. More...
 
Vector getMaxModalVelocityForGdls (int mode, const double &, const boost::python::list &gdls) const
 Returns the maximum modal velocity on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode. More...
 
Vector getMaxModalAccelerationForGdls (int mode, const double &, const boost::python::list &gdls) const
 Return the maximal modal acceleration on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode. More...
 
virtual int sendSelf (CommParameters &)
 Envia el objeto through the channel being passed as parameter.
 
virtual int recvSelf (const CommParameters &)
 Receives object through the channel being passed as parameter.
 
std::set< SetBase * > get_sets (void) const
 Returns the sets a los que pertenece este nodo.
 
void add_to_sets (std::set< SetBase * > &)
 Adds the node to the sets being passed as parameters.
 
virtual void Print (std::ostream &s, int flag=0)
 Imprime el objeto.
 
virtual const VectorgetReaction (void) const
 Return the node reaction.
 
const VectorgetResistingForce (const ElementConstPtrSet &, const bool &) const
 Return the action of the elements from the set over this node.
 
SVD3d getResistingSVD3d (const ElementConstPtrSet &, const bool &) const
 Returns the sliding vector system that represents the action of the elements of the set over the node.
 
virtual int addReactionForce (const Vector &, double factor)
 Increments the node reaction.
 
virtual int resetReactionForce (bool inclInertia)
 Calculate the reactions in this node (used in en Domain::calculateNodalReactions).
 
void checkReactionForce (const double &)
 Checks reaction on the node.
 
int addInertiaLoadSensitivityToUnbalance (const Vector &accel, double fact=1.0, bool tag=false)
 
Matrix getMassSensitivity (void)
 
virtual const MatrixgetDampSensitivity (void)
 
int getCrdsSensitivity (void)
 
int saveSensitivity (Vector *v, Vector *vdot, Vector *vdotdot, int gradNum, int numGrads)
 
double getDispSensitivity (int dof, int gradNum)
 
double getVelSensitivity (int dof, int gradNum)
 
double getAccSensitivity (int dof, int gradNum)
 
int setParameter (const std::vector< std::string > &argv, Parameter &param)
 
int updateParameter (int parameterID, Information &info)
 
int activateParameter (int parameterID)
 
- Public Member Functions inherited from XC::MeshComponent
 MeshComponent (int classTag)
 Constructor.
 
 MeshComponent (int tag, int classTag)
 Constructor.
 
- Public Member Functions inherited from XC::ContinuaReprComponent
 ContinuaReprComponent (int classTag)
 
 ContinuaReprComponent (int tag, int classTag)
 
- Public Member Functions inherited from XC::DomainComponent
 ~DomainComponent (void)
 Destructor.
 
size_t getIdx (void) const
 Returns the index of the object (to be used in VTK arrays).
 
virtual void setDomain (Domain *theDomain)
 Asigna a pointer al domain.
 
virtual DomaingetDomain (void) const
 Returns a pointer to the domain.
 
const PreprocessorGetPreprocessor (void) const
 Returns (if possible) a pointer to the preprocessor.
 
PreprocessorGetPreprocessor (void)
 Returns (if possible) a pointer to the preprocessor.
 
void set_indice (const size_t &i)
 Set the index for the object (see numera in Set). This index is used on VTK arrays.
 
- Public Member Functions inherited from XC::TaggedObject
 TaggedObject (int tag, EntCmd *owr=nullptr)
 Constructor.
 
void assignTag (int newTag)
 Establece el valor del tag.
 
int getTag (void) const
 
- Public Member Functions inherited from XC::MovableObject
 MovableObject (int classTag, int dbTag)
 Constructor.
 
 MovableObject (int classTag)
 Constructor.
 
 MovableObject (const MovableObject &otro)
 Copy constructor.
 
MovableObjectoperator= (const MovableObject &otro)
 Operacdor asignación.
 
int getClassTag (void) const
 Returns the tag de la clase.
 
int getDbTag (void) const
 Returns the tag para la database.
 
int getDbTag (CommParameters &)
 Returns the tag para la database.
 
void setDbTag (int dbTag)
 Asigna el tag para la database.
 
void setDbTag (CommParameters &)
 Asigna, sólo si es preciso, el tag para la database.
 
virtual int setVariable (const std::string &variable, Information &)
 Returns the identificador de la variable cuyo nombre being passed as parameter.
 
virtual int getVariable (const std::string &variable, Information &)
 
- Public Member Functions inherited from XC::DistributedBase
 DistributedBase (void)
 Constructor.
 
const int & getDbTagDataPos (const int &i) const
 Returns the data at the i-th position.
 
void setDbTagDataPos (const int &i, const int &v)
 Sets the data at the i-th position.
 
void inicComm (const int &dataSize) const
 Initializes communication.
 

Static Public Member Functions

static DefaultTaggetDefaultTag (void)
 Returns a default value for node identifier.
 

Protected Member Functions

DbTagDatagetDbTagData (void) const
 Returns a vector para almacenar los dbTags de los miembros de la clase.
 
int sendData (CommParameters &)
 Sends object members through the channel being passed as parameter.
 
int recvData (const CommParameters &)
 Receives object members through the channel being passed as parameter.
 
- Protected Member Functions inherited from XC::MeshComponent
void setup_matrices (std::deque< Matrix > &, const int &) const
 Initializes the matrix container.
 
int sendIdsEtiquetas (int posDbTag, CommParameters &)
 Send labelsthrough the channel being passed as parameter.
 
int recvIdsEtiquetas (int posDbTag, const CommParameters &)
 Receive labels through the channel being passed as parameter.
 
int sendData (CommParameters &)
 Send members through the channel being passed as parameter.
 
int recvData (const CommParameters &)
 Receives members through the channel being passed as parameter.
 
- Protected Member Functions inherited from XC::ContinuaReprComponent
int sendData (CommParameters &)
 Send members through the channel being passed as parameter.
 
int recvData (const CommParameters &)
 Receives members through the channel being passed as parameter.
 
- Protected Member Functions inherited from XC::DomainComponent
 DomainComponent (int tag, int classTag)
 Constructor.
 
int sendData (CommParameters &)
 Send object members through the channel being passed as parameter.
 
int recvData (const CommParameters &)
 Receives object members through the channel being passed as parameter.
 
- Protected Member Functions inherited from XC::TaggedObject
void setTag (int newTag)
 Establece el valor del tag.
 

Additional Inherited Members

- Protected Attributes inherited from XC::MeshComponent
int index
 Index for VTK arrays.
 
LabelContainer labels
 Label container.
 

Detailed Description

Mesh node.

Constructor & Destructor Documentation

XC::Node::Node ( int  theClassTag)

Default constructor.

Parameters
theClassTagtag of the class.
XC::Node::Node ( int  tag,
int  theClassTag 
)

Constructor.

Parameters
tagnode identifier.
theClassTagtag of the class.
XC::Node::Node ( int  tag,
int  ndof,
double  Crd1 
)

Constructor.

Parameters
tagnode identifier.
ndofnumber of degrees of freedom for the node.
Crd1node position (one single coordinate).
XC::Node::Node ( int  tag,
int  ndof,
double  Crd1,
double  Crd2 
)

Constructor for 2d nodes.

Parameters
tagnode identifier.
ndofnumber of degrees of freedom for the node.
Crd1node position (first coordinate).
Crd2node position (second coordinate).
XC::Node::Node ( int  tag,
int  ndof,
double  Crd1,
double  Crd2,
double  Crd3 
)

constructor for 3d nodes

Parameters
tagnode identifier.
ndofnumber of degrees of freedom for the node.
Crd1node position (first coordinate).
Crd2node position (second coordinate).
Crd3node position (third coordinate).
XC::Node::Node ( int  tag,
int  ndof,
const Vector crds 
)

Constructor.

Parameters
tagnode identifier.
ndofnumber of degrees of freedom for the node.
crdsvector of node coordinates.

Member Function Documentation

int XC::Node::addUnbalancedLoad ( const Vector add,
double  fact = 1.0 
)
virtual

Adds vector to unbalanced load.

Parameters
addvector to add.
factmultiplying factor.
double XC::Node::getDist ( const Pos2d &  p,
bool  initialGeometry = true 
) const

Returns the distance from the node to the point being passed as parameter.

Parameters
p2D point to calculate the distance.
initialGeometryif true initial position of the node is considered.
double XC::Node::getDist ( const Pos3d &  p,
bool  initialGeometry = true 
) const

Returns the distance from the node to the point being passed as parameter.

Parameters
p3D point to calculate the distance.
initialGeometryif true initial position of the node is considered.
double XC::Node::getDist2 ( const Pos2d &  p,
bool  initialGeometry = true 
) const

Returns the square of the distance from the node to the point being passed as parameter.

Parameters
p2D point to calculate the distance.
initialGeometryif true initial position of the node is considered.
double XC::Node::getDist2 ( const Pos3d &  p,
bool  initialGeometry = true 
) const

Returns the square of the distance from the node to the point being passed as parameter.

Parameters
p3D point to calculate the distance.
initialGeometryif true initial position of the node is considered.
XC::Vector XC::Node::getDistributionFactor ( int  mode,
const std::set< int > &  gdls 
) const

Returns the distribution factor corresponding to the mode being passed as parameter. If gdls argument is not it "projects" the i-th mode over the selected DOFs in the argument.

Parameters
modeindex of the mode.
gdlsdegrees of freedom to project on.
XC::Vector XC::Node::getMaxModalAccelerationForGdls ( int  mode,
const double &  accel_mode,
const std::set< int > &  gdls 
) const

Return the maximal modal acceleration on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode.

Parameters
gdlsdegrees of freedom to deal with.
XC::Vector XC::Node::getMaxModalAccelerationForGdls ( int  mode,
const double &  accel_mode,
const boost::python::list &  gdls 
) const

Return the maximal modal acceleration on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode.

Parameters
gdlsdegrees of freedom to deal with.
XC::Vector XC::Node::getMaxModalDisplacementForGdls ( int  mode,
const double &  accel_mode,
const std::set< int > &  gdls 
) const

Returns the maximal modal displacement on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode.

Parameters
gdlsdegrees of freedom to deal with.
XC::Vector XC::Node::getMaxModalDisplacementForGdls ( int  mode,
const double &  accel_mode,
const boost::python::list &  gdls 
) const

Returns the maximal modal displacement on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode.

Parameters
gdlsdegrees of freedom to deal with.
XC::Vector XC::Node::getMaxModalVelocityForGdls ( int  mode,
const double &  accel_mode,
const std::set< int > &  gdls 
) const

Returns the maximum modal velocity on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode.

Parameters
gdlsdegrees of freedom to deal with.
XC::Vector XC::Node::getMaxModalVelocityForGdls ( int  mode,
const double &  accel_mode,
const boost::python::list &  gdls 
) const

Returns the maximum modal velocity on the DOFs and mode being passed as parameter and the acceleration corresponding to that mode.

Parameters
gdlsdegrees of freedom to deal with.
double XC::Node::getModalParticipationFactor ( int  mode,
const std::set< int > &  gdls 
) const
virtual

Returns the modal participation factor corresponding to i-th mode. If the gdls argument is not empty it "projects" the i-th mode over the selected DOFs in the argument. It's written to allow expressing the participation with respect to a DOF (see verification test: test_cqc_01.xc). THE RESULTS OF THIS FUNCTION DOESN'T MATCH WITH THOSE OBTAINED FROM THE EIGENVALUE PROBLEM.

Parameters
modeindex of the mode.
gdlsdegrees of freedom to project on.
XC::Vector XC::Node::getModalParticipationFactors ( const std::set< int > &  gdls) const

Returns the modal participation factors. If gdls argument is not empty it "projects" the i-th mode over the selected DOFs in the argument.

Parameters
gdlsdegrees of freedom to project on.
XC::Vector XC::Node::getModalParticipationFactorsForGdls ( const boost::python::list &  l) const

Returns the modal participation factors. If gdls argument is not empty it "projects" the i-th mode over the selected DOFs in the argument.

Parameters
ldegrees of freedom to project on.

The documentation for this class was generated from the following files: