Hi,
I am trying to change the soil parameters of a soil already present in the Plaxis Model using Python and V22 (new material database).
How do you have to address the parameter in order to change the value? For example, if I try to change E50Ref for an exisiting soil, I am able to show the value with soil.E50Ref (with soil being the Plaxis soilmat object), but I am not able to change this parameter, either by "soil.E50Ref = " , by soil.set("E50Ref", ), or by soil.setproperties( ).
Changing the name is possible by Soil.Name = ""
What is the correct way to change strength/stiffness parameters of an already existing soil within the model? For now I am creating new soil materials and defining polygons with the new materials, but changing the material parameter itself might be easier.
Thanks in advance,
Christian
Dear Christian,
In V22 any change on the GUI results in an immediate change on the command line. If you try it you can see that the set command is used.
The setproperties can also be used but please check for the correct syntax. You can check our Scripting reference for examples.
Answer Verified By: Christian Rasch
Dear Steafonos,
Thank you for your quick response.
I think I also addressed to material object the wrong way. The setproperties method fits best in my case, as I'm also able to use the parameter as a variable (str). By searching the material based on the name en given the parameter to change I'm able to change the value.This method works fine in my case
material_to_change = None for material in g_i.Materials: if material.Identification == "Zand, schoon, matig": material_to_change = material parameter_to_change = "E50Ref" value = 60000 if material_to_change: g_i.setproperties(material_to_change, parameter_to_change, value)
Thanks