LightForm-group/UoM-CSF-matflow

Using 'generate_load_case' task with method 'random_2D' is there a way to specify which principle component is Zero?

Closed this issue · 2 comments

Hi all,

Describe the problem
I am running a Damask simulation and want the stress in 2D (one of the principle stress components is zero). I want to run the simulation many times with different combinations of the 2 non-zero stress components to fit and plot a yield function. When I use task: 'generate_load_case' task with method: 'random_2D' a different principle stress component is zero for each repeat (e.g. 1st sim its component 2, the next its component 3 etc...) which means I wouldn't be able to plot the points onto a 2D graph.

Expected behavior
The task might be working as intended but I wanted to be able to set the zero stress component in a 2D stress state Damask simulation. Does anyone know how I can do this with matflow?

Output from matflow validate
N/A

Workflow directory and/or profile location
/mnt/eps01-rds/Fonseca-Lightform/shared/matflow-debugging/fit_yield_function_Brass_Texture_2D_test_2021-02-01-092448

Thanks in advance,
Elliot

Thanks for the issue Elliot.

When I use task: 'generate_load_case' task with method: 'random_2D' a different principle stress component is zero for each repeat (e.g. 1st sim its component 2, the next its component 3 etc...) which means I wouldn't be able to plot the points onto a 2D graph.

I'm not sure I follow. Looking at the load.load files for the first three simulations (of task 8), they all are something like:

F (1+a) b 0 c (1+d) 0 0 0 * P * * * * * * * * 0 with small a, b, c, d, which should ensure an average zero stress in the z-direction, shouldn't it?

Maybe this is an issue with how the stress states are plotted in formable?

I was using from formable.maths_utils import get_principal_values but that sorts the principle values largest to smallest which was the problem. It's all sorted now thanks Adam!