46#define _MAZARS_MODEL_ITER_TOL 1.e-15
47#define _MAZARS_MODEL_MAX_ITER 400.
71 IsotropicDamageMaterial :: initializeFrom(ir);
72 RandomMaterialExtensionInterface :: initializeFrom(ir);
82 }
else if ( ver == 0 ) {
91 this->
Bc = (
Ac - 1.0 ) / (
Ac *
e0 );
110 this->
mapper.initializeFrom(ir);
117 double posNorm = 0.0;
124 StructuralMaterial :: giveFullSymVectorForm( strainb, strain, gp->
giveMaterialMode() );
128 strainb.
at(3) = -
nu * ( strainb.
at(1) + strainb.
at(2) ) / ( 1. -
nu );
129 }
else if ( ndim == 1 ) {
130 strainb.
at(2) = -
nu *strainb.
at(1);
131 strainb.
at(3) = -
nu *strainb.
at(1);
135 principalStrains.
resize(3);
136 for (
int i = 1; i <= 3; i++ ) {
137 principalStrains.
at(i) = strainb.
at(i);
154 for (
int i = 1; i <= 3; i++ ) {
155 if ( principalStrains.
at(i) > 0.0 ) {
156 posNorm += principalStrains.
at(i) * principalStrains.
at(i);
160 return sqrt(posNorm);
187MazarsMaterial :: giveNumberOfSpatialDimensions(
GaussPoint *gp)
const
202 answer.
resize(ndim, ndim);
203 for (
int i = 1; i <= ndim; i++ ) {
204 for (
int j = 1; j <= ndim; j++ ) {
206 answer.
at(i, j) = 1. /
E;
208 answer.
at(i, j) = -
nu /
E;
220 double gt,
gc, alpha_t, alpha_c, alpha, eqStrain2;
222 if ( kappa <= this->
e0 ) {
244 for (
int i = 1; i <= ndim; i++ ) {
245 if ( sigp.
at(i) < 0. ) {
257 epsi.
at(3) = -
nu * ( epsi.
at(1) + epsi.
at(2) ) / ( 1. -
nu );
258 epsti.
at(3) = -
nu * ( epsti.
at(1) + epsti.
at(2) ) / ( 1. -
nu );
259 }
else if ( ndim == 1 ) {
262 epsi.
at(2) = epsi.
at(3) = -
nu *epsi.
at(1);
263 epsti.
at(2) = epsti.
at(3) = -
nu *epsti.
at(1);
309 for (
int i = 1; i <= 3; i++ ) {
310 if ( epsi.
at(i) > 0.0 ) {
311 eqStrain2 += epsi.
at(i) * epsi.
at(i);
312 alpha += epsti.
at(i) * epsi.
at(i);
316 if ( eqStrain2 > 0. ) {
322 }
else if ( alpha < 0. ) {
326 if ( this->
beta == 1. ) {
328 alpha_c = 1. - alpha;
329 }
else if ( alpha <= 0. ) {
332 }
else if ( alpha < 1. ) {
333 alpha_t = pow(alpha, this->
beta);
334 alpha_c = pow( ( 1. - alpha ), this->
beta );
340 auto omega = alpha_t * gt + alpha_c *
gc;
348double MazarsMaterial :: computeGt(
double kappa,
GaussPoint *gp)
const
353 gt = 1.0 - ( this->
e0 / kappa ) * exp( ( this->
e0 - kappa ) / this->
ef );
355 gt = 1.0 - ( 1.0 - this->
At ) * this->
e0 / kappa - this->
At *exp( -this->
Bt * ( kappa - this->
e0 ) );
363 double aux, hCurrt, kappaRefT, dgt, R;
365 hCurrt = status->
giveLe();
369 gt = 1.0 - ( this->
e0 / kappaRefT ) * exp( ( this->
e0 - kappaRefT ) / this->
ef );
370 dgt = this->
e0 / kappaRefT / kappaRefT + this->
e0 / kappaRefT / this->
ef;
371 dgt *= exp( ( this->
e0 - kappaRefT ) / this->
ef );
373 gt = 1.0 - ( 1.0 - this->
At ) * this->
e0 / kappaRefT - this->
At *exp( -this->
Bt * ( kappaRefT - this->
e0 ) );
374 dgt = ( 1.0 - this->
At ) * this->
e0 / kappaRefT / kappaRefT + this->
At *exp( -this->
Bt * ( kappaRefT - this->
e0 ) ) * this->
Bt;
377 aux = 1 + gt * (
hReft / hCurrt - 1.0 );
378 R = kappaRefT * aux - kappa;
380 if ( ( gt < 0. ) || ( gt > 1.0 ) ) {
384 return gt * (
hReft * kappaRefT ) / ( hCurrt * kappa );
387 aux += dgt * kappaRefT * (
hReft / hCurrt - 1.0 );
388 kappaRefT += -R / aux;
391 OOFEM_ERROR(
"tension objectivity iteration internal error - no convergence");
395double MazarsMaterial :: computeGc(
double kappa,
GaussPoint *gp)
const
399 gc = 1.0 - ( 1.0 - this->
Ac ) * this->
e0 / kappa - this->
Ac *exp( -this->
Bc * ( kappa - this->
e0 ) );
405 double aux, hCurrc, kappaRefC, dgc, R;
410 gc = 1.0 - ( 1.0 - this->
Ac ) * this->
e0 / kappaRefC - this->
Ac *exp( -this->
Bc * ( kappaRefC - this->
e0 ) );
411 aux = 1 +
gc * (
hRefc / hCurrc - 1.0 );
412 R = kappaRefC * aux - kappa;
414 return gc * (
hRefc * kappaRefC ) / ( hCurrc * kappa );
417 dgc = ( 1.0 - this->
Ac ) * this->
e0 / kappaRefC / kappaRefC + this->
Ac *exp( -this->
Bc * ( kappaRefC - this->
e0 ) ) * this->
Bc;
418 aux += dgc * kappaRefC * (
hRefc / hCurrc - 1.0 );
419 kappaRefC += -R / aux;
422 OOFEM_ERROR(
"compression objectivity iteration internal error - no convergence");
428 int indmin = 1, indmax = 1;
430 FloatArray principalStrains, crackPlaneNormal(3);
434 if ( ( kappa > this->
e0 ) && ( status->
giveDamage() == 0. ) ) {
439 crackPlaneNormal.
zero();
440 crackPlaneNormal.
at(1) = 1.0;
449 principalDir.
resize(2, 2);
454 if ( principalStrains.
at(1) > principalStrains.
at(2) ) {
463 for (
int i = 2; i <= 3; i++ ) {
464 if ( principalStrains.
at(i) > principalStrains.
at(indmax) ) {
468 if ( principalStrains.
at(i) < principalStrains.
at(indmin) ) {
474 for (
int i = 1; i <= principalStrains.
giveSize(); i++ ) {
475 crackPlaneNormal.
at(i) = principalDir.
at(i, indmax);
482 for (
int i = 1; i <= principalStrains.
giveSize(); i++ ) {
483 crackPlaneNormal.
at(i) = principalDir.
at(i, indmin);
501 IsotropicDamageMaterial1Status :: saveContext(stream, mode);
511 IsotropicDamageMaterial1Status :: restoreContext(stream, mode);
#define REGISTER_Material(class)
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.
virtual double giveCharacteristicLength(const FloatArray &normalToCrackPlane)
Index giveSize() const
Returns the size of receiver.
void zero()
Zeroes all coefficients of receiver.
void beProductOf(const FloatMatrix &aMatrix, const FloatArray &anArray)
bool isEmpty() const
Returns true if receiver is empty.
void resize(Index rows, Index cols)
bool beInverseOf(const FloatMatrix &src)
double at(std::size_t i, std::size_t j) const
MaterialMode giveMaterialMode()
Returns corresponding material mode of receiver.
Element * giveElement()
Returns corresponding element to receiver.
IsotropicDamageMaterial1Status(GaussPoint *g)
Constructor.
SofteningType softType
Parameter specifying the type of softening (damage law).
double e0
Equivalent strain at stress peak (or a similar parameter).
IsotropicDamageMaterial1(int n, Domain *d)
Constructor.
static MMAContainingElementProjection mapper
Mapper used to map internal variables in adaptivity.
MaterialStatus * giveStatus(GaussPoint *gp) const override
EquivStrainType equivStrainType
Parameter specifying the definition of equivalent strain.
double ef
Determines ductility -> corresponds to fracturing strain.
double giveLe() const
Returns characteristic length stored in receiver.
double giveDamage() const
Returns the last equilibrated damage level.
void setLe(double ls)
Sets characteristic length to given value.
LinearElasticMaterial * linearElasticMaterial
Reference to bulk (undamaged) material.
enum oofem::IsotropicDamageMaterial::loaUnloCriterium llcriteria
double lec
Characteristic element length for compression, fixed as square from element size (for 2d).
void setLec(double ls)
Sets characteristic length to given value.
double giveLec()
Returns characteristic length stored in receiver.
double E
Elastic parameters.
double computeGt(double kappa, GaussPoint *gp) const
double beta
Beta coefficient reducing the effect of shear; default val = 1.06.
double computeGc(double kappa, GaussPoint *gp) const
double At
Model parameters related to the shape of uniaxial stress-strain diagrams.
void giveNormalBlockOfElasticCompliance(FloatMatrix &answer, GaussPoint *gp) const
enum oofem::MazarsMaterial::mazarsModelVariant modelVersion
double hReft
Reference elem-length for objectivity.
int giveNumberOfSpatialDimensions(GaussPoint *gp) const
static void computePrincipalValues(FloatArray &answer, const FloatArray &s, stressStrainPrincMode mode)
Common functions for convenience.
static void computePrincipalValDir(FloatArray &answer, FloatMatrix &dir, const FloatArray &s, stressStrainPrincMode mode)
#define _IFT_IsotropicLinearElasticMaterial_n
#define _IFT_IsotropicLinearElasticMaterial_e
#define _MAZARS_MODEL_ITER_TOL
#define _MAZARS_MODEL_MAX_ITER
#define _IFT_MazarsMaterial_ac
#define _IFT_MazarsMaterial_ef
#define _IFT_MazarsMaterial_at
#define _IFT_MazarsMaterial_beta
#define _IFT_MazarsMaterial_version
#define _IFT_MazarsMaterial_hrefc
#define _IFT_MazarsMaterial_e0
#define _IFT_MazarsMaterial_hreft
#define _IFT_MazarsMaterial_bc
#define _IFT_MazarsMaterial_bt
@ principal_strain
For computing principal strains from engineering strains.
@ CIO_IOERR
General IO error.
oofem::oofegGraphicContext gc[OOFEG_LAST_LAYER]