From 3be45727f69500dc6487f1c039bcfd89653a1095 Mon Sep 17 00:00:00 2001 From: cyrielle <l.noels@ulg.ac.be> Date: Tue, 29 Apr 2025 13:26:53 +0200 Subject: [PATCH] try push within ssh protocol --- dG3D/src/dG3DMaterialLaw.cpp | 12 ++++++------ dG3D/src/nonLocalDamageDG3DMaterialLaw.cpp | 4 ++++ 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/dG3D/src/dG3DMaterialLaw.cpp b/dG3D/src/dG3DMaterialLaw.cpp index 48855bd72..44a882b2d 100644 --- a/dG3D/src/dG3DMaterialLaw.cpp +++ b/dG3D/src/dG3DMaterialLaw.cpp @@ -260,7 +260,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV { ipvcur->getConstRefToDLocalVariableDStrain()[k].print("dpdE Analyique"); } - /*if (this->getMacroSolver() != NULL) + if (this->getMacroSolver() != NULL) { if (this->getMacroSolver()!=NULL) { @@ -268,7 +268,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV ipvcur->getConstRefToDIrreversibleEnergyDDeformationGradient().print("dEnedE Analytique"); } } - }*/ + } for (int i=0; i< numNonLocalVars; i++) { for (int j=0; j< numNonLocalVars; j++) @@ -276,7 +276,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV Msg::Info("dpdp Analytique: %e",ipvcur->getConstRefToDLocalVariableDNonLocalVariable()(j,i)); } ipvcur->getConstRefToDStressDNonLocalVariable()[i].print("dPdp Analytique"); - //Msg::Info("dEnedp Analytique: %e",ipvcur->getConstRefToDIrreversibleEnergyDNonLocalVariable(i)); + Msg::Info("dEnedp Analytique: %e",ipvcur->getConstRefToDIrreversibleEnergyDNonLocalVariable(i)); /*for (unsigned int j = 0; j < numCurlDof; ++j) { @@ -634,12 +634,12 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV { ipvcur->getConstRefToDLocalVariableDStrain()[k].print("dpdE Numerique"); } - /*if (this->getMacroSolver() != NULL) + if (this->getMacroSolver() != NULL) { if (this->getMacroSolver()->withPathFollowing() and this->getMacroSolver()->getPathFollowingMethod() == pathFollowingManager::LOCAL_BASED){ ipvcur->getConstRefToDIrreversibleEnergyDDeformationGradient().print("dEnedE Numerique"); } - }*/ + } for (int i=0; i< numNonLocalVars; i++) { for (int j=0; j< numNonLocalVars; j++) @@ -647,7 +647,7 @@ void dG3DMaterialLawWithTangentByPerturbation::stress(IPVariable* ipv, const IPV Msg::Info("dpdp Numerique: %e",ipvcur->getConstRefToDLocalVariableDNonLocalVariable()(j,i)); } ipvcur->getConstRefToDStressDNonLocalVariable()[i].print("dPdp Numerique"); - //Msg::Info("dEnedp Numerique: %e",ipvcur->getConstRefToDIrreversibleEnergyDNonLocalVariable(i)); + Msg::Info("dEnedp Numerique: %e",ipvcur->getConstRefToDIrreversibleEnergyDNonLocalVariable(i)); /*const unsigned int extradof_T = 0; // Thermal field EM source for (unsigned int j = 0; j < numCurlDof; ++j) diff --git a/dG3D/src/nonLocalDamageDG3DMaterialLaw.cpp b/dG3D/src/nonLocalDamageDG3DMaterialLaw.cpp index 04add7ee1..cc869bf04 100644 --- a/dG3D/src/nonLocalDamageDG3DMaterialLaw.cpp +++ b/dG3D/src/nonLocalDamageDG3DMaterialLaw.cpp @@ -4194,6 +4194,10 @@ void NonlocalDamageTorchANNBasedDG3DMaterialLaw::stress(IPVariable* ipv, const I plasticEnergy+=S_rec(i,j)*(Eplast_rec(i,j)-Eplast_rec0(i,j)); } } + if (plasticEnergy<ipvprev->getConstRefToPlasticEnergy()){ + //std::cout << "warning: the plastic energy decreases" << "\n"; + //plasticEnergy=ipvprev->getConstRefToPlasticEnergy(); + } //beginning step 9.2: computation of the damage energy -- GitLab