thelfer / MFrontGenericInterfaceSupport

This project aims at providing support for MFront generic behaviours. This project can be embedded in open-source and propriary sofware
37 stars 35 forks source link

Commands for Obtaining Calculation Results #114

Open tiantian0347 opened 1 year ago

tiantian0347 commented 1 year ago

Hello,what command should I use to update the calculated values of external variables in a Python program? And what command should I use to call the results calculated in tangenerator, such as @ Integrator and @ DissipatedEnergy?

thelfer commented 1 year ago

Hi, The setExternalStateVariable method is here for that. You have various examples in the tests. See IntegrationTest5.py for instance. The tangent operator is available through the MaterialDataManager in the K member, the other through the MaterialStateManager in stored_energies and dissipated_energies members.

tiantian0347 commented 1 year ago

Thanks for your answer. May I ask what is the difference between m.s1. gradients [0:] and m.s1. gradients [1:]? Why are there two? What would happen if I only assigned one value? And why does updating (m) after integrate result in the value of m.K becoming 0? What is the difference between update and not update?

thelfer commented 10 months ago

@tiantian0347 Sorry for not responding, I did not see your question. Did you find the anwsers ?

tiantian0347 commented 10 months ago

Hi, Thanks for your reply, it was very helpful to me. I will learn this test and contact you if I have any questions.

Best wishes. ---- Replied Message ---- | From | Thomas @.> | | Date | 06/05/2023 16:44 | | To | thelfer/MFrontGenericInterfaceSupport @.> | | Cc | 田甜 @.>, Author @.> | | Subject | Re: [thelfer/MFrontGenericInterfaceSupport] Commands for Obtaining Calculation Results (Issue #114) |

Hi, The setExternalStateVariable method is here for that. You have various examples in the tests. See IntegrationTest5.py for instance. The tangent operator is available through the MaterialDataManager in the K member, the other through the MaterialStateManager in stored_energies and dissipated_energies members.

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

thelfer commented 10 months ago

Ok, let me know if you have any trouble