From 2f6219a9c79e0f9d8ac52f75c3e305eabb1e34e6 Mon Sep 17 00:00:00 2001 From: FEA-eng <59876896+FEA-eng@users.noreply.github.com> Date: Sat, 2 Mar 2024 17:03:44 +0100 Subject: [PATCH] Update material_mechanicalnonlinear.py --- src/Mod/Fem/femobjects/material_mechanicalnonlinear.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Mod/Fem/femobjects/material_mechanicalnonlinear.py b/src/Mod/Fem/femobjects/material_mechanicalnonlinear.py index 7d56f122ebb6..a616b3410d81 100644 --- a/src/Mod/Fem/femobjects/material_mechanicalnonlinear.py +++ b/src/Mod/Fem/femobjects/material_mechanicalnonlinear.py @@ -91,6 +91,11 @@ def add_properties(self, obj): obj.MaterialModelNonlinearity = choices_nonlinear_material_models obj.MaterialModelNonlinearity = choices_nonlinear_material_models[0] + if hasattr(obj, "MaterialModelNonlinearity") and obj.MaterialModelNonlinearity == "simple hardening": + updated_choices_nonlinear_material_models = ["isotropic hardening", "kinematic hardening"] + obj.MaterialModelNonlinearity = updated_choices_nonlinear_material_models + obj.MaterialModelNonlinearity = updated_choices_nonlinear_material_models[0] + if not hasattr(obj, "YieldPoints"): obj.addProperty( "App::PropertyStringList",