OOFEM 3.0
Loading...
Searching...
No Matches
mat_cebfip90.C
Go to the documentation of this file.
1/*
2 *
3 * ##### ##### ###### ###### ### ###
4 * ## ## ## ## ## ## ## ### ##
5 * ## ## ## ## #### #### ## # ##
6 * ## ## ## ## ## ## ## ##
7 * ## ## ## ## ## ## ## ##
8 * ##### ##### ## ###### ## ##
9 *
10 *
11 * OOFEM : Object Oriented Finite Element Code
12 *
13 * Copyright (C) 1993 - 2025 Borek Patzak
14 *
15 *
16 *
17 * Czech Technical University, Faculty of Civil Engineering,
18 * Department of Structural Mechanics, 166 29 Prague, Czech Republic
19 *
20 * This library is free software; you can redistribute it and/or
21 * modify it under the terms of the GNU Lesser General Public
22 * License as published by the Free Software Foundation; either
23 * version 2.1 of the License, or (at your option) any later version.
24 *
25 * This program is distributed in the hope that it will be useful,
26 * but WITHOUT ANY WARRANTY; without even the implied warranty of
27 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
28 * Lesser General Public License for more details.
29 *
30 * You should have received a copy of the GNU Lesser General Public
31 * License along with this library; if not, write to the Free Software
32 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
33 */
34
35#include "mat_cebfip90.h"
36#include "gausspoint.h"
37#include "floatmatrix.h"
38#include "floatarray.h"
39#include "mathfem.h"
40#include "datastream.h"
41#include "contextioerr.h"
42#include "classfactory.h"
43#include "dynamicinputrecord.h"
44
45namespace oofem {
47
48CebFipSlip90Material :: CebFipSlip90Material(int n, Domain *d) : StructuralInterfaceMaterial(n, d)
49{ }
50
51
52double
53CebFipSlip90Material :: giveEngTraction_1d(double jump, GaussPoint *gp, TimeStep *tStep) const
54{
55 CebFipSlip90MaterialStatus *status = static_cast< CebFipSlip90MaterialStatus * >( this->giveStatus(gp) );
56 double slip = jump;
57 // compute value of loading function if strainLevel crit apply
58 double f = fabs(slip) - status->giveKappa();
59
60 double tempKappa;
61 if ( f <= 0.0 ) {
62 // kappa do not grow
63 tempKappa = status->giveKappa();
64 } else {
65 // kappa grow
66 tempKappa = fabs(slip);
67 // evaluate damage parameter
68 }
69
70 double answer = 0.0;
71 if ( tempKappa > 1.e-12 ) {
72 answer = ( this->computeBondForce(tempKappa) / tempKappa ) * slip;
73 }
74
75 // update gp
76 status->letTempJumpBe({jump, 0., 0.});
77 status->letTempTractionBe({answer, 0., 0.});
78 status->setTempKappa(tempKappa);
79
80 return answer;
81}
82
83
85CebFipSlip90Material :: give1dStiffnessMatrix_Eng(MatResponseMode mode, GaussPoint *gp, TimeStep *tStep) const
86{
87 CebFipSlip90MaterialStatus *status = static_cast< CebFipSlip90MaterialStatus * >( this->giveStatus(gp) );
88 FloatMatrixF<1,1> answer;
89
90 if ( mode == ElasticStiffness || mode == SecantStiffness ) {
91 double kappa = status->giveKappa();
92
93 if ( kappa > 0.0 ) {
94 answer.at(1, 1) = ( this->computeBondForce(kappa) / kappa );
95 } else {
96 answer.at(1, 1) = computeBondForceStiffness(0.0);
97 }
98 } else if ( mode == TangentStiffness ) {
99 answer.at(1, 1) = computeBondForceStiffness( status->giveTempKappa() );
100 } else {
101 OOFEM_ERROR("unknown MatResponseMode (%s)", __MatResponseModeToString(mode) );
102 }
103 return answer;
104}
105
106
107int
108CebFipSlip90Material :: giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
109{
110 CebFipSlip90MaterialStatus *status = static_cast< CebFipSlip90MaterialStatus * >( this->giveStatus(gp) );
111
112 if ( type == IST_DamageScalar ) {
113 answer.resize(1);
114 answer.at(1) = status->giveKappa();
115 return 1;
116 } else {
117 return StructuralInterfaceMaterial :: giveIPValue(answer, gp, type, tStep);
118 }
119}
120
121
122void
123CebFipSlip90Material :: initializeFrom(InputRecord &ir)
124{
125 StructuralInterfaceMaterial :: initializeFrom(ir);
126
129
133
134 alpha = 0.4;
135}
136
137
138void
139CebFipSlip90Material :: giveInputRecord(DynamicInputRecord &input)
140{
141 StructuralInterfaceMaterial :: giveInputRecord(input);
144
148}
149
150
151
152double
153CebFipSlip90Material :: computeBondForce(double s) const
154{
155 if ( s <= s1 ) {
156 return tmax *pow( ( s / s1 ), alpha );
157 } else if ( ( s >= s1 ) && ( s <= s2 ) ) {
158 return tmax;
159 } else if ( ( s >= s2 ) && ( s <= s3 ) ) {
160 return tmax - ( tmax - tres ) * ( s - s1 ) / ( s3 - s2 );
161 } else {
162 return tres;
163 }
164}
165
166
167double
168CebFipSlip90Material :: computeBondForceStiffness(double s) const
169{
170 if ( s <= s1 / 1000. ) {
171 s = s1 / 1000.;
172 return alpha *tmax *pow( ( s / s1 ), alpha - 1 ) / s1;
173 } else if ( s <= s1 ) {
174 return alpha *tmax *pow( ( s / s1 ), alpha - 1 ) / s1;
175 } else if ( ( s >= s1 ) && ( s <= s2 ) ) {
176 return 1.e-6; // should be zero
177 } else if ( ( s >= s2 ) && ( s <= s3 ) ) {
178 return -( tmax - tres ) / ( s3 - s2 );
179 } else {
180 return 1.e-6; // should be zero
181 }
182}
183
184
185CebFipSlip90MaterialStatus :: CebFipSlip90MaterialStatus(GaussPoint *g) : StructuralInterfaceMaterialStatus(g)
186{}
187
188
189void
190CebFipSlip90MaterialStatus :: printOutputAt(FILE *file, TimeStep *tStep) const
191{
192 StructuralInterfaceMaterialStatus :: printOutputAt(file, tStep);
193 fprintf(file, "status { ");
194 fprintf(file, "kappa %f", this->kappa);
195
196 fprintf(file, "}\n");
197}
198
199
200void
201CebFipSlip90MaterialStatus :: initTempStatus()
202{
203 StructuralInterfaceMaterialStatus :: initTempStatus();
204 this->tempKappa = this->kappa;
205}
206
207
208void
209CebFipSlip90MaterialStatus :: updateYourself(TimeStep *tStep)
210{
211 StructuralInterfaceMaterialStatus :: updateYourself(tStep);
212 this->kappa = this->tempKappa;
213}
214
215
216void
217CebFipSlip90MaterialStatus :: saveContext(DataStream &stream, ContextMode mode)
218{
219 StructuralInterfaceMaterialStatus :: saveContext(stream, mode);
220
221 if ( !stream.write(kappa) ) {
223 }
224}
225
226
227void
228CebFipSlip90MaterialStatus :: restoreContext(DataStream &stream, ContextMode mode)
229{
230 StructuralInterfaceMaterialStatus :: restoreContext(stream, mode);
231
232 if ( !stream.read(kappa) ) {
234 }
235}
236} // end namespace oofem
#define REGISTER_Material(class)
double giveKappa() const
Returns the last equilibrated scalar measure of the largest strain level.
void setTempKappa(double newKappa)
Sets the temp scalar measure of the largest strain level to given value.
double tempKappa
Non-equilibrated scalar of the largest slip displacement.
double giveTempKappa() const
Returns the temp. scalar measure of the largest strain level.
double kappa
Scalar measure of the largest slip reached in material.
double tmax
Max force (stress).
double s1
Slip valu at begining of yield plateau.
double s2
Slip at end of plateau.
double alpha
Alpha coeff.
double s3
Slip when residual force/stress activated.
double computeBondForceStiffness(double kappa) const
double computeBondForce(double kappa) const
double tres
Residual force/stress.
virtual int read(int *data, std::size_t count)=0
Reads count integer values into array pointed by data.
virtual int write(const int *data, std::size_t count)=0
Writes count integer values from array pointed by data.
void setField(int item, InputFieldType id)
void resize(Index s)
Definition floatarray.C:94
double & at(Index i)
Definition floatarray.h:202
double at(std::size_t i, std::size_t j) const
virtual MaterialStatus * giveStatus(GaussPoint *gp) const
Definition material.C:206
StructuralInterfaceMaterialStatus(GaussPoint *g)
Constructor. Creates new StructuralInterfaceMaterialStatus with number n, belonging to domain d and I...
void letTempTractionBe(const FloatArrayF< 3 > v)
Assigns tempTraction to given vector v.
void letTempJumpBe(const FloatArrayF< 3 > v)
Assigns tempJump to given vector v.
#define THROW_CIOERR(e)
#define OOFEM_ERROR(...)
Definition error.h:79
#define IR_GIVE_FIELD(__ir, __value, __id)
Definition inputrecord.h:67
#define _IFT_CebFipSlip90Material_tres
#define _IFT_CebFipSlip90Material_s1
#define _IFT_CebFipSlip90Material_s3
#define _IFT_CebFipSlip90Material_s2
#define _IFT_CebFipSlip90Material_tmax
long ContextMode
Definition contextmode.h:43
@ CIO_IOERR
General IO error.

This page is part of the OOFEM-3.0 documentation. Copyright Copyright (C) 1994-2025 Borek Patzak Bořek Patzák
Project e-mail: oofem@fsv.cvut.cz
Generated at for OOFEM by doxygen 1.15.0 written by Dimitri van Heesch, © 1997-2011