59 if ( result !=
IRRT_OK )
return result;
104 trialStress.
beProductOf(elasticStiffness, trialElastStrain);
110 double effectiveTrialStress = sqrt(3 * J2);
113 double temperatureScaling = 1.0;
118 temperature = et.
at(1) + 800;
120 double temperatureScaling = temperature <= 400 ? 1.0 : 1.0 - (temperature - 400) * 0.5 / 400;
124 double k = status->
giveK();
125 double phiTrial = effectiveTrialStress - ( temperatureScaling * this->
sig0 + temperatureScaling *
H * k );
127 if ( phiTrial < 0.0 ) {
128 answer = trialStress;
133 double mu = phiTrial / ( 3.0 * G + temperatureScaling *
H );
134 answer = devTrialStress * ( 1.0 - 3.0*G*mu/effectiveTrialStress);
135 answer.
add(sphTrialStress);
141 plasticStrain.
add(mu * 3. / (2. * effectiveTrialStress), dPlStrain);
156 double volumetricPart = ( sigV.
at(1) + sigV.
at(2) + sigV.
at(3) ) / 3.0;
157 sigSph = {volumetricPart, volumetricPart, volumetricPart, 0.0, 0.0, 0.0};
167 answer.
at(1,1) = answer.
at(2,2) = answer.
at(3,3) = 2.0/3.0;
168 answer.
at(1,2) = answer.
at(1,3) = answer.
at(2,3) = -1.0/3.0;
169 answer.
at(2,1) = answer.
at(3,1) = answer.
at(3,2) = -1.0/3.0;
170 answer.
at(4,4) = answer.
at(5,5) = answer.
at(6,6) = 1.0/2.0;
181 double effectiveTrialStress = sqrt(3 * J2);
184 double temperatureScaling = 1.0;
189 temperature = et.
at(1) + 800;
191 double temperatureScaling = temperature <= 400 ? 1.0 : 1.0 - (temperature - 400) * 0.5 / 400;
195 double k = status->
giveK();
196 double phiTrial = effectiveTrialStress - ( temperatureScaling * this->
sig0 + temperatureScaling *
H * k );
201 if ( phiTrial < 0.0 ) {
202 answer = elasticStiffness;
207 double h = 3.0 * G + temperatureScaling *
H;
208 double mu = phiTrial / h;
210 FloatArray nu = (3.0/2.0 / effectiveTrialStress ) * devTrialStress;
214 correction.
plusDyadUnsym(nu, nu, 2.0 * G / h * ( temperatureScaling * this->
sig0 + temperatureScaling * H * k ));
215 correction.
add(mu * 3.0 * G, Idev);
216 correction.
times(2.0 * G / effectiveTrialStress);
217 answer = elasticStiffness;
227 answer = {alpha, alpha, alpha, 0., 0., 0.};
235 if ( type == IST_PlasticStrainTensor ) {
249 tempPlasticStrain(6), plasticStrain(6),
250 tempDevTrialStress(6),
FloatArray PVector
Equilibrated first Piola-Kirchhoff stress vector.
const FloatArray & giveTempDevTrialStress()
virtual void updateYourself(TimeStep *tStep)
Update equilibrium history variables according to temp-variables.
virtual void updateYourself(TimeStep *tStep)
Update equilibrium history variables according to temp-variables.
InternalStateType
Type representing the physical meaning of element or constitutive model internal variable.
void letTempStrainVectorBe(const FloatArray &v)
Assigns tempStrainVector to given vector v.
virtual MaterialStatus * giveStatus(GaussPoint *gp) const
Returns material status of receiver in given integration point.
static void applyDeviatoricElasticCompliance(FloatArray &strain, const FloatArray &stress, double EModulus, double nu)
#define _IFT_TutorialMaterial_yieldstress
FloatArray tempStrainVector
Temporary strain vector in reduced form (to find balanced state)
static void computeSphDevPartOf(const FloatArray &sigV, FloatArray &sigSph, FloatArray &sigDev)
virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
Returns the integration point corresponding value in Reduced form.
double & at(int i)
Coefficient access function.
FloatArray tempFVector
Temporary deformation gradient in reduced form (to find balanced state)
This class implements a structural material status information.
FloatArray stressVector
Equilibrated stress vector in reduced form.
Element * giveElement()
Returns reference to element containing receiver.
const FloatArray & givePlasticStrain()
double sig0
Initial (uniaxial) yield stress.
void plusDyadUnsym(const FloatArray &a, const FloatArray &b, double dV)
Adds to the receiver the product .
#define _IFT_TutorialMaterial_hardeningmoduli
TutorialMaterial(int n, Domain *d)
double giveShearModulus()
Returns the shear elastic modulus .
MatResponseMode
Describes the character of characteristic material matrix.
void beDifferenceOf(const FloatArray &a, const FloatArray &b)
Sets receiver to be a - b.
virtual ~TutorialMaterial()
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
Abstract base class for all "structural" finite elements.
FloatArray tempPlasticStrain
Temporary plastic strain (the given iteration)
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
virtual void giveRealStressVector_3d(FloatArray &answer, GaussPoint *gp, const FloatArray &reducedE, TimeStep *tStep)
Default implementation relies on giveRealStressVector for second Piola-Kirchoff stress.
virtual MaterialStatus * CreateStatus(GaussPoint *gp) const
Creates new copy of associated status and inserts it into given integration point.
virtual void give3dMaterialStiffnessMatrix(FloatMatrix &answer, MatResponseMode, GaussPoint *gp, TimeStep *tStep)
Computes full 3d material stiffness matrix at given integration point, time, respecting load history ...
FloatArray tempPVector
Temporary first Piola-Kirchhoff stress vector (to find balanced state)
virtual void initTempStatus()
Initializes the temporary internal variables, describing the current state according to previously re...
FloatArray plasticStrain
Last equilibriated plastic strain (end of last time step)
void times(double f)
Multiplies receiver by factor f.
void letTempDevTrialStressBe(const FloatArray &values)
void giveStressDependentPartOfStrainVector_3d(FloatArray &answer, GaussPoint *gp, const FloatArray &reducedStrainVector, TimeStep *tStep, ValueModeType mode)
virtual void giveThermalDilatationVector(FloatArray &answer, GaussPoint *gp, TimeStep *tStep)
Returns a vector of coefficients of thermal dilatation in direction of each material principal (local...
void beProductOf(const FloatMatrix &aMatrix, const FloatArray &anArray)
Receiver becomes the result of the product of aMatrix and anArray.
double at(int i, int j) const
Coefficient access function.
void letTempPlasticStrainBe(const FloatArray &values)
static void giveDeviatoricProjectionMatrix(FloatMatrix &answer)
IntegrationRule * giveIntegrationRule()
Returns corresponding integration rule to receiver.
void letTempKBe(double value)
void subtract(const FloatMatrix &a)
Subtracts matrix from the receiver.
Abstract base class representing a material status information.
Class representing vector of real numbers.
virtual void give3dMaterialStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, GaussPoint *gp, TimeStep *tStep)
Computes full 3d material stiffness matrix at given integration point, time, respecting load history ...
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
FloatArray strainVector
Equilibrated strain vector in reduced form.
Implementation of matrix containing floating point numbers.
IRResultType
Type defining the return values of InputRecord reading operations.
void letTempStressVectorBe(const FloatArray &v)
Assigns tempStressVector to given vector v.
virtual void giveInputRecord(DynamicInputRecord &input)
Setups the input record string of receiver.
void resize(int rows, int cols)
Checks size of receiver towards requested bounds.
static double computeSecondStressInvariant(const FloatArray &s)
FloatArray FVector
Equilibrated deformation gradient in reduced form.
void add(const FloatMatrix &a)
Adds matrix to the receiver.
void zero()
Zeroes all coefficients of receiver.
virtual void giveInputRecord(DynamicInputRecord &ir)
Setups the input record string of receiver.
IsotropicLinearElasticMaterial D
Abstract base class for all "structural" constitutive models.
void zero()
Zeroes all coefficient of receiver.
Domain * giveDomain() const
virtual void giveInputRecord(DynamicInputRecord &input)
Setups the input record string of receiver.
virtual double give(int aProperty, GaussPoint *gp)
Returns the value of material property 'aProperty'.
REGISTER_Material(DummyMaterial)
the oofem namespace is to define a context or scope in which all oofem names are defined.
virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
Returns the integration point corresponding value in Reduced form.
FloatArray tempStressVector
Temporary stress vector in reduced form (increments are used mainly in nonlinear analysis) ...
Class representing integration point in finite element program.
double H
Hardening modulus.
Class representing solution step.
void add(const FloatArray &src)
Adds array src to receiver.
FloatArray tempDevTrialStress
TutorialMaterialStatus(int n, Domain *d, GaussPoint *g)
void resize(int s)
Resizes receiver towards requested size.