Closed rfaasse closed 4 months ago
Richard, a very useful step to improve the structure and to make functions more uniform. However, for my understand of the code it will be useful to split CalculateAnyOfMaterialResponse into three functions. What is your opinion? It can be next PR.
@markelov208 I fully agree with this observation and would have preferred 3 functions as well (I would really like to decouple this). However, we are bound by the Constitutive Law interface which does all three at the same time in the CalculateMaterialResponseCauchy
via the ConstitutiveLaw::Parameters&, so at this moment, I don't see a way to achieve this without doing the same calculation multiple times.
📝 Description This PR extracts lists for constitutive matrices and stress vectors. In doing so we add two identical functions to diff order and to the non-diff order element, but we reduce a lot of other duplicated code. If anyone has ideas how to extract something generic here, please let me know. I think it would mean we need to pass on the constitutive laws and maybe make a vector of constitutive parameters and pass that on to make a separate utility function, but that's open for discussion.