Skip to content
Snippets Groups Projects
Commit 677bfaf7 authored by Ujwal Kishore Jinaga's avatar Ujwal Kishore Jinaga :clown:
Browse files

[MINOR FIX] Corrected the rotated tangent if dqdgradt in TMDMN. Changed getRef...

[MINOR FIX] Corrected the rotated tangent if dqdgradt in TMDMN. Changed getRef functions to getConstRef functions when getting tangents from materials.
parent 112cafed
No related branches found
No related tags found
No related merge requests found
......@@ -294,7 +294,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV
ipvcur->getConstRefTodElecDisplacementdNonLocalVariable()[j][i].print("dElecDisplacement dp Analytique");
}*/
}
/*for (int i=0; i< numExtraDof; i++)
for (int i=0; i< numExtraDof; i++)
{
Msg::Info("Field Analytique: %e",ipvcur->getConstRefToField(i)); // FLE
ipvcur->getConstRefToFlux()[i].print("Flux Analytique"); // FLE
......@@ -374,7 +374,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV
ipvcur->getRefTodLocalVariabledVectorPotential()[k][i].print("dp dMagneticVectorPotential Analytique");
ipvcur->getRefTodLocalVariabledVectorCurl()[k][i].print("dp dMagneticVectorCurl Analytique");
}
}*/
}
 
#endif
if (stiff)
......@@ -666,7 +666,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV
ipvcur->getConstRefTodElecDisplacementdNonLocalVariable()[j][i].print("dElecDisplacement dp Numerique");
}*/
}
/*for (int i=0; i< numExtraDof; i++)
for (int i=0; i< numExtraDof; i++)
{
Msg::Info("Field Numerique: %e",ipvcur->getConstRefToField(i)); // FLE
ipvcur->getConstRefToFlux()[i].print("Flux Numerique"); // FLE
......@@ -746,7 +746,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV
ipvcur->getRefTodLocalVariabledVectorPotential()[k][i].print("dp dMagneticVectorPotential Numerique");
ipvcur->getRefTodLocalVariabledVectorCurl()[k][i].print("dp dMagneticVectorCurl Numerique");
}
}*/
}
#endif
}
}
......@@ -5915,14 +5915,14 @@ void StochTMDMNDG3DMaterialLaw::stress(IPVariable*ipv, const IPVariable*ipvprev,
 
if(stiff_loc){
const STensor43& L_i = ipv_i->getConstRefToTangentModuli();
const STensor3& dPdT_i = ipv_i->getRefTodPdT();
const STensor3& dqdgradT_i = ipv_i->getRefTodThermalFluxdGradT();
const SVector3& dqdT_i = ipv_i->getRefTodThermalFluxdT();
const STensor33& dqdF_i = ipv_i->getRefTodThermalFluxdF();
const double& dwdt_i = ipv_i->getRefTodThermalSourcedField();
const STensor3& dwdf_i = ipv_i->getRefTodThermalSourcedF(); STensorOperation::zero(dwdf);
const double& dmechSourcedt_i = ipv_i->getRefTodMechanicalSourcedField()(0,0);
const STensor3& dmechSourcedf_i = ipv_i->getRefTodMechanicalSourcedF()[0];
const STensor3& dPdT_i = ipv_i->getConstRefTodPdT();
const STensor3& dqdgradT_i = ipv_i->getConstRefTodThermalFluxdGradT();
const SVector3& dqdT_i = ipv_i->getConstRefTodThermalFluxdT();
const STensor33& dqdF_i = ipv_i->getConstRefTodThermalFluxdF();
const double& dwdt_i = ipv_i->getConstRefTodThermalSourcedField();
const STensor3& dwdf_i = ipv_i->getConstRefTodThermalSourcedF(); STensorOperation::zero(dwdf);
const double& dmechSourcedt_i = ipv_i->getConstRefTodMechanicalSourcedField()(0,0);
const STensor3& dmechSourcedf_i = ipv_i->getConstRefTodMechanicalSourcedF()[0];
 
if (_flag_isothermal && _flag_microTempFixed){
dwdtvec(i) = 0.;
......@@ -6162,15 +6162,18 @@ void StochTMDMNDG3DMaterialLaw::stress(IPVariable*ipv, const IPVariable*ipvprev,
for(int l=0; l<3; l++)
I4_first_type(m,n,k,l) = I2(m,k)*I2(n,l); // = dFrotdFrot
 
static STensor3 dHdH_rot; STensorOperation::zero(dHdH_rot);
static STensor43 dFdF_rot; STensorOperation::zero(dFdF_rot);
for(int m=0; m<3; m++)
for(int n=0; n<3; n++)
for(int k=0; k<3; k++)
for(int k=0; k<3; k++){
dHdH_rot(m,n) += RT(m,k)*I2(k,n);
for(int l=0; l<3; l++){
dFdF_rot(m,n,k,l) = 0.;
for(int p=0; p<3; p++)
dFdF_rot(m,n,k,l) += RT(m,p)*I4_first_type(p,n,k,l);
}
}
static STensor43 L_rot;
static STensor33 dqdF_rot;
......@@ -6178,7 +6181,7 @@ void StochTMDMNDG3DMaterialLaw::stress(IPVariable*ipv, const IPVariable*ipvprev,
STensorOperation::multSTensor43InPlace(L,dFdF_rot);
STensorOperation::multSTensor33STensor43InPlace1st(dqdF,dFdF_rot);
STensorOperation::multSTensor3STensor43InPlace1st(dqdgradT,dFdF_rot);
STensorOperation::multSTensor3InPlace1st(dqdgradT,dHdH_rot);
STensorOperation::multSTensor3STensor43(dwdf,dFdF_rot,dwdf_rot);
STensorOperation::multSTensor3STensor43(dmechSourcedf,dFdF_rot,dmechSourcedf_rot);
for(int i=0; i<3; i++)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment