xc
ZeroLengthContact2D.h
1 // -*-c++-*-
2 //----------------------------------------------------------------------------
3 // XC program; finite element analysis code
4 // for structural analysis and design.
5 //
6 // Copyright (C) Luis C. Pérez Tato
7 //
8 // This program derives from OpenSees <http://opensees.berkeley.edu>
9 // developed by the «Pacific earthquake engineering research center».
10 //
11 // Except for the restrictions that may arise from the copyright
12 // of the original program (see copyright_opensees.txt)
13 // XC is free software: you can redistribute it and/or modify
14 // it under the terms of the GNU General Public License as published by
15 // the Free Software Foundation, either version 3 of the License, or
16 // (at your option) any later version.
17 //
18 // This software is distributed in the hope that it will be useful, but
19 // WITHOUT ANY WARRANTY; without even the implied warranty of
20 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 // GNU General Public License for more details.
22 //
23 //
24 // You should have received a copy of the GNU General Public License
25 // along with this program.
26 // If not, see <http://www.gnu.org/licenses/>.
27 //----------------------------------------------------------------------------
28 /* ****************************************************************** **
29 ** OpenSees - Open System for Earthquake Engineering Simulation **
30 ** Pacific Earthquake Engineering Research Center **
31 ** **
32 ** **
33 ** (C) Copyright 1999, The Regents of the University of California **
34 ** All Rights Reserved. **
35 ** **
36 ** Commercial use of this program without express permission of the **
37 ** University of California, Berkeley, is strictly prohibited. See **
38 ** file 'COPYRIGHT' in main directory for information on usage and **
39 ** redistribution, and for a DISCLAIMER OF ALL WARRANTIES. **
40 ** **
41 ** Developed by: **
42 ** Frank McKenna (fmckenna@ce.berkeley.edu) **
43 ** Gregory L. Fenves (fenves@ce.berkeley.edu) **
44 ** Filip C. Filippou (filippou@ce.berkeley.edu) **
45 ** **
46 ** ****************************************************************** */
47 
48 
49 
50 // $Source: /usr/local/cvs/OpenSees/SRC/element/zeroLength/ZeroLengthContact2D.h,v $
51 // $Revision: 1.2 $
52 // $Date: 2007/11/28 00:08:58 $
53 
54 
55 
56 #ifndef ZeroLengthContact2D_h
57 #define ZeroLengthContact2D_h
58 
59 /*----+----+----+----+----+----+----+----+----+----+----+----+----+----+----*
60  | |
61  | ZeroLengthContact2D element |
62  + +
63  |--------------------------------------------------------------------------|
64  | |
65  + Authors: Gang Wang AND Professor Nicholas Sitar +
66  | |
67  | Department of Civil and Environmental Engineering |
68  + University of California, Berkeley, CA 94720, USA +
69  | |
70  | Email: wang@ce.berkeley.edu (G.W.) |
71  + +
72  | Disclaimers: |
73  | (1) Frame of this code is based on zeroLength element |
74  + (2) Questions regarding this code should be directed to Gang Wang +
75  | (3) Documentation could be found at |
76  | www.ce.berkeley.edu/~wang/OpenSees.html |
77  + +
78  | Development History: |
79  | Created -- Jan/23/2004 |
80  + Final Release -- June 2004 +
81  | Add Augmented Lagrange --Oct 21,2004 |
82  | |
83  +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----*/
84 
85 
86 
87 
88 
89 /*
90  element zeroLengthContact2D $eleID $sNdID $mNdID $Kn $Kt $fs -normal $Nx $Ny
91  Description: This file contains the class definition for ZeroLengthContact2D.
92  (1) A ZeroLengthContact2D element is defined by two nodes with the same coordinate
93  in R^2
94  (2) Normal to the contact plane through these contact nodes is preset by the user
95  to be either radial or any of x,y,z axis.
96  (3) Penalty (Kn,Kt) is used to enforce the constraints, i.e.
97  No (in fact, very small) penetration in the normal direction, and
98  Coulomb frictional law in the tangential direction.
99  (4) Backward Euler return mapping scheme is used for implicit formulation of
100  residual and consistent tangent modulus.
101  (5) This element is a modified version of continuum-based implicit formulation
102  (Laursen and Simo,1993) for small deformation. Contact detection is simplified
103  to be only related to these two nodes, and contributions of geometric
104  nonlinearities to consistent tangent moudulus are neglected.
105 
106  References:
107  Laursen,T.A. and Simo, J.C. "A Continuum-based Finite Element Formulation for the
108  Implicit Solution of Multibody, Large Deformation Frictional Contact Problems".
109  Int. J. Numer. Methods Eng. , 36, 3451-3485 (1993)
110 
111  Armero, F. and Petocz, E. "A New Dissipative Time-Stepping Algorithm for Frictional
112  Contact Problems: Fromulation and Analysis", Comp. Methods Appl. Mech. Eng., 179,
113  151-178 (1999)
114  www.ce.berkeley.edu/~wang
115 */
116 #include "ZeroLengthContact.h"
117 
118 namespace XC {
119 class Node;
120 class Channel;
121 class Response;
122 
124 //
127  {
128  private:
129  // contact forces
130  double lambda;
131 
132  // Normal and Tangental Vectors for Elemental Nodes, (4*1)
133  mutable Vector T;
134  Vector ContactNormal;
135 
136  int contactDetect(void) const;
137  void formResidAndTangent(int tang_flag ) const;
138 
139  // contact point and contact plane stuffs
140  double stickPt;
141  mutable double xi;
142 
143  //static variables for 2D contact
144  static Matrix stiff;
145  static Vector resid;
146  static Matrix zeroMatrix;
147 
148  public:
149  ZeroLengthContact2D(int tag= 0);
150  ZeroLengthContact2D(int tag, int Nd1, int Nd2,double Kn, double Kt, double fRatio, const Vector& normal);
151  Element *getCopy(void) const;
152 
153  void setDomain(Domain *theDomain);
154 
155 
156  // public methods to set the state of the element
157  int commitState(void);
158  int revertToLastCommit(void);
159  int revertToStart(void);
160  int update(void);
161 
162 
163  // public methods to obtain stiffness, mass, damping and residual information
164  const Matrix &getTangentStiff(void) const;
165  const Matrix &getInitialStiff(void) const;
166  const Matrix &getDamp(void) const;
167  const Matrix &getMass(void) const;
168 
169  const Vector &getResistingForce(void) const;
170  const Vector &getResistingForceIncInertia(void) const;
171 
172 
173  // public methods for element output
174  int sendSelf(Communicator &);
175  int recvSelf(const Communicator &);
176  void Print(std::ostream &os, int flag =0) const;
177 
178  Response *setResponse(const std::vector<std::string> &argv, Information &eleInformation);
179  int getResponse(int responseID, Information &eleInformation);
180  //void updateDir (const Vector& x, const Vector& y);
181  };
182 
183 } // end of XC namespace
184 
185 
186 #endif
187 
188 
189 
190 
191 
192 
193 
194 
195 
196 
197 
int getResponse(int responseID, Information &eleInformation)
Obtain information from an analysis.
Definition: ZeroLengthContact2D.cpp:318
Float vector abstraction.
Definition: Vector.h:94
ZeroLengthContact2D(int tag=0)
Default constructor.
Definition: ZeroLengthContact2D.cpp:82
Information about an element.
Definition: Information.h:81
Communication parameters between processes.
Definition: Communicator.h:66
Base class response objects.
Definition: Response.h:81
int update(void)
@ brief update calculate stress-strain relation – M.
Definition: ZeroLengthContact2D.cpp:199
int commitState(void)
Commit the current element state.
Definition: ZeroLengthContact2D.cpp:141
const Vector & getResistingForceIncInertia(void) const
Returns the resisting force vector including inertia forces.
Definition: ZeroLengthContact2D.cpp:260
int recvSelf(const Communicator &)
Receive the object.
Definition: ZeroLengthContact2D.cpp:279
const Vector & getResistingForce(void) const
Returns the resisting force vector for the element.
Definition: ZeroLengthContact2D.cpp:248
const Matrix & getMass(void) const
Returns the mass matrix.
Definition: ZeroLengthContact2D.cpp:241
int sendSelf(Communicator &)
Send the object.
Definition: ZeroLengthContact2D.cpp:273
double Kt
tangential penalty
Definition: ZeroLengthContact.h:58
void setDomain(Domain *theDomain)
to set a link to the enclosing Domain and to set the node pointers.
Definition: ZeroLengthContact2D.cpp:93
Base class for the finite elements.
Definition: Element.h:112
Zero length element for 2D contact problems.
Definition: ZeroLengthContact2D.h:126
double Kn
normal penalty
Definition: ZeroLengthContact.h:57
Response * setResponse(const std::vector< std::string > &argv, Information &eleInformation)
setResponse() is a method invoked to determine if the element will respond to a request for a certain...
Definition: ZeroLengthContact2D.cpp:300
void Print(std::ostream &os, int flag=0) const
Print stuff.
Definition: ZeroLengthContact2D.cpp:286
int revertToStart(void)
Reverts the element to its initial state.
Definition: ZeroLengthContact2D.cpp:179
const Matrix & getDamp(void) const
Returns the damping matrix.
Definition: ZeroLengthContact2D.cpp:234
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:35
Matrix of floats.
Definition: Matrix.h:111
Element * getCopy(void) const
Virtual constructor.
Definition: ZeroLengthContact2D.cpp:87
int revertToLastCommit(void)
Revert to the last committed state.
Definition: ZeroLengthContact2D.cpp:160
Domain (mesh and boundary conditions) of the finite element model.
Definition: Domain.h:117
Zero length contact element.
Definition: ZeroLengthContact.h:44
const Matrix & getTangentStiff(void) const
Return the tangent stiffness matrix.
Definition: ZeroLengthContact2D.cpp:209