55 template <
class TConstLawIntegratorType>
64 static constexpr
SizeType Dimension = TConstLawIntegratorType::Dimension;
67 static constexpr
SizeType VoigtSize = TConstLawIntegratorType::VoigtSize;
79 static constexpr
double tolerance = std::numeric_limits<double>::epsilon();
80 static constexpr
double threshold_tolerance = 1.0e-5;
97 const double PreviousStress0,
98 const double PreviousStress1,
99 const double MaxStress,
100 const double MinStress,
101 const unsigned int NumberOfCyclesGlobal,
102 const double FatigueReductionParameter)
104 mFatigueReductionFactor = FatigueReductionFactor;
106 PreviousStresses[0] = PreviousStress0;
107 PreviousStresses[1] = PreviousStress1;
108 mPreviousStresses = PreviousStresses;
109 mMaxStress = MaxStress;
110 mMinStress = MinStress;
111 mNumberOfCyclesGlobal = NumberOfCyclesGlobal;
112 mFatigueReductionParameter = FatigueReductionParameter;
117 ConstitutiveLaw::Pointer
Clone()
const override
119 return Kratos::make_shared<GenericSmallStrainHighCycleFatigueLaw<TConstLawIntegratorType>>(*this);
127 mFatigueReductionFactor(rOther.mFatigueReductionFactor),
128 mPreviousStresses(rOther.mPreviousStresses),
129 mMaxStress(rOther.mMaxStress),
130 mMinStress(rOther.mMinStress),
131 mPreviousMaxStress(rOther.mPreviousMaxStress),
132 mPreviousMinStress(rOther.mPreviousMinStress),
133 mNumberOfCyclesGlobal(rOther.mNumberOfCyclesGlobal),
134 mNumberOfCyclesLocal(rOther.mNumberOfCyclesLocal),
135 mFatigueReductionParameter(rOther.mFatigueReductionParameter),
136 mStressVector(rOther.mStressVector),
137 mMaxDetected(rOther.mMaxDetected),
138 mMinDetected(rOther.mMinDetected),
139 mWohlerStress(rOther.mWohlerStress)
259 const double& rValue,
270 bool& rValue)
override;
281 int& rValue)
override;
291 double& rValue)
override;
300 double& CalculateValue(
303 double& rValue)
override;
410 Vector GetStressVector() {
return mStressVector;}
411 void SetStressVector(
const Vector& toStressVector) {mStressVector = toStressVector;}
415 double mFatigueReductionFactor = 1.0;
417 double mMaxStress = 0.0;
418 double mMinStress = 0.0;
419 double mPreviousMaxStress = 0.0;
420 double mPreviousMinStress = 0.0;
421 unsigned int mNumberOfCyclesGlobal = 1;
422 unsigned int mNumberOfCyclesLocal = 1;
423 double mFatigueReductionParameter = 0.0;
425 bool mMaxDetected =
false;
426 bool mMinDetected =
false;
427 double mWohlerStress = 1.0;
428 double mThresholdStress = 0.0;
429 double mReversionFactorRelativeError = 0.0;
430 double mMaxStressRelativeError = 0.0;
431 bool mNewCycleIndicator =
false;
432 double mCyclesToFailure = 0.0;
433 double mPreviousCycleTime = 0.0;
434 double mPeriod = 0.0;
452 void save(
Serializer &rSerializer)
const override
455 rSerializer.
save(
"FatigueReductionFactor", mFatigueReductionFactor);
456 rSerializer.
save(
"PreviousStresses", mPreviousStresses);
457 rSerializer.
save(
"MaxStress", mMaxStress);
458 rSerializer.
save(
"MinStress", mMinStress);
459 rSerializer.
save(
"PreviousMaxStress", mPreviousMaxStress);
460 rSerializer.
save(
"PreviousMinStress", mPreviousMinStress);
461 rSerializer.
save(
"NumberOfCyclesGlobal", mNumberOfCyclesGlobal);
462 rSerializer.
save(
"NumberOfCyclesLocal", mNumberOfCyclesLocal);
463 rSerializer.
save(
"FatigueReductionParameter", mFatigueReductionParameter);
464 rSerializer.
save(
"StressVector", mStressVector);
465 rSerializer.
save(
"MaxDetected", mMaxDetected);
466 rSerializer.
save(
"MinDetected", mMinDetected);
467 rSerializer.
save(
"WohlerStress", mWohlerStress);
468 rSerializer.
save(
"ThresholdStress", mThresholdStress);
469 rSerializer.
save(
"ReversionFactorRelativeError", mReversionFactorRelativeError);
470 rSerializer.
save(
"MaxStressRelativeError", mMaxStressRelativeError);
471 rSerializer.
save(
"NewCycleIndicator", mNewCycleIndicator);
472 rSerializer.
save(
"CyclesToFailure", mCyclesToFailure);
473 rSerializer.
save(
"PreviousCycleTime", mPreviousCycleTime);
474 rSerializer.
save(
"Period", mPeriod);
480 rSerializer.
load(
"FatigueReductionFactor", mFatigueReductionFactor);
481 rSerializer.
load(
"PreviousStresses", mPreviousStresses);
482 rSerializer.
load(
"MaxStress", mMaxStress);
483 rSerializer.
load(
"MinStress", mMinStress);
484 rSerializer.
load(
"PreviousMaxStress", mPreviousMaxStress);
485 rSerializer.
load(
"PreviousMinStress", mPreviousMinStress);
486 rSerializer.
load(
"NumberOfCyclesGlobal", mNumberOfCyclesGlobal);
487 rSerializer.
load(
"NumberOfCyclesLocal", mNumberOfCyclesLocal);
488 rSerializer.
load(
"FatigueReductionParameter", mFatigueReductionParameter);
489 rSerializer.
load(
"StressVector", mStressVector);
490 rSerializer.
load(
"MaxDetected", mMaxDetected);
491 rSerializer.
load(
"MinDetected", mMinDetected);
492 rSerializer.
load(
"WohlerStress", mWohlerStress);
493 rSerializer.
load(
"ThresholdStress", mThresholdStress);
494 rSerializer.
load(
"ReversionFactorRelativeError", mReversionFactorRelativeError);
495 rSerializer.
load(
"MaxStressRelativeError", mMaxStressRelativeError);
496 rSerializer.
load(
"NewCycleIndicator", mNewCycleIndicator);
497 rSerializer.
load(
"CyclesToFailure", mCyclesToFailure);
498 rSerializer.
load(
"PreviousCycleTime", mPreviousCycleTime);
499 rSerializer.
load(
"Period", mPeriod);
Definition: constitutive_law.h:47
virtual bool Has(const Variable< bool > &rThisVariable)
Returns whether this constitutive Law has specified variable (boolean)
Definition: constitutive_law.cpp:128
virtual void SetValue(const Variable< bool > &rVariable, const bool &Value, const ProcessInfo &rCurrentProcessInfo)
Sets the value of a specified variable (boolean)
Definition: constitutive_law.cpp:279
virtual bool & GetValue(const Variable< bool > &rThisVariable, bool &rValue)
Returns the value of a specified variable (boolean)
Definition: constitutive_law.cpp:201
This class is the base class which defines the constitutive law used for high cycle fatigue (HCF) in ...
Definition: generic_small_strain_high_cycle_fatigue_law.h:58
Geometry< NodeType > GeometryType
The geometry definition.
Definition: generic_small_strain_high_cycle_fatigue_law.h:76
bool RequiresFinalizeMaterialResponse() override
If the CL requires to initialize the material response, called by the element in InitializeSolutionSt...
Definition: generic_small_strain_high_cycle_fatigue_law.h:329
Node NodeType
The node definition.
Definition: generic_small_strain_high_cycle_fatigue_law.h:73
GenericSmallStrainHighCycleFatigueLaw(const double FatigueReductionFactor, const double PreviousStress0, const double PreviousStress1, const double MaxStress, const double MinStress, const unsigned int NumberOfCyclesGlobal, const double FatigueReductionParameter)
Definition: generic_small_strain_high_cycle_fatigue_law.h:96
GenericSmallStrainIsotropicDamage< TConstLawIntegratorType > BaseType
Definition of the base class.
Definition: generic_small_strain_high_cycle_fatigue_law.h:83
GenericSmallStrainHighCycleFatigueLaw()
Definition: generic_small_strain_high_cycle_fatigue_law.h:92
GenericSmallStrainHighCycleFatigueLaw(const GenericSmallStrainHighCycleFatigueLaw &rOther)
Definition: generic_small_strain_high_cycle_fatigue_law.h:125
~GenericSmallStrainHighCycleFatigueLaw() override
Definition: generic_small_strain_high_cycle_fatigue_law.h:146
KRATOS_CLASS_POINTER_DEFINITION(GenericSmallStrainHighCycleFatigueLaw)
Counted pointer of GenericYieldSurface.
bool RequiresInitializeMaterialResponse() override
If the CL requires to initialize the material response, called by the element in InitializeSolutionSt...
Definition: generic_small_strain_high_cycle_fatigue_law.h:321
ConstitutiveLaw::Pointer Clone() const override
Definition: generic_small_strain_high_cycle_fatigue_law.h:117
This class is the base class which define all the constitutive laws for damage in small deformation.
Definition: generic_small_strain_isotropic_damage.h:58
Geometry base class.
Definition: geometry.h:71
This class defines the node.
Definition: node.h:65
ProcessInfo holds the current value of different solution parameters.
Definition: process_info.h:59
The serialization consists in storing the state of an object into a storage format like data file or ...
Definition: serializer.h:123
void load(std::string const &rTag, TDataType &rObject)
Definition: serializer.h:207
void save(std::string const &rTag, std::array< TDataType, TDataSize > const &rObject)
Definition: serializer.h:545
Variable class contains all information needed to store and retrive data from a data container.
Definition: variable.h:63
#define KRATOS_SERIALIZE_SAVE_BASE_CLASS(Serializer, BaseType)
Definition: define.h:812
#define KRATOS_SERIALIZE_LOAD_BASE_CLASS(Serializer, BaseType)
Definition: define.h:815
bool Has(const std::string &ModelerName)
Checks if the modeler is registered.
Definition: modeler_factory.cpp:24
Parameters GetValue(Parameters &rParameters, const std::string &rEntry)
Definition: add_kratos_parameters_to_python.cpp:53
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
KratosZeroVector< double > ZeroVector
Definition: amatrix_interface.h:561
Internals::Matrix< double, AMatrix::dynamic, 1 > Vector
Definition: amatrix_interface.h:472
std::size_t SizeType
The definition of the size type.
Definition: mortar_classes.h:43
def SetValue(entity, variable, value)
Definition: coupling_interface_data.py:256
def load(f)
Definition: ode_solve.py:307
Definition: constitutive_law.h:189