some questions about the class"TriaxialStressController"

Asked by Fu zuoguang

Dear Jan Stránský and Bruno Chareyre:
     Thanks for helping me yesterday, now I have downloaded "yade-0.95" as your suggestion and find that there are some obvious changes in the newest vision especially in classes for simulation controlling. I have Confused by them one more time and can hardly find a complete example that can include all the attributes about their applications. The only thing I can do is to write my puzzles here for seeking your help!
     The purpose of my simulation is the same as that the first time I communicated you. In this new vision, the class "TriaxialCompressionEngine" can help me achieve my wish but is different from the older class "ThreeDTriaxialEngine". It is significant for me to rewrite the "triax" in my script of which the first step is to understand how this class works.
     From the TriaxialCompressionEngine.hpp's expression, there are 3 basic steps that the class suggests me to follow, which can be described as that:
    (1). STATE_ISO_COMPACTION;
    (2). STATE_ISO_UNLOADING;
    (3). STATE_TRIAX_LOADING;
As I understand, these three steps can be achieved in turn by invoking only class "TriaxialCompressionEngine". But I can not really know how and there are almost no examples for explaining that.So I have wrote some command as that:

triax=TriaxialCompressionEngine(
     wall_bottom_id=wallIds[2],
     wall_top_id=wallIds[3],
     wall_left_id=wallIds[0],
     wall_right_id=wallIds[1],
     wall_back_id=wallIds[4],
     wall_front_id=wallIds[5],
     internalCompaction=False,
     sigmaIsoCompaction=50e3, # isotropic compaction (compression) until thesigmaIsoCompaction is reached.(the first step )
     sigmaLateralConfinement=50e2, # isotropic unloading from the previously reached state, until the mean pressure sigmaLateralConfinement is reached.(the second step)
     max_vel=10,
     strainRate=0.01,
     label="triax"
)

My first question is that why the simulation can not stop when the sigmaLateralConfinement is reached and the second one is that how can I do to finish the third step in this script.

SEEKING YOUR HELP!

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Hien Nguyen
Solved:
Last query:
Last reply:
Revision history for this message
wangxiaoliang (wangxiaoliang) said :
#1

either a lower version say 0.90.1 will do everything you need.

or u may rewrite by just a small changes, say goal1 goal2 goal3 stressMask?

good luck

Revision history for this message
Bruno Chareyre (bruno-chareyre) said :
#2

I suggest to forget STATE_ISO_UNLOADING and similar flags. It was too specific and so easy to break the algorithm.

Instead, check the triax-tutorial/script1.py and see how it is done with goals and stressMask. After 30min you should get the idea, and it will be a lot more flexible.

Revision history for this message
Best Hien Nguyen (giahien) said :
#3

Hi,
corcerning the triaxial test, for me I separated it into 2 steps:
Step 1: isotropic compression by moving wall, the code will be:

triax=TriaxialStressController(
 stressMask = 7,
 goal1=50e3,
 goal2=50e3,
 goal3=50e3,
 max_vel=5,
 internalCompaction=False,
)

And to check the equilibrium while compressing:

while 1:
  O.run(1000, True)
  unb=unbalancedForce()
  meanS=(triax.stress(triax.wall_right_id)[0]+triax.stress(triax.wall_top_id)[1]+triax.stress(triax.wall_front_id)[2])/3
  print 'unbalanced force:',unb,' mean stress: ',meanS
  if unb<stabilityThreshold and abs(meanS-50e3)/50e3<0.001:
    break

Then switch to step 2: deviatoric loading:

triax.stressMask = 5
triax.goal2=-0.05
triax.goal1=100000
triax.goal3=100000

And to stop the simulation you can put a stop condition following the discussion here:
https://answers.launchpad.net/yade/+question/224169

According to the code, we work only with (1) (code: while 1....), I dont' see any use of the state (3) here since with the stressMask we can more easily play with the "triaxial loading"
I just extract from the example code and modify a little to make it clearer, correct me if you find any fault.

Revision history for this message
Fu zuoguang (zgfu1985) said :
#4

Thanks Nguyen N.G. Hien, that solved my question.