/
ShellMITC4.h
191 lines (141 loc) · 5.79 KB
/
ShellMITC4.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
/* ****************************************************************** **
** OpenSees - Open System for Earthquake Engineering Simulation **
** Pacific Earthquake Engineering Research Center **
** **
** **
** (C) Copyright 1999, The Regents of the University of California **
** All Rights Reserved. **
** **
** Commercial use of this program without express permission of the **
** University of California, Berkeley, is strictly prohibited. See **
** file 'COPYRIGHT' in main directory for information on usage and **
** redistribution, and for a DISCLAIMER OF ALL WARRANTIES. **
** **
** Developed by: **
** Frank McKenna (fmckenna@ce.berkeley.edu) **
** Gregory L. Fenves (fenves@ce.berkeley.edu) **
** Filip C. Filippou (filippou@ce.berkeley.edu) **
** **
** ****************************************************************** */
// $Revision: 1.10 $
// $Date: 2011/03/10 22:51:21 $
// $Source: /usr/local/cvs/OpenSees/SRC/element/shell/ShellMITC4.h,v $
// Written: Leopoldo Tesser, Diego A. Talledo, Véronique Le Corvec
//
// Bathe MITC 4 four node shell element with membrane and drill
// Ref: Dvorkin,Bathe, A continuum mechanics based four node shell
// element for general nonlinear analysis,
// Eng.Comput.,1,77-88,1984
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <ID.h>
#include <Vector.h>
#include <Matrix.h>
#include <Element.h>
#include <Node.h>
#include <SectionForceDeformation.h>
#include <R3vectors.h>
class ShellMITC4 : public Element {
public:
//null constructor
ShellMITC4( );
//full constructor
ShellMITC4( int tag,
int node1,
int node2,
int node3,
int node4,
SectionForceDeformation &theMaterial ) ;
//destructor
virtual ~ShellMITC4( ) ;
//set domain because frank is a dumb ass
void setDomain( Domain *theDomain ) ;
//get the number of external nodes
int getNumExternalNodes( ) const ;
//return connected external nodes
const ID &getExternalNodes( ) ;
Node **getNodePtrs( );
//return number of dofs
int getNumDOF( ) ;
//commit state
int commitState( ) ;
//revert to last commit
int revertToLastCommit( ) ;
//revert to start
int revertToStart( ) ;
//print out element data
void Print( OPS_Stream &s, int flag ) ;
//return stiffness matrix
const Matrix &getTangentStiff( ) ;
const Matrix &getInitialStiff( );
const Matrix &getMass( );
// methods for applying loads
void zeroLoad( void );
int addLoad( ElementalLoad *theLoad, double loadFactor );
int addInertiaLoadToUnbalance( const Vector &accel );
//get residual
const Vector &getResistingForce( ) ;
//get residual with inertia terms
const Vector &getResistingForceIncInertia( ) ;
// public methods for element output
int sendSelf ( int commitTag, Channel &theChannel );
int recvSelf ( int commitTag, Channel &theChannel, FEM_ObjectBroker
&theBroker );
Response* setResponse( const char **argv, int argc, OPS_Stream &output );
int getResponse( int responseID, Information &eleInfo );
//plotting
int displaySelf( Renderer &theViewer, int displayMode, float fact );
private :
//static data
static Matrix stiff ;
static Vector resid ;
static Matrix mass ;
static Matrix damping ;
//quadrature data
static const double root3 ;
static const double one_over_root3 ;
static double sg[4] ;
static double tg[4] ;
static double wg[4] ;
//node information
ID connectedExternalNodes ; //four node numbers
Node *nodePointers[4] ; //pointers to four nodes
//drilling stiffness
double Ktt ;
//material information
SectionForceDeformation *materialPointers[4] ; //pointers to four materials
//local nodal coordinates, two coordinates for each of four nodes
//static double xl[][4] ;
double xl[2][4] ;
//shell basis vectors
double g1[3] ;
double g2[3] ;
double g3[3] ;
//compute local coordinates and basis
void computeBasis( ) ;
//inertia terms
void formInertiaTerms( int tangFlag ) ;
//form residual and tangent
void formResidAndTangent( int tang_flag ) ;
//compute Bdrill matrix
double* computeBdrill( int node, const double shp[3][4] ) ;
//assemble a B matrix
const Matrix& assembleB( const Matrix &Bmembrane,
const Matrix &Bbend,
const Matrix &Bshear ) ;
//compute Bmembrane matrix
const Matrix& computeBmembrane( int node, const double shp[3][4] ) ;
//compute Bbend matrix
const Matrix& computeBbend( int node, const double shp[3][4] ) ;
//Matrix transpose
Matrix transpose( int dim1, int dim2, const Matrix &M ) ;
//shape function routine for four node quads
void shape2d( double ss, double tt,
const double x[2][4],
double shp[3][4],
double &xsj ) ;
// vector for applying loads
Vector *load;
Matrix *Ki;
} ;