102 FloatArray princStress, nonlocalStrain, reducedSpaceStressVector;
103 FloatArray reducedNonlocStrainVector, fullNonlocStrainVector, principalStrain;
108 FloatArray reducedLocalStrainVector, localStrain;
117 for (
auto &lir: *list ) {
120 nonlocalContribution.
times(lir.weight);
122 reducedNonlocStrainVector.
add(nonlocalContribution);
132 reducedLocalStrainVector = totalStrain;
146 fullNonlocStrainVector,
176 int anyOpeningCrack = 0;
177 for (
int i = 1; i <= 3; i++ ) {
184 if ( anyOpeningCrack ) {
186 double minSofteningPrincStress = this->
Ft,
E, Le, CurrFt,
Gf, Gf0, Gf1, e0,
ef, ef2, damage;
189 for (
int i = 1; i <= 3; i++ ) {
192 if ( princStress.
at(i) < minSofteningPrincStress ) {
193 minSofteningPrincStress = princStress.
at(i);
203 double G, minG, currG, princStressDis, princStrainDis;
211 for (
int i = 4; i <= 6; i++ ) {
216 }
else if ( i == 5 ) {
219 }
else if ( i == 6 ) {
226 princStressDis = princStress.
at(ii) -
228 princStrainDis = principalStrain.
at(ii) -
229 principalStrain.
at(jj);
234 currG = princStressDis / ( 2.0 * princStrainDis );
238 minG =
min(minG, currG);
251 for (
int i = 1; i <= 3; i++ ) {
256 minSofteningPrincStress = princStress.
at(i);
259 if ( princStress.
at(i) < minSofteningPrincStress ) {
260 minSofteningPrincStress = princStress.
at(i);
271 OOFEM_ERROR(
"can not switch to sd mode, while no cracking");
281 e0 = principalStrain.
at(ipos);
285 ef2 = Gf1 / princStress.
at(ipos);
323 Ds0.
times(1.0 - damage);
338 reducedSpaceStressVector.
beProductOf(Ds0, localStrain);
340 answer = reducedSpaceStressVector;
356 if ( result !=
IRRT_OK )
return result;
359 if ( result !=
IRRT_OK )
return result;
379 this->
Gf = this->
Ft * this->
ef;
382 this->
ef = this->
Gf / this->
Ft;
406 if ( ( dist >= 0. ) && ( dist <= this->
R ) ) {
407 double help = ( 1. - dist * dist / ( R *
R ) );
441 tempNonlocalStrainVector(), localStrainVectorForAverage()
460 fprintf(file,
"nonlocstatus { ");
461 fprintf(file,
" nonloc strains ");
463 for (
auto &val : helpVec ) {
464 fprintf( file,
" %.4e", val );
467 fprintf(file,
"}\n");
567 this->buildNonlocalPointTable(ip);
568 this->updateDomainBeforeNonlocAverage(tStep);
static int giveSizeOfVoigtSymVector(MaterialMode mmode)
Returns the size of symmetric part of a reduced stress/strain vector according to given mode...
bool contains(int value) const
Abstract base class for all nonlocal structural materials.
MaterialMode giveMaterialMode()
Returns corresponding material mode of receiver.
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Stores receiver state to output stream.
RCSDNLMaterial(int n, Domain *d)
virtual void updateYourself(TimeStep *)
Update equilibrium history variables according to temp-variables.
static int giveVoigtSymVectorMask(IntArray &answer, MaterialMode mmode)
The same as giveVoigtVectorMask but returns a mask corresponding to a symmetric second order tensor...
FloatArray localStrainVectorForAverage
void letTempStrainVectorBe(const FloatArray &v)
Assigns tempStrainVector to given vector v.
void setTransitionEpsCoeff(double val)
virtual MaterialStatus * giveStatus(GaussPoint *gp) const
Returns material status of receiver in given integration point.
void updateDomainBeforeNonlocAverage(TimeStep *tStep)
Updates data in all integration points before nonlocal average takes place.
#define _IFT_RCSDNLMaterial_r
double computeCurrEquivStrain(GaussPoint *, const FloatArray &, double, TimeStep *)
GaussPoint * gp
Associated integration point.
virtual double computeWeightFunction(const FloatArray &src, const FloatArray &coord)
Evaluates the basic nonlocal weight function for two points with given coordinates.
void endIPNonlocalAverage(GaussPoint *gp)
Notifies the receiver, that the nonlocal averaging has been finished for given ip.
FloatArray nonlocalStrainVector
virtual void initTempStatus()
Initializes the temporary internal variables, describing the current state according to previously re...
For computing principal strains from engineering strains.
The purpose of DataStream abstract class is to allow to store/restore context to different streams...
#define _IFT_RCSDNLMaterial_ft
contextIOResultType storeYourself(DataStream &stream) const
double & at(int i)
Coefficient access function.
virtual int packUnknowns(DataStream &buff, TimeStep *tStep, GaussPoint *ip)
Pack all necessary data of integration point (according to element parallel_mode) into given communic...
int max(int i, int j)
Returns bigger value form two given decimals.
LinearElasticMaterial * linearElasticMaterial
double giveTempMaxEquivStrain()
LinearElasticMaterial * giveLinearElasticMaterial()
const IntArray & giveTempCrackStatus()
double giveCrackStrain(int icrack) const
const FloatArray & giveLocalStrainVectorForAverage()
void setTempMode(__rcsdModeType mode)
This class implements associated Material Status to RCSDNLMaterial.
void buildNonlocalPointTable(GaussPoint *gp)
Builds list of integration points which take part in nonlocal average in given integration point...
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
void setDs0Matrix(FloatMatrix &mtrx)
virtual ~RCSDNLMaterialStatus()
virtual ~RCSDNLMaterial()
void giveStressDependentPartOfStrainVector(FloatArray &answer, GaussPoint *gp, const FloatArray &reducedStrainVector, TimeStep *tStep, ValueModeType mode)
Method for subtracting from reduced space strain vector its stress-independent parts (caused by tempe...
static void computePrincipalValDir(FloatArray &answer, FloatMatrix &dir, const FloatArray &s, stressStrainPrincMode mode)
Computes principal values and directions of stress or strain vector.
Class implementing an array of integers.
double giveTransitionEpsCoeff()
__rcsdModeType giveTempMode()
virtual void initTempStatus()
Initializes the temporary internal variables, describing the current state according to previously re...
virtual Interface * giveInterface(InterfaceType)
Interface requesting service.
void setEpsF2Coeff(double val)
static void giveFullSymVectorForm(FloatArray &answer, const FloatArray &vec, MaterialMode matMode)
Converts the reduced unsymmetric Voigt vector (2nd order tensor) to full form.
virtual Interface * giveInterface(InterfaceType t)
Interface requesting service.
IRResultType initializeFrom(InputRecord *ir)
This class implements associated Material Status to RCSDEMaterial.
double distance(const FloatArray &x) const
Computes the distance between position represented by receiver and position given as parameter...
virtual void printOutputAt(FILE *file, TimeStep *tStep)
Print receiver's output to given stream.
This class implements a Rotating Crack Model with transition to scalar damage for fracture in smeared...
virtual double give(int aProperty, GaussPoint *gp)
Returns the value of material property 'aProperty'.
#define _IFT_RCSDNLMaterial_gf
virtual void giveRealStressVector(FloatArray &answer, GaussPoint *, const FloatArray &, TimeStep *)
Computes the real stress vector for given total strain and integration point.
double ef
Strain at complete failure.
int givePackSize(DataStream &buff) const
void setLocalStrainVectorForAverage(FloatArray ls)
virtual void printOutputAt(FILE *file, TimeStep *tStep)
Print receiver's output to given stream.
RCSDNLMaterialStatus(int n, Domain *d, GaussPoint *g)
void times(double f)
Multiplies receiver by factor f.
std::vector< localIntegrationRecord > * giveIPIntegrationList(GaussPoint *gp)
Returns integration list corresponding to given integration point.
#define _IFT_RCSDNLMaterial_sdtransitioncoeff
contextIOResultType restoreYourself(DataStream &stream)
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
FloatArray tempNonlocalStrainVector
void beProductOf(const FloatMatrix &aMatrix, const FloatArray &anArray)
Receiver becomes the result of the product of aMatrix and anArray.
double computeDamageCoeff(double, double, double)
const FloatArray & giveCrackStrainVector() const
virtual void giveMaterialStiffnessMatrix(FloatMatrix &answer, MatResponseMode, GaussPoint *gp, TimeStep *tStep)
virtual int estimatePackSize(DataStream &buff, GaussPoint *ip)
Estimates the necessary pack size to hold all packed data of receiver.
virtual void updateBeforeNonlocAverage(const FloatArray &strainVector, GaussPoint *gp, TimeStep *tStep)
Implements the service updating local variables in given integration points, which take part in nonlo...
virtual double give(int aProperty, GaussPoint *gp)
Returns the value of material property 'aProperty'.
const FloatMatrix * giveDs0Matrix()
Class representing vector of real numbers.
#define _IFT_RCSDNLMaterial_ef
#define _IFT_RCSDNLMaterial_sdtransitioncoeff2
Implementation of matrix containing floating point numbers.
IRResultType
Type defining the return values of InputRecord reading operations.
void setTempDamageCoeff(double val)
void letTempStressVectorBe(const FloatArray &v)
Assigns tempStressVector to given vector v.
void setTempMaxEquivStrain(double val)
void giveRealPrincipalStressVector3d(FloatArray &answer, GaussPoint *, FloatArray &, FloatMatrix &, TimeStep *)
Base class for all nonlocal structural material statuses.
virtual int unpackAndUpdateUnknowns(DataStream &buff, TimeStep *tStep, GaussPoint *ip)
Unpack and updates all necessary data of given integration point (according to element parallel_mode)...
virtual void updateYourself(TimeStep *tStep)
Update equilibrium history variables according to temp-variables.
void times(double s)
Multiplies receiver with scalar.
double SDTransitionCoeff2
Nondimensional parameter controlling the transition between rc and sd model, with respect to shear st...
long ContextMode
Context mode (mask), defining the type of information written/read to/from context.
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Stores receiver state to output stream.
const FloatMatrix & giveTempCrackDirs()
InterfaceType
Enumerative type, used to identify interface type.
double giveIntegrationScale()
Returns associated integration scale.
int min(int i, int j)
Returns smaller value from two given decimals.
REGISTER_Material(DummyMaterial)
int giveSize() const
Returns the size of receiver.
the oofem namespace is to define a context or scope in which all oofem names are defined.
void setTempNonlocalStrainVector(FloatArray ls)
virtual void initTempStatus(GaussPoint *gp)
Initializes temporary variables stored in integration point status at the beginning of new time step...
double giveCharLength(int icrack) const
virtual double giveMinCrackStrainsForFullyOpenCrack(GaussPoint *gp, int i)
Class representing integration point in finite element program.
#define OOFEM_WARNING(...)
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Restores the receiver state previously written in stream.
Class representing solution step.
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Restores the receiver state previously written in stream.
void add(const FloatArray &src)
Adds array src to receiver.
virtual void updateCrackStatus(GaussPoint *gp, const FloatArray &crackStrain)
virtual double computeStrength(GaussPoint *, double)
double R
Interaction radius, related to the nonlocal characteristic length of material.
void resize(int s)
Resizes receiver towards requested size.