Closed jrubiogonzalez closed 4 years ago
I'll add @AlejandroCornejo just in case he knows something
It is stranger in Linux but if you run (at least in fedora) the test enough times it ends up failing
Does it use openmp? it may be a race condition...
Finite strain are my fault, many operations are involved, may be my fault
I thought the same, but OpenMP inside a constitutive law... Please check you can reproduce the issue
My be a memory issue, finite strain makes mandatory backup intermediate values which are restores later in the values of the CL, as using pure references and raw pointers may be memory problematic
We should use valgrind
I attached the file with the valgrind output, not very clear
Valgrind is never clear :P
Valgrind is never clear :P
Looks like a bug in the constitutive law utilities, I will check tonight
I think I found the error, back stress vector is used unitialized in both finite_strains and small_strains kinematic plasticity CL.
Hi, I'm going to check what @ddiezrod says, one sec
Here for example (its copied in many places) https://github.com/KratosMultiphysics/Kratos/blob/b6212cf7c7ce0c5f9c4b4a7514fb12615444e8e8/applications/StructuralMechanicsApplication/custom_advanced_constitutive/generic_finite_strain_kinematic_plasticity.cpp#L129
It is used later inside the integrator when you compute the plastic denominator
yes, I think It is smthg wrong with this CL, working on it
yes, I think It is smthg wrong with this CL, working on it
Ok, if you do
Vector back_stress_vector = ZeroVector(VoigtZise)
tests pass
Sure but the algorithm should track the value of the BackStress historically... I forgot to create as member variable
I've done some changes in https://github.com/KratosMultiphysics/Kratos/pull/5871 I've run the tests and they run (maybe yo could run them just in case). As you were saying, the Back stress vector should be historical and I forgot to create the member variable.
I think this can be closed with #5871 and #5878 . Just to mention it #5835
When running QA, it is failing randomly specially in windows, but sometimes also in Liunux (Fedora). The failing test is
Ran 849 of 850 test cases in 2.45259s. 1 failed: TestConstitutiveLawIntegrateStressPlasticityFiniteStrainKinematic Failed with message: Error: Check failed because vector VMres with values [-1.80942e+07, -1.80942e+07, -1.80036e+07, 0, 0, 0] Is not near vector TestVM with values 6 Mismatch found in component 0: -1.80942e+07 not near -1.76859e+07 within relative tolerance 0.0001.
In fact both included in the same file fail alternatively
I went thorug valgrind adding unly this test and this is the output. valgrind_salida_kinematic_plasticity_constitutive_laws.txt
Looks like an uninitalised variable. @pooyan-dadvand @roigcarlo @RiccardoRossi @ipouplana @ddiezrod