XC Open source finite element analysis program
DispBeamColumn2d.h
1 //----------------------------------------------------------------------------
2 // XC program; finite element analysis code
3 // for structural analysis and design.
4 //
5 // Copyright (C) Luis Claudio Pérez Tato
6 //
7 // This program derives from OpenSees <http://opensees.berkeley.edu>
8 // developed by the «Pacific earthquake engineering research center».
9 //
10 // Except for the restrictions that may arise from the copyright
11 // of the original program (see copyright_opensees.txt)
12 // XC is free software: you can redistribute it and/or modify
13 // it under the terms of the GNU General Public License as published by
14 // the Free Software Foundation, either version 3 of the License, or
15 // (at your option) any later version.
16 //
17 // This software is distributed in the hope that it will be useful, but
18 // WITHOUT ANY WARRANTY; without even the implied warranty of
19 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 // GNU General Public License for more details.
21 //
22 //
23 // You should have received a copy of the GNU General Public License
24 // along with this program.
25 // If not, see <http://www.gnu.org/licenses/>.
26 //----------------------------------------------------------------------------
27 /* ****************************************************************** **
28 ** OpenSees - Open System for Earthquake Engineering Simulation **
29 ** Pacific Earthquake Engineering Research Center **
30 ** **
31 ** **
32 ** (C) Copyright 1999, The Regents of the University of California **
33 ** All Rights Reserved. **
34 ** **
35 ** Commercial use of this program without express permission of the **
36 ** University of California, Berkeley, is strictly prohibited. See **
37 ** file 'COPYRIGHT' in main directory for information on usage and **
38 ** redistribution, and for a DISCLAIMER OF ALL WARRANTIES. **
39 ** **
40 ** Developed by: **
41 ** Frank McKenna (fmckenna@ce.berkeley.edu) **
42 ** Gregory L. Fenves (fenves@ce.berkeley.edu) **
43 ** Filip C. Filippou (filippou@ce.berkeley.edu) **
44 ** **
45 ** ****************************************************************** */
46 
47 // $Revision: 1.14 $
48 // $Date: 2003/03/04 00:48:14 $
49 // $Source: /usr/local/cvs/OpenSees/SRC/element/dispBeamColumn/DispBeamColumn2d.h,v $
50 
51 // Written: MHS
52 // Created: Feb 2001
53 //
54 // Description: This file contains the class definition for DispBeamColumn2d.
55 // The element displacement field gives rise to constant axial strain and
56 // linear curvature.
57 
58 #ifndef DispBeamColumn2d_h
59 #define DispBeamColumn2d_h
60 
61 #include <domain/mesh/element/truss_beam_column/BeamColumnWithSectionFDTrf2d.h>
62 #include "domain/mesh/element/utils/fvectors/FVectorBeamColumn2d.h"
63 #include "utility/matrix/Matrix.h"
64 #include "utility/matrix/Vector.h"
65 
66 namespace XC {
67 class Node;
68 class SeccionBarraPrismatica;
69 class CrdTransf2d;
70 class Response;
71 class GaussQuadRule1d01;
72 
74 //
77  {
78  private:
79  mutable Vector q;
82 
83  double rho;
84 
85  // AddingSensitivity:BEGIN //////////////////////////////////////////
86  int parameterID;
87  // AddingSensitivity:END ///////////////////////////////////////////
88 
89  const Matrix &getInitialBasicStiff(void) const;
90 
91  static Matrix K; // Element stiffness, damping, and mass Matrix
92  static Vector P; // Element resisting force vector
93 
94  static double workArea[];
95 
96  static GaussQuadRule1d01 quadRule;
97 
98  protected:
99  int sendData(CommParameters &cp);
100  int recvData(const CommParameters &cp);
101  public:
102  DispBeamColumn2d(int tag, int nd1, int nd2,
103  int numSections,const std::vector<SeccionBarraPrismatica *> &s,
104  CrdTransf2d &coordTransf, double rho = 0.0);
105  DispBeamColumn2d(int tag= 0);
106  DispBeamColumn2d(int tag,int numSec,const Material *theSection,const CrdTransf *coordTransf);
107  Element *getCopy(void) const;
108 
109  int getNumDOF(void) const;
110  void setDomain(Domain *theDomain);
111 
112  // public methods to set the state of the element
113  int commitState(void);
114  int revertToLastCommit(void);
115  int revertToStart(void);
116 
117  // public methods to obtain stiffness, mass, damping and residual information
118  int update(void);
119  const Matrix &getTangentStiff(void) const;
120  const Matrix &getInitialStiff(void) const;
121  const Matrix &getMass(void) const;
122 
123  void zeroLoad();
124  int addLoad(ElementalLoad *theLoad, double loadFactor);
125  int addInertiaLoadToUnbalance(const Vector &accel);
126 
127  const Vector &getResistingForce(void) const;
128  const Vector &getResistingForceIncInertia(void) const;
129 
130  // public methods for element output
131  int sendSelf(CommParameters &);
132  int recvSelf(const CommParameters &);
133  int displaySelf(Renderer &theViewer, int displayMode, float fact);
134  void Print(std::ostream &s, int flag =0);
135 
136  Response *setResponse(const std::vector<std::string> &argv, Information &eleInfo);
137  int getResponse(int responseID, Information &eleInfo);
138 
139  // AddingSensitivity:BEGIN //////////////////////////////////////////
140  int setParameter(const std::vector<std::string> &argv, Parameter &param);
141  int updateParameter(int parameterID, Information &info);
142  int activateParameter(int parameterID);
143  const Vector & getResistingForceSensitivity(int gradNumber);
144  const Matrix & getKiSensitivity(int gradNumber);
145  const Matrix & getMassSensitivity(int gradNumber);
146  int commitSensitivity(int gradNumber, int numGrads);
147  // AddingSensitivity:END ///////////////////////////////////////////
148 };
149 } // end of XC namespace
150 
151 #endif
152 
CrdTransf provides the abstraction of a frame coordinate transformation. It is an abstract base class...
Definition: CrdTransf.h:87
void Print(std::ostream &s, int flag=0)
Imprime el objeto.
Definition: DispBeamColumn2d.cpp:665
2D beam element with SectionForceDeformation type material.
Definition: BeamColumnWithSectionFDTrf2d.h:43
One-dimensional Gauss quadrature.
Definition: GaussQuadRule1d01.h:69
Base class for materials.
Definition: Material.h:85
const Vector & getResistingForceIncInertia(void) const
Returns the action of the element over its attached nodes. Computes damping matrix.
Definition: DispBeamColumn2d.cpp:582
Domain (mesh and boundary conditions) of the finite element model.
Definition: Domain.h:98
void zeroLoad()
Zeroes loads on element.
Definition: DispBeamColumn2d.cpp:453
Definition: Vector.h:82
int sendData(CommParameters &cp)
Send members through the channel being passed as parameter.
Definition: DispBeamColumn2d.cpp:618
int update(void)
Actualiza el estado of the element.
Definition: DispBeamColumn2d.cpp:216
void setDomain(Domain *theDomain)
Sets the domain for the element.
Definition: DispBeamColumn2d.cpp:146
const Matrix & getMass(void) const
Returns the mass matrix.
Definition: DispBeamColumn2d.cpp:440
Information about an element.
Definition: Information.h:80
Base calass for the finite elements.
Definition: Element.h:104
Base class for loads over elements.
Definition: ElementalLoad.h:73
int commitState(void)
Consuma el estado of the element.
Definition: DispBeamColumn2d.cpp:173
Element * getCopy(void) const
Virtual constructor.
Definition: DispBeamColumn2d.cpp:140
int recvData(const CommParameters &cp)
Receives members through the channel being passed as parameter.
Definition: DispBeamColumn2d.cpp:630
Definition: Matrix.h:82
displacement based 2D beam element with SeccionBarraPrismatica type material.
Definition: DispBeamColumn2d.h:76
Internal forces for a beam-column 2D element.
Definition: FVectorBeamColumn2d.h:40
Definition: Parameter.h:65
Communication parameters between processes.
Definition: CommParameters.h:65
Base class for 2D coordinate transformation.
Definition: CrdTransf2d.h:77
================================================================================
Definition: ContinuaReprComponent.h:34
Definition: Response.h:71