Tutorial example script 04-periodic-simple-shear.py does not work

Asked by Rioual


I face the same problem as Jan in 2016 concerning 2 bugs in Tutorial example script 04-periodic-simple-shear.py.
These bugs were reported as https://bugs.launchpad.net/yade/+bug/1634434
if stress.trace()/3.<limitMeanStress:
limitMeanStress is given a negative value (that's expected )

and stress.trace is positive and is increasing with time so the condition (L75) is never fulfilled.

Furthermore, it gives ZeroDivisionError in the beginning
and stress[2,2] is taking zero value at the beginning.

Was there improvements on the example script since with respect to these bugs ??
The film shown in the example can not for this reason be reproduced.

Thank you for your input,


Question information

English Edit question
Yade Edit question
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Robert Caulk (rcaulk) said :

Have you tried only adding plot data if stress[2,2] != 0?

Revision history for this message
Rioual (francois-rioual-v) said :

Hi Robert,

That's ok for the second error, thanks.
My worry concerns more the first error
 of the script..



Revision history for this message
Robert Caulk (rcaulk) said :

I'm sorry buy I cannot locate the script you are referring to. A link would be helpful. Or a minimal working example. [1]


Revision history for this message
Chareyre (bruno-chareyre-9) said :
Revision history for this message
Rioual (francois-rioual-v) said :

...Thanks Bruno, the script is running now.

I have two other questions:

1- the maximum rotation represented by red colors appear at the top and the bottom of the cell in the corrected script that you sent whereas in the example of YADE tutorial (https://yade-dem.org/doc/tutorial-examples.html#periodic-simple-shear) the colored layer representing high rotations is in the middle of the cell.....???

2- On a more fundamental point of view, I would like to know the point of studying a numerical periodic shear configuration that is far from the real experimental shear devices where we have shear localisation etc...
Is it to be able to relate stress and strain rates on a representative volume element (RVE) and deduce for instance effective quantities as viscosities etc... for continuum theories ????
Sorry this is not a directly yade related query but you would be welcome to bring me any light....



Revision history for this message
Chareyre (bruno-chareyre-9) said :

You are welcome.
For 1/ I don't know what colors are supposed to show.
2/ If it was possible to impose 3D PBCs experimentally we would surely do
it (in fact it is in possible in one direction in Couette cells for
instance) since it minimizes boundary effects. But it is not possible. That
is why we use rigid walls, membranes, and other non-periodic BCs.

Can you help with this problem?

Provide an answer of your own, or ask Rioual for more information if necessary.

To post a message you must log in.