TotalLagrangianFD20NodeBrick.h

Go to the documentation of this file.
00001 //===============================================================================
00002 //# COPYRIGHT (C): Woody's license (by BJ):
00003 //                 ``This    source  code is Copyrighted in
00004 //                 U.S.,  for  an  indefinite  period,  and anybody
00005 //                 caught  using it without our permission, will be
00006 //                 mighty good friends of ourn, cause we don't give
00007 //                 a  darn.  Hack it. Compile it. Debug it. Run it.
00008 //                 Yodel  it.  Enjoy it. We wrote it, that's all we
00009 //                 wanted to do.''
00010 //
00011 //# PROJECT:           Object Oriented Finite Element Program
00012 //# PURPOSE:           Finite Deformation Hyper-Elastic classes
00013 //# CLASS:
00014 //#
00015 //# VERSION:           0.6_(1803398874989) (golden section)
00016 //# LANGUAGE:          C++
00017 //# TARGET OS:         all...
00018 //# DESIGN:            Zhao Cheng, Boris Jeremic (jeremic@ucdavis.edu)
00019 //# PROGRAMMER(S):     Zhao Cheng, Boris Jeremic
00020 //#
00021 //#
00022 //# DATE:              Sept2003
00023 //# UPDATE HISTORY:    28May2004, Zhao Optimized the Stiffness Tensor
00024 //#
00025 //#
00026 //===============================================================================
00027 #ifndef TOTALLAGRANGIANFD20BRICK_H
00028 #define TOTALLAGRANGIANFD20BRICK_H
00029 
00030 #ifndef _bool_h
00031 #include "bool.h"
00032 #endif
00033 
00034 #include <ID.h>
00035 #include <Renderer.h>
00036 #include <Domain.h>
00037 #include <Element.h>
00038 #include <Node.h>
00039 
00040 #include <string.h>
00041 
00042 #include <OPS_Globals.h>
00043 
00044 #include <basics.h>
00045 #include <nDarray.h>
00046 #include <Vector.h>
00047 #include <Matrix.h>
00048 #include <BJtensor.h>
00049 #include <stresst.h>
00050 #include <straint.h>
00051 
00052 #include <NDMaterial.h>
00053 
00054 #include <Information.h>
00055 #include <Channel.h>
00056 #include <FEM_ObjectBroker.h>
00057 #include <ElementResponse.h>
00058 #include <ElementalLoad.h>
00059 
00060 
00061 class TotalLagrangianFD20NodeBrick: public Element
00062 {
00063   public:
00064     TotalLagrangianFD20NodeBrick(int tag,
00065     int node_numb_1,  int node_numb_2,  int node_numb_3,  int node_numb_4,
00066     int node_numb_5,  int node_numb_6,  int node_numb_7,  int node_numb_8,
00067     int node_numb_9,  int node_numb_10, int node_numb_11, int node_numb_12,
00068     int node_numb_13, int node_numb_14, int node_numb_15, int node_numb_16,
00069     int node_numb_17, int node_numb_18, int node_numb_19, int node_numb_20,
00070     NDMaterial &m, double b1=0.0, double b2=0.0, double b3=0.0);
00071 
00072     TotalLagrangianFD20NodeBrick ();
00073     ~TotalLagrangianFD20NodeBrick();
00074     
00075     const char *getClassType(void) const {return "TotalLagrangianFD20NodeBrick";};
00076     
00077     int getNumExternalNodes () const;
00078     const ID &getExternalNodes ();
00079     Node **getNodePtrs();
00080 
00081     int getNumDOF ();
00082     void setDomain(Domain *theDomain);
00083 
00084     int commitState ();
00085     int revertToLastCommit ();
00086     int revertToStart ();
00087     int update();
00088 
00089     const Matrix &getTangentStiff ();
00090     const Matrix &getInitialStiff();
00091     const Matrix &getMass ();
00092 
00093     void zeroLoad ();
00094     int addLoad(ElementalLoad *theLoad, double loadFactor);
00095     int addInertiaLoadToUnbalance(const Vector &accel);
00096 
00097     const Vector &getResistingForce ();
00098     const Vector &getResistingForceIncInertia ();
00099 
00100     // public methods for element output
00101     int sendSelf (int commitTag, Channel &theChannel);
00102     int recvSelf (int commitTag, Channel &theChannel, FEM_ObjectBroker &theBroker);
00103     int displaySelf (Renderer &theViewer, int displayMode, float fact);
00104     void Print(OPS_Stream &s, int flag =0);
00105 
00106     Response *setResponse (const char **argv, int argc, Information &eleInformation, OPS_Stream &s);
00107     int getResponse (int responseID, Information &eleInformation);
00108 
00109 //    int setParameter(const char **argv, int argc, Information &info);
00110 //    int updateParameter(int parameterID, Information &info);
00111 
00112 
00113   protected:
00114 
00115   private:
00116 
00117     NDMaterial **theMaterial; // Pointer to the NDMaterial objects
00118     ID  connectedExternalNodes; // Tags of TotalLagrangianFD20Brick nodes
00119     Node *theNodes[20];
00120 
00121     static Matrix K;    // Element stiffness Matrix
00122 //    static Matrix C;    // Element damping matrix
00123     static Matrix M;    // Element mass matrix
00124     static Vector P;    // Element resisting force vector
00125     static const double pts[3];   // Stores quadrature points
00126     static const double wts[3];   // Stores quadrature weights
00127     Vector *Q;     // Applied nodal loads
00128     Vector bf;    // Body forces
00129 
00130     double rho;    // Mass per unit volume
00131 
00132     double det_of_Jacobian;
00133     
00134     Matrix *Ki;
00135 
00136   private:
00137     
00138     static const int  NumIntegrationPts;
00139     static const int  NumTotalGaussPts;
00140     static const int  NumNodes;
00141     static const int  NumDof;
00142     static const int  NumElemDof;
00143     
00144     tensor shapeFunction(double , double , double );
00145     tensor shapeFunctionDerivative(double , double , double );
00146 
00147     tensor Jacobian_3D(double , double , double);
00148     tensor Jacobian_3Dinv(double , double , double);
00149     tensor dh_Global(double , double , double);
00150     tensor getNodesCrds(void);
00151     tensor getNodesDisp(void);
00152 
00153     tensor getStiffnessTensor(void);
00154     tensor getRtensor(void);
00155     tensor getBodyForce(void);
00156     tensor getSurfaceForce(void);
00157     tensor getForces(void);
00158 
00159 };
00160 
00161 
00162 #endif
00163 

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