FeapMaterial.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.3 $
00022 // $Date: 2006/08/04 18:18:37 $
00023 // $Source: /usr/local/cvs/OpenSees/SRC/material/nD/FeapMaterial.h,v $
00024                                                                       
00025 // Written: MHS
00026 // Created: June 2001
00027 //
00028 // Description: This file contains the class definition for 
00029 // FeapMaterial. FeapMaterial wraps a Feap material subroutine.
00030 
00031 #ifndef FeapMaterial_h
00032 #define FeapMaterial_h
00033 
00034 #include <NDMaterial.h>
00035 
00036 class FeapMaterial : public NDMaterial
00037 {
00038  public:
00039   FeapMaterial(int tag, int classTag, int numHV, int numData,
00040                double rho = 0.0);
00041   FeapMaterial(int classTag);
00042   virtual ~FeapMaterial();
00043 
00044   virtual const char *getClassType(void) const {return "FeapMaterial";};
00045   
00046   virtual int setTrialStrain(const Vector &strain);
00047   virtual const Vector &getStrain(void);
00048   virtual const Vector &getStress(void);
00049   virtual const Matrix &getTangent(void);
00050   virtual double getRho(void);
00051   
00052   virtual int commitState(void);
00053   virtual int revertToLastCommit(void);    
00054   virtual int revertToStart(void);        
00055   
00056   virtual NDMaterial *getCopy(void);
00057   virtual NDMaterial *getCopy(const char *type);
00058   virtual const char *getType(void) const;
00059   virtual int getOrder(void) const;
00060   
00061   virtual int sendSelf(int commitTag, Channel &theChannel);  
00062   virtual int recvSelf(int commitTag, Channel &theChannel, 
00063                        FEM_ObjectBroker &theBroker);    
00064   
00065   virtual void Print(OPS_Stream &s, int flag = 0);
00066   
00067  protected:
00068   // Invokes the Feap subroutine
00069   virtual int invokeSubroutine(int isw);
00070   virtual int fillDArray(void);
00071   
00072   double *ud;   // Material parameters array
00073   double *hstv; // History array: first half is committed, second half is trial
00074   
00075   static double d[];    // Feap material parameter array
00076   
00077   double rho;           // Material mass density
00078   
00079  private:
00080   int numHV;            // Number of history variables
00081   int numData;          // Number of material parameters
00082   
00083   double eps[6];        // Strain vector
00084   static double sig[6]; // Stress vector
00085   static double dd[36]; // Tangent matrix
00086   
00087   static Vector strain3;
00088   static Vector strain4;
00089   static Vector strain6;
00090   
00091   static Vector sigma3;
00092   static Vector sigma4;
00093   static Vector sigma6;
00094   
00095   static Matrix tangent3;
00096   static Matrix tangent4;
00097   static Matrix tangent6;
00098   
00099   enum Formulation{Unknown, ThreeDimensional, PlaneStrain, AxiSymmetric};
00100   int myFormulation;
00101   void setType(Formulation form);
00102 };
00103 
00104 #endif

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