ForceBeamColumn3d.h

Go to the documentation of this file.
00001 /* ****************************************************************** **
00002 **    OpenSees - Open System for Earthquake Engineering Simulation    **
00003 **          Pacific Earthquake Engineering Research Center            **
00004 **                                                                    **
00005 **                                                                    **
00006 ** (C) Copyright 1999, The Regents of the University of California    **
00007 ** All Rights Reserved.                                               **
00008 **                                                                    **
00009 ** Commercial use of this program without express permission of the   **
00010 ** University of California, Berkeley, is strictly prohibited.  See   **
00011 ** file 'COPYRIGHT'  in main directory for information on usage and   **
00012 ** redistribution,  and for a DISCLAIMER OF ALL WARRANTIES.           **
00013 **                                                                    **
00014 ** Developed by:                                                      **
00015 **   Frank McKenna (fmckenna@ce.berkeley.edu)                         **
00016 **   Gregory L. Fenves (fenves@ce.berkeley.edu)                       **
00017 **   Filip C. Filippou (filippou@ce.berkeley.edu)                     **
00018 **                                                                    **
00019 ** ****************************************************************** */
00020 
00021 // $Revision: 1.9 $
00022 // $Date: 2006/09/05 23:24:12 $
00023 // $Source: /usr/local/cvs/OpenSees/SRC/element/forceBeamColumn/ForceBeamColumn3d.h,v $
00024 
00025 #ifndef ForceBeamColumn3d_h
00026 #define ForceBeamColumn3d_h
00027 
00028 #include <Element.h>
00029 #include <Node.h>
00030 #include <Matrix.h>
00031 #include <Vector.h>
00032 #include <Channel.h>
00033 #include <BeamIntegration.h>
00034 #include <SectionForceDeformation.h>
00035 #include <CrdTransf3d.h>
00036 
00037 class Response;
00038 class ElementalLoad;
00039 
00040 class ForceBeamColumn3d: public Element
00041 {
00042  public:
00043   ForceBeamColumn3d();
00044   ForceBeamColumn3d(int tag, int nodeI, int nodeJ, 
00045                     int numSections, SectionForceDeformation **sec,
00046                     BeamIntegration &beamIntegr,
00047                     CrdTransf3d &coordTransf, double rho = 0.0, 
00048                     int maxNumIters = 10, double tolerance = 1.0e-12);
00049   
00050   ~ForceBeamColumn3d();
00051   const char *getClassType(void) const {return "ForceBeamColumn3d";};
00052   
00053   int getNumExternalNodes(void) const;
00054   const ID &getExternalNodes(void);
00055   Node **getNodePtrs(void);
00056   
00057   int getNumDOF(void);
00058   
00059   void setDomain(Domain *theDomain);
00060   int commitState(void);
00061   int revertToLastCommit(void);        
00062   int revertToStart(void);
00063   int update(void);    
00064   
00065   const Matrix &getTangentStiff(void);
00066   const Matrix &getInitialStiff(void);
00067   const Matrix &getMass(void);    
00068   
00069   void zeroLoad(void);  
00070   int addLoad(ElementalLoad *theLoad, double loadFactor);
00071   int addInertiaLoadToUnbalance(const Vector &accel);
00072   
00073   const Vector &getResistingForce(void);
00074   const Vector &getResistingForceIncInertia(void);            
00075   
00076   int sendSelf(int cTag, Channel &theChannel);
00077   int recvSelf(int cTag, Channel &theChannel, FEM_ObjectBroker &theBroker);
00078   int displaySelf(Renderer &theViewer, int displayMode, float fact);        
00079   
00080   friend OPS_Stream &operator<<(OPS_Stream &s, ForceBeamColumn3d &E);        
00081   void Print(OPS_Stream &s, int flag =0);    
00082   
00083   Response *setResponse(const char **argv, int argc, Information &eleInformation, OPS_Stream &s);
00084   int getResponse(int responseID, Information &eleInformation);
00085   
00086   int setParameter(const char **argv, int argc, Parameter &param);
00087   int updateParameter(int parameterID, Information &info);
00088   
00089  protected:
00090   void setSectionPointers(int numSections, SectionForceDeformation **secPtrs);
00091   int getInitialFlexibility(Matrix &fe);
00092   
00093  private:
00094   void getForceInterpolatMatrix(double xi, Matrix &b, const ID &code);
00095   void getDistrLoadInterpolatMatrix(double xi, Matrix &bp, const ID &code);
00096   void compSectionDisplacements(Vector sectionCoords[], Vector sectionDispls[]) const;
00097   void initializeSectionHistoryVariables (void);
00098   
00099   // internal data
00100   ID     connectedExternalNodes; // tags of the end nodes
00101 
00102   BeamIntegration *beamIntegr;
00103   int numSections;
00104   SectionForceDeformation **sections;          // array of pointers to sections
00105   CrdTransf3d *crdTransf;        // pointer to coordinate tranformation object 
00106   // (performs the transformation between the global and basic system)
00107   double rho;                    // mass density per unit length
00108   int    maxIters;               // maximum number of local iterations
00109   double tol;                      // tolerance for relative energy norm for local iterations
00110   
00111   int    initialFlag;            // indicates if the element has been initialized
00112   
00113   Node *theNodes[2];   // pointers to the nodes
00114   
00115   Matrix kv;                     // stiffness matrix in the basic system 
00116   Vector Se;                     // element resisting forces in the basic system
00117   
00118   Matrix kvcommit;               // commited stiffness matrix in the basic system
00119   Vector Secommit;               // commited element end forces in the basic system
00120   
00121   Matrix *fs;                    // array of section flexibility matrices
00122   Vector *vs;                    // array of section deformation vectors
00123   Vector *Ssr;                   // array of section resisting force vectors
00124   
00125   Vector *vscommit;              // array of commited section deformation vectors
00126   
00127   Matrix *sp;
00128   double p0[5]; // Reactions in the basic system due to element loads
00129   double v0[5]; // Initial deformations due to element loads
00130 
00131   Matrix *Ki;
00132 
00133   bool isTorsion;
00134   
00135   static Matrix theMatrix;
00136   static Vector theVector;
00137   static double workArea[];
00138   
00139   enum {maxNumSections = 10};
00140   
00141   // following are added for subdivision of displacement increment
00142   int    maxSubdivisions;       // maximum number of subdivisons of dv for local iterations
00143   
00144   static Vector *vsSubdivide;
00145   static Vector *SsrSubdivide;
00146   static Matrix *fsSubdivide;
00147   //static int maxNumSections;
00148 };
00149 
00150 #endif

Generated on Mon Oct 23 15:05:06 2006 for OpenSees by doxygen 1.5.0